Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Snippets by SQL
Message
From
15/12/2014 03:32:21
 
 
To
15/12/2014 03:00:10
Lutz Scheffler
Lutz Scheffler Software Ingenieurbüro
Dresden, Germany
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Windows 8.1
Network:
SAMBA Server
Database:
Visual FoxPro
Application:
Desktop
Miscellaneous
Thread ID:
01612276
Message ID:
01612283
Views:
44
>Hi,
>
>todays problem #1
>
>I have a generic table, I know nothing about it then taht wahta I could read via VFP functions.
>
>In special:
>-no order
>-no index
>
>I need to move this into an excel spread sheet.
>I do this with an array to write into Excel
>Now the table is a bit large, so I get OLE Errors.
>
>Should not be a problem, I can write in chunks.
>
>But now I need to chunk the table
>Like (example)
>First 100 recs
>Next 100 recs
>....
>Last recs
>
>Is there a way to do this with VFP SQL (note: no chance for SELECT TOP, no ORDER given ...)
>
>Any other idea how to do this?

Maybe connect to Excel spreadsheet via ODBC? https://www.connectionstrings.com/microsoft-excel-odbc-driver/

Dunno if you can get all your data that way in one shot in a cursor, or if you need to play around with CURSORSETPROP() Fetch*, MaxRecords properties and/or pulling data from "main" cursor into a secondary one 100 rows at a time.

Also dunno if OLEDB/CursorAdapter offers any advantages with this.
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform