jatin_sanghi
22nd May 2013, 12:31
Hi All,

I'm trying to read a file on baan server using the standard seq.open() command. The file size is 9.5 GB.
Now, in debugger when I go past the file_pntr = seq.open(...), the file_pntr returns nothing..neither zero nor any other value. The program continues to execute and exits smoothly without any errors. However, I'm not able to open the file and read records from it.

All smaller files (I have checked upto 800MB) are being handled successfully. Is there any limitation of file size that Baan can handle in seq.open?

Please help.

Thanks and Regards,
Jatin

mark_h
23rd May 2013, 01:20
Is splitting the file an option?

Never had to read a file that large - I do recall on some of our API code we had to limit the number records. So we would use the UNIX to split the file into several other files for processing. Just thought I would mention it.

jatin_sanghi
23rd May 2013, 09:15
Hi Mark,

Thanks for your reply...

Actually, splitting is an option that we have to avoid. We are working on an interface design where the file size will not be static, so we need to upload the file as it is.

Thanks,
Jatin

Han Brinkman
23rd May 2013, 17:24
Jatin,

Looking at seq.seek you can specify an offset. The offset is of type long. According to the programmers guide:

Long variables can contain any whole number from -2147483648 to 2147483647.

So I guess that files larger than 2Gb can't be handled.

NPRao
29th May 2013, 00:21
Actually, splitting is an option that we have to avoid. We are working on an interface design where the file size will not be static, so we need to upload the file as it is.

You have to question what is the true reason to avoid?

Processing a huge file will also result in increased execution time and transaction delay.

Alternative smart solution is to build a small program which splits the file into chunks of 2gb, get the number of files to be processed, starts activate() another 3-GL which takes a file name as a parameter and does the multi-processing and loads the data faster.