Presentation is loading. Please wait.

Presentation is loading. Please wait.

Natural Conference in Philadelphia, PA

Similar presentations


Presentation on theme: "Natural Conference in Philadelphia, PA"— Presentation transcript:

1 Natural Conference in Philadelphia, PA
Storr Consulting October 2006 ADABAS Little Known Features Natural Conference in Philadelphia, PA October 17-20, 2006 Dieter W. Storr Dieter W. Storr --

2 Dieter W. Storr -- info@storrconsulting.com
October 2006 Content ADAM Files Hyperdescriptors Coupling Multi-client Files October 2006 Dieter W. Storr -- Dieter W. Storr --

3 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAM Adabas Direct Access Method How it works Performance issues Read access Write access October 2006 Dieter W. Storr -- Dieter W. Storr --

4 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAM – How to Create ADACMP ADAMER REPORT ADALOD ADAMFILE ADABAS ADAULD ADABAS October 2006 Dieter W. Storr -- Dieter W. Storr --

5 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAM Measurements and evaluations ADAMPARM ADAMOFLOW DSSIZE I/Os with FINDs and value not found, key values -1 to -99 I/Os with hit rate 100% for ADAM and not ADAM descriptors What happened if poor distribution of ADAM key - Pros and Cons October 2006 Dieter W. Storr -- Dieter W. Storr --

6 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAM October 2006 Dieter W. Storr -- Dieter W. Storr --

7 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER Parameters ERROR-076, Mandatory parameter MAXISN missing October 2006 Dieter W. Storr -- Dieter W. Storr --

8 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER Parameters ADAMDE=UQ DE or ISN No sub-, super-, hyper-, collation, or phonetic descriptor No MU or PE field No variable length field No NU defined descriptor The field to be used as the ADAM descriptor is specified with the ADAMDE parameter. A multiple value field or a field contained within a periodic group may not be used. The ISN assigned to the record may be used instead of a descriptor as the basis for randomization (ADAMDE=ISN parameter). The ADAM descriptor must contain a different value in each record, since the file cannot be successfully loaded with the ADAM option of the ADALOD utility if duplicate values are present for the ADAM descriptor. The ADAMER utility requires a descriptor field defined as unique (UQ), but does not check for unique values; checking for unique descriptor values is done by the ADALOD utility when loading the file as an ADAM file. October 2006 Dieter W. Storr -- Dieter W. Storr --

9 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER Parameters BITRANGE=X,Y,Z Bit Truncation for ADAM Keys X= minimum Y = maximum Z = incremental BITRANGE: Bit Truncation for ADAM Key The BITRANGE parameter may be used to specify that a given number of bits are to be truncated from each ADAM descriptor value before the value is used as input to the randomization algorithm. This permits records containing ADAM descriptor values beginning with the same value (for example, , , ) to be loaded into the same physical block in Data Storage. This technique can be used to optimize sequential reading of the file when using the ADAM descriptor to control the read sequence, or to remove insignificant information such as a check digit. The minimum, maximum, and incremental number of bits to be truncated from each ADAM descriptor value before the value is used as input to the ADAM randomization algorithm. Bits are always truncated from the rightmost portion of the compressed value. A maximum of 20 different bit truncations is permitted for each ADAMER execution. The following specification results in the truncation of 0 bits, 2 bits, and 4 bits for each Data Storage size for which statistics are provided. BITRANGE=0,4,2 October 2006 Dieter W. Storr -- Dieter W. Storr --

10 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER Parameters DATASIZE=n1,n2,n3 Data Storage Size for Estimates n1= min cylinders n2 = max cylinders n3 = increments For example: DATASIZE=100,175,25 DATASIZE: Data Storage Sizes for ADAM Estimates The Data Storage sizes, in cylinders, for which ADAM statistics are to be provided. A maximum of four Data Storage sizes can be calculated per ADAM execution. The minimum and maximum values may be specified without the increment. ADAMER calculates two increments to produce a report based on all four values. Example: The following specification results in statistics for Data Storage sizes of 100, 125, 150, and 175 cylinders. DATASIZE=100,175,25 If DATASIZE is omitted, ADAMER provides statistics for four Data Storage sizes as follows: Size 1: The first 100 input records are read and the Data Storage size requirement is based on the ADAM descriptor values present in these records and the value specified for MAXISN. The resulting Data Storage size is used as Data Storage Size 1. Size 2: Data Storage Size 1 x 1.33. Size 3: Data Storage Size 2 x 1.33. Size 4: Data Storage Size 3 x 1.33. October 2006 Dieter W. Storr -- Dieter W. Storr --

