If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Filtering on a specific list on a join query

Started by BigOCombe, 06 May 2013 11:37:34 AM

Previous topic - Next topic

BigOCombe

Hello Group,

Here is what I am looking to do. I have a sales query and a inventory query and I am joining on part id. I have a specific list of 100 part id's that I want to use. I don't want to have to maintain the list in both the sales query and the inventory query, is there a way to add the list of 100 part id's to the final query without having to key them in one by one?

Thanks!

the_xxx

You can use a detailed filter in the final query using in condition (Ex: Part_id in ('1','2','3','4'....). I hope this helps.

BigOCombe

the_xxx

This still requires a manual entry of each Part_id correct? If not, maybe I am not sure how the in condition works.
If I am just using a simple sales query I can copy a list of Part_id's from Excel and past it into the filter without having to key in each individual sku. I am trying to replicate this same type of process with a join query and on the final query. I hope this makes sense. What I am trying to accomplish is to not have to keep the list updated in both a inventory query and a sales query.

Thanks!

Michael75

BigOCombe, try this:

1. Create a new query PartNosToInclude which has one column, Part_Id, and populate this from your Excel (or whatever)

2. Add a new filter to your sales query:     [Sales].[Part_Id] in ([PartNosToInclude].[Part_Id])

3. Add a similar filter to your inventory query:     [Inventory].[Part_Id] in ([PartNosToInclude].[Part_Id])

If I've understood your requirement correctly, this should achieve the desired effect.

BigOCombe