DBA Data[Home] [Help]

APPS.BSC_SECURITY dependencies on V$SESSION

Line 399: v$session s,

395: s.audsid,
396: s.sid,
397: s.serial#
398: From
399: v$session s,
400: v$session_wait w,
401: bsc_current_sessions c
402: Where
403: s.audsid = c.session_id And

Line 400: v$session_wait w,

396: s.sid,
397: s.serial#
398: From
399: v$session s,
400: v$session_wait w,
401: bsc_current_sessions c
402: Where
403: s.audsid = c.session_id And
404: s.sid = w.sid And

Line 462: --Where session_id Not In (Select vs.audsid From V$Session vs);

458:
459: BSC_SECURITY.Refresh_System_Lock(x_program_id);
460: -- Clean BSC_CURRENT_SESSIONS to leave only current sessions
461: --Delete bsc_current_sessions
462: --Where session_id Not In (Select vs.audsid From V$Session vs);
463: --commit;
464: --
465: -- Clean BSC_CURRENT_SESSIONS for ibuilder when users click "logout" button
466: -- Added for BIS Application ID (191), so that loader session is not removed.

Line 522: --Where session_id In (Select vs.audsid From V$Session vs Where vs.status = 'KILLED');

518: --
519: -- Delete KILLED sessions from bsc_current_sesions
520: -- Even tough we do not kill session, we can try this.
521: --Delete bsc_current_sessions
522: --Where session_id In (Select vs.audsid From V$Session vs Where vs.status = 'KILLED');
523: --commit;
524:
525: -- Make the query to validate if the application can run or not.
526: IF x_program_id = -600 then

Line 536: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

532:
533: -- fixed the following SQLS for the literals bug
534:
535: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
536: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
537: ' WHERE c.session_id = s.audsid'||
538: ' AND c.program_id in (-700, -800)'||
539: ' AND c.session_id <> :1 '||
540: ' AND c.user_id = u.user_id (+)';

Line 548: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

544: -- Several instances can run at the same time.
545: -- It can run at the same time with iViewer, Metadata Optimizer(Generate Documentation or Rename input tables)
546: -- They cannot run at the same time with Loader or Metadata(Configure Indicators), Upgrade or Migration.
547: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
548: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
549: ' WHERE c.session_id = s.audsid'||
550: ' AND c.program_id in (-100, -101, -200, -700, -800, -802)'||
551: ' AND c.session_id <> :1 '||
552: ' AND c.user_id = u.user_id (+)';

Line 561: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

557: -- They can run at the same time with iViewer, Security and Metadata Optimizer (Rename input tables)
558: -- They cannot run at the same time with Loader, Metadata(Configure Indicators),
559: -- Metadata Optmizer(Generate documention), Upgrade or Migration.
560: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
561: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
562: ' WHERE c.session_id = s.audsid'||
563: ' AND c.program_id in (-100, -101, -200, -201, -700, -800, -802)'||
564: ' AND c.session_id <> :1 '||
565: ' AND c.user_id = u.user_id (+)';

Line 572: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

568: -- Loader UI
569: -- Only one instance at the same time.
570: -- It cannot run at the same time with any other tool but IViewer and Metadata Optmizer(Generate documentation).
571: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
572: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
573: ' WHERE c.session_id = s.audsid'||
574: ' AND c.program_id in (-100, -101, -200, -202, -300, -400, -500, -700, -800, -802)'||
575: ' AND c.session_id <> :1'||
576: ' AND c.user_id = u.user_id (+)';

Line 584: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

580: -- Only one instance at the same time.
581: -- It cannot run at the same time with any other tool but IViewer and Metadata Optmizer(Generate documentation).
582: -- It cannot run with other Loader Concurrent program but It can run with a Loader UI.
583: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
584: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
585: ' WHERE c.session_id = s.audsid'||
586: ' AND c.program_id in (-101, -200, -202, -300, -400, -500, -700, -800, -802)'||
587: ' AND c.session_id <> :1'||
588: ' AND c.user_id = u.user_id (+)';

