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


P: 1

I have csv file with 44million bytes. My Perl program is converting csv file in txt through C++ using below command.

system(csv2wtf -i/phoenix/prod/data/delivery/client846/TDTWKSTR.csv -l/phoenix/prod/etc/file_str.layout -o/phoenix/prod/data/delivery/client846/TDTWKSTR.TXT -tTXT)

On above csv2wtf command interanlly invoke C++ programs to convert input file into required out put file. Here system throwing error as St9bad_alloc.

We have enough server RAM memory and space on system.

Can you please guide how to overcome on this issue
Jan 15 '08 #1
Share this Question
Share on Google+
1 Reply

Expert 100+
P: 254
Hi shaikrasheed,

Whatever the problem is, and there is no reason to assume that it is a lack of physical or virtual memory, it appears to come from csv2wtf. This program does not appear to be Perl and a google search does not turn up anything about it. I have no idea where you got it or what it does, much less how it does it. I don't see much likelihood of getting the answer in a Perl group.

That said, and knowing nothing at all about whether you have source or any documentation on csv2wtf, there is still a certain amount of "black box debugging" that you can do. You appear to at least have some idea of what csv2wtf requires as input and what it ought to give as output. I'd suggest running some tests manually with various inputs and see if you can learn anything. It may (or may not) turn out to be the case that the error appears on input with a certain size, in which case you might be able to split up your input and reassemble the output. Or it may turn out that a certain chunk of input triggers the error. I couldn't say, but depending on various factors, it may turn out to be worth your time to test it.

Jan 15 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.