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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Convert one-column txt file to comma delimited file? 1

Status
Not open for further replies.

Katya85S

Programmer
Jul 19, 2004
190
Is it posible to convert one-column txt file to comma delimited file?
The input file looks like this
229920
244286
246689
251558
256366

The output file should look like this:
229920,244286,246689,251558,256366
Would appreciate any advice.
Thank you all in advance.
 
You may use Excel, PasteSpecial with Transpose, SaveAs csv.

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Thank you PHV. that would work, but I have more then 3000 rows, so when trying paste Special in excel i'm getting an error "the information cannot be pasted because the copy area and teh paste area are not the same size..." :(
 
And you want to convert to a single line of 3000 fields ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
I believ that's what we can have in cvs format: information split by commas...
Are you saying that's a wrong approach?
 
Are you saying that's a wrong approach?
I just wonder ...
What do you want to do ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
The user asked to convert that 1-column txt file to a comma delimited one. It just turned out, the user wanted comma after the numbers in each row. that was it. So the project turned to be a very simple one: i run a query adding "& ','" to each row.
PHV, thank you very much for your help. I'm sorry for the confusion. Your advice to use Excel, PasteSpecial with Transpose, SaveAs csv will be handy many times with other manipulations.
Thanks!
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top