Line 597: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

593: -- Only one instance at the same time.
594: -- It can run at the same time with: IViewer (Bug 3731337)
595: -- It cannot run at the same time with any other tool.
596: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
597: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
598: ' WHERE c.session_id = s.audsid'||
599: ' AND c.program_id in (-100, -101, -200, -201, -202, -300, -400, -500, -700, -800, -802)'||
600: ' AND c.session_id <> :1 '||
601: ' AND c.user_id = u.user_id (+)';

Line 611: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

607: -- It can run at the same time with: Loader, Security and Viewer
608: -- It cannot run at the same time with: Metadata Optimizer(Configure Indicators or Rename input tables),
609: -- Builder, Designer, Upgrade or Migration
610: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
611: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
612: ' WHERE c.session_id = s.audsid'||
613: ' AND c.program_id in (-200, -202, -400, -500, -700, -800, -802)'||
614: ' AND c.session_id <> :1 '||
615: ' AND c.user_id = u.user_id (+)';

Line 623: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

619: -- It can run at the same time with: Security, Designer, Builder and Viewer
620: -- It cannot run at the same time with: Metadata Optimizer(Configure Indicators or Rename input tables
621: -- or Generate Documentation), Loader, Upgrade or Migration
622: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
623: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
624: ' WHERE c.session_id = s.audsid'||
625: ' AND c.program_id in (-100, -101, -200, -201, -202, -700, -800, -802)'||
626: ' AND c.session_id <> :1 '||
627: ' AND c.user_id = u.user_id (+)';

Line 633: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

629: ELSIF x_program_id = -801 THEN
630: -- Migration ui
631: -- It cannot run if there is any other user in migration UI or migration CON req is running
632: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
633: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
634: ' WHERE c.session_id = s.audsid'||
635: ' AND c.program_id in (-700, -800, -801, -802)'||
636: ' AND c.session_id <> :1 '||
637: ' AND c.user_id = u.user_id (+)';

Line 643: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

639: ELSIF x_program_id = -802 THEN
640: -- Migration backend (source)
641: -- iViewer can run with Migration backend (source)
642: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
643: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
644: ' WHERE c.session_id = s.audsid'||
645: ' AND c.program_id in (-100, -101, -200, -201, -202, -300, -400, -500, -700, -800, -801)'||
646: ' AND c.session_id <> :1 '||
647: ' AND c.user_id = u.user_id (+)';

Line 655: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||

651: -- Only one instance at the same time.
652: -- It cannot run at the same time with any other tool.
653: -- code -801 added for migration UI. migration process can not run if any user is there in UI
654: h_sql := 'SELECT c.program_id, u.user_name, s.machine, s.terminal'||
655: ' FROM bsc_current_sessions c, v$session s, bsc_apps_users_v u'||
656: ' WHERE c.session_id = s.audsid'||
657: ' AND c.program_id in (-100, -101, -200, -201, -202, -300, -400, -500, -600, -700, -800, -801, -802)'||
658: ' AND c.session_id <> :1 '||
659: ' AND c.user_id = u.user_id (+)';

Line 758: FROM V$SESSION VS);