11 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER LOAD ADALOD LOAD FILE=xxx ADALOD ADAMFILE ADAMDE=field | ISN ADALOD ADAMOFLOW=size ADALOD ADAMPARM=number | 0 <snip> DATASIZE: Data Storage Sizes for ADAM Estimates The Data Storage sizes, in cylinders, for which ADAM statistics are to be provided. A maximum of four Data Storage sizes can be calculated per ADAM execution. The minimum and maximum values may be specified without the increment. ADAMER calculates two increments to produce a report based on all four values. Example: The following specification results in statistics for Data Storage sizes of 100, 125, 150, and 175 cylinders. DATASIZE=100,175,25 If DATASIZE is omitted, ADAMER provides statistics for four Data Storage sizes as follows: Size 1: The first 100 input records are read and the Data Storage size requirement is based on the ADAM descriptor values present in these records and the value specified for MAXISN. The resulting Data Storage size is used as Data Storage Size 1. Size 2: Data Storage Size 1 x 1.33. Size 3: Data Storage Size 2 x 1.33. Size 4: Data Storage Size 3 x 1.33. October 2006 Dieter W. Storr -- Dieter W. Storr --

12 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER LOAD 16:35:10 ***** P R E D I C T ***** - Modify Adabas attributes - File ID TEST-BROY Added at 13:18 Contained in DA . TEST by M197/9 PDBnr PFnr ADAM descriptor definition Field ID * Parm Overflow Additional attributes ..* S DATASIZE: Data Storage Sizes for ADAM Estimates The Data Storage sizes, in cylinders, for which ADAM statistics are to be provided. A maximum of four Data Storage sizes can be calculated per ADAM execution. The minimum and maximum values may be specified without the increment. ADAMER calculates two increments to produce a report based on all four values. Example: The following specification results in statistics for Data Storage sizes of 100, 125, 150, and 175 cylinders. DATASIZE=100,175,25 If DATASIZE is omitted, ADAMER provides statistics for four Data Storage sizes as follows: Size 1: The first 100 input records are read and the Data Storage size requirement is based on the ADAM descriptor values present in these records and the value specified for MAXISN. The resulting Data Storage size is used as Data Storage Size 1. Size 2: Data Storage Size 1 x 1.33. Size 3: Data Storage Size 2 x 1.33. Size 4: Data Storage Size 3 x 1.33. October 2006 Dieter W. Storr -- Dieter W. Storr --

13 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER Disadvantages ADAM key is not unique Determine DS block with ADAM routine Search DS block in buffer pool DS block is not in buffer pool DATA I/O to copy block into buffer pool DS block not found Access via normal descriptor in ASSO DATASIZE: Data Storage Sizes for ADAM Estimates The Data Storage sizes, in cylinders, for which ADAM statistics are to be provided. A maximum of four Data Storage sizes can be calculated per ADAM execution. The minimum and maximum values may be specified without the increment. ADAMER calculates two increments to produce a report based on all four values. Example: The following specification results in statistics for Data Storage sizes of 100, 125, 150, and 175 cylinders. DATASIZE=100,175,25 If DATASIZE is omitted, ADAMER provides statistics for four Data Storage sizes as follows: Size 1: The first 100 input records are read and the Data Storage size requirement is based on the ADAM descriptor values present in these records and the value specified for MAXISN. The resulting Data Storage size is used as Data Storage Size 1. Size 2: Data Storage Size 1 x 1.33. Size 3: Data Storage Size 2 x 1.33. Size 4: Data Storage Size 3 x 1.33. October 2006 Dieter W. Storr -- Dieter W. Storr --

14 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER Disadvantages ADAM key is not unique – cont’ Search ASSO block in buffer pool ASSO I/O to copy block into buffer pool Found DE with ISN? NO: record not found YES: read AC and translate ISN to RABN AC is normally in buffer pool, no I/O DATASIZE: Data Storage Sizes for ADAM Estimates The Data Storage sizes, in cylinders, for which ADAM statistics are to be provided. A maximum of four Data Storage sizes can be calculated per ADAM execution. The minimum and maximum values may be specified without the increment. ADAMER calculates two increments to produce a report based on all four values. Example: The following specification results in statistics for Data Storage sizes of 100, 125, 150, and 175 cylinders. DATASIZE=100,175,25 If DATASIZE is omitted, ADAMER provides statistics for four Data Storage sizes as follows: Size 1: The first 100 input records are read and the Data Storage size requirement is based on the ADAM descriptor values present in these records and the value specified for MAXISN. The resulting Data Storage size is used as Data Storage Size 1. Size 2: Data Storage Size 1 x 1.33. Size 3: Data Storage Size 2 x 1.33. Size 4: Data Storage Size 3 x 1.33. October 2006 Dieter W. Storr -- Dieter W. Storr --

