Microsoft KB Archive/266089

= PRB: MODIFY VIEW with Long IN Clause Causes Visual FoxPro to Terminate =

Article ID: 266089

Article Last Modified on 10/16/2002

-

APPLIES TO


 * Microsoft Visual FoxPro 5.0 Standard Edition
 * Microsoft Visual FoxPro 5.0a
 * Microsoft Visual FoxPro 6.0 Professional Edition

-



This article was previously published under Q266089



SYMPTOMS
When you modify a view in the View Designer that contains a long IN clause, Visual FoxPro terminates. Visual FoxPro 6.x either generates a fatal error or terminates without any error message. Visual FoxPro 5.x generates the error message

Mismatched Pushjmp/Popjmp Call

followed by:

.DBC Internal Consistency Error

and then terminates.



RESOLUTION
To resolve this problem, you can:

  Reduce the IN clause to a shorter statement

-or-

Break the IN clause into two statements and use the .OR. operator to join them together as two separate criteria, such as: CREATE SQL VIEW view2 as SELECT *; FROM customer!customer1; WHERE Customer1.cust_id IN (&quot;ABC11&quot;,&quot;DBF11&quot;,&quot;ADF11&quot;,&quot;DFR11&quot;,&quot;WDS11&quot;,&quot;RRR11&quot;); OR (Customer1.cust_id IN (&quot;GGG11&quot;,&quot;AFR11&quot;,&quot;TRE11&quot;,&quot;YUI11&quot;,&quot;OUI11&quot;,&quot;POI11&quot;,&quot;QWE11&quot;)); ORDER BY Customer1.cust_id   Break the IN clause into two statements and use the .OR. operator to join them together as two separate criteria, such as: CREATE SQL VIEW view2 as SELECT *; FROM customer!customer1; WHERE Customer1.cust_id IN (&quot;ABC11&quot;,&quot;DBF11&quot;,&quot;ADF11&quot;,&quot;DFR11&quot;,&quot;WDS11&quot;,&quot;RRR11&quot;); OR (Customer1.cust_id IN (&quot;GGG11&quot;,&quot;AFR11&quot;,&quot;TRE11&quot;,&quot;YUI11&quot;,&quot;OUI11&quot;,&quot;POI11&quot;,&quot;QWE11&quot;)); ORDER BY Customer1.cust_id 



Steps to Reproduce Behavior
  Run the following code to create a database and a table: CREATE DATABASE customer CREATE TABLE customer1 (cust_id C(5), cust_name C(40)) INSERT INTO customer1 VALUES (&quot;ASD11&quot;,&quot;John&quot;) INSERT INTO customer1 VALUES (&quot;OUI11&quot;,&quot;Smith&quot;) INSERT INTO customer1 VALUES (&quot;TRE11&quot;,&quot;Ken&quot;) INSERT INTO customer1 VALUES (&quot;BRE11&quot;,&quot;Kenneth&quot;) INSERT INTO customer1 VALUES (&quot;ABC11&quot;,&quot;Joe&quot;)   While the database is still open, in the Command window, run the following code to create a view: CREATE SQL VIEW view2 as SELECT *; FROM customer1; WHERE Customer1.cust_id IN ; (&quot;ABC11&quot;,&quot;DBF11&quot;,&quot;ADF11&quot;,&quot;DFR11&quot;,&quot;WDS11&quot;,&quot;RRR11&quot;, &quot;GGG11&quot;,&quot;AFR11&quot;,&quot;TRE11&quot;,&quot;YUI11&quot;,&quot;OUI11&quot;,&quot;POI11&quot;,&quot;QWE11&quot;); ORDER BY Customer1.cust_id Type the following into the Command window to try to modify view2: MODIFY VIEW view2 NOTE: Visual FoxPro 6.x will error out with fatal error or terminate without any error message. 

Keywords: kbbug kbdesigner kbprb KB266089

-

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

© Microsoft Corporation. All rights reserved.