[Info-vax] Cannot Access CDD/Repository Records from Basic Using %INCLUDE %FROM %CDD
Shael Richmond
shael.richmond at gmail.com
Thu Jun 13 11:34:46 EDT 2019
On Wednesday, June 12, 2019 at 4:39:27 PM UTC-5, Craig Dedo wrote:
> Everyone:
> When I compile a Basic program in OpenVMS that uses CDD definitions, I get error messages of the type:
> %INCLUDE %FROM %CDD "FILES.APDIST_RECORD"
> ........^
> %BASIC-E-CDDACCERR, CDD/Repository access error
> -BASIC-E-NODNOTFND, directory or object not found
> at line number 1 in file SMP_DEVELOP_DV:[YYY1V30.TOLAS.DEV.OLIVE]APDIST.BAS;1
>
> Apparently, my user account is not configured properly so that I can access the CDD records when I compile.
>
> However, when I login to my own account using the login configuration of a work colleague, I don't get these error messages. This happens when using the same command to compile the same source code. The only difference is the login configuration procedures.
>
> I have tried to compare the definitions of the two sets of login configuration procedures without success. I also printed out copies of the results of some inquiries:
> 1. OpenVMS system access privileges and rights identifiers. Both configurations have the same sets of privileges and rights identifiers.
> 2. Complete list of ALL logical name definitions from ALL logical name tables. So far, I have reconciled a number of differences but no changes have cleared the access problems to the CDD definitions.
>
> What definitions do I need to have in order to get access to the CDD definitions? What other tests can I run in order to find and correct the configurations that need to be fixed?
>
> Any help that anyone can give me would be very much appreciated.
>
> Sincerely,
> Craig T. Dedo, OpenVMS Software Development Consultant
> Navistar, Inc.
> 2701 Navistar Drive
> Lisle, IL 60532-3637
> E-mail: Craig dot Dedo at navistar dot com
Here are the two procedures I have had to run to make sure our Fortran/Cobol programs will compile.
$!
$ set noon
$!
$ mc sql$
set output sql.out
att 'filename PPR$DISK:[PPR.PPR_COMMON.DIC30a]CDD$DATABASE.RDB';
show protection on database rdb$dbhandle;
exit
$!
$ open/read/share outfile sql.out
$read_loop:
$ ident = ""
$ read/end=eof outfile outrec
$ ptr = f$locate("IDENTIFIER=", outrec)
$ if ptr .eqs. f$length(outrec) then goto read_loop
$ endptr = f$locate(",ACCESS=", outrec)
$ ident = f$extract(ptr+11, endptr-(ptr+11), outrec)
$ write sys$output ident
$ if ident .eqs. "CDD$SYSTEM" .or. -
ident .eqs. "[*,*]" then goto read_loop
$!
$eof:
$ close outfile
$ if ident .eqs. "" then goto endit
$ open/write cmdfile fix_cdd1.sql
$ write cmdfile "att 'filename PPR$DISK:[PPR.PPR_COMMON.DIC30a]CDD$DATABASE.RDB';"
$ write cmdfile "show protection on database rdb$dbhandle;"
$ write cmdfile "revoke entry on database alias rdb$dbhandle from ''ident';"
$ write cmdfile "grant all on database alias rdb$dbhandle to cdd$system;"
$ write cmdfile "revoke security,distribtran on database alias rdb$dbhandle from cdd$system;"
$ write cmdfile "show protection on database rdb$dbhandle;"
$ write cmdfile "commit;"
$ write cmdfile "exit"
$ close cmdfile
$!
$ mc sql$
@fix_cdd1.sql
$!
$endit:
$ delete sql.out;*
$ delete fix_cdd1.sql;*
$ exit
BGPPRA> type fix_cdd2.com
$!
$ set noon
$ assign/process ppr$disk:[ppr.ppr_common.dic30a] ppr$cdd
$!
$ dict
set output cdd.out
show protection for repository ppr$cdd
exit
$!
$ open/read/share outfile cdd.out
$ ident_count = 0
$read_loop:
$ ident = ""
$ read/end=eof outfile outrec
$ ptr = f$locate("IDENTIFIER=", outrec)
$ if ptr .eqs. f$length(outrec) then goto read_loop
$ ident_count = ident_count + 1
$ endptr = f$locate(",ACCESS=", outrec)
$ ident = f$extract(ptr+11, endptr-(ptr+11), outrec)
$ write sys$output ident
$ if ident .nes. "[*,*]" then goto read_loop
$!
$eof:
$ close outfile
$ open/write cmdfile fix_cdd2.cdo
$ write cmdfile "change protection for repository ppr$cdd position ''ident_count' access control."
$ write cmdfile "show protection for repository ppr$cdd"
$ write cmdfile "exit"
$ close cmdfile
$!
$ dict
@fix_cdd2.cdo
$!
$endit:
$ delete cdd.out;*
$ delete fix_cdd2.cdo;*
$ exit
Shael Richmond
International Paper
More information about the Info-vax
mailing list