How to calculate number of threads  running  on Windows 2000 terminal?

How to calculate number of threads running on Windows 2000 terminal for the oracle process?
I have installed Oracle 9i DataBase with 6 patch(9.2.0.6.0) on Windows 2000 Terminal.
But,after database is started up, when i check up the sessions in v$session view.
It is showing like for SYSTEM osuser alone, 10 ORACLE.EXE sessions running on this server machine in active state.
Why it is creating 10 ORACLE.EXE sessions for a single Oracle Server.
This is the output of v$session view.
SQL> select terminal,osuser,status,sid,serial#,program from v$session;
TERMINAL OSUSER STATUS SID SERIAL# PROGRAM
IMGDBSVR SYSTEM ACTIVE 1 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 2 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 3 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 4 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 5 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 6 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 7 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 8 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 9 1 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 10 1 ORACLE.EXE
SUGANTHI_DBA suganthi ACTIVE 11 91 sqlplusw.exe
11 rows selected.
SQL>

This is how i have related these two views:
SQL> select s.terminal,s.osuser,s.status,s.paddr s_paddr,b.paddr p_paddr,s.program
2 from v$session s,gv$bgprocess b
3 where s.paddr=b.paddr;
TERMINAL OSUSER STATUS S_PADDR P_PADDR PROGRAM
IMGDBSVR SYSTEM ACTIVE 33AF2270 33AF2270 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF2654 33AF2654 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF2A38 33AF2A38 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF2E1C 33AF2E1C ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF3200 33AF3200 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF35E4 33AF35E4 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF39C8 33AF39C8 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF3DAC 33AF3DAC ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF4958 33AF4958 ORACLE.EXE
IMGDBSVR SYSTEM ACTIVE 33AF4D3C 33AF4D3C ORACLE.EXE
10 rows selected.
SQL>
Here, It shows 10 sessions are running.
Whether this means 10 threads are running on the particular server or not?

