dbTalk Databases Forums  

CALLX Not Working

comp.databases.pick comp.databases.pick


Discuss CALLX Not Working in the comp.databases.pick forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Cliff
 
Posts: n/a

Default CALLX Not Working - 06-19-2006 , 06:42 PM






I can't believe I can't get this CALLX test to work. I must be doing
something stupid.

Here are the basics:

File CLIFF.TEST exists and contains a CALLX statement in attribute 8 of
the data d-pointer.

CT DICT CLIFF.TEST CLIFF.TEST

CLIFF.TEST
001 D
002 $(MDS):$(MD)/CLIFF.TEST/CLIFF.TEST/CLIFF.TEST
003 3
004
005
006
007
008 CALLX CLIFF.UPDATE
009
010

The program CLIFF.UPDATE is FLASHED and CATALOGED in the account in
which I am working.

CT CLIFF.BP CLIFF.UPDATE

CLIFF.UPDATE
001 SUBROUTINE CLIFF.UPDATE(ITEM)
002 *
003 OPEN 'CLIFF.LOG' TO F.LOG ELSE RETURN
004 READ LOG.ITEM FROM F.LOG,'LOG.CNT' ELSE LOG.CNT = 0
005 LOG.CNT = LOG.CNT + 1
006 WRITE LOG.ITEM ON F.LOG,'LOG.CNT'
007 *
008 RETURN
008 *
009 END

If I add a new item item to the CLIFF.TEST file or change an existing
one I would expect the LOG.CNT item to be created and incremented.
After doing so the CLIFF.LOG file is empty. The item never gets
created. I have updated the file using ED and U.

I have tried the program both with and without the ITEM parameter.

I have tried logging off and logging back on with a different user
name.

What am I doing wrong? This is so basic it must be something so simple
I am overlooking it.

Cliff


Reply With Quote
  #2  
Old   
Cliff
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 06:46 PM







One more thing, I am using D3/NT.


Reply With Quote
  #3  
Old   
Tracy Raines
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 06:59 PM




Cliff wrote:
Quote:
I can't believe I can't get this CALLX test to work. I must be doing
something stupid.

Here are the basics:

File CLIFF.TEST exists and contains a CALLX statement in attribute 8 of
the data d-pointer.

CT DICT CLIFF.TEST CLIFF.TEST

CLIFF.TEST
001 D
002 $(MDS):$(MD)/CLIFF.TEST/CLIFF.TEST/CLIFF.TEST
003 3
004
005
006
007
008 CALLX CLIFF.UPDATE
009
010

The program CLIFF.UPDATE is FLASHED and CATALOGED in the account in
which I am working.

CT CLIFF.BP CLIFF.UPDATE

CLIFF.UPDATE
001 SUBROUTINE CLIFF.UPDATE(ITEM)
002 *
003 OPEN 'CLIFF.LOG' TO F.LOG ELSE RETURN
004 READ LOG.ITEM FROM F.LOG,'LOG.CNT' ELSE LOG.CNT = 0
005 LOG.CNT = LOG.CNT + 1
006 WRITE LOG.ITEM ON F.LOG,'LOG.CNT'
007 *
008 RETURN
008 *
009 END
I see a couple of things wrong here. On line 4 you read in LOG.ITEM
ELSE LOG.CNT = 0. Then on line 6 you try to write LOG.ITEM, when it
should be LOG.CNT, or else update LOG.ITEM instead of LOG.CNT

Quote:
If I add a new item item to the CLIFF.TEST file or change an existing
one I would expect the LOG.CNT item to be created and incremented.
After doing so the CLIFF.LOG file is empty. The item never gets
created. I have updated the file using ED and U.

I have tried the program both with and without the ITEM parameter.

I have tried logging off and logging back on with a different user
name.

What am I doing wrong? This is so basic it must be something so simple
I am overlooking it.

Cliff


Reply With Quote
  #4  
Old   
Tracy Raines
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 07:02 PM




Tracy Raines wrote:
Quote:
Cliff wrote:
I can't believe I can't get this CALLX test to work. I must be doing
something stupid.

Here are the basics:

File CLIFF.TEST exists and contains a CALLX statement in attribute 8 of
the data d-pointer.

CT DICT CLIFF.TEST CLIFF.TEST

CLIFF.TEST
001 D
002 $(MDS):$(MD)/CLIFF.TEST/CLIFF.TEST/CLIFF.TEST
003 3
004
005
006
007
008 CALLX CLIFF.UPDATE
009
010

The program CLIFF.UPDATE is FLASHED and CATALOGED in the account in
which I am working.

CT CLIFF.BP CLIFF.UPDATE

