Re: SQL*Forms & Multiple logons

From: Bruce Pihlamae <pihlab_at_cbr.hhcs.gov.au>
Date: 27 Sep 94 14:06:18 +1000
Message-ID: <1994Sep27.140618.1_at_cbr.hhcs.gov.au>


In article <367795$cnb_at_deathstar.cris.com>, Jpm_at_deathstar.cris.com (Jpm) writes:
>
> We're developing a Forms application which needs to let a user sign on under
> their own account, select some options, then display other options based on
> data contained in a second account. This second account is determined by
> some of the initial user selections, so it's not predetermined. Can anyone
> help me figure out how to connect to the second account, get the needed
> info,a nd bring it back for use with the first connection? For some very
> ugly reasons that I can't go into here, using grants is not an option.

If you just want to display the other account's information then you could try using database links to the second accounts tables.

Pre-create all the database links (one for each possible 'second' account).

When you have worked out which 'second' acount (and object?) you simply create a SYNONYM for the object link.

      eg (VAX/VMS) CREATE SYNONYM abc FOR user.object_at_dblink;

Your form can now use the current user's tables and the synonym abc.

Remember to drop the synonym after you are finished with it OR drop it just before recreating it each time.

Don't do too complex a query as databse links are a bit slow under Oracle V6.

If you want UPDATE access then you will need Oracle7 and 2phase commit option. Actually, I have a possible work around that is more complex but might give you distributed update without 2phase or Oracle7. It will be slower and clunckier but it should work.

Hope that's of some help.

-- 

Bruce...        pihlab_at_cbr.hhcs.gov.au

*******************************************************************
* Bruce Pihlamae  --  Database Administration                     *
* Commonwealth Department of Human Services and Health            *
* Canberra, ACT, Australia                        (W) 06-289-7056 *
*=================================================================*
* These are my own thoughts and opinions, few that I have.        *
*******************************************************************

"The more complex the argument gets, the easier it is to refute."
"Killing is wrong!"  -- Trent 'The Uncatchable' Castanaveras
Received on Tue Sep 27 1994 - 05:06:18 CET

Original text of this message