ca.portal.admin

Re:ADS question

Discussion created by ca.portal.admin on Dec 2, 2006
Hi:

I have an application that accesses a record in an area that is
sometimes offline for batch processing. I have tried to trap the 0966
that results from trying to CALC to that record so I can code around it
and keep our application up. I thought I could check the ERROR-STATUS
from a READY, but I have found that READY statements that are coded are
not actually executed until you execute a DML command, such as OBTAIN.
At least it appears that way when I ADS-Alive it.

Any ideas on how I can determine if an area is off-line before I try to
issue a DML command?

Thanks.

Tim Gortner
Sr. Consultant - Sogeti USA LLC
Iowa Department of Human Services
DDM Medical Systems and Data Warehousing
"
IDMS Public Discussion Forum
IDMS-L@LISTSERV.IUASSN.COM
SMTP
IDMS-L@LISTSERV.IUASSN.COM
IDMS-L@LISTSERV.IUASSN.COM
SMTP








Normal

Normal
Transaction Sharing in Rel 16
"A question for fellow listers...

Release 16 of IDMS introduced a new feature called ""Transaction Sharing""
as an SQL enhancement. Is anyone using this new feature in a production
environment? Can you tell me how well it works? Did you see any
performance hits? Any surprises?

Thanks in advance.

Dan Hall
GE
Capital Solutions
Danbury, CT

T 513.217.5060
E dan.hall@ge.com
http://www.ge.com/capitalsolutions/
"
IDMS Public Discussion Forum
IDMS-L@LISTSERV.IUASSN.COM
SMTP
IDMS-L@LISTSERV.IUASSN.COM
IDMS-L@LISTSERV.IUASSN.COM
SMTP








Normal

Normal
Re: ADS question (is AREA available?)
"Thanks Gary...

Here was my solution, based upon some other things I received from Chris
Wood (btw, the Avs will win tonight!).

First, 2 work records:

REPL
RECORD NAME IS W474RHDI VERSION IS 1
PUBLIC ACCESS IS ALLOWED FOR ALL
RECORD NAME SYNONYM IS W474RHDI VERSION 1
.
*+
02 DCMT-COMMAND-LENGTH PIC S9(04) COMP.
02 DCMT-COMMAND PIC X(100).
02 UPDATE-LIT PIC X(03) VALUE 'Upd'.
02 OFFLINE-LIT PIC X(03) VALUE 'Ofl'.
02 RETRIEVAL-LIT PIC X(03) VALUE 'Ret'.
REPL
RECORD NAME IS W474RHDO VERSION IS 1
PUBLIC ACCESS IS ALLOWED FOR ALL
RECORD NAME SYNONYM IS W474RHDO VERSION 1
.
*+
02 OUTREC-RETURN-LENGTH PIC S9(08) COMP VALUE +2016.
02 OUTREC-RETURN-CODE PIC S9(02) COMP.
02 OUTREC-OUTPUT-CODE PIC S9(01) COMP VALUE 0.
02 OUTREC-LENGTH-REQD PIC S9(08) COMP VALUE 0.
02 OUTREC-LENGTH-USED PIC S9(08) COMP VALUE 0.
02 OUTREC-TEXT PIC X(2000).

Then code in the dialog:

MOVE 'DISPLAY AREA K474M01S.TXIX-AREA '
TO DCMT-COMMAND.
MOVE +32 TO DCMT-COMMAND-LENGTH.
LINK TO PROGRAM 'RHDCMT00'
USING ( W474RHDI
W474RHDO ).

IF SUBS(OUTREC-TEXT,113,3) = OFFLINE-LIT
DO.
X.
END.
ELSE
DO.
Y.
END.

I also discovered that you will need to issue ""READY area USAGE-MODE IS
NOREADY"" at various times to make sure the areas you are concerned about
don't get READYd.

Tim Gortner
Iowa Department of Human Services

----- Original message -----
From: ""Cherlet, Gary (JTS)"" <Cherlet.Gary@SAUGOV.SA.GOV.AU>
To: IDMS-L@LISTSERV.IUASSN.COM
Date: Tue, 19 Dec 2006 15:02:27 +1030
Subject: Re: ADS question (is AREA available?)

Tim (and anybody else who is interested) - the program that I promised
is pretty much ready - and just in time for Christmas too! I was not
able to get any information about working out the run-time segment name
- so you will need to ""tweak"" a couple of lines of code - otherwise the
thing works as advertised.

14:27 19/12/06 JTS Utilities
SUTL020F
JDAGPC/RES Queue/Scratch Record Utility
GUT0002M

------------------------------------------------------------------------
-------
Queue or Scratch: S Queue id or Scratch area name: GUT0102D

Scroll mode: F Next/Prior/First/Last or Record id: 00000000

Display format: 1 Lines per record or Screen: 0 of 0

Delete: NO (NO/YES/ALL) Marker: <EOR> (Max) Record
length: 0079

........................................................................
......
Dialog: GAMS034D Date: 07/15/04 Time: 12154868
< First and subsequent Scratch records -
d/t: GAMS034M 02/10/98 162842R2
< output to the ""scratch"" area that was -
Schema: SCHMJIS Subschema: GAMSSS01
< passed in the work record.
Premap: GAMS034-PREMAP
<
Response: GAMS034-ENTER
<
Area Name Usage Mode Need Curr Avail
Y/N <
JIS.AM-ACCMAN01 Shared Retrieval READ UPD Yes
< Here's the Areas with their Ready Area Table Usage -
JIS.OF-OFOFFCX1 Shared Retrieval READ UPD Yes
< followed by the analysis of premap and response needs -
JIS.OF-OFOFFC01 Shared Retrieval READ UPD Yes
< followed by Current area status - and available or not