Similar Messages

  • Is there any way to limit the number of Threads running in Application(JVM)

    Hello all,
    is there any way to limit the number of Threads running in Application(JVM)?
    how to ensure that only 100 Threads are running in an Application?
    Thanks
    Mohamed Javeed

    You should definitely use a thread pool for this. You can specify maximum number of threads that can be run. Be note that the thread pool will only limit the number of threads that are submitted to it. So donot call "Thread"s start() method to start thread on your own. Submit it to the pool. To know more, study about executor service and thread pool creation. Actually it will not be more than 20 line code for a class and you might need maximum of 2 such classes, one for threadPool and other one for rejection handler (if you want).
    Just choose the queue used carefully, you just have to pass it as a parameter to the pool.
    You should use "Bounded" queue for limiting threads, but also be careful in using queues like SynchronizedQueue as the queue will execute immediately the threads submitted to it if maximum number of threads have not been running. Otherwise it will reject it and you should use rejection handler. So if your pool has a synchronized queue of size 100, if you submit 101th thread, it will be rejected and is not executed.
    If you want some kind of waiting mechanism, use something like LinkedBlockingQueue. What this will do is even if you want 100 threads, you can specify the queue's size to be 1000, so that you can submit 1000 threads, only 100 will run at a time and the remaining will wait in the queue. They will be executed when each thread already executing will complete. Rejection occurs only when the queue oveflows.

  • How to calculate number of rows for perticular characterstic in SAP BI Bex

    Hi experts,
    Please let me know how to calculate  ' number of rows  ' for perticular characterstic in Bex query. 
    Thanks & Regards,
    Babu..

    Hello,
    You can try this
    Create a CKF and assign the vale 1 to it. Open the query and select Character where you want to display ' number of rows ', go to properties windows, select 'display', in the results row drop down box, select  'always display'.
    Thanks.
    With regards,
    Anand Kumar

  • How to calculate  number of sundays and saturdays between two Dates

    friends i want to calculate how many Sundays come in two Dates
    i have tried following code which is hard coded i have to impliment method which can give me number of Sundays between two Dates
    please help me
    import java.util.Date;
         import java.text.DateFormat;
         import java.text.SimpleDateFormat;
         import java.util.Calendar ;
         import java.util.GregorianCalendar;
    public class DateDiffCalculator     {
         private static final SimpleDateFormat SDF = new SimpleDateFormat("yyyy-MMM-dd");
    public DateDiffCalculator()     {
         public static Date getDate (String date) throws Exception {
    //log.debug(" "+date);
              return SDF.parse(date);
    public static Date getDate (Date date) throws Exception {
    // log.debug("date is "+date);
              return getDate(SDF.format(date));
    public static long getDiffInDays(Date d1,Date d2)     {
         boolean isdiffGreaterThanYear=false;
         long diffInMilliSeconds=d1.getTime()-d2.getTime();
         return diffInMilliSeconds/(1000*60*60*24);
    public static int getYear(String date)     {
              //String[] day=     {Sun,Mon,Tue,Wed,Thu,Fri,Sat};
              Integer     year=new     Integer(date.substring(0,4));
         return year.intValue();
    public static int getMonth(String date)     {
              //String date.substring(5,7);
              System.out.println(" "+date.substring(5,8));
              String     m= date.substring(5,8);
              int month=0;
              if(m.equalsIgnoreCase("Jan"))     {
              month=1;
              if(m.equalsIgnoreCase("Feb"))     {
              month=2;
              if(m.equalsIgnoreCase("Mar"))     {
              month=3;
              if(m.equalsIgnoreCase("Apr"))     {
              month=4;
              if(m.equalsIgnoreCase("May"))     {
              month=5;
              if(m.equalsIgnoreCase("Jun"))     {
              month=6;
              if(m.equalsIgnoreCase("Jul"))     {
              month=7;
              if(m.equalsIgnoreCase("Aug"))     {
              month=8;
              if(m.equalsIgnoreCase("Sep"))     {
              month=9;
              if(m.equalsIgnoreCase("Oct"))     {
              month=10;
              if(m.equalsIgnoreCase("Nov"))     {
              month=11;
              if(m.equalsIgnoreCase("Dec"))     {
              month=12;
              return month;
         public static int getDay(String date)     {
              Integer     day=new     Integer(date.substring(9,11));
         return day.intValue();
    public static int getNumberofSundays(String d1,String d2) throws Exception     {
              //d1 is leave start date d2 is leave end date
              // get object in Date form
                   Date date1=getDate(d1);
                   Date date2=getDate(d2);
              // now get calender objects from it
              GregorianCalendar c1= new GregorianCalendar(getYear(d1),getMonth(d1),getDay(d1));
              GregorianCalendar c2= new GregorianCalendar(getYear(d2),getMonth(d2),getDay(d2));
              // get period
              long leavePeriod = getDiffInDays(date1,date2);
         return 12; // it should return number of sundays but we type 12 to perform compilation
    public static void main(String[] arg)throws Exception     {
    System.out.println(" "+getNumberofSundays("2005-Oct-07","2006-Mar-01"));
    }

    thanks now i have modified the get Month Code
    as follows
    public static int getMonth(String date)     {
              //String date.substring(5,7);
              System.out.println(" "+date.substring(5,8));
              String     m= date.substring(5,8);
              int month=0;
              if(m.equalsIgnoreCase("Jan"))     {
              month=0;
              if(m.equalsIgnoreCase("Feb"))     {
              month=1;
              if(m.equalsIgnoreCase("Mar"))     {
              month=2;
              if(m.equalsIgnoreCase("Apr"))     {
              month=3;
              if(m.equalsIgnoreCase("May"))     {
              month=4;
              if(m.equalsIgnoreCase("Jun"))     {
              month=5;
              if(m.equalsIgnoreCase("Jul"))     {
              month=6;
              if(m.equalsIgnoreCase("Aug"))     {
              month=7;
              if(m.equalsIgnoreCase("Sep"))     {
              month=8;
              if(m.equalsIgnoreCase("Oct"))     {
              month=9;
              if(m.equalsIgnoreCase("Nov"))     {
              month=10;
              if(m.equalsIgnoreCase("Dec"))     {
              month=11;
              return month;
    but question remains same how to calculate number of Sundays Between 2 Dates

  • Oracle 8i Client running on Windows 2000 Server

    Hi,
    I have Oracle 8i Client running on Windows 2000 Server. I need to connect to Oracle 8i Server running on Sun Box.
    I have problems with connectivity.
    When I do tnsping <service name>, I am geting the followiing
    error:
    C:\>tnsping <Instance name>
    TNS Ping Utility for 32-bit Windows: Version 8.1.7.0.0 - Production on 04-FEB-20
    02 16:37:01
    (c) Copyright 1997 Oracle Corporation. All rights reserved.
    Attempting to contact (ADDRESS=(PROTOCOL=TCP)(HOST=<IP Address>)(PORT=1521)) TNS-12541: TNS:no listener
    Can any one help me out
    Thanks
    mka

    Hi,
    I have Oracle 8i Client running on Windows 2000 Server. I need to connect to Oracle 8i Server running on Sun Box.
    I have problems with connectivity.
    When I do tnsping <service name>, I am geting the followiing
    error:
    C:\>tnsping <Instance name>
    TNS Ping Utility for 32-bit Windows: Version 8.1.7.0.0 - Production on 04-FEB-20
    02 16:37:01
    (c) Copyright 1997 Oracle Corporation. All rights reserved.
    Attempting to contact (ADDRESS=(PROTOCOL=TCP)(HOST=<IP Address>)(PORT=1521)) TNS-12541: TNS:no listener
    Can any one help me out
    Thanks
    mka

  • Will the firefox web browser run on windows 2000?

    I'm new to firefox and have one question.
    Will the firefox web browser run on windows 2000?
    System details: Win 2000, Version 5, SP 4. X86 @ 930MHz.
    Will download and try. Thank you for your help.

    Firefox should run on windows 2000, what are the system specs?
    Let me know if it doesn't.

  • How to calculate number of days in hijri

    Dear all,
    I need to develop a custom report in which i required to calculate number of days in hijri month and also the first and last day of the hijri month. we normally use Last_date(sysdate) function to get the last date of the english calender. but how can we find same for month.
    Looking after for your support.
    Regards,
    Saquib

    Convert to hirjih date using:
    select
    to_char(sysdate,'YYYY/MM/DD','NLS_CALENDAR=''English Hijrah''') hijrih_date
    from dual;
    You can replace sysdate with the date of your choice.
    Also I wrote this for my last project:
    /* get hirjih date */
    FUNCTION get_hijrah_date(
    p_date in date,
    p_date_format in varchar2
    ) return varchar2
    is
    v_hijrah_date varchar2(500);
    begin
    select
    to_char(p_date,p_date_format,'NLS_CALENDAR=''English Hijrah''')
    into v_hijrah_date
    from dual;
    return v_hijrah_date;
    end get_hijrah_date;
    So you can have get_hijrah_date(sysdate,'DD-MON-YYYY') from dual;
    (or any other date formate of your choice)
    Edited by: igwe on Jan 30, 2013 8:07 AM

  • How to calculate Number of weeks in Year ?? urgent

    hi gurus,
    i have to calculate the number of weeks in year. could you please suggest me is there any function module for that or do we need to create variable to get the number of weeks?
    regards

    Get some pointers frm
    http://sap.ittoolbox.com/groups/technical-functional/sap-dev/help-on-function-day_get_week-1067350
    Re: printing calender
    Calculating the number of days of a year including leap year
    Re: How to calculate No.of Weeks?

  • How to throw Exception in Thread.run() method

    I want to throw exception in Thread.run() method. How can I do that ?
    If I try to compile the Code given below, it does not allow me to compile :
    public class ThreadTest {
         public static void main(String[] args) {
         ThreadTest.DyingThread t = new DyingThread();
         t.start();
         static class DyingThread extends Thread {
         public void run() {
         try {
                   //some code that may throw some exception here
              } catch (Exception e) {
              throw e;//Want to throw(pass) exception to caller
    }

    (a) in JDK 1.4+, wrap your exception in RuntimeException:
    catch (Exception e)
    throw new RuntimeException(e);
    [this exception will be caught by ThreadGroup.uncaughtException() of this thread's parent thread group]
    In earlier JDKs, use your own wrapping unchecked exception class.
    (b) if you know what you are doing, you can make any Java method throw any exception using Thread.stop(Throwable) regardless of what it declares in its "throws" declaration.

  • How to calculate Number of Hours between 2 dates

    Hi,
    I have a Column in a table of datatype DATE i.e. Update_Date. Now How do I calculate number of hours passed starting from this date entered in the Update_Date column to SYSDATE. e.g. if the date in column is 2-FEB-2009 and the sysdate is 2/2/2009 2:07:40 AM it should give me 24. How can I get this number of hours.
    Update_Date - Sysdate = Number of Hours.
    Thanks

    When you subtract two dates in Oracle, you get a difference in terms of days. Just multiply that by 24 to get hours.
    SELECT (sysdate - update_date) days,
           (sysdate - update_date) * 24 hours
      FROM your_tableThat said, it is not obvious how your example works. You state
    if the date in column is 2-FEB-2009 and the sysdate is 2/2/2009 2:07:40 AM it should give me 24Since both dates are on February 2, 2009, the only difference is in the time component. If we assume that the time component of the UPDATE_DATE value is midnight since it is not specified, there is a little more than 2 hours of difference between the two dates. How is it that you determine there are 24 hours of difference?
    Justin
    Edited by: Justin Cave on Feb 2, 2009 10:39 AM

  • How to calculate number of employees according to gender

    Now our customer want to calculate number of employees(0HDCNT_LAST) according to gender, expecially for female employee. we know that SAP has gender infoobject(0GENDER), and male with 1 and female with 2.
    1) how should we use infoobject 0GENDER with female information connect R/3 table, and calculate number of employees at the end of one periode or time point? Should we use infoobject 0GENDER in cube?
    2) How to write ABAP code? And what should we do in BW side ? should we do some enhancement?

    Hi,
    you can use 0GENDER in your Cube. If you want to count you can do this in query.
    For counting you build your own calculated key figure (formula).
    Create a calculated keyfigure on global, formula ' =1' . Then drag this newly created global KF to the report column, restrict it with 0GENDER wich is restricted to male or female .
    This would provide a count based on 0GENDER
    Regards
    Andreas

  • How to know number of databases running

    HI Experts,
    How to easily know how many databases are running in Windows OS and Solaris OS
    Thanks
    Shaan

    Hi Adith,
    It means i have to loggin to sqlplus, but even if i logging to sqlplus it won't show total numbers of databases running on the server. Is there any other way to know.
    My query is how do I know about number and name of the databases running on a server which is unknown to me. Lsnrctl is one option, but it also doesn't give the 100% result.
    Thanks
    Shaan

  • How to calculate number of data records in a XML output file

    Hi,
    After generating a XML output file from Oracle Reports, I want to calculate number of records in the XML file. Is it possible? Specifically, I want to calculate number of records for a group variable ( organization_id, which I use for bursting).
    Thanks for the help.

    Thanks BIPuser. It is useful for me.
    I can use this xsl function within the template. However, I'm also looking to print this in the concurrent request log file. So, outside of rtf template, id there any PL/SQL based XML functions I can use to count the number of records.
    Thanks.

  • How to calculate number of cutomers that have bought more than variable qnt

    Hi BW Gurus!
    My InfoProvider has following structure:
    CalDay     BusinessPartner1 Customer SoldQnty
    01.02.2005                    1               3       100
    02.02.2005                    2               4       50
    03.02.2005                    1               3       150
    04.02.2005                    1               3       70
    I need to calculate a number of Customers who has bought more than user typed quantity.
    If user input 90 then according to my example number of customers should be 1.
    If user input 40 then number of customers should be 2.
    I have to use formula variable so that user could input quantity.
    In this case I cannot use calculated key figure with type "assignment" to redefine exceptional aggregation.
    Please help.
    Any responce is highly appreciated.
    Thanx!

    Hi Bhanu!
    Thank you for your response!
    I will describe my problem more precisely.
    InfoProvider has(approximately) following structure:
    CalDay BPartner1 BPartner2 BPartner3 Customer SoldQty
    02.02.2005   1       2        3       101        90
    02.02.2005   1       2        4       101       120
    03.02.2005   1       2        3       102        50
    03.02.2005   1       2        4       101       150
    04.02.2005   1       2        3       103       150
    We have to build a query  to calculate a number of customers which have SoldQty greater than predefined by user on selection screen by variable with possibility to drill-down with all BusinessPartners.
    CalDay is restricted by interval variable.
    According to example above
    report should have following result for variable
    for SoldQty = 100
    and CalDay interval = [01.02.2005 ; 05.02.2005]
    via selection screen
    BPartner2   BPartner3    CountOfCustomers
       2           3                1
       2           4                1
    In case of variable for SoldQty = 80
    and CalDay interval = [01.02.2005 ; 05.02.2005]
    BPartner2   BPartner3     CountOfCustomers
       2           3                2
       2           4                1
    Using formula you described I recieve just 1
    in each row of the report. I can create calculated key figure instead of formula with the same logic(on Infoprovider level)with calculations before aggregation.
    But in that case I calculate number of sales greater than predefined quantity
    and I need number of customers...
    Please help!

  • How to get Illustrator 10 to run on windows 7 ultimate and not in XP mode?

    I have been running Illustrator 10 on windows 7 pro with no problems. I upgraded to a new computer with windows 7 Ultimate and Illustrator will only run in XP mode. It will not open my existing files stating that they were created in a newer version.
    How can Illustrator be run in windows 7 Ultimate?

    Actually, if you go to the program .exe file (usually in Program files(x86)\Adobe\Illustrator 10\Support Files\Contents\Windows).
    Right click on it and select properties.
    Select the Compatibility tab.
    In the section "Compatibility mode".
    Check the box "Run this program ...."
    From the dropdown list select Windows 7
    In the "Settings" section
    Check "Disable visual themes" and "Disable desktop composition"
    This will allow Illustrator to run normally in Windows 7 Pro and Ultimate 64bit systems.

Maybe you are looking for

  • Installing MF4320d Canon on Snow Leopard 10.6.4

    Hello! I've a serious headache since yesterday, when I bought Canon MF4320d. Yesterday I connected it successful, first like scanner (using Euro-version of software Mac Scangear MF V1.20 EN.dmg). Then I spent hour trying to connect it like printer. A

  • Phone only charges when hooked up to mac not to wall...

    My wife's iphone 3G will no longer charge when plugged into the wall, but it will charge when plugged into the imac. I know the plug works because my 3gs is charging right now. any ideas? thanks

  • How to move up the List Box for para. values in the "Edit Values" window?

    Hi, I am using Crystal Reprots 11. I create 10 subreports, and each subreport contains a Parameters Field. The 10 subreports are put in 10 footer sections in increasing order, i.e. subreport1, subreport2, subreport3, ..., subreport10. When I use "Pri

  • Make a BPEL instance recoverable from a BPEL fault hanler?

    Hi Does anybody know of a way to make a BPEL instance recoverable from a BPEL catch fault handler, e.g. using Java to programatically instruct the service engine to do the same thing as when using the fault management framework and fault policies to

  • Can't play video burned on PC

    My son created a slideshow with audio and graphics on his PC, but I can't play it on my Mac. I have QuickTime 7.6 plus Flip4Mac WMV 2.2.1 but I can't figure out how to play the video. When I try to open the DVD, all I get are 4 folders named EXT, MPE