15 Dieter W. Storr -- info@storrconsulting.com
October 2006 ADAMER Disadvantages ADAM key is not unique – cont’ Access to DS overflow area DS overflow area not in buffer pool DATA I/O to copy block into buffer pool Record is ready to be displayed DATASIZE: Data Storage Sizes for ADAM Estimates The Data Storage sizes, in cylinders, for which ADAM statistics are to be provided. A maximum of four Data Storage sizes can be calculated per ADAM execution. The minimum and maximum values may be specified without the increment. ADAMER calculates two increments to produce a report based on all four values. Example: The following specification results in statistics for Data Storage sizes of 100, 125, 150, and 175 cylinders. DATASIZE=100,175,25 If DATASIZE is omitted, ADAMER provides statistics for four Data Storage sizes as follows: Size 1: The first 100 input records are read and the Data Storage size requirement is based on the ADAM descriptor values present in these records and the value specified for MAXISN. The resulting Data Storage size is used as Data Storage Size 1. Size 2: Data Storage Size 1 x 1.33. Size 3: Data Storage Size 2 x 1.33. Size 4: Data Storage Size 3 x 1.33. October 2006 Dieter W. Storr -- Dieter W. Storr --

16 Dieter W. Storr -- info@storrconsulting.com
October 2006 Hyperdescriptors How it works Hyperdescriptor Exits What Approach Pros and Cons October 2006 Dieter W. Storr -- Dieter W. Storr --

17 Hyperdescriptor Exit – Nucleus
Storr Consulting October 2006 Hyperdescriptor Exit – Nucleus ADANUC HyperDE Exit ASSO DATA October 2006 Dieter W. Storr -- Dieter W. Storr --

18 Hyperdescriptor Exits DDCARD
Storr Consulting October 2006 Hyperdescriptor Exits DDCARD Assembler routines located on a concatenated ADABAS load library. <snip> ADARUN DUALPLS=13500 ADARUN FASTPATH=NO ADARUN FMXIO=16 ADARUN HEX01=HYPEX001 ADARUN HEX02=HYPEX002 ADARUN INTNAS=3432 ADARUN LBP= October 2006 Dieter W. Storr -- Dieter W. Storr --

19 Hyperdescriptor Exit – Compress
Storr Consulting October 2006 Hyperdescriptor Exit – Compress ADACMP HyperDE Exit ADALOD ASSO DATA October 2006 Dieter W. Storr -- Dieter W. Storr --

20 Hyperdescriptor Exits -- ADACMP DDCARD
<snip> ADARUN DBID=919,SVC=254 ADARUN DEVICE=9990,LP=65535 ADARUN PROGRAM=ADACMP ADARUN HEX01=HYPEX001 ADARUN MODE=MULTI Exit 1 assembler routine located on a load library, which is part of the ADACMP JCL October 2006 Dieter W. Storr --

21 Hyperdescriptor Exits – ADACMP DDKARTE
ADACMP COMPRESS ADACMP FNDEF='01,AA,7,A,DE,FI' Field AA ADACMP FNDEF='01,AB,15,A,DE,MU,NU' Field AB ADACMP FNDEF='01,GA' Group GA ADACMP FNDEF='02,AC,15,A,NU' Field AC ADACMP FNDEF='02,AD,2,P,FI' Field AD ADACMP FNDEF='02,AE,5,P,NU' Field AE ADACMP FNDEF='02,AF,6,W' Field AF ADACMP COLDE='7,Y1=AF' Collation descriptor Y1 ADACMP SUBDE='BB=AA(1,4)' Subdescriptor BB ADACMP SUPDE='CC=AA(1,4),AD(1,1)' Superdescriptor CC ADACMP HYPDE='1,DD,4,A,MU=AB,AC,AD‘ Hyperdescriptor DD ADACMP PHONDE='EE(AA)' Phonetic descriptor EE ADACMP SUBFN='FF=AA(1,2)' Subfield FF ADACMP SUPFN='GG=AA(1,4),AD(1,1)' Superfield GG October 2006 Dieter W. Storr --

22 Hyperdescriptor Exit – ADAINV
ADANUC ADAINV HyperDE Exit ASSO DATA October 2006 Dieter W. Storr --

23 Hyperdescriptor Exits -- ADAINV DDCARD
<snip> ADARUN PROGRAM=ADAINV ADARUN HEX01=HYPEX001 ADARUN MODE=MULTI Uses exit located in ADABAS nucleus October 2006 Dieter W. Storr --

