Friday, 28 July 2017

How to make a .tar file on Linux

https://dbissues.blogspot.com/2017/07/how-to-make-tar-file-on-linux.html

tar -czvf tt_new.tar tt

Thursday, 11 May 2017

PLSQL Queries for User Sessions

http://dbissues.blogspot.com/2017/05/plsql-queries-for-user-sessions.html

1: Use this SQL statement  to check the query of current/Active users
=============================================================
select fnd.user_name, icx.responsibility_application_id, icx.responsibility_id, frt.responsibility_name,
icx.session_id, icx.first_connect,
icx.last_connect,
DECODE ((icx.disabled_flag),'N', 'ACTIVE', 'Y', 'INACTIVE') status
from
fnd_user fnd, icx_sessions icx, fnd_responsibility_tl frt
where
fnd.user_id = icx.user_id
and icx.responsibility_id = frt.responsibility_id
and icx.disabled_flag <> 'Y'
and trunc(icx.last_connect) = trunc(sysdate)
order by icx.last_connect;

2:  Use this SQL statement to count number of concurrent_users connected to Oracle apps:
===========================================================================
select count(distinct d.user_name) from apps.fnd_logins a, v$session b, v$process c, apps.fnd_user d
where b.paddr = c.addr and a.pid=c.pid and a.spid = b.process and d.user_id = a.user_id
and (d.user_name = ‘USER_NAME’ OR 1=1)

3:  Use this SQL statement to count number of users connected to Oracle Apps in the past 1 hour.
=============================================================================
select count(distinct user_id) “users” from icx_sessions where last_connect > sysdate – 1/24 and user_id != ‘-1’;

4:  Use this SQL statement to get number of users connected to Oracle Apps in the past 1 day.
==========================================================================
select count(distinct user_id) “users” from icx_sessions where last_connect > sysdate – 1 and user_id != ‘-1’;

5:  Use this SQL statement to get number of users connected to Oracle Apps in the last 15 minutes.
============================================================================
select limit_time, limit_connects, to_char(last_connect, ‘DD-MON-RR HH:MI:SS’) “Last Connection time”, user_id, disabled_flag from icx_sessions where last_connect > sysdate – 1/96;

6: How do we know how many users are connected to Oracle Applications
==========================================================
select distinct fu.user_name User_Name,fr.RESPONSIBILITY_KEY Responsibility
from fnd_user fu, fnd_responsibility fr, icx_sessions ic
where fu.user_id = ic.user_id AND
fr.responsibility_id = ic.responsibility_id AND
ic.disabled_flag='N' AND
ic.responsibility_id is not null AND
ic.last_connect like sysdate;
7: Count Number of concurrent_users in Oracle apps?
============================================
select count(distinct d.user_name) from apps.fnd_logins a,
v$session b, v$process c, apps.fnd_user d
where b.paddr = c.addr
and a.pid=c.pid
and a.spid = b.process
and d.user_id = a.user_id
and (d.user_name = 'USER_NAME' OR 1=1);

8:How to find out which users are logged on to an Apps instance :-
====================================================
FND_USER table stores the details of all the end users. If we give this query:
select user_name,to_char(last_logon_date,'DD-MON-YYYY HH24:MI:SS')
from apps.fnd_user
where to_char(last_logon_date,'DD-MON-YYYY')=to_char(sysdate,'DD-MON-YYYY');

9: You can check the number of user session for the application using ICX_SESSIONS table. Use below query for checking the number of user sessions.
=================================================================================
select ((select sysdate from dual)),(select  ‘ user sessions : ‘ || count( distinct session_id) How_many_user_sessions
from icx_sessions icx
where disabled_flag != ‘Y’
and PSEUDO_FLAG = ‘N’
and (last_connect + decode(FND_PROFILE.VALUE(‘ICX_SESSION_TIMEOUT’), NULL,limit_time, 0,limit_time,FND_PROFILE.VALUE(‘ICX_SESSION_TIMEOUT’)/60)/24) > sysdate
and counter < limit_connects) from dual

Tuesday, 1 November 2016

How to Check Database Character Set (PLSQL Query)

http://dbissues.blogspot.com/2016/11/how-to-check-character-set-query-in.html

select * from v$nls_parameters where parameter like '%CHARACTERSET%';

select * from NLS_DATABASE_PARAMETERS ;

Saturday, 22 October 2016

INS-32011: The string that you have specified contains the space character.

http://dbissues.blogspot.com/2016/10/ins-32011-string-that-you-have.html

INS-32011: The string that you have specified contains the space character.
Cause: The string you entered contains the space character.
Action: Please choose a string containing only alphanumeric, and a few additional characters that are allowed for your platform.

Remove Spaces from Path if any.

[INS-13001] Environment does not meet minimum requirements error." appears. How can I prevent it from appearing?

http://dbissues.blogspot.com/2016/10/ins-13001-environment-does-not-meet.html

Question

When installing the Oracle 11g 32-bit client on a Microsoft Windows 2012 Server R2 64-bit server, a dialog box displaying "[INS-13001] Environment does not meet minimum requirements error." appears. How can I prevent it from appearing?

Answer

To prevent this dialog box from appearing, do the following:
  1. Right click on the setup.exe for the Oracle 11g 32-bit client, and select Properties.
  2. Select the Compatibility tab, and set the Compatibility mode to Windows 7.
  3. Click OK to close the Properties tab.
  4. Double click setup.exe to install the client.

The following document is for handling printer issue in linux/unix. (How to Cancel Print Requests from Oracle)

http://dbissues.blogspot.com/2016/10/how-to-cancel-all-prints-from-all.html

1:) The following command will delete single request .
cancel queuename

2:) The following command will provide u the list of all and current and old process.
lpstat

3:) The following command will provide You the list of printer with name.
lpstat (printername)

4:) You can cancel only jobs owned by you, or by an specified user (provided that you have the rights to do it).

cancel -u user

5:) The following command will cancel all job related to any printer .

cancel -a

Friday, 26 August 2016

How to Restart Printer Services in Oracle

http://dbissues.blogspot.com/2016/08/how-to-restart-printer-services-in.html

Connect to root from Database

su - root
Pwd:
service cups restart


exit
exit