Export without quote

dmyoungsal

Registered User.
Local time
Today, 09:34
Joined
May 1, 2016
Messages
112
I have an module that exports data to a CSV. My problem is that the data comes out with double-quotes around all the fields.

what parameter can I use to eliminate this from happening? Below is my code:

DoCmd.TransferText acExportDelim, , "qryRFIDEIDLocation", "p:\rental man\FTPRM\RMUpload.csv", 1
 
you must setup the schema,
this tell access how to export, what delimiters, etc.
do an export or import of the csv file, click advanced, set the schema.

DoCmd.TransferText acExportDelim, "mySchema", "qryRFIDEIDLocation", "p:\rental man\FTPRM\RMUpload.csv", 1
 
I think I have a better understanding how the "spec" file works now, but my do.cmd line is still because of the error "The Text file specification "RMUploadExp" does not exist.

HEre is my Do.CMD line:
DoCmd.TransferText acExportDelim, "RMUploadExp", "qryRFIDEIDLocation", "p:\rental man\FTPRM\RMUpload.csv", 1

When I open Saved Exports in the External tab in my DB, I see the export there and runs.

What am I missing?
 
I think I have a better understanding how the "spec" file works now, but my do.cmd line is still because of the error "The Text file specification "RMUploadExp" does not exist.

HEre is my Do.CMD line:
DoCmd.TransferText acExportDelim, "RMUploadExp", "qryRFIDEIDLocation", "p:\rental man\FTPRM\RMUpload.csv", 1

When I open Saved Exports in the External tab in my DB, I see the export there and runs.

What am I missing?

I figured it out. I mistook the "Saved" name for the actual Spec. It was actually there, but I was not referring to the spec but the saved procedure name.
 
Is there an easy way to add a time and date stamp to my CSV file at the same time?
 
Is there an easy way to add a time and date stamp to my CSV file at the same time?

I went a completely different direction and used a series of DOS batch files that will accomplish exactly what I was attempting to do.

I would still like to know what if it is possible to do this through the do.CMD procedure.
 
A Google search will give you examples. However, I would copy the file and then delete the old file, ie

Code:
Filecopy strFullPathFilename, strFullPathFilename & format(now(),"yyyymmddhhnnss")
Kill strFullPathFilename
 
Hi
Can we export the Schema.ini File specification from one database and import to another as we do for other access objects?
 
If I understand your question, then when you do an external data import, the last button is Options >>. If you click on that you will see tick boxes and there you would tick "Import/Export Specs".
 

Users who are viewing this thread

Back
Top Bottom