DBA Data[Home] [Help]

APPS.ZPB_USER_UPDATE dependencies on BISM_SUBJECTS

Line 8: t_subjecttype bism_subjects.subject_type%type;

4:
5: b_userexists boolean :=true;
6: b_groupexists boolean :=true;
7: b_writetolog boolean :=false;
8: t_subjecttype bism_subjects.subject_type%type;
9: t_subname bism_subjects.subject_name%type;
10: t_newguid bism_objects.object_id%type := null;
11: t_subid1 bism_subjects.subject_id%type;
12: t_subjecttype1 bism_subjects.subject_type%type;

Line 9: t_subname bism_subjects.subject_name%type;

5: b_userexists boolean :=true;
6: b_groupexists boolean :=true;
7: b_writetolog boolean :=false;
8: t_subjecttype bism_subjects.subject_type%type;
9: t_subname bism_subjects.subject_name%type;
10: t_newguid bism_objects.object_id%type := null;
11: t_subid1 bism_subjects.subject_id%type;
12: t_subjecttype1 bism_subjects.subject_type%type;
13: t_subid2 bism_subjects.subject_id%type;

Line 11: t_subid1 bism_subjects.subject_id%type;

7: b_writetolog boolean :=false;
8: t_subjecttype bism_subjects.subject_type%type;
9: t_subname bism_subjects.subject_name%type;
10: t_newguid bism_objects.object_id%type := null;
11: t_subid1 bism_subjects.subject_id%type;
12: t_subjecttype1 bism_subjects.subject_type%type;
13: t_subid2 bism_subjects.subject_id%type;
14: t_subjecttype2 bism_subjects.subject_type%type;
15: n_status zpb_account_states.account_status%type;

Line 12: t_subjecttype1 bism_subjects.subject_type%type;

8: t_subjecttype bism_subjects.subject_type%type;
9: t_subname bism_subjects.subject_name%type;
10: t_newguid bism_objects.object_id%type := null;
11: t_subid1 bism_subjects.subject_id%type;
12: t_subjecttype1 bism_subjects.subject_type%type;
13: t_subid2 bism_subjects.subject_id%type;
14: t_subjecttype2 bism_subjects.subject_type%type;
15: n_status zpb_account_states.account_status%type;
16: t_objectid bism_objects.object_id%type :='31';

Line 13: t_subid2 bism_subjects.subject_id%type;

9: t_subname bism_subjects.subject_name%type;
10: t_newguid bism_objects.object_id%type := null;
11: t_subid1 bism_subjects.subject_id%type;
12: t_subjecttype1 bism_subjects.subject_type%type;
13: t_subid2 bism_subjects.subject_id%type;
14: t_subjecttype2 bism_subjects.subject_type%type;
15: n_status zpb_account_states.account_status%type;
16: t_objectid bism_objects.object_id%type :='31';
17: n_comboexists number :=0;

Line 14: t_subjecttype2 bism_subjects.subject_type%type;

10: t_newguid bism_objects.object_id%type := null;
11: t_subid1 bism_subjects.subject_id%type;
12: t_subjecttype1 bism_subjects.subject_type%type;
13: t_subid2 bism_subjects.subject_id%type;
14: t_subjecttype2 bism_subjects.subject_type%type;
15: n_status zpb_account_states.account_status%type;
16: t_objectid bism_objects.object_id%type :='31';
17: n_comboexists number :=0;
18: n_namelength number :=64;

Line 22: l_subj_user_id bism_subjects.subject_id%type;

18: n_namelength number :=64;
19: n_epbproductid number :=210;
20: n_writepermission number :=20;
21:
22: l_subj_user_id bism_subjects.subject_id%type;
23: l_subj_resp_id bism_subjects.subject_id%type;
24: l_user_exists VARCHAR2(1);
25:
26: cursor usernames is

Line 23: l_subj_resp_id bism_subjects.subject_id%type;

19: n_epbproductid number :=210;
20: n_writepermission number :=20;
21:
22: l_subj_user_id bism_subjects.subject_id%type;
23: l_subj_resp_id bism_subjects.subject_id%type;
24: l_user_exists VARCHAR2(1);
25:
26: cursor usernames is
27: select /*+ LEADING (c) */ distinct(a.user_name) name, a.user_id

