Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Create Database Table from SPT
Message
 
 
To
14/12/2005 14:07:20
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 6
Miscellaneous
Thread ID:
01077989
Message ID:
01078013
Views:
17
COPY TO (lcTableName) DATABASE DatabaseName
>I would like to create a snapshot of a DB2 database. I won't need the most current records so it seems feasible to me to pull down all the tables and store them locally (none of the tables are more than 25K records so space is not a consideration).
>
>In order to keep the full name of the fields I need to store it all in a database. So I now have an empty DBC called aw_data. I also have a free table (awstru) which contains a list of all the tables I will need to pull down. I can get the data into a cursor, but I don't remember (can't figure out, am missing something simple, etc.) how to get that cursor into the database.
>
>So far I have
>CREATE DATABASE aw_data
>USE awstru
>SCAN
>     =SQLEXEC(myConn,"SELECT * FROM " + awstru.tablename)
>     ** A miracle is needed to put SQLRESULT into aw_data as < awstru.tablename >
>ENDSCAN
>
>Could somebody please show me how to perform this miracle?
>
>Thanks to all
>
>.......Rich
--sb--
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform