Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Query >> exclude & empty field

Status
Not open for further replies.

domel

Vendor
Feb 3, 2001
1
BE
I've a database with products of a store. Those products are diveded in categories and subcategories. Every product has a categorie, but not every product has a subcategorie.

When I make a query with a criterium to exclude 1 subcategorie, access indeed exclude the products with that subcategorie BUT also the products that have no subcategorie.

What should I do?

Dr
 
It sounds like you might have two or three tables, with subcategories in their own table, and you're using these tables in your query with join lines between them. If that's correct, it doesn't matter whether you have the subcategory exclusion there or not, products with no subcategory will be left out of the query. To fix that, double click on the join line for the subcategory table. Access will display the Join Properties dialog. Select the option button numbered 2, and click OK. Products with no subcategories will then be included in your query.

To understand why this works, for Access 97, look in the Help index under "joins, join type" and select the topic "Join types and how they affect query results". For Access 2000, click the Answer Wizard in the Help file, enter "join types", and choose the topic "Join types and how they affect query results". Rick Sprague
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top