Line 119: bism_subjects b1,

115: b2.subject_name resp_sub_name
116: from fnd_user a,
117: fnd_user_resp_groups b,
118: fnd_responsibility c,
119: bism_subjects b1,
120: bism_subjects b2
121: where a.user_id = b.user_id and
122: (c.end_date is NULL or c.end_date > SYSDATE) and
123: b.responsibility_id=c.responsibility_id and

Line 120: bism_subjects b2

116: from fnd_user a,
117: fnd_user_resp_groups b,
118: fnd_responsibility c,
119: bism_subjects b1,
120: bism_subjects b2
121: where a.user_id = b.user_id and
122: (c.end_date is NULL or c.end_date > SYSDATE) and
123: b.responsibility_id=c.responsibility_id and
124: c.application_id=n_epbproductid and

Line 135: select subject_name from bism_subjects

131: b2.subject_id = ast.group_id and
132: ast.business_Area_id = p_business_area_id);
133:
134: cursor deleted is
135: select subject_name from bism_subjects
136: where subject_name <> BIBEANS and subject_name <> ZPBUSER
137: minus
138: (select /*+ LEADING (c) */ distinct(a.user_name)
139: from fnd_user a,

Line 157: bism_subjects y,

153: --
154: cursor reinstated is
155: select /*+LEADING (x) */ y.subject_name
156: from zpb_account_states x,
157: bism_subjects y,
158: fnd_user a,
159: fnd_user_resp_groups b,
160: fnd_responsibility c
161: where x.subject_id = y.subject_id

Line 178: bism_subjects u,

174: -- and user_id <> group_id
175: cursor revokedroles is
176: select u.subject_name uname, g.subject_name gname
177: from zpb_account_states s,
178: bism_subjects u,
179: bism_subjects g
180: where s.account_status <> HIDE_ACCOUNT
181: and u.subject_id = s.subject_id
182: and g.subject_id = s.group_id

Line 179: bism_subjects g

175: cursor revokedroles is
176: select u.subject_name uname, g.subject_name gname
177: from zpb_account_states s,
178: bism_subjects u,
179: bism_subjects g
180: where s.account_status <> HIDE_ACCOUNT
181: and u.subject_id = s.subject_id
182: and g.subject_id = s.group_id
183: and s.business_area_id = p_business_area_id

Line 196: zpb_account_states s, bism_subjects u, bism_subjects g

192: -- roles resinstated for an active user.
193: cursor reinstatedroles is
194: select /*+LEADING (s) */ a.user_name uname, c.responsibility_key gname
195: from fnd_user a, fnd_user_resp_groups b, fnd_responsibility c,
196: zpb_account_states s, bism_subjects u, bism_subjects g
197: where a.user_id = b.user_id
198: and (a.end_date is NULL or a.end_date > SYSDATE)
199: and (b.end_date is NULL or b.end_date > SYSDATE)
200: and b.responsibility_id=c.responsibility_id

Line 220: select SUBJECT_NAME,SUBJECT_TYPE into t_subname,t_subjecttype from bism_subjects where subject_name = each.name;

216: if length(each.name) <= n_namelength then
217: begin
218: b_userexists := true;
219: -- checking user in the Catalog
220: select SUBJECT_NAME,SUBJECT_TYPE into t_subname,t_subjecttype from bism_subjects where subject_name = each.name;
221: -- the following condition should not happen but putting in an additional check
222: if t_subname is null then
223: b_userexists := false;
224: end if;

Line 233: insert into bism_subjects (subject_id, subject_name, subject_type) values (t_newguid,each.name,'u');

229: end;
230:
231: if b_userexists = false then
232: t_newguid := bism_utils.get_guid;
233: insert into bism_subjects (subject_id, subject_name, subject_type) values (t_newguid,each.name,'u');
234: insert into bism_groups (user_id, group_id) values(t_newguid,t_newguid);
235:
236: if (b_writetolog) then
237: FND_LOG.STRING(FND_LOG.LEVEL_PROCEDURE, MODULE_NAME,

Line 271: from bism_subjects

267:
268: -- checking group in the Catalog
269: select SUBJECT_NAME,SUBJECT_TYPE
270: into t_subname,t_subjecttype
271: from bism_subjects
272: where subject_name = eachgroup.role;
273:
274: -- the following condition should not happen but putting in an additional check
275: if t_subname is null then

Line 286: insert into bism_subjects (subject_id, subject_name, subject_type) values(t_newguid,eachgroup.role,'g');

282: end;
283:
284: if b_groupexists = false then
285: t_newguid := bism_utils.get_guid;
286: insert into bism_subjects (subject_id, subject_name, subject_type) values(t_newguid,eachgroup.role,'g');
287:
288: -- give user some default privileges
289: insert into bism_permissions(subject_id, object_id, privilege) values(t_newguid, t_objectid, n_writepermission);
290:

Line 332: FROM bism_subjects a,

328: FOR brand_new_user_resp_rec IN brand_new_user_resp_csr LOOP
329:
330: SELECT subject_id
331: INTO l_subj_user_id
332: FROM bism_subjects a,
333: fnd_user b
334: WHERE a.subject_name = b.user_name
335: AND b.user_id = brand_new_user_resp_rec.user_id
336: AND a.subject_type = 'u';

Line 340: FROM bism_subjects a,

336: AND a.subject_type = 'u';
337:
338: SELECT subject_id
339: INTO l_subj_resp_id
340: FROM bism_subjects a,
341: fnd_responsibility b
342: WHERE a.subject_name = b.responsibility_key
343: AND b.responsibility_id = brand_new_user_resp_rec.resp_id
344: AND a.subject_type = 'g';

Line 506: from bism_subjects

502: -- delete users and groups that are no longer in the EPB domain
503: for eachdeleted in deleted loop
504:
505: select subject_id into t_subid1
506: from bism_subjects
507: where subject_name = eachdeleted.subject_name;
508:
509: --remove the following code to ensure hidden accounts
510: --do not get reset to expired, bug 2968955

Line 548: from bism_subjects

544:
545: -- reset reinstated(unexpired) users
546: for eachreinstated in reinstated loop
547: select subject_id into t_subid1
548: from bism_subjects
549: where subject_name = eachreinstated.subject_name;
550:
551: -- mark all accounts as new
552: update zpb_account_states

Line 573: from bism_subjects

569: -- remove users from groups whose relationship no longer exists in the EPB domain
570: for eachrevoked in revokedroles loop
571:
572: select subject_id into t_subid1
573: from bism_subjects
574: where subject_name = eachrevoked.uname;
575:
576: select subject_id into t_subid2
577: from bism_subjects

Line 577: from bism_subjects

573: from bism_subjects
574: where subject_name = eachrevoked.uname;
575:
576: select subject_id into t_subid2
577: from bism_subjects
578: where subject_name = eachrevoked.gname;
579:
580: -- delete bism_groups
581: -- where user_id = t_subid1

Line 605: from bism_subjects

601:
602: -- reset reinstated(unexpired) roles for active users
603: for eachreinstatedrole in reinstatedroles loop
604: select subject_id into t_subid1
605: from bism_subjects
606: where subject_name = eachreinstatedrole.uname;
607:
608: select subject_id into t_subid2
609: from bism_subjects

Line 609: from bism_subjects

605: from bism_subjects
606: where subject_name = eachreinstatedrole.uname;
607:
608: select subject_id into t_subid2
609: from bism_subjects
610: where subject_name = eachreinstatedrole.gname;
611:
612: -- mark all accounts as new
613: update zpb_account_states

Line 655: l_subject_id bism_subjects.subject_id%type;

651: procedure init_user_session (p_user_id in number,
652: p_resp_id in number,
653: p_business_area_id in number) is
654:
655: l_subject_id bism_subjects.subject_id%type;
656: l_group_id bism_subjects.subject_id%type;
657:
658: begin
659:

Line 656: l_group_id bism_subjects.subject_id%type;

652: p_resp_id in number,
653: p_business_area_id in number) is
654:
655: l_subject_id bism_subjects.subject_id%type;
656: l_group_id bism_subjects.subject_id%type;
657:
658: begin
659:
660: savepoint init_user_session;