Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
CursorAdap & Logical Fields
Message
 
To
05/05/2004 10:19:29
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00900858
Message ID:
00901420
Views:
12
Thanks, I came up with something very close to that. Building a new cursor and attaching it. I ended up using the CursorSchema property to do identify the fields to convert to Logical. My hope is in a future version VFP will be able to convert these automaticly.

I see that there is a ConversionFunc property that works with updates and inserts but I wish there was a ConversionFunc property equivilant that worked with the SELECT command for cases like this.

BTW have you found the performance for this method acceptable? I will be working with small sets of data so hopefully it will not be a big issue.


>We did something similar using the cursoradapter for another customer who was using a backend that didn't have a bit data type.
>
>
>Here is the CA code. The CA has is a member array that contains the fields to convert. We call a function from AfterCursorFill() that spins through the array, detaches from the original cursor, and makes a converted cursor which the CA attaches to. Note that CursorRefresh() will not work, you need to call CursorFill() again to refresh the cursor. The comments in the code should be sufficient to explain what we did.
>
Previous
Reply
Map
View

Click here to load this message in the networking platform