Can i get a number of rows in the select list??

Hello~
I am studying the "oracle call interface". but i don't know much about oci.
Anyway i want to know that how can i get a number of rows.
for example, there is a source code of the number of colums in the select list.
The following is a list of DB(example)
/*DB table*/
ID NAME CODE ID
1 A 1 A
2 B 2 B
/*source*/
err = OCIAttrGet ((dvoid *) stmhp, (ub4)OCI_HTYPE_STMT, (dvoid*)
&parmcnt, (ub4 *) 0, (ub4)OCI_ATTR_PARAM_COUNT, errhp);
/*result*/
The Column is 4. (ID, NAME, CODE, ID)
So, i think that the row is 3 (ID, 1, 2) in the DB table.
Simply, Can i get a number of rows in the select list??
for example,
err = OCIAttrGet ((dvoid *) stmhp, (ub4)OCI_HTYPE_STMT, (dvoid*)
&parmcnt, (ub4 *) 0, (ub4)OCI_ATTR_RAW_COUNT, errhp);
I'm trying to get the number of row count. but i can't find.
Please, could you let me know that how can i get the number of row count.
Thank you.

Thank you for your reply.
we are tested the source code by reply.
The following is the test source code.
/*source code*/
strcpy (szStatement, "SELECT * from DB_TABLE");
OCIStmtPrepare(gpOCIReadStmHandle, gpOCIErrHandle, szStatement,
     strlen(szStatement), OCI_NTV_SYNTAX, OCI_DEFAULT);
OCIStmtExecute(gpOCISvcHandle, gpOCIReadStmHandle, gpOCIErrHandle,
     0, 0, 0, 0, OCI_DEFAULT);
/* get a number of rows count , Reply : prajithparan*/
OCIAttrGet((dvoid *)gpOCIReadStmHandle, OCI_HTYPE_STMT, (dvoid *)&nRowCount, NULL, OCI_ATTR_ROW_COUNT, gpOCIErrHandle))
But There is a problem of the result value.
The result value is 0. It's mean that the row count is 0. and then we are using the all of fuction is succeed.(return value)
I don't know what is problem. Please let me know about the problem and solution.
Thank you.

