Microsoft KB Archive/119711

= ACC2: Union Query with Calculated Field May Cause GP Fault =

Article ID: 119711

Article Last Modified on 6/25/2002

-

APPLIES TO


 * Microsoft Access 2.0 Standard Edition

-



This article was previously published under Q119711



Novice: Requires knowledge of the user interface on single-user computers.



SYMPTOMS
When you run a union query containing a calculated field in the first subquery, and an Order By clause containing the calculated field, you may receive a general protection (GP) fault error message.



RESOLUTION
Change the order of the subqueries in the union query, or remove the Order By clause from the query.



STATUS
This behavior no longer occurs in Microsoft Access version 7.0.



Steps to Reproduce Behavior
WARNING: Following the steps in this example will cause your computer to stop. Save and close any open files before following these steps.

 Open the sample database NWIND.MDB. Create a new, blank query. From the Query menu, choose SQL Specific then choose Union.  Enter the following SQL statement in the Union Query window.

NOTE: In the following SQL statement, neither the blank lines nor the line breaks affect the query. They are used here to improve readability.

     Select [First Name] & " " & [Last Name] as FullName From Employees

Union Select [Contact Name] from Customers Order By FullName;  Save and then run the query. Note that you receive a GP fault.</li></ol>

Additional query words: all gpf

Keywords: kberrmsg kbprb kbusage KB119711

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.