I have linked Sybase database table with Access 2003. I only have read access to the Sybase database and created a pass-through query in access. Now what I need is, I need to create a temp table开发者_如何学运维 in Access with the data output of pass-through query.
If you can do a "SELECT" on that table, then you can do a "SELECT INTO" with that table.
For instance:
SELECT *
INTO myTempTable
FROM mySybaseTable
Which will copy all records from your Sybase table to your temp table.
Another alternative is DoCmd.TransferDatabase to import the table directly, using the appropriate ODBC connect string. I don't know if it's more efficient than the INSERT INTO, but I do know that INSERT INTO can get the data types badly wrong and won't import your indexes, whereas TransferDatabase is likely to do better (though likely also not perfectly).
精彩评论