CLIFF.UPDATE
001 SUBROUTINE CLIFF.UPDATE(ITEM)
002 *
003 OPEN 'CLIFF.LOG' TO F.LOG ELSE RETURN
004 READ LOG.ITEM FROM F.LOG,'LOG.CNT' ELSE LOG.CNT = 0
005 LOG.CNT = LOG.CNT + 1
006 WRITE LOG.ITEM ON F.LOG,'LOG.CNT'
007 *
008 RETURN
008 *
009 END

I see a couple of things wrong here. On line 4 you read in LOG.ITEM
ELSE LOG.CNT = 0. Then on line 6 you try to write LOG.ITEM, when it
should be LOG.CNT, or else update LOG.ITEM instead of LOG.CNT


If I add a new item item to the CLIFF.TEST file or change an existing
one I would expect the LOG.CNT item to be created and incremented.
After doing so the CLIFF.LOG file is empty. The item never gets
created. I have updated the file using ED and U.

I have tried the program both with and without the ITEM parameter.

I have tried logging off and logging back on with a different user
name.

What am I doing wrong? This is so basic it must be something so simple
I am overlooking it.

Cliff
I just re-read my reply and that was as clear as mud. Let me know if
you don't understand what I said.



Reply With Quote
  #5  
Old   
Cliff
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 07:14 PM



No, it was clear. I see the bug. I fixed it but still not working.

CLIFF.UPDATE
001 SUBROUTINE CLIFF.UPDATE(ITEM)
002 *
003 OPEN 'CLIFF.LOG' TO F.LOG ELSE RETURN
004 READ LOG.CNT FROM F.LOG,'LOG.CNT' ELSE LOG.CNT = 0
005 LOG.CNT = LOG.CNT + 1
006 WRITE LOG.CNT ON F.LOG,'LOG.CNT'
007 *
008 RETURN
009 *
010 END


Reply With Quote
  #6  
Old   
Tracy Raines
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 07:37 PM




Cliff wrote:
Quote:
No, it was clear. I see the bug. I fixed it but still not working.

CLIFF.UPDATE
001 SUBROUTINE CLIFF.UPDATE(ITEM)
002 *
003 OPEN 'CLIFF.LOG' TO F.LOG ELSE RETURN
004 READ LOG.CNT FROM F.LOG,'LOG.CNT' ELSE LOG.CNT = 0
005 LOG.CNT = LOG.CNT + 1
006 WRITE LOG.CNT ON F.LOG,'LOG.CNT'
007 *
008 RETURN
009 *
010 END
After I fixed the minor problem, it worked fine on a Linux D3 7.4
system for me. I don't know much about NT systems, so I won't be of
much more help I'm afraid.



Reply With Quote
  #7  
Old   
Cliff
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 07:48 PM




Yeah, this is driving me nuts. I see no reason why it should not work.

I am on D3/NT version 7.4.6.


Reply With Quote
  #8  
Old   
Mike Wooding
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 09:10 PM



"Cliff" <cponce (AT) easternmetal (DOT) com> wrote


Quote:
I can't believe I can't get this CALLX test to work. I must be doing
something stupid.

Here are the basics:

File CLIFF.TEST exists and contains a CALLX statement in attribute 8
of the data d-pointer.
<snip>

Quote:
If I add a new item item to the CLIFF.TEST file or change an existing
one I would expect the LOG.CNT item to be created and incremented.
After doing so the CLIFF.LOG file is empty. The item never gets
created. I have updated the file using ED and U.
And there, IIRC, is your problem.

I've no experience with D3/NT, but I know "way back when", that a CALLX on
D3/Linux didn't work unless it was created correctly.

The correct way to create it was using "UD {FILENAME}". Although "U DICT
{filename} {filename}" and "ED DICT {filename} {filename}" allow the CALLX
line to be added to attribute 8, it only works if added via a "UD".

So, if I were you, I would "ED DICT CLIFF.TEST CLIFF.TEST" and remove the
CALLX entry from line 8.

Then, "UD CLIFF.TEST" and add the CALLX to the "Correlative" line.

Finally, repeat your test.

If that doesn't work, please let me know and I'll have another look when
I've had some sleep.

Regards

Mike Wooding




Reply With Quote
  #9  
Old   
Kevin Powick
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 09:11 PM



Cliff wrote:

Quote:
I can't believe I can't get this CALLX test to work. I must be doing
something stupid.

CLIFF.TEST
001 D
002 $(MDS):$(MD)/CLIFF.TEST/CLIFF.TEST/CLIFF.TEST
003 3
004
005
006
007
008 CALLX CLIFF.UPDATE
009
010
IIRC, you need the full path to your subroutine on line 8 of the dict.
Note comma spacing.

008 CALLX MYACCT,BP, CLIFF.UPDATE

--
Kevin Powick


Reply With Quote
  #10  
Old   
Cliff
 
Posts: n/a

Default Re: CALLX Not Working - 06-19-2006 , 10:10 PM




The fully qualified path worked! Thanks Kevin.

Thanks everyone for all of your help.


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.