754: --Delete all orphan the sessions
755: DELETE BSC_CURRENT_SESSIONS
756: WHERE SESSION_ID NOT IN
757: (SELECT VS.AUDSID
758: FROM V$SESSION VS);
759:
760: --Delete all the session not being reused by FND
761: DELETE BSC_CURRENT_SESSIONS
762: WHERE ICX_SESSION_ID IN (

Line 798: FROM v$session s, v$session_wait w

794: DELETE BSC_CURRENT_SESSIONS
795: WHERE PROGRAM_ID = -600
796: AND SESSION_ID IN (
797: SELECT s.audsid
798: FROM v$session s, v$session_wait w
799: WHERE s.sid = w.sid
800: AND w.seconds_in_wait > 1200);
801: END IF;
802: END IF;

Line 808: FROM V$SESSION VS

804: --Delete all the Killed Sessions
805: DELETE BSC_CURRENT_SESSIONS
806: WHERE SESSION_ID IN (
807: SELECT VS.AUDSID
808: FROM V$SESSION VS
809: WHERE VS.STATUS = 'KILLED');
810: COMMIT;
811: END Refresh_System_Lock;
812:

Line 876: ' from v$session@'||c_src_db_link||' s'||

872:
873: -- Get the session id in the source system
874: /* changed to fixed bug 2669465
875: h_sql := 'select s.user#, s.audsid'||
876: ' from v$session@'||c_src_db_link||' s'||
877: ' where s.process = ('||
878: ' select vs.process'||
879: ' from v$session vs'||
880: ' where vs.audsid = userenv(''SESSIONID'')'||

Line 879: ' from v$session vs'||

875: h_sql := 'select s.user#, s.audsid'||
876: ' from v$session@'||c_src_db_link||' s'||
877: ' where s.process = ('||
878: ' select vs.process'||
879: ' from v$session vs'||
880: ' where vs.audsid = userenv(''SESSIONID'')'||
881: ' )'; */
882: h_sql := 'select s.user#, s.audsid from bsc_session_v@'||c_src_db_link||' s';
883:

Line 911: ' Where session_id Not In (Select audsid From V$Session@'||c_src_db_link||')';

907: commit;
908:
909: -- Clean BSC_CURRENT_SESSIONS in the source system to leave only current sessions
910: h_sql := 'Delete bsc_current_sessions@'||c_src_db_link||
911: ' Where session_id Not In (Select audsid From V$Session@'||c_src_db_link||')';
912: BSC_APPS.Execute_Immediate(h_sql);
913:
914: commit;
915:

Line 918: ' Where session_id In (Select audsid From V$Session@'||c_src_db_link||

914: commit;
915:
916: -- Delete KILLED sessions from bsc_current_sessions
917: h_sql := 'Delete bsc_current_sessions@'||c_src_db_link||
918: ' Where session_id In (Select audsid From V$Session@'||c_src_db_link||
919: ' Where status = ''KILLED'')';
920: BSC_APPS.Execute_Immediate(h_sql);
921:
922: commit;

Line 929: ' FROM bsc_current_sessions@'||c_src_db_link||' c, v$session@'||c_src_db_link||' s'||

925: -- This procedure is called by MIgration (-800)
926: -- Only one instance at the same time.
927: -- It cannot run at the same time with any other tool.
928: h_sql := 'SELECT c.program_id, s.username, s.machine, s.terminal'||
929: ' FROM bsc_current_sessions@'||c_src_db_link||' c, v$session@'||c_src_db_link||' s'||
930: ' WHERE c.session_id = s.audsid'||
931: ' AND c.program_id in (-100, -101, -200, -201, -202, -300, -400, -500, -600, -700, -800)'||
932: ' AND c.session_id <> :1 ';
933:

Line 1208: h_sql :='SELECT COUNT(*) FROM BSC_CURRENT_SESSIONS C, V$SESSION S, V$SESSION_WAIT W, BSC_APPS_USERS_V U ';

1204: h_cursor t_cursor;
1205:
1206: begin
1207:
1208: h_sql :='SELECT COUNT(*) FROM BSC_CURRENT_SESSIONS C, V$SESSION S, V$SESSION_WAIT W, BSC_APPS_USERS_V U ';
1209: h_sql := h_sql || 'WHERE C.SESSION_ID = S.AUDSID AND S.SID = W.SID AND S.STATUS <> ''KILLED'' AND U.USER_ID = C.USER_ID AND C.PROGRAM_ID = -200';
1210:
1211: yes_no :='N';
1212: -- bug fix 3008243