Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Exporting table to text without delimiters

Status
Not open for further replies.

bscs1963

Programmer
Apr 7, 2009
22
US
I have a table with unique lines that have 'pipes' as the delimiter already built into the fields.

Now I want to export the table to a text file without delimiters. I can not use a specification becase I must have something for a delimiter.

How can I simply export the data to a txt to csv file without an delimiter.
 
If the Number of rows in your table is not to big or you are selecting a subset of the rows.... you could always concatenate the rows into one string and then right each row to a text file... that way you will the pipes from your fields without any further delimiter.
 

Code:
SELECT Replace(FieldName,"|"," ") As NoDelim
FROM TableName


Randy
 
Thanks everyone for your help. In the end, I added the pipe to each field in the table. I then exported the file as comma delimited to a file. I then imported the file back in telling Access that the delimiter was now a semi colon. this put all the data into the first field.

I then removed the commas in the field, and re-exported to the final file as comma delimited. This left only the pipes in the file.

A little of along winded route, but it worked. I had to complete the project this morning, and will clean this up at a later date.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top