Similar Messages

  • Dynamic LOV's - can we display more than one field in the Select list.

    I have the following query.
    SELECT DISTINCT NAME d, legal_entity_id r
    FROM xle_entity_profiles
    ORDER BY NAME
    So the drop down would contain the Organizational  Name - say in the case   China mobilex
    The legal entity  id is - 100
    Issue, there's also a legal entity id of 110 that is mapped to the same Organizational name - China mobilex
    so in the select list display it would look like
                                   China mobile
                                   China mobile
    QUESTION - is there a way to display BOTH
                                   China mobile 100 
                                   China mobile 110

    Hi Mikez,
    Perhaps the super LOV plugin of Skillbuilders would suit your needs more. It lets you create a modal dialog LOV with multiple columns, so you can display your selectable entries like:
    "Organizational Name" | "Country" | "Address" | "Phone Number"
    From a users point of view that would make more sense than an id column.
    - Item Plugin - SkillBuilders Super LOV
    Regards,
    Vincent Deelen

  • How can I get total number of pages in the folio?

    Hello guys, I need some help.
    I'm trying to get  the total number of pages in the folio, but, currently, I only success to get the total number of pages from current article, is there someway to get it? 
    My code: gist:de1de89b493024815c3e
    Thanks so much.

    My first advice in situations like this is the double and triple check that this requirement still exists and it is driven
    by the business.  This is great opportunity to refactor some unnecessary complexity out of the solution if you identify it.
    Assuming it is a valid and verified requirement, how you approach depends on the composition of the Interchange.  Meaning, if you receive single ISA...IEA blocks with a single GS...GE, you can use the max of BTS.InterchangeSequenceNumber.
    If you receive multiple ISA or GS's, it's a little different.

  • How can i get  all albums to appear in the artist list

    Not all of my albums for a particular artist appear in the artist list. How can I correct this?

    Hi spike1954,
    Welcome to Apple Support Communities.
    You may want to first check the Song Info associated with the albums that are not displaying correctly. See this article for the details:
    Playing and managing content in iTunes
    http://support.apple.com/kb/ht1399
    Editing and arranging content
    Editing Info
    Each audio or video file in iTunes has several settings and tags that can be easily modified. These options can be accessed by selecting any file in the iTunes browser windows and selecting "Get Info" from the File menu. You can add song lyrics, artwork and set special playback options. The "Info" tab lets you edit information about the file including artist and album info.
    Additionally, while this article refers to a previous version of iTunes, the information within can still be helpful:
    Fixing Incorrect Song or Album Listings in iTunes
    http://support.apple.com/kb/ta24677
    Best,
    Jeremy

  • How can I get a folder to appear in the Folder list when I am trying to import pictures?

    There is a folder on my hard drive that does not appear in the list of folders in the import dialog. I have tried expanding all the other folders around it (my photos are filed by date of capture) to see if it was somehow imported as a subfolder. It is simply not there. I can find and open it and access all the pictures in Photoshop Elements but not in Lightroom 4. Any ideas?

    I would try this:
    In Lr import one photo into a different folder that you can see in the list.
    Then in your OS (mac Finder / Win Explorer) move the photo to the folder that you cannot see.
    In Lr the photo will now appear with a question mark on its frame. Click directly on the question mark and select <Locate photo>. Navigate to the folder, open it, and click on the photo.
    Maybe this will help Lr to recognize the folder.
    If this doesn't help try renaming the folder in your OS.

  • Adding new row to the reports list page

    How can I add a new report row in the reports list of the reports tab.
    Ex: a new row to the report "users by Date of Join report" is to be added
    How can we add Please help me out in this

    I am facing the same problem!
    camickr wrote:
    Try adding an empty row containing a null value for the String instead of the empty String.camickr, it will not help, the DefaultRowSorter in the "*+compare(int model1, int model2)+*" method return -1 if the first value is null and 1 if the sacond value is null. and incase of DESCENDING it mult by -1.
                    // Treat nulls as < then non-null
                    if (v1 == null) {
                        if (v2 == null) {
                            result = 0;
                        } else {
                            result = -1;
                    } else if (v2 == null) {
                        result = 1;
                    } else {
                        result = sortComparators[counter].compare(v1, v2);
                    if (sortOrder == SortOrder.DESCENDING) {
                        result *= -1;
                    }And this is the real problem!
    The empty line is sorted as the smallest value and incase of DESCENDING it will be the first line (because of the mult by -1).
    We could have overide it and incase of the empty row(usualy the last row) do not mult by -1 in DESCENDING mode.
    But the problem is that the "+*compare*+" method and it's caller "*+Row+*" inner class are private :-(
    It is not wise to do it but we can do like kmp83 wrote:
    kmp83  wrote:
    copy/duplicate "private" code from DefaultRowSorter into my extended class.Anyone have another suggestion?

  • How to get number of rows return in SELECT query

    i'm very new in java, i have a question:
    - How to get number of rows return in SELECT query?
    (i use SQL Server 2000 Driver for JDBC and everything are done, i only want to know problems above)
    Thanks.

    make the result set scroll insensitve, do rs.last(), get the row num, and call rs.beforeFirst(), then you can process the result set like you currently do.
             String sql = "select * from testing";
             PreparedStatement ps =
              con.prepareStatement(sql,ResultSet.TYPE_SCROLL_INSENSITIVE,ResultSet.CONCUR_READ_ONLY);
             ResultSet rs = ps.executeQuery();
             rs.last();
             System.out.println("Row count = " + rs.getRow());
             rs.beforeFirst();~Tim
    NOTE: Ugly, but does the trick.

  • I have an iphone4 and my husband merge his numbers with mine and i think it was deleted can you tell me how can he get his number back on his phone

    have an iphone4 and my husband merge his numbers with mine and i think it was deleted can you tell me how can he get his number back on his phone

    Do you possibly mean the contacts have been merged?
    If so, where are each of you syncing contacts?  A supported application on the computer? iCloud or another cloud service? An Exchange server?
    WIthout details, it's difficult to offer specific resolutions.

  • I just read the tutorial and did exactly what it was telling me to do, and I still can't get it done. Once I have selected the file, I get a box that pops up that says "Subscribe now to convert unlimited number of files to PDFs. Subscribe Now.  I already

    I just watched the tutorial and did exactly what it was telling me to do, and I still can't get it done. Once I have selected the file, I get a box that pops up that says "Subscribe now to convert unlimited number of files to PDFs. Subscribe Now.  I already have done this! I am a subscriber!  Arrrrhhhgggg!

    Hello Kathie,
    Please let me know what exactly are you trying to do using Adobe online service.
    You might try accessing the same service for some other PDFs and check.
    Have you signed up correctly at "https://cloud.acrobat.com/" using your Adobe ID credentials.
    If the same message pops up, then please visit Contact Customer Care as they could let you know if there is any problem with your account.
    Hope to get your response.
    regards,
    Anubha

  • I purchased Adobe Photoshop Elements 12. Logged in and can not get serial number. Says it is incorrect. Going in circles.

    Can't get serial number for Photoshop Elements. I'm logged in. I have a redemption code and also codes on the back of the box. nothing works and am running in circles. I want to install and use it and can't because I can't get the correct serial number. On the front of the box it says use the card (with redemptiom code to receive the serial number.HELP!!!

    Dear Brian,
    I activated my product in August of 2014.  I had it a few months, October, when my computer crashed.  Therefore I had to go back to Adobe tell them what happened, and then until December I had noticed that it said that I had a trial copy.  I was not worried, as I had the serial number.  it was working, but in January I got a message that my "trial" copy had expired. 
    At that time I had contacted Adobe and was told that because it was beyond the 3 months, they would no longer help me.
    Therefore, at one point, when the computer crashed, I had not deactivated the program.  But Adobe had gotten it working for me again. 
    I do not know what happened between October and December to have changed the software from a real copy to a trial copy.
    Now to your patient questions.
    As you wrote, that is what happens to the point of getting the trial copy, but when I follow the process through, I get a message that my "trial copy has expired".    When I go the the editor, the whole process loops again, sign in, trial copy, licence page, add serial number, then the message that the trial has expired.
    When I got that message the first few times months ago, I went back to the Adobe web site and downloaded another copy.  (I have done this numerous times)  It still said that I had a trial copy and that it had expired, there is a box to licence this software, when I click that, I have to sign in again, This time I also had gone to the Adobe web site signed in and left it open, while I put in the serial number, hoping that would help (have also tried that before).  It waits and then the Editor/Organized box comes up again.  When I go to the Editor, it tells me that this is a trial copy which has expired and it starts all over again.
    I was so frustrated, that I waited a couple of months to try it again.   The thinking was that there was some glitch that would work it self out and I could again  down load a clean copy of the original, not a trial.  (I do not know how I keep getting a trial copy of PSE 12, as it is not even offered on the site.)
    The crazy thing is this morning when I turned on my computer, I had an update for the Adobe PSE 12 and Camera Raw.  Probably because I had downloaded a copy again. 
    When I go the the web site to down load a copy of the PSE !2, I am doing it from the My accounts/ products page and downloads.  I have left the web page open to copy the serial number from that page, although it always matches my notes. 
    ThanksT

  • The LCD for my macbook air model number MC965LL/A (purchased 2011) is broken , where  can I get new one and what is the part number for it ?

    The LCD for my macbook air model number MC965LL/A (purchased 2011) is broken , where  can I get new one and what is the part number for it ?

    You can find them at vendors like ifixit and instructions to install.
    http://www.ifixit.com/Mac-Parts/MacBook-Air-13%22-Mid-2011

  • Can't get my number pad to work - No Num Lock

    Hello,
    I recently got my iMac with the wireless keyboard and noticed that I can not get my number pad to work. There is no num lock button to turn on/off, just the clear button. Can someone help me figure this out? Thanks
    Jay

    This is from the built-in Mac Help.
    Hope it works for you.
    My numeric keypad doesn't work
    The way the numeric keypad works depends on your computer, the keyboard you're using, the application you're working in, and whether the Num Lock key is engaged. Usually, the numeric keypad is used to enter numbers in a document, but in some applications you might be able to use the keypad to navigate (move around in) your document.
    Press the Num Lock key to switch between the ways the numeric keypad functions.
    If you have a separate numeric keypad on your keyboard, the Num Lock key is located in the numeric keypad. If you're using a portable computer, the Num Lock is a function key, marked Num Lock (F6). If your keyboard has a separate keypad but no Num Lock key, try pressing Shift-Clear.
    Most portables have a group of keys on the keyboard that can function as the numeric keypad. To find the keypad, look for small numbers or symbols in the lower-right corner of keys on the right side of your keyboard. Press the Num Lock key (F6) to turn on the keypad. The green light glows on the Num Lock key when the keypad is active.
    S
    iMac 2Ghz Intel Core Duo   Mac OS X (10.4.8)  

  • I currently have aT-Mobile sim, and therefore, a UK telephone number. Can I get a sim from EE with the same number to use in my iphone 5?

    I currently have aT-Mobile sim, and therefore, a UK telephone number. Can I get a sim from EE with the same number to use in my iphone 5?

    The easiest way to find out what carrier it's locked to would be to call the store where you purchased the phone.
    The phone can be unlocked from any location.  However, most carrier have restrictions about unlocking and you have to contact them for details.

  • How can i get a number of working days in a month PL/SQL

    How can i get a number of working days in a month(excluding Saturday and Sunday) in a query in PL/SQL ?

    Please do a search before posting
    sql>
    select count(*)
    from(
    select trunc(sysdate,'month')+rownum-1 dy
    from all_objects
    where rownum <= last_day(sysdate) - trunc(sysdate,'month')+1)
    where to_char(dy,'fmday') not in ('sunday','saturday');
    COUNT(*) 
    23
    Message was edited by:
            jeneesh
    Please try yourself to change the query to one that doesn't use a subquery..                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • How can I get Notification Number from Material Document?

    Can you please tell me that how can I get Notificatin Number(QMEL-QMNUM) from Material Document(MSEG-BELNR)?
    Regards,
    Subhasish

    This question is closed but unanswered.

Maybe you are looking for

  • BSP to trigger a Process Chain in BW

    Hi ,   I have a requirement to develop a BSP Application in the BW System where the BSP Application have to get some input parameter and in the back ground trigger a process chain. Can any one tell me how to trigger the process chain in BW System fro

  • Infotype log audit S_AHR_61016380

    Hi Experts, I am using S_AHR_61016380 report to trcak infotype changes. But on execution no data is displayed. Do I have to mke some specific selections? Thankls Aryan

  • How to Convert all PSDs/TIFFs to JPEGs within subfolders (no "JPEG" folder)?

    Hello all, I come to you with what I hope is a fairly simple question and I would put it in scripting if needed but I'm not a scripter. I am sifting through many terabyte drives trying to track down all large image files and delete them after making

  • Any one noticed issues when UCM contributor data files indexing in GSA

    Hi Guys, We are using Google search appliance to crawl UCM content (native documents). We don't have any issues with search results in this way. We are using dynamic converters to convert these documents into HTML in site studio web sites. But we hav

  • How to install recovery image on Satellite 5200 using USB DVD drive

    Hello, I have this problem with a Satellite 5200-902 that has the DVD-ROM corrupt and I don't find the part to change. (model DVD: uj-810b) But I would like to reinstall the notebook with the CD recovery and I don't be able to enter in the BIOS for c