Union queries and crosstab...

N

ngan adams

I created a union query that combined three tables. Three tables that store
three types of deposits (ID, Coupon, Misc). The union query has a criteria
of a date range. The fields include SalesAmt for all of the deposit types.

If one of the tables do not have data for that date range (let's say Misc),
the SalesAmt column for the Misc table does not show up in the query. Is
there a way for me to have a filler column so it can be displayed in a
report? Currently, if a table has no data, the report errors out saying the
column does not exist.

Thanks.
 
K

KARL DEWEY

Use a NZ function on that field so that there will not be a null.
AliasFieldName: Nz([YourFieldName], 0) if you want a zero.

AliasFieldName: Nz([YourFieldName], "") if you want a blank.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top