24 Hyperdescriptor Exits – ADAINV DDKARTE
ADAINV INVERT FILE=xxx ADAINV TEMPSIZE=100,SORTSIZE=50 ADAINV HYPDE='1,DD,4,A,MU=AB,AC,AD‘ DD is assigned to hyperexit 1 HyperDE DD (A4) consisting of fields AB,AC and AD October 2006 Dieter W. Storr --

25 Dieter W. Storr -- info@storrconsulting.com
Hyperdescriptor Exit October 2006 Dieter W. Storr --

26 Hyperdescriptor Exit Input
October 2006 Dieter W. Storr --

27 Hyperdescriptor Exit Output
October 2006 Dieter W. Storr --

28 Hyperdescriptor Exit -- Assembler Example
ADABAS.ADA742.SRCE(USERHX01) ADABAS.ADA811.SRCE(USERHX01) * SAMPLE HYPER-EXIT ROUTINE TO BE USED TOGETHER WITH * FILE 2 (AUTOMOBILES) TO CREATE THE VALUES FOR THE * HYPERDESCRIPTOR HA: * HYPDE='1,HA,20,A,MU,NU=AA,AB,AC' * WHERE: * FNDEF='1,AA,20,A,NU' * FNDEF='1,AB,20,A,NU' * FNDEF='1,AC,15,A,NU' * THE FIELDS 'AA','AB' AND 'AC' CONTAINS THE 'MAKE','MODEL' * AND THE 'BODY'-DESCRIPTION OF A CAR. THE VALUES OF THOSE * FIELDS MAY CONSIST OF TWO VERBS DELIMITED BY A BLANK. * E.G. AA='GENERAL MOTORS'. October 2006 Dieter W. Storr --

29 Hyperdescriptor Exit – UNIX/Win
October 2006 Dieter W. Storr --

30 Hyperdescriptor Exit – UNIX/Win
Control Block October 2006 Dieter W. Storr --

31 Hyperdescriptor Exit – UNIX/Win
The routines should be written in the C programming language. The user must be present as a dynamic shared library. hy_mode = HY_REENTRANT hy_dlng = data transfer buffer length hy_xlng = index transfer buffer length hy_ilng = isn transfer buffer length (0 = not used) hy_plng = periodic transfer buffer length (0 = not used) hy_flng = optional: own FB length (0 = not used) hy_fptr = optional: own FB <snip> See ADABAS Manual, User Exits and Hyperexits October 2006 Dieter W. Storr --

32 Dieter W. Storr -- info@storrconsulting.com
Hyperdescriptor Exit Exit only called for update commands, for example STORE, UPDATE Not used for READ / FIND / HISTOGRAM 3.3 / 6.2 / 7.1 / 7.4  SL24 October 2006 Dieter W. Storr --

33 Use of Hyperdescriptors
Create "Superdescriptor" from more than 5 / 20 basic fields Example from a German company ADA51: Not clear how to handle NU fields Field is in input parameter but leave the exit w/o filling the output parameter – why NU in hyper definition? Customer wishes better documentation and more examples October 2006 Dieter W. Storr --

34 Use of Hyperdescriptors
Create "Superdescriptor" from variable numbers of basic fields Example from SAG-NA October 2006 Dieter W. Storr --

35 Use of Hyperdescriptors
Create "Superdescriptor" from variable numbers of basic fields and files Example from SAG-NA October 2006 Dieter W. Storr --

36 Use of Hyperdescriptors
Translate from lower to upper case Example from the Swiss government Bern Store info in upper/lower case For search in upper case only October 2006 Dieter W. Storr --

37 Use of Hyperdescriptors
Translate from lower to upper case and “Umlaute” Example from a German company, Bremen ä/Ä = AE, ü/Ü = UE, ß = SS, ö/Ö = OE Store info in upper case Can be sorted Predict: define as HY October 2006 Dieter W. Storr --

38 Use of Hyperdescriptors
Create complementary values Example from SAG-NA Numeric values can be read in descending order Since ADA6 hyperexit is no longer necessary: READ IN DESCENDING ORDER October 2006 Dieter W. Storr --

39 Use of Hyperdescriptors
Create special phonetic descriptors Summarize (compute) fields Create calculation routines Include compressed superdescriptors to build a hyperdescriptor October 2006 Dieter W. Storr --

40 Use of Hyperdescriptors
Create tables to check-out data Build special descriptors for record types (entities) Suppress values Separate words Build word groups October 2006 Dieter W. Storr --

41 Dieter W. Storr -- info@storrconsulting.com
Hyperdescriptor Exit ADA81: For extended MU/PU fields HEXV8V7 Must be linked with existing hyperdescriptor But: module not found in ADABAS Version (Beta Test II) ADABAS Version (+ L002) October 2006 Dieter W. Storr --

