How many rows in detail block

How can I get how many rows I have in my detail block.
Thanks Sibel

There is a way to find out though without iterating through the entire result set and incrementing a counter along the way.
Just issue another select beforehand of the form:select count(*) from ( YOUR SELECT STATEMENT HERE )This will give you a result set with 1 row and 1 column containing a value representing the row-count of the select statement you want to execute.

Similar Messages

  • How to know how many rows including headers and footers does subreport has from Main Report

    Hi, we are sturuggling with subreports. Main report has 3 subreports, each subreport is inplmented in a group header(3 subreports and 3 group headers). We would like to print a group header under subreport as a column header every page, and need a page break when group number is changed. This report exports a MS Excel(97-2003) report file.
    In main report, [New After Page] is checked under Group Header #1d from [Section Expert]
    In each subreport, [Repeat Group Header On Each Page] is checked under the highest group from [Group Expert]
    Here are two issues;
    Since Crystal Reports has more rows than Excel in one page, colmun header in each subreport is being printed in the middle of the page. It should be printed at the top of the page
    When Subreport has many rows and has to be printed in more than 1 page, a page break is automatically inserted before column header. It should be printed right below column header which is Group Header #1
    We have been trying to pass row counts(count of group header because group header is used as the details) using a shared variable from Subreport 1 to Subreport 2 via main report since Subreport2 cannot predict how many rows Subreport 1 has.
    Here is what we are trying but we are getting an error which is "A constant expression is required here" under main report
    - In Sunreport 1
    whileprintingrecords;
    shared numbervar SubGroupCount := DistinctCount({Table.Field});
    - In Mainreport
    shared numbervar SubGroupCount;
    if(pagenumber) = 1
    then (SubGroupCount)
    else 50
    Is there any solutionss or better ways other than above?
    Thank you,
    Main Report: Group Header #1a --> as Page Header
    Run Date: mm/dd/yyyy                                                                 Report Name
    Main Report Group Header #1b --> Subreport 1
    Header 1
    Header 2
    Header 3
    Header 4
    Header 5
    Header 6
    Main Report Goup Header #1c --> Subreport 2
    Header 1
    Header 2
    Header 3
    Header 4
    Header 5
    Header 6
    Main Report Froup Header #1d --> Subreport 3
    Header 1
    Header 2
    Header 3
    Header 4
    Header 5
    Header 6

    Thank you for your reply and sorry for my complicated explanations. The report has confidential information, so I replaced to some fake data but I believe you can still see what I am trying to do..
    Main Report
    Subreport 2
    Output1
    Output2: the following page
         --> more rows are printed..
    We have two problems;
    1. The column header in Output2 is supposed to be pronted right below the last row in Output2, however, a page break is automatically inserted. But even in the same output document, it works for some group when it has a few rows..
    2. Since Crystal Reports prints more rows in one page than MS Excel does, Column header is not be printed at the top of the page.
    I tried the way you advised me but it did not work..

  • RAC 'how many rows left to process'

    Hi guys
    I m recently start working on RAC.
    I m try to find out , after running a query .
    How to find out that "How many rows are left to process by stmt'
    Is there any script available would be great help
    Thanks.

    user12281508 wrote:
    Thanks aman for prompt response.
    I m try to find out if i run update stmt. which update xyz rows. i dont know the row count.
    5 min after fired of this stmt. i want get information that how many row it has updated so far and how much is left. What's the reason for such requirement? I can't think of anything which would require this except that the Update is updating some millions of rows and you want to know when it would eb finished. But even for that, there is no way to know AFAIK that how many rows currently have been effected by the statement.
    does the total_work.gv$session_longops , column can help ????No, that would only show the total work done in % . It won't reveal and update continously the row count of rows getting updated.
    joining v$session, v$transation , v$rollstat can only tell me how much undo blocks are used so far, not rows.Nope, as I said already, there is no way at least in my knowledge to check this and IMO, there is no need to know this as well.
    HTH
    Aman....

  • Is there an easy way to see how many rows in a table? (selected or unselected)

    Hi all,
    Forgive me if this is a REALLY dumb question but I would love to know if there there is an easy way to to see how many rows there are in a table in InDesign?
    (And I bet I am really going to kick myself when I hear the answer and how simple it probably is..lol !)
    I am working on a huge catalog and am dealing with LOTS of tables...very long tables too at times. I am also doing a lot of copying and pasting back and forth between InDesign and Excel and it would REALLY help if I knew how many rows there are in a table without having to manually count them (TIRESOME!!).
    Also, is there a way to see how many rows I have selected at any one time? It would be SO WONDERFUL if the info box could also provide this information.
    Thank you SO MUCH in advance for your help:))
    Christine
    **UPDATE**
    Oh boy I AM going to kick myself! Why only NOW that I wrote this question did I suddenly notice that the Table palette shows the number of rows and columns? lol.
    Okay, then is there a way to see how many rows I have selected at any given time?

    @Christine – try the following ExtendScript (JavaScript):
    if(app.selection.length === 0
        || !app.selection[0].constructor.name === "Cell"
        || !app.selection[0].constructor.name === "Table"){
        exit(0);
    var sel = app.selection[0];
    if(sel.constructor.name === "Cell"){
        var tableRowLength = sel.parent.rows.everyItem().getElements().length;
    if(sel.constructor.name === "Table"){
        alert("All "+sel.rows.everyItem().getElements().length+" rows selected in current table." );
        exit(0);
    var numberOfRowsSelected = sel.rows.length;
    var indexOfSelectedRows = sel.rows.everyItem().index;
    var startRowSel = indexOfSelectedRows[0]+1;
    var endRowSel = indexOfSelectedRows.length+indexOfSelectedRows[0];
    alert(numberOfRowsSelected +" row(s) selected.\r"+startRowSel+" to "+endRowSel+" out of "+tableRowLength+" of current table.");
    You need not select whole rows, just one or a couple of cells.
    Then run the script.
    An alert message is telling you how many rows belong to the cell range you have selected and:
    which rows of the table are selected…
    A typical message would be:
    6 row(s) selected.
    3 to 8 out of 20 of current table.
    The script does some basic checks of the selection.
    If no cell or table is selected, it will just do nothing…
    Uwe
    Message was edited by: Laubender | Some language cosmetics in the alert message

  • ADF: Best way to find out how many rows are fetched?

    Hello,
    I have overridden method executeQueryForCollection of ViewObject in which I execute supper.executeQueryForCollection and after that want to find out how many rows are fetched during the execution.
    If I try to use getFetchedRowCount I always get "0", if using getEstimatedRowCount, query are being re-executed.
    What method is better to use for that?
    Thank you,
    Veniamin Goldin
    Forbis, Ltd.

    I have a 'home-made' view called RBS, whose definition is this:
    create view RBS as
    select /*+ RULE  */ substr(s.username,1,10) oracle,
           substr(case when s.osuser like 'oramt%'
                       then nvl(upper(s.client_info),'client_info not set')
                       else substr(s.machine,instr(s.machine, '\')+1,length(s.machine))||':'||s.osuser
                  end
                  ,1,20) CLIENT
    ,      substr(''''||s.sid||','||s.serial#||''''||decode(s.status,'KILLED','*',''),1,12) kill_id
    ,      lpad(to_char(t.xidusn),4) rbs#
    ,      lpad(to_char(t.used_ublk),4) ublk
    ,      lpad(to_char(t.used_urec),8) urecords
    ,      i.block_gets
    ,      lpad(to_number(round((sysdate - to_date(t.start_time,'MM/DD/YY HH24:MI:SS')) * 60 * 60 * 24)),9) time
    ,      upper(substr(s.program,1,20)) PROGRAM
    ,      to_char(s.LOGON_TIME,'HH24:MI:SS DD-MON') LOGIN_TIME
    from   sys.v_$transaction t
    ,      sys.v_$session s
    ,      sys.v_$sess_io i
    ,      sys.v_$process p
    where  s.saddr = t.ses_addr
    and    i.sid = s.sid
    and    p.addr = s.paddr
    /By monitoring the URECORDS column value of the row that corresponds to my session doing a transaction, I can see how it progresses.
    Toon

  • How to find out How many rows and coloumn exists in the Excel sheet

    hai gurus,
                 present iam uploading data from presentation server to application server.  when i use gui_upload the data is coming non-readable format.
    so i used alsm_excel_to_int fm for that . but the problem is user can give any type of excel so... i need to know how many rows and coloumn s existed in that Excel
    so is there any possiblity to get those values(Total rows and total coloumns).
    plz help me..
    if any one answered , appreciate with reward points,
    thanks&regards,
    Venu.T

    see you have to come into an agreement with other system before starting development..
    Please dont do unnecessary coding for impractical things ..you may solve this but this is not good way of working in eRP packages..
    Al least u can get final list of all Columns and which can be blank or non blank like this
    then u can  do coding for this scenerio
    regards...
    Message was edited by:
            Madan Gopal Sharma

  • To find out how many rows are processed/updated?

    Hi Gurus,
    I have given an update statement with parallelism. The data to be processed is huge around 50 million records.
    I know that from OEM, we can find out how many rows it has processed or completed. I would like to know the dictionary view/ query to find out the same in SQL Plus.
    Thanks
    Cherrish Vaidiyan

    I have a 'home-made' view called RBS, whose definition is this:
    create view RBS as
    select /*+ RULE  */ substr(s.username,1,10) oracle,
           substr(case when s.osuser like 'oramt%'
                       then nvl(upper(s.client_info),'client_info not set')
                       else substr(s.machine,instr(s.machine, '\')+1,length(s.machine))||':'||s.osuser
                  end
                  ,1,20) CLIENT
    ,      substr(''''||s.sid||','||s.serial#||''''||decode(s.status,'KILLED','*',''),1,12) kill_id
    ,      lpad(to_char(t.xidusn),4) rbs#
    ,      lpad(to_char(t.used_ublk),4) ublk
    ,      lpad(to_char(t.used_urec),8) urecords
    ,      i.block_gets
    ,      lpad(to_number(round((sysdate - to_date(t.start_time,'MM/DD/YY HH24:MI:SS')) * 60 * 60 * 24)),9) time
    ,      upper(substr(s.program,1,20)) PROGRAM
    ,      to_char(s.LOGON_TIME,'HH24:MI:SS DD-MON') LOGIN_TIME
    from   sys.v_$transaction t
    ,      sys.v_$session s
    ,      sys.v_$sess_io i
    ,      sys.v_$process p
    where  s.saddr = t.ses_addr
    and    i.sid = s.sid
    and    p.addr = s.paddr
    /By monitoring the URECORDS column value of the row that corresponds to my session doing a transaction, I can see how it progresses.
    Toon

  • AdvancedDataGrid: how to tell how many rows are currently visible?

    Does anyone know how to query an ADG (or its rows) to figure out how many rows are currently visible (i.e. not collapsed) when displaying different levels of a hierarchical collection?
    In other words I'd like a function that tells me that 7 lines are visible in this view
    and 1 line is currently visible in this one
    I  assume this is simple but can't seem to find the right keyword anywhere.
    thank you!
    f

    Never mind. Wrong post.

  • How many Rows?

    My old Appleworks Spreadsheet was limited to roughly 16,000 rows. Before I pop for new software, how many rows can I make a spreadsheet with using this new software? I've a project where a spreadsheet with the calicity to have 45,000 rows would be great. Otherwise, I'll have to do my project in Appleworks in batches.
    Thanks in Advance!

    I forget exactly. Somewhere upward of 60,000 I believe.  You might find the exact number by searching the forum. It will be an old post, probably by Yvan Koenig.
    Note that Numbers can get really slow with large tables. You might be pushing the limits of the current version.

  • Neha.R how many levels we can block billing docs...?

    Hi SAP GURUS,
    How many levels we can block billing documents.
    how it is imapact of billing levels.
    send me every level of impact , and how is to be......
    Advance Thanks
    Neha .R

    Hi G. Lakshmipathi,
    Thanks for your suggestion,
    My Question is where we can make setting this kind of Requirement.
    Based on customization only it impact in SO level .
    Thanks,
    Neha.R

  • How many rows will be allowed in Cusom Section?

    how many rows will be allowed in Cusom Section? can I modify the max rows setting?

    I think the hardcoded limit in Admin is 250.  However, I don't think 250 active rows in a single custom section on a specification would perform very well.  I would try not to exceed 30 active rows per section per specification.  Performance involves so many variables, it will depend on the type of extended attributes you have used in each cell.   For example, if you had one section with 10 columns and 30 rows and every cell had 15 radio button choices the section would take quite a while to render.   If helpful, you can always submit your custom section designs to support and we can review it for any potential gotchas.
    Thanks
    Kelly

  • Java mysql ResultSet - how many rows

    Hi
    As a beginner java dude I'm trying to work with java on my mysql database instead of using perl (which works fine by the way). BTW this is not an apple specific question.
    I have properly managed to connect to my database and executa a query which returns a ResultSet object. By using the next() method I would like to populate an array with the results of my query using a while loop. All of this works fine. One problem persists however. I would like to know how many rows my query has so I can creat my array with the correct number , i.e if the query has 10 rows then the array should be String[] Array = new String[10].
    But i can only loop through the ResultSet once as it appears to be detsroyed after that. I have solved the issue by making two identical statements and I use one with getRow() in a while loop so I can create an array with the correct variables, and the other to loop through and populate the array.
    It seems to me there must be a better way to check how many rows a query returns ... i mean if I take the original query an put it through
    int nr = 0;
    while (rset.next()) {
    nr = rset.getRow();
    String[] Data = new String[nr];
    and then do
    while (rset.next()) {
    int count = rset.getRow();
    --count;
    int idnr = rset.getInt("One");
    String name = rset.getString("Name");
    Data[count] = idnr + " " + name;
    the the last while returns null results.
    How can withdraw the number of rows from the ResultSet and still use that same ResultSet in the last while loop? I have a feeling i'm missing something very elementary here.. but being new thats to be expected.
    Thanks

    Darn, just after I posted this I was struck by lightning and found an answer. The ResultSet isnt destroyed its just that the marker is at the end efter looping through a while loop, so if you want to loop again you have to the the marker to move to the absolute beginning.. thsi can be done using ResultSet.beforeFirst() which nice and neatly pops the marker back to its initial state.
    Sorry for bothering everyone.

  • Is there a way to know how many rows were rejected using external tables?

    Hi,
    I'm developing a package that needs to load different kinds of text files into the DB.
    I was wondering whether there's a way of knowing in SQL or PL/SQL how many rows were rejected if my external table is defined with "reject limit unlimited".
    I'm using the external tables in "insert into ... (select ... from external_table where...)"
    sql%rowcount returns the number of inserted rows
    I was hoping for something similar/easy to get the number of rejected rows as well.
    I know I can try to analyze the bad file for the number of records if there's no other way...
    Thanks in advance.

    Pyrocks wrote:
    I was afraid of this answer...
    this is a certain "no there's no other way" or should i wait for other responses (no disrespect - just want to make sure :) )Well the difference would be that this external table will have no complex logic. You would simple read in all the lines from the bad file. The chances that this is broken are therefore very slim compared with your original external table.
    And tehre are many other ways possible. For example you can first copy the file into a real internal (temp) table without using any processing logic but with using an external table. Then do the processing / logic checking of the data and move the data from this temp table into your final data structure. Since you move the data two times the whole process will be slower then the original version.

  • How many ways we can block the vendor

    hi friends,
                 How many ways we can block the vendor

    Hello
    Adding further,
    Within Accounts Payable, you can block a vendor account for posting. You have to block a vendor master record before you can mark it for deletion. You would also block a vendor that you use only as an alternative payment recipient, so that nobody can post to it by mistake.
    There are several fields in the vendor master record available to you. You can set the following blocks:
    Posting block for certain company codes or for all company codes
    Purchasing block for certain purchasing organizations or for all purchasing organizations. This is of course only if you have purchased and installed the purchasing application component.
    This topic describes how to block a vendor account and blocking an account for the accounting department only. A separate topic explains how you block a vendor from being paid.
    You can cancel a vendor account block at any time. To do this, simply remove the relevant indicator.
    Only block an account if there are no more open items in the account. If an account is blocked, you cannot clear any open items in it.
    Reg
    assign points if useful

  • How many row data the DBObjectFiles can allow?

    i have a project that will run for 7 months long,I anticipate
    there will be 500,000 row userdatas ,each userdata has 6
    attributes,
    does anyone know that the multiserver can allow this big
    number to store?
    if it can, will the number of data effect the efficiency of
    searching data (slowing down , or lag)?

    Thanks Rob for answering but im talking about the enterprise licence as a developer.
    You re misstaken about inhouse apps. You do need a licence (It's 299USD). With a standard developer licence you can not create inhouse apps. You can only make time limited applications (for testing) and you are confined to 100 unique devices. I need to know how many devices I can deploy inhouse with an enterprise account.
    http://developer.apple.com/library/ios/#featuredarticles/FA_Wireless_Enterprise_ App_Distribution/Introduction/Introduction.html#//apple_ref/doc/uid/TP40009979

Maybe you are looking for

  • Why can't I hear music from my iPod Touch in the car using the auxilliary jack?.

    When I am in my car I am not able to hear much of my music from my iPod touch.  I use an auxilliary jack.  Is there some setting or adjustment that can be made?

  • Get Community ID list using user id in 4.5

    Need to get a list of communities a user belongs to by his userid. Anyone done this? M

  • Is there a way to create a group function?

    I want to create a group function like max,sum,count for a pl/sgl function. This group function will be something like max (let's call it max2) but it will return the second highest value of a group. Any ideas anyone?

  • ORA-01031: insufficient privileges problem

    Hi all, I am trying to create the below procedure in the BOLMIN schema which in turn selects data from the tables of VALMIN schema. and I get ORA-01031: insufficient privileges error. CREATE OR REPLACE PROCEDURE BOLMIN.prcs_load_data IS BEGIN FOR c I

  • Measurement of count

    hi i have a characteristic and depending on the condition some no. of items are available for reporting in the structure of the query. my problem is how do i measure the no of items for the selection condition. i have to show the measured count only,