If the ""Avail Y/N"" status is not YES for all areas - then the work
record will have 'ERR' where the following SNAP output shows '***'
because all areas are available in the required usage mode:

14:27 AREASTATUSREC GUT0102D - after LINK

14:27 18BFA450 40404040 40404040 40404040 5C5C5CC7 * ***G*

14:27 18BFA460 C1D4E2F0 F3F4C4F0 F761F1F5 61F0F4F1 AMS034D07/15/041

14:27 18BFA470 F2F1F5F4 F8F6F8E2 C3C8D4D1 C9E240C7 *2154868SCHMJIS G*

14:27 18BFA480 C1D4E2E2 E2F0F1C7 C1D4E2F0 F3F4D4F0 AMSSS01GAMS034M0

14:27 18BFA490 F261F1F0 61F9F8F1 F6F2F8F4 F2D9F240 *2/10/98162842R2 *

14:27 18BFA4A0 40404040 40404040 40404040 404040C7 * G*

14:27 18BFA4B0 E4E3F0F1 F0F2C440 40404040 40404040 UT0102D        


The GUT0102D at the end is the scratchAreaOut name where the scratch
records went to - the 3 '***'s at the front of the reecord is the
areaStatus indicating all records are available in the required usage
mode. Here's the results after I varied the first area OFFline:

14:51 AREASTATUSREC GUT0102D - after LINK
14:51 18BFA450 40404040 40404040 40404040 C5D9D9C7 * ERRG*
'ERR' means at least one area is not available in required usage mode
14:51 18BFA460 C1D4E2F0 F3F4C4F0 F761F1F5 61F0F4F1 AMS034D07/15/041
14:51 18BFA470 F2F1F5F4 F8F6F8E2 C3C8D4D1 C9E240C7 *2154868SCHMJIS G*
14:51 18BFA480 C1D4E2E2 E2F0F1C7 C1D4E2F0 F3F4D4F0 AMSSS01GAMS034M0
14:51 18BFA490 F261F1F0 61F9F8F1 F6F2F8F4 F2D9F240 *2/10/98162842R2 *
14:51 18BFA4A0 40404040 40404040 40404040 404040C7 * G*
14:51 18BFA4B0 E4E3F0F1 F0F2C4D9 C5C1D1C9 E24BC1D4 UT0102DREAJIS.AM
Error AREA is JIS.AM-ACCMAN01
14:51 18BFA4C0 60C1C3C3 D4C1D5F0 F1404040 40404040 -ACCMAN01      
14:51 18BFA4D0 40404040 40D6C6C6 40404040 40404040 * OFF *
Currently OFFline
14:51 END OF SNAP

Full gory details are available in the Scratch area if you want them -
ignore them if you don't want them:

14:51 19/12/06 JTS Utilities
SUTL020F
JDAGPC/RES Queue/Scratch Record Utility
GUT0002M

------------------------------------------------------------------------
-------
Queue or Scratch: S Queue id or Scratch area name: GUT0102D

Scroll mode: F Next/Prior/First/Last or Record id: 00000000

Display format: 1 Lines per record or Screen: 0 of 0

Delete: NO (NO/YES/ALL) Marker: <EOR> (Max) Record
length: 0079

........................................................................
......
Dialog: GAMS034D Date: 07/15/04 Time: 12154868
<
d/t: GAMS034M 02/10/98 162842R2
<
Schema: SCHMJIS Subschema: GAMSSS01
<
Premap: GAMS034-PREMAP
<
Response: GAMS034-ENTER
<
Area Name Usage Mode Need Curr Avail
Y/N <
JIS.AM-ACCMAN01 Shared Retrieval READ OFFL No
25 <
JIS.OF-OFOFFCX1 Shared Retrieval READ UPD Yes
25 <
JIS.OF-OFOFFC01 Shared Retrieval READ UPD Yes
25 <

........................................................................
......
Response : ( QUEUE )


If you want to test the thing out - realising you will need to ""tweak"" a
couple of lines which I will provide detailed instructions for - you are
welcome to the code and the work record - just e-mail and I'll send you
everything you need in a ""zipped"" package.

Merry Christmas everybody!

Cheers - Gary

PS: Here's the code that produced the above results - note the simple,
clean API (sounds like a vendor claim doesn't it?) :

MOD PROCESS NAME IS GUT0102-PREMAP VERSION IS 1
PROCESS SOURCE FOLLOWS

! GUT0102D Test program for GUT0102O - Are ALL Areas Available for
Dialog?

move 'GAMS034D' to DIALOGNAME .
move 'GUT0102D' to scratchAreaOut .

link pgm 'GUT0102O' using ( areaStatusRec ).

snap records ( areaStatusRec ) title 'GUT0102D - after LINK'.

leave ads next task 'SUTL000K'.

MSEND
.

PPS: when the IUA web site is available I'll submit this to the User
Contributed Library - but there is usually a time lag to do this.

Outcomes