42 Dieter W. Storr -- info@storrconsulting.com
File Coupling Type Logical Coupled Files Physical Coupled Files Soft Coupling Natural Code ADABAS Direct Calls Pros and Cons October 2006 Dieter W. Storr --

43 #S-NR #A-NR #S-NAME #S-COMM
File Coupling (0-N) belongs to SALESMEN #S-NR #A-NR #S-NAME #S-COMM AREA #A-NR #S-NR #A-TURNO points to (N C) Search salesmen with a commission of > 30% in an area with a planned turnover of more than 1 million. October 2006 Dieter W. Storr --

44 File Coupling (Two Views)
DDM DBID DDM FNR SALESMEN T L DB Name F Leng S D Re 1 AA S-NR N N D 1 AB A-NR N N D 1 AC S-NAME A N 1 AD S-COMM N N D DDM DBID DDM FNR AREA 1 AA A-NR N N D 1 AB S-NR N N D 1 AC A-TURNO N N D October 2006 Dieter W. Storr --

45 Coupled Files (Logical)
0010 DEFINE DATA 0020 LOCAL USING LDA /* two views 0030 END-DEFINE 0040 FIND SALESMEN WITH S-COMM = 30 FIND AREA WITH AREA.S-NR = SALESMEN.S-NR AND A-TURNO > WRITE /* TITLE 'Logical coupled - 2 FINDs' / 'Logical Coupled - 2 FINDs' / '=========================' / / 'S-NR from SALESMEN:' SALESMEN.S-NR / 'A-NR from SALESMEN:' SALESMEN.A-NR / 'S-NAME from SALESMEN:' SALESMEN.S-NAME / 'S-COMM from SALESMEN:' SALESMEN.S-COMM / 'S-NR from AREA....:' AREA.S-NR / 'A-NR from AREA....:' AREA.A-NR / 'A-TURNO from AREA....:' AREA.A-TURNO / 'ISN from SALESMEN...:' *ISN(0040) / 'ISN from AREA :' *ISN(0050) END-FIND 0200 END-FIND October 2006 Dieter W. Storr --

46 Coupled Files (Logical)
Logical Coupled - 2 FINDs ========================= S-NR from SALESMEN: A-NR from SALESMEN: S-NAME from SALESMEN: HUGO00029 S-COMM from SALESMEN: 30 S-NR from AREA....: A-NR from AREA....: A-TURNO from AREA....: ISN from SALESMEN...: ISN from AREA : October 2006 Dieter W. Storr --

47 Dieter W. Storr -- info@storrconsulting.com
TEST DBLOG MENU 17:05: ***** NATURAL TEST UTILITIES ***** User ZINDWS DBLOG Menu Library LBZINDWS Code Function B Begin Logging of Adabas Commands E End and Display Log Records S Snapshot of Specific Adabas Commands . Exit Code .. b Command .. _Skip _ Program .... COUPLLOG DBID _FNR _ Line from Low Resp . _High Resp _Line to Optional Buffers for Code B FB .. x RB .. x SB .. x VB .. x IB .. _ October 2006 Dieter W. Storr --

48 Coupled Files (Logical)
No Cmd DB FNR Rsp ISN ISQ 1 S 2 S 3 RC 200 October 2006 Dieter W. Storr --

49 Coupled Files (Logical)
TEST DBLOG MENU: SALESMEN File 235: Search Buffer: AD,3,U. Value Buffer: 030 Format Buffer: AA,005,U,AB,005,U,AC,010,A,AD,003,U. AREA File 236: Search Buffer: AB,5,U,D,AC,8,U,GT. Value Buffer: AA,005,U,AB,005,U,AC,008,U. S-NR S-NR October 2006 Dieter W. Storr --

50 Coupled Files (Logical)
Pros Cons No denormalization, tables are still relational Two FIND commands No additional ASSO space October 2006 Dieter W. Storr --

51 Dieter W. Storr -- info@storrconsulting.com
Physical Coupling File numbers < 255 One file can be coupled with up to 18 other files Descriptor (DE, UQ, XI) with identical format and length in both files October 2006 Dieter W. Storr --

52 Dieter W. Storr -- info@storrconsulting.com
Physical Coupling ADABAS UTILITY ~ to couple two files ADAINV COUPLE FILES=235,236 ADAINV DESCRIPTOR=‘AA,AB’ ADAINV TEMPSIZE=3335 ADAINV SORTSIZE=5738 ADAINV LWP=8268K File 235 (SALESMEN) successfully processed File 236 (AREA ) successfully processed October 2006 Dieter W. Storr --

53 Dieter W. Storr -- info@storrconsulting.com
Physical Coupling ADABAS REPORT * File (SALESMEN ) * Coupled Files Descriptor AA coupled with Descriptor AB in file 236 File (AREA ) * Coupled Files Descriptor AB coupled with Descriptor AA in file 235 October 2006 Dieter W. Storr --

54 Dieter W. Storr -- info@storrconsulting.com
Physical Coupling 0010 DEFINE DATA 0020 LOCAL USING LDA /* two views 0030 END-DEFINE 0040 FIND SALESMEN WITH S-COMM = 30 AND COUPLED TO AREA WITH A-TURNO > WRITE / 'Physical Coupling - 1 FIND' / 'FIND SALESMEN AND COUPLED TO AREA' / '=================================' / / 'S-NR from SALESMEN:' SALESMEN.S-NR / 'A-NR from SALESMEN:' SALESMEN.A-NR / 'S-NAME from SALESMEN:' SALESMEN.S-NAME / 'S-COMM from SALESMEN:' SALESMEN.S-COMM / 'S-NR from AREA....:' AREA.S-NR / 'A-NR from AREA....:' AREA.A-NR / 'A-TURNO from AREA....:' AREA.A-TURNO / 'ISN from SALESMEN....:' *ISN(0040) / 'ISN from AREA :' 'n/a' 0200 END-FIND October 2006 Dieter W. Storr --

55 Dieter W. Storr -- info@storrconsulting.com
Physical Coupling Physical Coupling - 1 FIND FIND SALESMEN AND COUPLED TO AREA ================================= S-NR from SALESMEN: A-NR from SALESMEN: S-NAME from SALESMEN: HUGO00029 S-COMM from SALESMEN: 30 S-NR from AREA....: A-NR from AREA....: A-TURNO from AREA....: ISN from SALESMEN....: ISN from AREA : n/a October 2006 Dieter W. Storr --

56 Dieter W. Storr -- info@storrconsulting.com
TEST DBLOG MENU 17:05: ***** NATURAL TEST UTILITIES ***** User ZINDWS DBLOG Menu Library LBZINDWS Code Function B Begin Logging of Adabas Commands E End and Display Log Records S Snapshot of Specific Adabas Commands . Exit Code .. b Command .. _Skip _ Program .... COUPLPHY DBID _FNR _ Line from Low Resp . _High Resp _Line to Optional Buffers for Code B FB .. x RB .. x SB .. x VB .. x IB .. _ October 2006 Dieter W. Storr --

57 Dieter W. Storr -- info@storrconsulting.com
Physical Coupling TEST DBLOG MENU: No Cmd DB FNR Rsp ISN ISQ 1 S 2 RC 200 SB:/235/AD,3,U,D,/236/AC,8,U,GT. VB: FB: AA,005,U,AB,005,U,AC,010,A,AD,003,U. RB: HUGO October 2006 Dieter W. Storr --

58 Dieter W. Storr -- info@storrconsulting.com
Physical Coupling Number of ADABAS Calls: ONE S1 (FIND) Direct Programming: File Salesmen: 235 File Area: 236 Command: S ???? File Number: 235 Search Buffer: /22/PN,D,/103/TO. October 2006 Dieter W. Storr --

59 Dieter W. Storr -- info@storrconsulting.com
Physical Coupling Pros Cons No denormalization, tables are still relational Uncouple utility before maintenance Faster access More ASSO space One FIND only Longer update time No DATA fields from the soft coupled file(s), in this case AREA October 2006 Dieter W. Storr --

60 Dieter W. Storr -- info@storrconsulting.com
Coupled Files (Soft) 0010 DEFINE DATA 0020 LOCAL USING LDA /* two views 0030 END-DEFINE 0040 FIND SALESMEN WITH S-COMM = 30 AND COUPLED TO AREA VIA S-NR = S-NR WITH A-TURNO > WRITE / 'Soft Coupling - 1 FIND' / 'FIND SALESMEN AND COUPLED TO AREA VIA S-NR = S-NR' / '=================================================' / / 'S-NR from SALESMEN:' SALESMEN.S-NR / 'A-NR from SALESMEN:' SALESMEN.A-NR / 'S-NAME from SALESMEN:' SALESMEN.S-NAME / 'S-COMM from SALESMEN:' SALESMEN.S-COMM <snip> 0200 END-FIND October 2006 Dieter W. Storr --

61 Dieter W. Storr -- info@storrconsulting.com
Coupled Files (Soft) Soft Coupling - 1 FIND FIND SALESMEN AND COUPLED TO AREA VIA S-NR = S-NR ================================================= S-NR from SALESMEN: A-NR from SALESMEN: S-NAME from SALESMEN: HUGO00029 S-COMM from SALESMEN: 30 S-NR from AREA....: A-NR from AREA....: A-TURNO from AREA....: ISN from SALESMEN....: ISN from AREA : n/a October 2006 Dieter W. Storr --

62 Dieter W. Storr -- info@storrconsulting.com
Coupled Files (Soft) TEST DBLOG MENU: No Cmd DB FNR Rsp ISN ISQ 1 S 2 RC 200 SB:(235,AA,236,AB)/235/AD,3,U,D,/236/AC,8,U,GT. VB: FB:AA,005,U,AB,005,U,AC,010,A,AD,003,U. RB: HUGO October 2006 Dieter W. Storr --

63 Dieter W. Storr -- info@storrconsulting.com
Coupled Files (Soft) Supported since ADABAS (1988) CMD: S1 FNR: 135 SB: (235,AA,236,AB)/235/AD,/236/AC. NATURAL – (<1998) (FIND … COUPLED TO….. VIA October 2006 Dieter W. Storr --

64 Dieter W. Storr -- info@storrconsulting.com
Coupled Files (Soft) Pros Cons No denormalization, tables are still relational No DATA fields from the soft coupled file, in this case AREA Only one ADABAS FIND command (S1) + L1s Reduced interregion communication October 2006 Dieter W. Storr --

65 Dieter W. Storr -- info@storrconsulting.com
October 2006 Multi-client Files Since ADABAS 5.3.2, July 1994 Functions How to load Pros and cons Multiclient Files Records for multiple users or groups of users can be stored in a single ADABAS physical file defined as "multiclient". The multiclient feature divides the physical file into multiple logical files by attaching an internal owner ID to each record. The owner ID is assigned to a user ID. A user ID can have only one owner ID, but an owner ID can belong to more than one user. Each user can access only the subset of records that is associated with the user's owner ID. Note: For any installed external security package such as RACF, CA-ACF2, or CA-Top Secret, a user is still identified by either Natural ETID or LOGON ID. All database requests to multiclient files are handled by the Adabas nucleus. October 2006 Dieter W. Storr -- Dieter W. Storr --

66 Dieter W. Storr -- info@storrconsulting.com
October 2006 Multi-client Files The owner ID is assigned to a user ID. A user ID can have only one owner ID, but an owner ID can belong to more than one user. Each user can access only the subset of records that is associated with the user's owner ID. Multiclient Files Records for multiple users or groups of users can be stored in a single ADABAS physical file defined as "multiclient". The multiclient feature divides the physical file into multiple logical files by attaching an internal owner ID to each record. The owner ID is assigned to a user ID. A user ID can have only one owner ID, but an owner ID can belong to more than one user. Each user can access only the subset of records that is associated with the user's owner ID. Note: For any installed external security package such as RACF, CA-ACF2, or CA-Top Secret, a user is still identified by either Natural ETID or LOGON ID. All database requests to multiclient files are handled by the Adabas nucleus. October 2006 Dieter W. Storr -- Dieter W. Storr --

67 Dieter W. Storr -- info@storrconsulting.com
Multi-client Files Physical File 20 OWNERID Multiple Logical Files OWNERID OWNERID October 2006 Dieter W. Storr --

68 Loading Multi-client Files
Storr Consulting October 2006 Loading Multi-client Files ADALOD LOAD FILE=20 ADALOD LOWNERID=2,NUMREC=0 Creates file 20 as a multi-client file. The length of the internal owner ID is two bytes, but no actual owner ID (ETID) is specified. No records are actually loaded in the file (NUMREC=0). Multiclient Files Records for multiple users or groups of users can be stored in a single ADABAS physical file defined as "multiclient". The multiclient feature divides the physical file into multiple logical files by attaching an internal owner ID to each record. The owner ID is assigned to a user ID. A user ID can have only one owner ID, but an owner ID can belong to more than one user. Each user can access only the subset of records that is associated with the user's owner ID. Note: For any installed external security package such as RACF, CA-ACF2, or CA-Top Secret, a user is still identified by either Natural ETID or LOGON ID. All database requests to multiclient files are handled by the Adabas nucleus. October 2006 Dieter W. Storr -- Dieter W. Storr --

69 Loading Multi-client Files
Storr Consulting October 2006 Loading Multi-client Files ADALOD LOAD FILE=20 ADALOD LOWNERID=2,ETID=USER1 Creates file 20 as a multi-client file, load all supplied records, and assign them to user USER1. The length of the internal owner ID is two bytes. Multiclient Files Records for multiple users or groups of users can be stored in a single ADABAS physical file defined as "multiclient". The multiclient feature divides the physical file into multiple logical files by attaching an internal owner ID to each record. The owner ID is assigned to a user ID. A user ID can have only one owner ID, but an owner ID can belong to more than one user. Each user can access only the subset of records that is associated with the user's owner ID. Note: For any installed external security package such as RACF, CA-ACF2, or CA-Top Secret, a user is still identified by either Natural ETID or LOGON ID. All database requests to multiclient files are handled by the Adabas nucleus. October 2006 Dieter W. Storr -- Dieter W. Storr --

70 Loading Multi-client Files
Storr Consulting October 2006 Loading Multi-client Files ADALOD UPDATE FILE=20 ADALOD ETID=USER2 Performs a mass update to add records to file 20, a multi-client file. Load all the new records and assign them to USER2. Multiclient Files Records for multiple users or groups of users can be stored in a single ADABAS physical file defined as "multiclient". The multiclient feature divides the physical file into multiple logical files by attaching an internal owner ID to each record. The owner ID is assigned to a user ID. A user ID can have only one owner ID, but an owner ID can belong to more than one user. Each user can access only the subset of records that is associated with the user's owner ID. Note: For any installed external security package such as RACF, CA-ACF2, or CA-Top Secret, a user is still identified by either Natural ETID or LOGON ID. All database requests to multiclient files are handled by the Adabas nucleus. October 2006 Dieter W. Storr -- Dieter W. Storr --

71 Loading Multi-client Files
Storr Consulting October 2006 Loading Multi-client Files 12:25: ***** P R E D I C T ***** - Modify Adabas attributes - File ID TEST-BROY Added at 13:18 Contained in DA . TEST by M197/9 PDBnr PFnr Adabas Security definition Access level (0-15) Update level (0-15) Loading attributes Ciphered N (Y,N) LOWNERID (0-8) Refresh from program ... N (Y,N) Automatic allocation ... Y (Y,N) PLOG Y (Y,N) ISN size * 0 Erase N (Y,N) Index compression N (Y,N) Multiclient Files Records for multiple users or groups of users can be stored in a single ADABAS physical file defined as "multiclient". The multiclient feature divides the physical file into multiple logical files by attaching an internal owner ID to each record. The owner ID is assigned to a user ID. A user ID can have only one owner ID, but an owner ID can belong to more than one user. Each user can access only the subset of records that is associated with the user's owner ID. Note: For any installed external security package such as RACF, CA-ACF2, or CA-Top Secret, a user is still identified by either Natural ETID or LOGON ID. All database requests to multiclient files are handled by the Adabas nucleus. October 2006 Dieter W. Storr -- Dieter W. Storr --

72 Loading Multi-client Files
Storr Consulting October 2006 Loading Multi-client Files Multiclient Files Records for multiple users or groups of users can be stored in a single ADABAS physical file defined as "multiclient". The multiclient feature divides the physical file into multiple logical files by attaching an internal owner ID to each record. The owner ID is assigned to a user ID. A user ID can have only one owner ID, but an owner ID can belong to more than one user. Each user can access only the subset of records that is associated with the user's owner ID. Note: For any installed external security package such as RACF, CA-ACF2, or CA-Top Secret, a user is still identified by either Natural ETID or LOGON ID. All database requests to multiclient files are handled by the Adabas nucleus. October 2006 Dieter W. Storr -- Dieter W. Storr --

73 Dieter W. Storr -- info@storrconsulting.com
Users Experiences A Danish user reported in 2002 to use the feature since 8 years (Source: SAG-L) Unload production data by using ADAUNLD and SEL-CRIT= <switch> one-byte descriptor Load into test environment with UPDATE and ETID Coupled ETID as OWNER-ID to the user who wants to test. Reset <switch> in production Delete the records in the test-environment by coupling the ETID to the userid October 2006 Dieter W. Storr --

74 Dieter W. Storr -- info@storrconsulting.com
Users Experiences Keep the unloaded files on request, so they can re-load the test set with another ETID. Be aware of file changes between the different environments, especially if you keep the unloaded files for a while. Be aware of UQ descriptors if you ADALOD UPDATE the testset. October 2006 Dieter W. Storr --

75 Dieter W. Storr -- info@storrconsulting.com
Users Experiences A user from Holland (NL) reported in 1999 on SAG-L: We are working with multi-client files in development and acceptance environment. It works great and smoothly. A little more maintenance sometimes when it comes to file changes. Then, you have to unload/decompress/compress/load the first set of data. And unload/decompress/compress/update the others. October 2006 Dieter W. Storr --

76 Dieter W. Storr -- info@storrconsulting.com
Thank you! Questions? October 2006 Dieter W. Storr --


Download ppt "Natural Conference in Philadelphia, PA"

Similar presentations


Ads by Google