Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Adding column to a cursor based on SQL table?
Message
 
 
To
01/03/2012 14:53:56
General information
Forum:
Visual FoxPro
Category:
Other
Environment versions
Visual FoxPro:
VFP 9 SP1
Miscellaneous
Thread ID:
01536972
Message ID:
01536974
Views:
54
>Hi,
>
>I never had a problem with the following code when working with the VFP database. But I get error with the SQL Server
>
>
>
>*-- I get a cursor C_TBLFROMSQL from a table in SQL or VFP (code not shown)
>*-- In this case (the problem) the table is in SQL Server
>
>select C_TBLFROMSQL
>local array aDbfStruct[1]
>afields( aDbfStruct )
>
>create cursor EMPL_WO from array aDbfStruct
>
>*!!!!-- I get error on the following ALTER TABLE line
>alter table EMPL_WO add column SORT_ORD N(6,0)
>
>
>Is the problem on the ALTER TABLE .. ADD COLUMN because VFP does not allow changing structure of the cursor created based on SQL server table?

Yes. You better create extra field placeholders in advance. By default the cursor obtained with the mysqlexec is in buffered mode.
If it's not broken, fix it until it is.


My Blog
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform