K
Kodawari
I am having a major problem with a “query by form†“blowing upâ€. I am using
the following query on the criteria line:
[forms]![Q&A data query]![carrier] Or [forms]![Q&A data query]![carrier] Is
Null
Everything works just fine and the results are totally as predicted. Then,
I close the query (after saving it) and re-open it in “design viewâ€. The
results are the query statement has been separated at the “or†and the later
half deposited into the next field incomplete. This causes the query to
fail. On a form with many fields, it is a giant mess and Access cannot even
open the query any longer.
I am not proficient in SQL, but upon recommendation of a colleague, took a
look at what was happening in SQL before and after these events. By looking
at the SQL it is quite obvious something is going wrong. The following is a
before and after look at the SQL statements:
Before:
SELECT [Issues Prime Data].[name & IATA]
FROM [Issues Prime Data]
WHERE ((([Issues Prime Data].[name & IATA])=[forms]![Q&A data
query]![carrier] Or [forms]![Q&A data query]![carrier] Is Null));
After: SQL created for a field I did not even specify:
After (field one – left side)
SELECT
FROM [Issues Prime Data]
WHERE ((([Issues Prime Data].[name & IATA])=[forms]![Q&A data
query]![carrier])) OR ((([forms]![Q&A data query]![carrier]) Is Null));
After (field two – right side)
SELECT
FROM [Issues Prime Data]
WHERE ((([Issues Prime Data].[name & IATA])=[forms]![Q&A data
query]![carrier])) OR ((([forms]![Q&A data query]![carrier]) Is Null));
The only action I performed to receive this result is closing and opening
the query.
Is this a known issue with Access prior to SP2? My company has not
installed SP2 yet.
Hoping someone out there could help solve this problem.
Thanks.
the following query on the criteria line:
[forms]![Q&A data query]![carrier] Or [forms]![Q&A data query]![carrier] Is
Null
Everything works just fine and the results are totally as predicted. Then,
I close the query (after saving it) and re-open it in “design viewâ€. The
results are the query statement has been separated at the “or†and the later
half deposited into the next field incomplete. This causes the query to
fail. On a form with many fields, it is a giant mess and Access cannot even
open the query any longer.
I am not proficient in SQL, but upon recommendation of a colleague, took a
look at what was happening in SQL before and after these events. By looking
at the SQL it is quite obvious something is going wrong. The following is a
before and after look at the SQL statements:
Before:
SELECT [Issues Prime Data].[name & IATA]
FROM [Issues Prime Data]
WHERE ((([Issues Prime Data].[name & IATA])=[forms]![Q&A data
query]![carrier] Or [forms]![Q&A data query]![carrier] Is Null));
After: SQL created for a field I did not even specify:
After (field one – left side)
SELECT
FROM [Issues Prime Data]
WHERE ((([Issues Prime Data].[name & IATA])=[forms]![Q&A data
query]![carrier])) OR ((([forms]![Q&A data query]![carrier]) Is Null));
After (field two – right side)
SELECT
FROM [Issues Prime Data]
WHERE ((([Issues Prime Data].[name & IATA])=[forms]![Q&A data
query]![carrier])) OR ((([forms]![Q&A data query]![carrier]) Is Null));
The only action I performed to receive this result is closing and opening
the query.
Is this a known issue with Access prior to SP2? My company has not
installed SP2 yet.
Hoping someone out there could help solve this problem.
Thanks.