From: dwarakv@hotmail.com
Subject: Fetching records matching condition in a master-detail relation
Date: 1998/04/20
Message-ID: <6hh87u$fg8$1@nnrp1.dejanews.com>#1/1
X-Http-User-Agent: Mozilla/4.0 (compatible; MSIE 4.0; MSN 2.5; Windows 95)
Organization: Deja News - The Leader in Internet Discussion
X-Article-Creation-Date: Tue Apr 21 04:44:46 1998 GMT
Newsgroups: comp.databases.oracle.tools,comp.databases.oracle.misc,comp.databases.oracle.server



Hi,
   I have a form with a master-detail blocks. I have the user logging into
the application using his/her private code(user_id). When the user performs a
query on the master block, I would like him/her to see only the people
associated with him. For e.g., I have users 1, 2. The people associated with
user 1 are 6, 7, 8. Those associated with 2 are 9, 10, 11. When user 1
performs a query, he should be able to see only the records corresponding to
people 6, 7, 8 and he should NOT be able to see anything relating to people
9, 10, 11. I do have an LOV which lets user 1 select only from people 6, 7,
8. But if the user hits F8, the query shows all the people, namely, 6, 7, 8,
9, 10, 11. Is there some way I can do this? I tried assigning to the where
clause of the master block this condition (master_block.user = user_id, but
when I try to query, I get error FRM-40505 (unable to perform query)).

  I have a second related question. I have different fields in the detail
block. One of the fields is a status field which tells if the person is in
the company or not. When doing the query, I don't need the query to show
people who are no longer in the company. For e.g in the above example itself,
if person 8 was terminated, when user 1 does a query he should see only
people 6, 7 and NOT 8.

Thanks
Dwaraka

-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/   Now offering spam-free web-based newsreading


