Re: Union Query requesting parameter

Tech-Archive recommends: Fix windows errors by optimizing your registry



Post the SQL statements for Qry_Aus_Budget_Sales and Qry_Aus_Actual_Sales

--
Allen Browne - Microsoft MVP. Perth, Western Australia
Tips for Access users - http://allenbrowne.com/tips.html
Reply to group, rather than allenbrowne at mvps dot org.

"Allen Browne" <AllenBrowne@xxxxxxxxxxxxxx> wrote in message
news:e1wsV$jlJHA.3760@xxxxxxxxxxxxxxxxxxxxxxx
Suggestions:

1. Make sure Name AutoCorrect is turned off.
Explanation of why:
http://allenbrowne.com/bug-03.html
Then compact/repair the database.

2. Open each of the following in turn, and clear the Filter and OrderBy properites:
a) the budget table
b) the sales table
c) Qry_Aus_Budget_Sales
d) Qry_Aus_Actual_Sales
e) the UNION query.

Post back if still stuck.

"Tige Brown" <TigeBrown@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:F3667C81-3F7F-4149-BD2D-3C8B3CB93C75@xxxxxxxxxxxxxxxx
I have the following union query to consolidate transactions from an actual
sales table located on a Microsoft SQL server database table with budget
transactions located on an access table. The actual transactions are linked
to the access database.

select * from Qry_Aus_Budget_Sales
UNION select * from Qry_Aus_Actual_Sales;

When I run this query I am requested to provide a parameter for
"Query1.unique_no". I have no query entitled "Query1". "unique_no" is the
primary key in the actual sales table.

For the budget table I created a similar key with the name ID. In the
Qry_Aus_Budget_Sales query I used table_name.ID as unique_no to rename the
field.

Some further information, I am working with two countries with separate
tables for both actual and budget data. I first created the tables needed
and queries for one country and then used this as a template to create the
tables & queries for the second country. The first country is working fine
and does not ask me for a parameter input, only the second country's union
query.

I have tried renaming the relevant field in the budget sales table as
unique_no thereby not requiring a name change but this has had no effect on
the parameter request.

Thanks in advance for any assistance.


.



Relevant Pages

  • Re: SQL Query - Help with Joins
    ... I don't know for certain without running it through the query analyzer, ... (select * from budget ... the sales table has a seven character product code of which the first ... three characters set a parent product group (for which the budgets are ...
    (comp.sys.ibm.as400.misc)
  • Re: Union Query requesting parameter
    ... Then compact/repair the database. ... sales table located on a Microsoft SQL server database table with budget ... tables & queries for the second country. ...
    (microsoft.public.access.queries)
  • Re: Union Query requesting parameter
    ... Allen Browne - Microsoft MVP. ... sales table located on a Microsoft SQL server database table with budget ... tables & queries for the second country. ...
    (microsoft.public.access.queries)
  • Re: Union Query requesting parameter
    ... Then compact/repair the database. ... sales table located on a Microsoft SQL server database table with budget ... tables & queries for the second country. ...
    (microsoft.public.access.queries)
  • Re: Union Query requesting parameter
    ... Check the Order By under properties of both of the queries used in the Union ... When I run this query I am requested to provide a parameter for ... For the budget table I created a similar key with the name ID. ... tables & queries for the second country. ...
    (microsoft.public.access.queries)