Cascading comboboxes using UNION query (1 Viewer)

Gabi

New member
Local time
Today, 06:17
Joined
Jul 10, 2017
Messages
8
Hi,

Im trying to cascade comboxes using a UNION query, but comes up with "Enter parameter vaule - qryClauseNumbers.ClauseNumber"

I have checked if the row source is setup correctly, looks fine. Not sure where im missing it.

This is the query:
SELECT tblClauses.ClauseNumber
FROM tblClauses
UNION SELECT "0 - All" AS [ClauseNumber]
FROM tblClauses
WHERE (((qryClauseNumbers.[ClauseNumber])=[Forms]![Clauses]![ChapterTitle]));


thank you.
 

Ranman256

Well-known member
Local time
Today, 09:17
Joined
Apr 9, 2015
Messages
4,337
You used brackets as a label. Brackets are only for fields...

... "0-all" AS ClauseNumber
 

Gabi

New member
Local time
Today, 06:17
Joined
Jul 10, 2017
Messages
8
Thanks for the reply, im a beginner in MS Access, not sure if I understand by me using brackets as a label, if you can, please rearrange the query or point out what it should be than having the brackets added.

thank you.
 

Gabi

New member
Local time
Today, 06:17
Joined
Jul 10, 2017
Messages
8
when i add an input into the field, takes me back to the query.
 

plog

Banishment Pending
Local time
Today, 08:17
Joined
May 11, 2011
Messages
11,645
Code:
SELECT "0 - All" AS [ClauseNumber]
FROM tblClauses
WHERE (((qryClauseNumbers.[ClauseNumber])=[Forms]![Clauses]![ChapterTitle]));

You are trying to reference a table and field not part of your query in the WHERE clause. Your query doesn't have access to qryClauseNumbers because its not in the FROM so it has no idea what you are asking when you put a field of its in the WHERE.
 

Users who are viewing this thread

Top Bottom