By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
435,335 Members | 2,281 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 435,335 IT Pros & Developers. It's quick & easy.

Text Parser - how to

P: n/a
I am a very beginner in c. I have to write a text parser to parse a
file with certain fields, a special delimiter.

This file may be in network, and may have to acces from the network.
Any help

Sep 20 '06 #1
Share this Question
Share on Google+
6 Replies


P: n/a
hi...
what is the delimiter... what is the format in which the file is to be
written...be specific.... people will help only if u be specific ...
pritywiz wrote:
I am a very beginner in c. I have to write a text parser to parse a
file with certain fields, a special delimiter.

This file may be in network, and may have to acces from the network.
Any help
Sep 20 '06 #2

P: n/a
pritywiz wrote:
I am a very beginner in c. I have to write a text parser to parse a
file with certain fields, a special delimiter.
Then you better get busy. Since your requirements are so secret it
looks like you best write some code and then show us.
This file may be in network, and may have to acces from the network.
Any help
Start simple. Leave networking out of it for now, and just concentrate
on your logic against a test file.
Sep 20 '06 #3

P: n/a
At the moment I really dont know, but wanted to give an initial start,
actually I am a PHP programmer and have done such parsing a lot.

But currently we have a requirement in C. I just want you all to give
me a beginner link or a basic code how to achieve this.

For example, if I have an attribute value pair data with each attribute
and value separated by '-' dash and the pair separated by a
semicolon';' and each new record in a new line.

Then if I want this in a database table -- which is also a task after I
parse the text, I should be able to do it.

Prity
ra*******************@gmail.com wrote:
hi...
what is the delimiter... what is the format in which the file is to be
written...be specific.... people will help only if u be specific ...
pritywiz wrote:
I am a very beginner in c. I have to write a text parser to parse a
file with certain fields, a special delimiter.

This file may be in network, and may have to acces from the network.
Any help
Sep 20 '06 #4

P: n/a
ra*******************@gmail.com wrote:
hi...
Please don't top-post. Your replies belong following or interspersed
with properly trimmed quotes. See the majority of other posts in the
newsgroup, or:
<http://www.caliburn.nl/topposting.html>
Sep 20 '06 #5

P: n/a
pritywiz wrote:
At the moment I really dont know, but wanted to give an initial start,


Please don't top-post. Your replies belong following or interspersed
with properly trimmed quotes. See the majority of other posts in the
newsgroup, or:
<http://www.caliburn.nl/topposting.html>
Sep 20 '06 #6

P: n/a
iuz
pritywiz wrote:
At the moment I really dont know, but wanted to give an initial start,
actually I am a PHP programmer and have done such parsing a lot.

But currently we have a requirement in C. I just want you all to give
me a beginner link or a basic code how to achieve this.
if you are familiar to PHP.. ask yourself how PHP parses php files?
but i think that you need a simple parser so try to write some code and then
come back..

--
www.iuz-lab.info
Sep 21 '06 #7

This discussion thread is closed

Replies have been disabled for this discussion.