1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

How to convert txt files to csv

Discussion in 'Databases' started by komrad, Aug 6, 2009.

  1. #1
    Hello,

    Could you please help me how to convert txt files to csv one.


    Thanks.
     
    komrad, Aug 6, 2009 IP
  2. jestep

    jestep Prominent Member Premium Member

    Messages:
    3,529
    Likes Received:
    201
    Best Answers:
    17
    Trophy Points:
    330
    #2
    If it is csv data, you can just change the extension to .csv.

    What format is the data in otherwise?
     
    jestep, Aug 6, 2009 IP
  3. puppetguy

    puppetguy Peon

    Messages:
    85
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #3
    Open your txt file with notepad. Click on "save as", and type yourfilename.csv
     
    puppetguy, Aug 6, 2009 IP
  4. premiumscripts

    premiumscripts Peon

    Messages:
    1,062
    Likes Received:
    46
    Best Answers:
    0
    Trophy Points:
    0
    #4
    Show a sample text file.
     
    premiumscripts, Aug 6, 2009 IP
  5. awesometbn

    awesometbn Peon

    Messages:
    268
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    0
    #5
    CSV just means comma separated values. If your text file has data in rows, just make sure the columns are separated by a comma. Save the file with a .csv file extension instead of .txt. Then you can use the CSV file to import into another database or use it as input for a software program.

    Most databases have an export feature that will assist you in getting the data output saved in CSV format. Otherwise if you have the raw data, you may have to search and replace column separators with actual commas, or you'll have to do a little bit of manual formatting.
     
    awesometbn, Aug 8, 2009 IP
  6. dulcificum

    dulcificum Active Member

    Messages:
    535
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    68
    #6
    Just rename the extension.
     
    dulcificum, Aug 8, 2009 IP
  7. ptalent

    ptalent Peon

    Messages:
    26
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    0
    #7
    Show us a sample of your txt data.

    For it to be in CSV format your first row should be your column headers and each entity needs to have a comma delimiter. If the delimiter is not a comma, then you can simply do a find a replace.

    If it already meets this criteria then just change the extension to .csv as mentioned before.

    Excel is a good tool to work with columns and save as CSV format.
     
    ptalent, Aug 9, 2009 IP
  8. Somebodysomeone

    Somebodysomeone Peon

    Messages:
    7
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #8
    that s not enough to make the file .CSV
    u need to seperate the colums with commas!
    the easiest way is using excel. just save as.
     
    Somebodysomeone, Aug 12, 2009 IP
    flippers.be likes this.
  9. Nitros

    Nitros Banned

    Messages:
    296
    Likes Received:
    5
    Best Answers:
    0
    Trophy Points:
    0
    #9
    Just found this: Link

    Not sure if it will work, but it's worth a try ;)
     
    Nitros, Aug 12, 2009 IP
  10. heavyweight

    heavyweight Peon

    Messages:
    82
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #10
    open with notepad, separate columns with commas and save as .csv it will work
     
    heavyweight, Aug 12, 2009 IP
  11. dulcificum

    dulcificum Active Member

    Messages:
    535
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    68
    #11
    The columns should already be separated if you're converting txt.
     
    dulcificum, Aug 12, 2009 IP
  12. komrad

    komrad Well-Known Member

    Messages:
    2,432
    Likes Received:
    14
    Best Answers:
    0
    Trophy Points:
    150
    #12
    The txt file is some products datafeed with | separated columns. When i tried to use an application it require csv files. Thats what i meant.

    Here is the data sample:

    453629947|Ticket Sales Representative|65|JobsInSports.com|http://www.shareasale.com/m-pr.cfm?merchantID=65&userID=98236&productID=453629947|http://www.jobsinsports.com/images/new-minilogo.gif|http://www.jobsinsports.com/images/new-minilogo.gif|9.95||Business/Services|Careers|JobsInSports.com is assisting a major professional sports franchise hire Ticket Sales Representatives. This is a full time position that requires a college degree. Other requirements are a professional appearance, excellent Communication and organizational skills and the desire and work ethic to be the best.||||New Jersey Professional Sports Franchise|New Jersey|2005-05-16 19:41:49.233|instock|||||||
    Code (markup):
     
    komrad, Aug 20, 2009 IP
  13. pepprs

    pepprs Peon

    Messages:
    195
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    0
    #13
    Use MS Excel or any such tool and import this TXt file. You can run through the steps and you will get the excel sheet. now save it as CSV. you delimiter will be |
     
    pepprs, Aug 21, 2009 IP
  14. KsNitro

    KsNitro Greenhorn

    Messages:
    60
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    20
    #14
    Fields appear to be delimited by | . Lines should be terminated by something as well, or set to a fixed number of fields. Look at your text file and try to import into excel or a similar app. You just need set the import options correctly.
     
    KsNitro, Aug 24, 2009 IP
  15. olddocks

    olddocks Well-Known Member

    Messages:
    3,234
    Likes Received:
    164
    Best Answers:
    0
    Trophy Points:
    153
    #15
    or specify a fixed width
     
    olddocks, Aug 24, 2009 IP
  16. seanlopez

    seanlopez Active Member

    Messages:
    245
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    65
    #16
    Hi,
    For converting the .txt file which contains contact no. to .csv files u have to go at microsoft outlook express with the whole content of txt file and that will automatically change it in csv
     
    seanlopez, Aug 25, 2009 IP
  17. Douglas Henderson

    Douglas Henderson Peon

    Messages:
    1
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    1
    #17
    Open the text file in excel or calc if you have open office, it will prompt you to convert the txt delimited to csv.
     
    Douglas Henderson, Sep 13, 2013 IP
  18. BotaniQ

    BotaniQ Member

    Messages:
    97
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    45
    #18
    U need replace "|" by ";" and save in csv
     
    BotaniQ, Oct 11, 2013 IP
  19. arshiabhardwaj21191

    arshiabhardwaj21191 Greenhorn

    Messages:
    22
    Likes Received:
    2
    Best Answers:
    0
    Trophy Points:
    23
    #19
    There are two ways to import data from a text file by using Microsoft Office Excel: You can open the text file in Excel, or you can import the text file as an external data range. To export data from Excel to a text file, use the Save As command.
    There are two commonly used text file formats:

    • Delimited text files (.txt), in which the TAB character (ASCII character code 009) typically separates each field of text.
    • Comma separated values text files (.csv), in which the comma character (,) typically separates each field of text.
    You can change the separator character that is used in both delimited and .csv text files. This may be necessary to make sure that the import or export operation works the way that you want it to.
     
    arshiabhardwaj21191, Oct 29, 2013 IP