EDI files and C

P

pereges

This might be a little offtopic..But I wanted to know if there are any
functions in C library (even if its in the most recent C standard)
that can aid me in creating EDI files from CSV files. I've managed to
read the CSV files line by line with standard C library functions.
 
R

Rui Maciel

pereges said:
This might be a little offtopic..But I wanted to know if there are any
functions in C library (even if its in the most recent C standard)
that can aid me in creating EDI files from CSV files. I've managed to
read the CSV files line by line with standard C library functions.

In order to extract information from a data format you need to employ a parser that recognizes that
particular language/data format. The only reason you were able to use standard functions to extract
information from a specific data format (CSV) is due to nothing more than sheer dumb luck. In fact,
I'm not sure if the word "luck" should be used to describe this because, as that particular data
input procedure doesn't employ any error detection, if you rely on this method to import data then
there is absolutely no assurance that you are handling a valid data format, let alone that the data
you have been importing is valid.

So, if you need to import data from any file, whether it's CSV or EDI, you should make sure that the
data is correctly described through a valid language/data format and you should rely on a parser to
both extract the information and react to any possible error. As the C standard library doesn't
include any parser, you need to either write your own or get your hands on a library that does that
for you.


Hope this helps,
Rui Maciel
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,777
Messages
2,569,604
Members
45,208
Latest member
RandallLay

Latest Threads

Top