Sql query to  know the number of triggers and cursors present in a schema?

friends,is there any way to know the number of triggers and cursors preseent in a schema.
thanks in advance..

what do you mean by triggers in a schema? is it the triggers owned by that schema? or the triggers applied on tables owned by that schema? remember you may own triggers applied on the tables belong to other schemas. Anyways, all this information can be extracted from oracle dictionary using a combination of all_triggers and all_tables.
As far as cursors, please elaborate. Do you mean cursors declared in PL/SQL blocks?

Similar Messages

  • SQL Query, to know the list of Invoices associated with a sales order

    Hello All,
    Can any one let me know the query to know the list of all the invoices associated with a sales order.
    Please do the needful.
    Thanks,

    Hello All,
    Please let me know is this possible to have the list of Invoices for an associated Sales Order.
    Thanks,
    Abdul

  • Sql Query to know the OS in which database is installed

    Hi,
    I want to know the OS in which my database is installed using SQL Query.
    Is it possible?
    Regards
    Salih KM

    SQL> select dbms_utility.port_string from dual;
    PORT_STRING
    IBM AIX64/RS6000 V4 - 8.1.0
    SQL> Nicolas.

  • SCCM 2007 R2 - SQL query to know the compliance status of the client machines.

    Hi All,
    Can some one share the SQL query that will show the compliance of a "All systems" collection in SCCM 2007 R2 for past six months. I know that it is possible to get the reports from SCCM reporting but would like to run it from database.
    Rgs,

    In SQL queries used in the reports we have prompts and hence I wanted avoid that.
    What wrong with either removing the prompts from the query or hard coding the prompt data?
    Garth Jones | My blogs: Enhansoft and
    Old Blog site | Twitter:
    @GarthMJ

  • What is the sql query to know the database name having known table name?

    when i am running the following query....error coming
    select * from information_schema.tables where table_name = 'articles'
    Error starting at line 1 in command:
    select * from information_schema.tables where table_name = 'articles'
    Error at Command Line:1 Column:33
    Error report:
    SQL Error: ORA-00942: table or view does not exist
    00942. 00000 - "table or view does not exist"
    *Cause:
    *Action:
    i am running the above query in SQLDeveloper tool against ORACLE database
    plz give alternate solution.

    Hi,
    select * from information_schema.tables where table_name = 'articles'You are trying query view ( information_schema.tables ) from MSSQL on ORACLE??!!
    Each RDBMS have your own data dictionary... you must check documention of ORACLE to query the properly data dictionary.
    Try it:
    select * from users_tables where table_name = 'articles'
    or
    select * from all_tables where table_name = 'articles'
    or
    select * from dba_tables where table_name = 'articles'http://docs.oracle.com/cd/E11882_01/server.112/e25494/general011.htm#ADMIN11564
    Regards,
    Levi Pereira

  • SQL Query to get the # of files in folders in a library

    Anyone has the SQL query to list the number of files in each folders in a SharePoint library?

    Technically it's a grey area of support as MS don't mind you doing it but won't help you if you encounter problems, the script is much better though.
    Scratch that, the script isn't that good. It's using .items which won't work on large lists and is slow. The version below is untested but should be significantly faster and work on large lists.
    $starttime = Get-Date
    #Creating new site object
    $siteurl = Read-Host "Enter the name of your site and press enter"
    $site = New-Object Microsoft.SharePoint.SPSite($siteurl)
    #Assigning all webs (sites) to $webs
    $webs = $site.Allwebs
    #System Libraries defined so they won't be touched##
    $systemlibs =@("Converted Forms", "Customized Reports", "Documents", "Form Templates",
    "Images", "List Template Gallery", "Master Page Gallery", "Pages",
    "Reporting Templates", "Site Assets", "Site Collection Documents",
    "Site Collection Images", "Site Pages", "Solution Gallery",
    "Style Library", "Theme Gallery", "Web Part Gallery", "wfpub")
    Write-Host "Total number of webs that will be traversed: " $webs.count
    $DocLibsCount = 0
    $DocLibwItems = 0
    $totalitems = 0
    $subfolderitems = 0
    foreach($web in $webs)
    $listcoll = $web.lists
    foreach($list in $listcoll)
    if($list -eq $null)
    Write-Host
    else
    $base = $list.GetType()
    if($base.name -eq "SPDocumentLibrary")
    if ($systemlibs -contains $list)
    { continue}
    else
    $DocLibsCount += 1
    $totalitems += $List.itemcount
    $name = $list.Title
    $folders = $web.GetFolder($name).SubFolders
    for($etr = 0;$etr -lt $folders.count; $etr++)
    if($folders[$etr].Name -ne "Forms")
    Write-Host "Processing SubFolder ItemCount" -ForegroundColor Red
    $tempcount = $folders[$etr].ItemCount
    $subfolderitems += $tempcount
    Write-Host
    Write-Host
    Write-Host "Total # of Document Libraries: " $DocLibsCount -ForegroundColor Green
    Write-Host "Total # of Document Libraries that contain items: " $DocLibwItems -ForegroundColor Green
    Write-Host "Total # of items: " $totalitems -ForegroundColor Green
    Write-Host "Total # of items in DocLib\Subfolders: " $subfolderitems -ForegroundColor Green
    $finishtime = Get-Date
    Write-Host
    Write-Host “Script Duration” –ForegroundColor Yellow
    Write-Host “Started: “ $starttime –ForegroundColor Yellow
    Write-Host “Finished: “ $finishtime –ForegroundColor Yellow
    Stop-SPAssignment -Global

  • Sql query to achive the running division

    Hi all, plz help me out with the sql query to achive the below output
    create table emp_a (empno number, deptno number, sal number)
    insert into emp_a values(901, 10,100);
    insert into emp_a values(902, 10,400);
    insert into emp_a values(901, 20,300);
    insert into emp_a values(902, 20,2100);
    i want the ouput in below format
    empno deptno sal div_sal
    901 10 100 (300/100)
    901 20 300 (300/100)
    902 10 400 (2100/400)
    902 20 2100 (2100/400)
    the div_sal column should have the output of greatest sal/second smallest sal for each empno

    Hi,
    781649 wrote:
    Hi all, plz help me out with the sql query to achive the below output
    create table emp_a (empno number, deptno number, sal number)
    insert into emp_a values(901, 10,100);
    insert into emp_a values(902, 10,400);
    insert into emp_a values(901, 20,300);
    insert into emp_a values(902, 20,2100);
    i want the ouput in below format
    empno deptno sal div_sal
    901 10 100 (300/100)
    901 20 300 (300/100)
    902 10 400 (2100/400)
    902 20 2100 (2100/400)
    the div_sal column should have the output of greatest sal/second smallest sal for each empnofor empno=901, then second smallest sal is 300. For empno=902, the second smallest sal is 2100.
    Instead of "second *smallest* ", do you mean "second *greatest* "?
    What if there's a tie (e.g.
    INSERT INTO emp_a (empno, deptno, sal) VALUES (903, 10, 300);
    INSERT INTO emp_a (empno, deptno, sal) VALUES (903, 20, 300);
    INSERT INTO emp_a (empno, deptno, sal) VALUES (903, 30, 200);) Would you count 200 or 300 as the second greatest?
    Here's one way:
    WITH     got_r_num     AS
         SELECT     empno, deptno, sal
         ,     ROW_NUMBER () OVER ( PARTITION BY  empno
                                   ORDER BY          sal     DESC
                           )         AS r_num
         FROM    emp_a
    SELECT       e.empno
    ,       e.deptno
    ,       e.sal
    ,       '(' || TO_CHAR (r1.sal)
               || '/'
               || TO_CHAR (r2.sal)
               || ')'          AS div_sal
    FROM       emp_a           e
    JOIN       got_r_num     r1  ON      e.empno     = r1.empno
    JOIN       got_r_num     r2  ON   e.empno     = r2.empno
    WHERE       r1.r_num     = 1
    AND       r2.r_num     = 2
    ;

  • SQL query to get the list of approvals

    Hi,
    Could someone let me know the SQL query to get the list of all the pending approvals for a user in OIM 11g R2.
    Thanks

    There are a few ways to do this:
    -  The easiest would be to use a Relationship Query from the CMC. To do this, go to the Universes section on the CMC, right click on the relevant universe, select tools >> Check Relationships.
    - Use Query Builder. You will need more than one query to pull the information you need. You could try something like the below (for Webi)
    SELECT SI_NAME, SI_WEBI, SI_DATACONNECTION FROM CI_APPOBJECTS
    WHERE SI_KIND = 'universe' and SI_NAME = 'Universe Name'
    This will give you a list of Webi Reports by SI_ID.
    You'll need another query to list Webi report names:
    SELECT SI_NAME FROM CI_INFOOBJECTS WHERE SI_ID IN (SI_ID from query above)
    - This is trivial via Auditing / the Activity universe. This of course will only return reports that have already run.
    Best.
    Srinivas

  • SQL Query To Select The 5th Element

    In the report I am currently working on, I am using an Add Command custom SQL query to pull the data that I need. The structure is a Call and a list of associated Activities. In this particular scenario, there are 8 activity notes for a type of call and I want to return the 5th one. The activity notes are a specific sequence of captured actions and I need the note from the 5th step in the sequence.
    This is what I have come up with:
    SELECT CALL.call_id,
         (select top 1 from (select top 5 CONVERT(char(8000),ACTIVITY.activity_note) from ACTIVITY
          where CALL.call_id = ACTIVITY.call_id
          order by ACTIVITY.creat_date desc))
         as activity_tx
    FROM CALL
    The intent of the Top 5 was to get the first 5 activity notes, of which the 5th note would be the last, then reverse sort them so I could take the Top 1 (which would be the 5th of 8). But I am getting a vague syntax error between "from" and "order by". Any suggestions would be appreciated.
    Thanks!
    Fuskie
    Who thought he had a solution but is flummoxed he can't bring it home...

    Hello,
    Let me explain that Crystal assumes the user knows how to write SQL. We only report on the data provided by the SQL you write.
    I did a quick search using Microsofts new search engine - www.bing.com and it returned this as well as lots more:
    http://forums.devshed.com/php-development-5/how-to-access-a-certain-element-in-the-results-of-606217.html
    Try searching in MSSQL's site also for more info on how to get the results you are looking for.
    Thank you
    Don

  • Sql query to indetify the identical data

    Hi
    I would like to know the query to identify the identical data in same table.
    Example: I have table called 'AA" having same data for load_ctry i.e. 'MY' and 'HK' ,I need sql query to indetify the identical data for above countries in that table.
    Thanks
    MR

    Hi,
    Table called "AA" with columns col1,col2,col3,load_ctry with following sample date
    col1 col2 col3 load_ctry
    3 bg xx TH
    4 op xc TH
    3 bg xx MY
    4 op xc MY
    3 vb nb MY
    When query ,if data is identical for both countries ,no data to fecth or data identical .If data is differ ,it will return the mismatching data becuase we are using same table for both countries .
    Thanks
    MR

  • Can anybody provide the SQL query to find the files uploaded in a particular folder?

    Hi All,
    Can anybody provide the SQL query to find the documents (document name) uploaded in a particular folder? While clicking on folder in
    GUI I'm hitting the Timeout error. I would like to find the files uploaded into this folder from SQLPLUS.
    Any help is greatly appreciated.
    With best regards,
    Nevin

    Nevin,
    Be great if we could know the version of Portal. For Rel. 1, here's the query
    select id,masterthingid from wwv_things
    where siteid = &site
    and cornerid = &corner
    &site - Content Area id
    &corner - Folder id
    if you don't know the folder id, use
    select id from wwv_corners where siteid = &site
    and name = &folder
    Hope this helps. I have run into this situation before. Usually, the culprits were
    one of the following:
    1. Junk Characters in description of item (caused due to Copy-Paste)
    2. Special Characters in the File name
    Hi All,
    Can anybody provide the SQL query to find the documents (document name) uploaded in a particular folder? While clicking on folder in
    GUI I'm hitting the Timeout error. I would like to find the files uploaded into this folder from SQLPLUS.
    Any help is greatly appreciated.
    With best regards,
    Nevin

  • SQL query to know which users are working on which forms in APPS R12

    Dear gurus
    We need the SQL query to know which users are working on which forms in APPS R12, and how to get the user.name of those records.
    thanks in advance
    best regards

    Hi,
    Please see this thread.
    USERS CONNECTED
    Re: USERS CONNECTED
    Regards,
    Hussein

  • How to know the number of the week in iCal ?

    Hi !
    I'm very enjoying iCal. But, there is something very important for me that I can't find in iCal !
    I need to know the number of the week (in Month, Week or Day views).
    Is that a way to easily see it ?
    Regards,
    ant
    iMac G5   Mac OS X (10.4.2)  

    there's no option for a week view in iCal, but John Maisey wrote this applescript.
    paste it in the Script Editor (Applications --> AppleScript --> Script Editor) and run it once...
    if your weekview starts on an other day change this line:
    set daysText to "MonTueWedThuFriSatSun"
    to (example)
    set daysText to "SunMonTueWedThuFriSat"
    --Copy below this line into Script Editor and click run --
    --Annual Week numbers
    --John Maisey
    --4/2/5
    set numberOfWeeks to 1000 -- change as needed
    set daysText to "MonTueWedThuFriSatSun"
    set aDate to (current date)
    set day of aDate to 1
    set month of aDate to January
    set aDay to weekday of aDate
    set weekNo to 1
    --Day of week as num. starting with 0
    set aDayText to (characters 1 thru 3 of (aDay as text)) as text
    set dayOff to ((offset of aDayText in daysText) - 1) / 3 as integer
    if dayOff is less than 5 then
    set StartDate to aDate - dayOff * days
    else
    set StartDate to aDate + (7 - dayOff) * days
    end if
    tell application "iCal"
    set newCal to make new calendar at end of calendars with properties {title:"Week No."}
    set myCal to (count of every calendar)
    end tell
    repeat with myCount from 1 to numberOfWeeks
    if (month of StartDate is December) and (day of StartDate is greater than 28) then set weekNo to 1
    if (month of StartDate is January) and (day of StartDate is less than 5) then set weekNo to 1
    set weekText to "Week No. " & weekNo
    tell application "iCal"
    tell calendar myCal
    make new event at end of events with properties {start date:StartDate, allday event:true, summary:weekText}
    end tell
    end tell
    set weekNo to weekNo + 1
    set StartDate to StartDate + 7 * days
    end repeat
    --

  • How to know the number of the document copy being printed?

    Hi all,
    Another question: If one is printing, for instance, two copies of the same document, is it possible to change the text of a field or floating field from one copy to another? For instance, in copy 1, the field would say "client" and the second copy "enterprise".
    Thank you

    I've been here all the time, ever since I got my G4 and could finally OS X (started with 10.1.5). Don't know how ya coulda missed me.... I'm usually in the Using the OS Forum and the Finder forum, with occasionaly excursions in the Spotlight forum.
    BTW, so this isn't completely off topic, after getting frustrated by the file count and Finder displaying correct sizes I experimented with a couple of Applescripts but then found a wonderful little Contextual Menu item, CalculateSize:
    http://www.pixture.com/software/macosx.php
    It tells you not only the number of files and sub-folders in a given folder, it also tells you the number of invisibles of each and the total size of the items, and it calculates sizes ever so much faster than the Finder does.
    Francine
    Francine
    Schwieder

  • How can i know the number of lines in field-symbol internal table

    how can i know the number of lines in field-symbol internal table

    Hi,
    If your field symbol has been defined as an internal table :
    Use std describe as
    Data: l type i.
    describe <fs> lines l.
    'l' will contain the number of lines as needed.
    FYI
    The size of this storage area in a field symbols depends on the number of table lines which is not fixed, but determined dynamically at runtime.
    Regards,
    Amit

