insert imported data into existing fields

jun90

Registered User.
Local time
Today, 08:37
Joined
Jan 10, 2010
Messages
22
can i insert a imported file (using DoCmd.TransferText acImportDelim) which got 2 fields to the following function?

SQL = "INSERT INTO Table ( field1, field2, field3, field4 ) SELECT '" & LogUser & "' AS x1, #" & Now() & "# as x2;"
 
The generally accepted procedure would be to import the table or excel spreadsheet and then do an append query.

You can certainly try the procedure you suggest.

Good luck.
 
The generally accepted procedure would be to import the table or excel spreadsheet and then do an append query.

You can certainly try the procedure you suggest.

Good luck.

can u show me an example on how do i import the table then append the query pls? because when i:
data = DoCmd.TransferText acImportDelim, it says syntax error.

thanks n regards!
 
can u show me an example on how do i import the table then append the query pls? because when i:
data = DoCmd.TransferText acImportDelim, it says syntax error.

thanks n regards!

Use Access Help to learn more about
Transfertext method of DoCmd
see:http://msdn.microsoft.com/en-us/library/aa220768%28office.11%29.aspx

The steps involved in importing .txt file

http://www.ehow.com/how_10845_import-spreadsheet-text.html

Here are some other sites that could be helpful
http://www.allenbrowne.com/casu-22.html
http://www.btabdevelopment.com/main/AccessSamples/tabid/54/Default.aspx
 

Users who are viewing this thread

Back
Top Bottom