Queries

T

timboellis

I have a vary large 200m database with over 200 tables however I need to
create a CSV, XLS of a selection of the tables however the issue is this.

If I just now quote 2 of my tables called Coredetails and occupationdetails.

If I do a query on the coredetails this given me 3075 results.

If I do a query on occupationdetails this gives me 2366 results

however if i combine the details this gives me 2366 results.

However I want all the results so expecting 3075

can someone advise what i am doing wrong here or how to get all the results.

I am looking to get info out of approx 5 different tables , some tables will
have no info for certain clients and others will

Thanks for any help
 
B

Bob Quintal

timboellis said:
I have a vary large 200m database with over 200 tables however I
need to create a CSV, XLS of a selection of the tables however the
issue is this.

If I just now quote 2 of my tables called Coredetails and
occupationdetails.

If I do a query on the coredetails this given me 3075 results.

If I do a query on occupationdetails this gives me 2366 results

however if i combine the details this gives me 2366 results.

However I want all the results so expecting 3075

can someone advise what i am doing wrong here or how to get all
the results.

I am looking to get info out of approx 5 different tables , some
tables will have no info for certain clients and others will

Thanks for any help
It is obvious that the query returns only the results where the
joined field(s) from both tables are equal.

If you want to show the records in coredetails with no matching
records in occupationdetails you must do the following.
1) remove any criteria against fields in the occupationaldetails (if
any)
2) from the query builder design view, double click on each join
line, and select the correct option from the popup (either 2 or 3 as
applicable)
 
K

Kipp Woodard

It may be that you want to use outer joins in your query. Right-clcik the
join line between the two tables, and open the join properties. Choose the
option that makes sense for your situation. It looks like you need to select
"select all records from cordetails and only those records from
occupationdetails ....."
 
Top