Re: validating the comma separated value message in C++



On Tue, 04 Jul 2006 15:29:00 -0400, Joe Wright
<joewwright@xxxxxxxxxxx> wrote:

Nishanth wrote:
I want to know how to validate a string which is comma separated

"C1","2","12344","Mr","John","Chan","05/07/1976".........


I need to validate each field value against a set of rules, for example

checking if the string is a character or a numeric value, for the
length of the character etc.

It looks like a .csv file to me. That's Comma Separated Value. Lots of
programs write files like this, dBASE, Clipper, FoxPro, Access, Excel,
etc. If you have a set of rules, please share.

http://www.creativyst.com/Doc/Articles/CSV/CSV01.htm

rossum

.



Relevant Pages

  • Re: validating the comma separated value message in C++
    ... I need to validate each field value against a set of rules, ... length of the character etc. ... You do not say where the string comes from, I will assume that you are ... before proceeding. ...
    (comp.programming)
  • Re: How to open a .CSV file ?
    ... character) could be escaped before any parsing took place. ... it wold split the string at whatever character it is told ... I assume when you said "parse at the comma" you meant string.split. ... it would be stupid to use it on a CSV file. ...
    (microsoft.public.dotnet.languages.vb)
  • Re: validating the comma separated value message in C++
    ... I need to validate each field value against a set of rules, ... checking if the string is a character or a numeric value, ... length of the character etc. ... field to the appropriate testing function. ...
    (comp.programming)
  • Re: How to check if a character appears in a form variable?
    ... in PHP so that you can check if a specific character is contained ... : within the string. ... by ensuring it contains the '@' character. ... That is hardly a check to validate an email address! ...
    (comp.lang.php)
  • Re: validating the comma separated value message in C++
    ... I need to validate each field value against a set of rules, ... checking if the string is a character or a numeric value, ... length of the character etc. ... It looks like a .csv file to me. ...
    (comp.programming)