Thread: csv issues.

  1. #1
    Registered User caroundw5h's Avatar
    Join Date
    Oct 2003
    Posts
    751

    csv issues.

    I have a text file that when i convert to a csv file and open it up, some of the information is missing. it seems to be only a number or two, but its annoying. i a string is supposed to be nine digits sometimes one or 2 digits might be missing. This only happens with the numbers by the way. Why are some truncated and how can i avoid this?

    Thank you?
    Warning: Opinions subject to change without notice

    The C Library Reference Guide
    Understand the fundamentals
    Then have some more fun

  2. #2
    The Defective GRAPE Lurker's Avatar
    Join Date
    Feb 2003
    Posts
    949
    How are you converting it? Your own program? Commercial program? Do I care?
    Do not make direct eye contact with me.

  3. #3
    C++ Developer XSquared's Avatar
    Join Date
    Jun 2002
    Location
    Ontario, Canada
    Posts
    2,718
    >Do I care?
    God. Someone's in a ..........ty mood today. Try to keep it to yourself, OK?
    Naturally I didn't feel inspired enough to read all the links for you, since I already slaved away for long hours under a blistering sun pressing the search button after typing four whole words! - Quzah

    You. Fetch me my copy of the Wall Street Journal. You two, fight to the death - Stewie

  4. #4
    The Defective GRAPE Lurker's Avatar
    Join Date
    Feb 2003
    Posts
    949
    At least I gave him some questions to consider .

    Actually, I'm in a pretty good mood. Occasionally, my mind decides to make me a jerk. I wonder if there's some mental disease that does that?
    Do not make direct eye contact with me.

  5. #5
    Registered User caroundw5h's Avatar
    Join Date
    Oct 2003
    Posts
    751
    we're all entitled to our bad days. its all good bi**h!!!

    anyways the way i convert it is simple select the text file then save it as a .csv file. all the info in it is comma delimited. but as i said when i open it up, it seems to truncate some of the sequences
    Warning: Opinions subject to change without notice

    The C Library Reference Guide
    Understand the fundamentals
    Then have some more fun

  6. #6
    The Defective GRAPE Lurker's Avatar
    Join Date
    Feb 2003
    Posts
    949
    OK, so you take a .txt file, simply rename it to .csv, open it in Notepad, and it is different from the .txt file? Doesn't seem very likely; am I missing something here?
    Do not make direct eye contact with me.

  7. #7
    Registered User BillBoeBaggins's Avatar
    Join Date
    Oct 2003
    Posts
    107
    You never stated what program your doing the "Save as" in. If you are using Excel and you are losing numbers like 0 per say, make sure you convert the format to TEXT so the Program (Excel in this instance) knows to put qoutes around it.

    CSV files are simple.
    They are rows of information like Excel; if the information is text it has quotes, if it is not then it doesn't.

    Secondly you never mentioned what program you are trying to open up the CSV in. Because if you use Jacks Cracked Excel he might of screwed up on his import proc...

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Beginner C programmer - My CSV reader
    By spadez in forum C Programming
    Replies: 6
    Last Post: 04-04-2009, 08:46 PM
  2. read in csv file
    By gums in forum C Programming
    Replies: 5
    Last Post: 05-10-2007, 07:38 AM
  3. DBF to CSV in c#
    By TheMajorRager in forum C# Programming
    Replies: 0
    Last Post: 10-04-2005, 11:23 AM
  4. how to read csv file ?
    By kosong in forum C Programming
    Replies: 5
    Last Post: 11-13-2003, 08:14 PM
  5. hexdump issues
    By daluu in forum C Programming
    Replies: 2
    Last Post: 03-04-2003, 09:01 PM