Maybe you are looking for

  • Mac mini 2004 stopped working

    Hi all, I have just bought a second hand Mac mini 2004 and was working have taken a copy of the internal hard drive through disk utility, but it went to blue screen and couldn't restart it back up so switched it off and now it doesn't start just stay

  • Turning off yellow warning messages?

    Do we have any control over various warning messages? For example 'Swiss Franc is not an official Currency in Unites States' or ' Expense date doesn't fall within the dates of the expense report'

  • Accrual Rebuild Reconciliation Report

    Accrual Rebuild Reconciliation Report works fine for the transaction dates between 2003 and 2005.But When the report runs for transaction dates from 2006 to till date there were some new transactions(from the transaction dates between 2003 and 2005)

  • Axiom 25 Mk II + Garageband 10.0.1?

    Can anyone clue me in on how to configure garageband 10.0.1 and my Axiom 25 Mk II so that I can control effects, e.g.: cutoff, filter, pulse, delay, etc. using keyboard controller knobs? Any input is greatly appreciated. Than

  • Setting up 4 images 90 degrees

    I have been racking my brain trying to set up 4 images at 90 degrees to each other on the' floor' so I can rotate an active camera around them to look like an x pattern. Can anyone help me figure this out? Thanks-working in Motion 4. Sandy V.