[Search for users] [Overall Top Noters] [List of all Conferences] [Download this site]

Conference iosg::all-in-1_v30

Title:*OLD* ALL-IN-1 (tm) Support Conference
Notice:Closed - See Note 4331.l to move to IOSG::ALL-IN-1
Moderator:IOSG::PYE
Created:Thu Jan 30 1992
Last Modified:Tue Jan 23 1996
Last Successful Update:Fri Jun 06 1997
Number of topics:4343
Total number of notes:18308

2245.0. "Rename account and OA$SITE_LIB:SITE_SM_RENAME.COM" by BUSHIE::SETHI (Man from Downunder) Thu Feb 11 1993 04:54

    G'day,
    
    The rename option submits the OA$LIB:SM_RENAME.COM and this in turn
    calls OA$LIB:SM_RENAME.SCP.  Both search for OA$SITE_LIB:SITE_SM_RENAME.COM
    and execute it before they finish.
    
    Is this command procedure ment to be executed twice ?  Or is this just
    something that was over looked ?
    
    Regards,
    
    Sunil
T.RTitleUserPersonal
Name
DateLines
2245.1The way it worksIOSG::MAURICEBecause of the architect the building fell downThu Feb 11 1993 08:5154
    Hi Sunil,
    
    It's not very elegant is it!? This "design" has been in the product for
    a long time now, and it's difficult to change it without impacting
    existing applications.
    
    The first time it is called as in the ALL-IN-1 sub-process which means
    that it can access ALL-IN-1 symbols.
    
    The second time it is called from DCL which means that it can run up
    ALL-IN-1 without the /NOCUST parameter.
    
    When I had to write one of these the first few lines were:
    
    $! Get rename user parameters & check that we are being run from ALL-IN-1.
    $! The first call is as a subprocess of ALL-IN-1 from sm_rename.scp, and
    $! the second call outside of ALL-IN-1 from sm_rename.com.
    $!
    $! The first call will do the DCL work and collect parameters required
    $! for the second call. The second call will invoke ALL-IN-1 without the
    $! /NOCUST parameter.
    $!
    $ on error then continue
    $ old_a1_username = ""
    $ new_a1_username = ""
    $!
    $ define sys$error NL:
    $ define sys$output NL:
    $ write oamailbox "oa get #a1_username"
    $ @dclmailbox:
    $ deassign sys$error
    $ deassign sys$output
    $ if "''result'" .eqs. "" then goto second_time
    $ old_a1_username := 'result
    $!
    $ write oamailbox "oa get #new_a1_username"
    $ @dclmailbox:
    $ if "''result'" .eqs. "" then exit
    $ new_a1_username := 'result
    
    ...
    
    $second_time:
    $!
    $! Invoke ALL-IN-1 without the /NOCUST  parameter.
    $!
    $ ALLIN1/USER="''manager'"/NOINITIALIZE/REENTER/LANGUAGE='language'
    oa$ini_init
    
    ...
    
    HTH
    
    Stuart
2245.2Another way to do itIOSG::SHOVEDave Shove -- REO2-G/M6Thu Feb 11 1993 11:245
    You can also find out if you're in the ALL-IN-1 subprocess by seeing if
    logical OAMAILBOX is defined (of course, it'll be undefined in a normal
    process).
    
    Dave.