Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Alternative access solution

Re: Alternative access solution

From: Ed prochak <ed.prochak_at_alltel.com>
Date: 9 Nov 2001 14:50:24 -0800
Message-ID: <e51b160.0111091450.62dfb1c9@posting.google.com>


miha.znidarsic_at_ixtlan-team.si (Miha) wrote in message news:<8c69a0da.0111090431.3fe3f665_at_posting.google.com>...
> Hello.
> We are looking for alternative access solution for our current data structure:
> Simplified:
> ACCOUNT - Account data (ACC_ID)
> ORGANIZATION - Organization data (ORG_ID) - hierarchical structure
> ACCOUNT_ORGANIZATION - Which organizations can access accounts (ACC_ID, ORG_ID)
> USER - User data (USR_ID)
> USER_ORGANIZATION - Which organizations user can access. (USR_ID, OGR_ID)
>
> So we want 2 that user is able to see all of his accounts.
> Currently we do it like this:
> SELECT *
> FROM ACCOUNT ACC
> WHERE EXISTS (SELECT 1
> FROM ACCOUNT_ORGANIZATION ACO
> WHERE ACO.ACC_ID = ACC.ACC_ID AND
> ACO.ORG_ID IN (SELECT ORG_ID
> FROM USER_ORGANIZATION
> WHERE USR_ID = USER)
> )
>
> We tried all possible ways of this structure but is not good enough.
> What we would like is to get rid of ACCOUNT_ORGANIZATION table.
>
> Any ideas.
>
> Thanks in advance.
> Miha

What do you mean by "not good enough"??
  and then do you mean to get rid of ACCOUNT_ORGANIZATION from the query or from the database?

Do you mean you tried other ways of organizing the query, or did you also try reorganizing the tables (different tables with different relations). What exactly did you try?

 Please explain the problem. Received on Fri Nov 09 2001 - 16:50:24 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US