OPENSEQ statement

29 views
Skip to first unread message

karthik

unread,
Jul 18, 2008, 3:07:09 AM7/18/08
to jb...@googlegroups.com

Hi all,

when i run the below code, it goes to the else clause even after setting the environment variable JBCEMULATE to "seq"(before compiling) and also the openseq_creates is set to true in Config_EMULATE.

FN.SEQ="TEST.BP/CUST.TXT"
OPENSEQ FN.SEQ TO F1.OUT ELSE
         CRT "ERR1"
END

I know to use the CREATE syntax in the else clause, however i wanted to know why the sequential file is not getting created?
 
jBASE: Major 5.0 , Minor 6
 
Regards
Karthik
 

Daniel Klein

unread,
Jul 18, 2008, 6:32:55 AM7/18/08
to jB...@googlegroups.com
Add a SETTING clause to the OPENSEQ statement to see what error is being returned.

Dan

karthik

unread,
Jul 18, 2008, 7:24:44 AM7/18/08
to jB...@googlegroups.com
Thanks dan. After setting the SETTING clause, its displaying "128" error msg.
 
Regards
Karthik

Korvin

unread,
Jul 18, 2008, 9:38:47 AM7/18/08
to jBASE
"128" error means, that there is no file which You try to open.

Try to use this...

FN.SEQ = "TEST.BP/CUST.TXT"
OPENSEQ FN.SEQ TO F1.OUT ELSE CREATE F1.OUT ELSE CRT "Can't open or
create file"

Daniel Klein

unread,
Jul 18, 2008, 9:47:03 AM7/18/08
to jB...@googlegroups.com
In that case, you need to change the code to:

OPENSEQ FN.SEQ TO F1.OUT ELSE NULL

Dan
Reply all
Reply to author
Forward
0 new messages