Fetch Data through Caml Query using textboxes as parameters

Hi All,
       *I am very new to SharePoint and working on SharePoint dev.I have task to get the list items based on 2 conditions and I am passing parameters as texboxes to get the data dynamically .
     *I had written the below code(Code 1) for which it is showing me errors and Code2 is working fine.Can any one help me what is error
Code 1
  SPList mylist = myweb.Lists["Manager"];
                SPItem myitem = mylist.Items.Add();
                SPQuery myquery = new SPQuery();
                string idvalue = txtid.Text.ToString();
                //myquery.Query = @"<Where><Eq><FieldRef Name='ID'/><Value Type='Number'>"+txtid.Text.ToString()+"</Value> </Eq></Where>";
                string idvaluuue=txtid.Text.ToString();;
                myquery.Query = @"<Where>
              <And>
                  <Eq>
                     <FieldRef Name='ID'/>
                     <Value Type='Number'>"+idvaluue+"</Value>
                  </Eq>
                   <Eq>
                     <FieldRef Name='NumberOfEvents'/>
                     <Value Type='Text'>"+drbcalenders.SelectedItem.Text.ToString()+"</Value>
                   </Eq>
               </And>
              </Where>";
Code 2
SPList mylist = myweb.Lists["sample"];
                SPItem myitem = mylist.Items.Add();
                SPQuery myquery = new SPQuery();
                string idvalue = txtid.Text.ToString();
                //myquery.Query = @"<Where><Eq><FieldRef Name='ID'/><Value Type='Number'>"+txtid.Text.ToString()+"</Value> </Eq></Where>";
                string idvaluuue=txtid.Text.ToString();;
                myquery.Query = @"<Where>
              <And>
                  <Eq>
                     <FieldRef Name='ID'/>
                     <Value Type='Number'>9</Value>
                  </Eq>
                   <Eq>
                     <FieldRef Name='NumberOfEvents'/>
                     <Value Type='Text'>July</Value>
                   </Eq>
               </And>
              </Where>";
Samar

below is query with multiple AND usage...I hope it will help you out...
string four = "4";
string five = "5";
string fifty = "50";
myQuery.Query = @"<Where>
<And>
<And>
<Eq>
<FieldRef Name='PCurrency' />
<Value Type='Currency'>"+fifty+@"</Value>
</Eq>
<Eq>
<FieldRef Name='PNumber' />
<Value Type='Number'>"+four+@"</Value>
</Eq>
</And>
<Eq>
<FieldRef Name='ID' />
<Value Type='Counter'>"+five+@"</Value>
</Eq>
</And>
</Where>";
***If my post is answer for your query please mark as answer***
***If my answer is helpful please vote ***

Similar Messages

  • FETCH DATA FROM ORACLE DATABASE USING Web Dynpro

    I want to fetch data from ORACLE database using Web Dynpro.How can I do this?

    1) Are you sure that you get no results? It sounds like you are having name resolution issues, which would imply that you should be getting an ORA-00942 error indicating that the table doesn't exist (or that you don't have access to the table). If you are not seeing this error, I would tend to suspect an overzealous exception handler.
    2) What database account owns the table? What database account is your ASP.Net application using to connect? Assuming these two accounts are different, your application would either have to
    - Explicitly prefix the table name with the schema name
    - Have a public or private synonym that maps the table name to the fully qualified identifier schema_name.table_name
    - Issue the command ALTER SESSION SET CURRENT_SCHEMA = <<schema name>> in each session, in which case all queries in the session would use the specified schema name as the default if no schema name is prefixed.
    Justin

  • Help needed in Exporting tables data through SQL query

    Hi All,
    I need to write a shell script(ksh) to take some of the tables data backup.
    The tables list is not static, and those are selecting through dynamic sql
    query.
    Can any body tell help me how to write the export command to export tables
    which are selected dynamically through SQL query.
    I tried like this
    exp ------ tables = query \" select empno from emp where ename\= \'SSS\' \"
    but its throws the following error
    EXP-00035: QUERY parameter valid only for table mode exports
    Thanks in advance,

    Hi,
    You can dynamically generate parameter file for export utility using shell script. This export parameter file can contain any table list you want every time. Then simply run the command
    $ exp parfile=myfile.txt

  • Slow Speed While fetching data from SQL 2008 using DoQuery.

    Hello,
    I am working for an AddOn and tried to use DoQuery for fetching data from SQL 2008 in C#.
    There are around 148 records which full fill this query condition but it takes much time to fetch the data.
    I wanna know that is there any problem in this code by which my application is getting slower.
    I used break Points and checked it, I founds that while connecting to the server it is taking time.
    Code:
    // Get an initialized SBObob object
    oSBObob = (SAPbobsCOM.SBObob)oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoBridge);
    //// Get an initialized Recordset object
    oRecordset = (SAPbobsCOM.Recordset)oCompany.GetBusinessObject(SAPbobsCOM.BoObjectTypes.BoRecordset);
    string sqlstring = "select DocEntry,ItemCode From OWOR  where OWOR.Status='R' and DocEntry not in ( Select distinct(BaseRef) from IGE1 where IGE1.BaseRef = OWOR.DocEntry)";
    oRecordset.DoQuery(sqlstring);
    var ProductList = new BindingList<KeyValuePair<string, string>>();
    ProductList.Add(new KeyValuePair<string, string>("", "---Please Select---"));
    while (!(oRecordset.EoF))
    ProductList.Add(new KeyValuePair<string, string>(oRecordset.Fields.Item(0).Value.ToString(), oRecordset.Fields.Item(0).Value.ToString() + " ( " + oRecordset.Fields.Item(1).Value.ToString() + " ) "));
    oRecordset.MoveNext();
    cmbProductionOrder.ValueMember = "Key";
    cmbProductionOrder.DisplayMember = "Value";
    Thanks and Regards,
    Ravi Sharma

    Hi Ravi,
    your code and query look correct. But can you ellaborate a little bit.
    It seems to be a DI API program ( no UI API ) ?
    When you say "I founds that while connecting to the server it is taking time." do you mean the recordset query or the DI API connection to SBO ? The later would be "normal" since the connection can take up to 30 seconds.
    To get data it is usually better to use direct SQL connections.
    regards,
    Maik

  • CAML Query Using CSOM in PowerShell

    Hi,
    I am trying to retrieve list items based on certain conditions using CAML query. I am using CAML query in Powershell using CSOM.​ The issue is no matter what condition i provide, it returns all list items. Any help would be highly appreciated. The script is: 
    # Location of DLL's
    $loc ="C:\SharePoint\ClientDLL"
    Write-Host "Date Range"
    Set-Location $loc
    Add-Type -Path (Resolve-Path Microsoft.SharePoint.Client.dll)
    Add-Type -Path (Resolve-Path Microsoft.SharePoint.Client.Runtime.dll)
    #Write the path of SharePoint Portal within double braces
    $siteUrl = ""
    #Login ID
    $loginname = ""
    #$listname=""
    Write-Host "Please enter password for $($siteUrl):"
    $pwd = Read-Host -AsSecureString
    $ctx = New-Object Microsoft.SharePoint.Client.ClientContext($siteUrl)
    $ctx.Credentials = New-Object System.Net.NetworkCredential($loginname, $pwd)
    $web = $ctx.Web
    $list=$Web.Lists.GetByTitle($listname)
    $count = $list.ItemCount
    Write-Host $count
    $newline = [environment]::newline
    $($list.Title)
    Write-Host -NoNewline "Deleting list items from : $($listname)" -foregroundcolor black -backgroundcolor yellow
    #$caml="<View><Query><Where><Eq><FieldRef Name='Title'/><Value Type='Text'>achint</Value></Eq></Where></Query></View>"
    $caml="<View><Query><Where><Eq><FieldRef Name='Created'/><Value Type='DateTime' IncludeTimeValue='FALSE'>11/9/2014</Value></Eq></Where></Query></View>"
    $cquery = New-Object Microsoft.SharePoint.Client.CamlQuery
    $cquery.ViewXml=$caml    
    $listItems = $list.GetItems($cquery)
    $ctx.Load($listItems)
    $ctx.ExecuteQuery()
    $newline
    Write-Host  $listItems.Count
    if ($listItems.Count -gt 0)
            #$listItems | % {$list.GetItemById($_.Id).DeleteObject()}        
            #$ctx.ExecuteQuery()
            Write-Host "All list items deleted from List." -foregroundcolor black -backgroundcolor green
    else
            Write-Host "No Item in list: $($listname) to delete" -foregroundcolor black -backgroundcolor red
    Regards,
    Sudheer
    Thanks & Regards, Sudheer

    HI?
    TRY to use query like this :
    $query = "<query>
    <where>
    <eq>
    <FieldRef Name="ID"
    <Value Type="Number">$IDNum</value>
    </eq>
    </where>
    </query>"

  • Caml query using managed metadata column

    hi,
     I am having a console appln, where i want  to pass the one paramater in the form of siteCol1:subsite1:subsite2  where  siteCol1:subsite1:subsite2 is the path of subsite which is in MMS.
    Can i pass this string paramter to the splist which contains a taxonomy column   and match this paramter in the listitemcollection and fetch only those recordw which matches this crirteria.
    and it should fetch the values which matches in a splist. the caml query it expects contains the taxonomy -managed metadata column - , but i am stuck with
    SPList splistLIST = parenttWeb.Lists.TryGetList("LIST1");
                          if ((splistLIST.Items.Count > 0 && splistLIST!= null))
                              SPQuery   objnodeQuery = new SPQuery();
                              objnodeQuery.Query =
                                  string.Format(
           "<OrderBy>" +
              "<FieldRef Name='ID' />" +
           "</OrderBy>" +
           "<Where>" +
              "<Eq>" +
                 "<FieldRef Name='myTaxonomy' />" +
                 "<Value Type='Text'>{0}</Value>" +
              "</Eq>" +
           "</Where>", _mcurrentPathTermSet);
                              SPListItemCollection nodeItemCollection = splistLIST1.GetItems(objnodeQuery);
    am not able to retrieve the listitems which passes this as a parameter and retrieve those records where it matches this taxonomy column.
    my doubt is, how to pass a string parameter to the splist contains taxonomy column and fetch those records

    Hi,
    Managed metada column does not supported in lookup column as the thread below:
    https://social.technet.microsoft.com/Forums/en-US/0dee5ba4-9648-445f-a774-8c59cf01b81c/confirmation-needed-cant-lookup-managed-metadata-field-with-lookup-column?forum=sharepointgeneralprevious
    If you prefer managed metadata in Search, then I'd suggest you find workaround to use managed metadata column in lookup column. You could use a workflow to copy the managed metadata column to a text field, make the text field to be hidded from the list if
    necessary. Then lookup this text field in other list.
    Regards,
    Rebecca Tu
    TechNet Community Support

  • FETCHING DATA FROM A TABLE USING ARRAYLIST

    how can we fetch data from database using arraylist????

    Hi ,
    This is the way to fetch data into 2d array , you can customize to fetch in array list .
    we will assume that we have stm as Statement and rs as ResultSet
    rs = stm.executeQuery("select * from emp");
    int noOfColumns = rs.getMetaData.getColumnCount();
    rs.last();
    int noOfRows = rs.getRow;
    rs.befpreFirst();
    String [][] result = new String[noOfRows][noOfColumns];
    for(int i = 0 ; i<noOfColumns;i++){
    rs.next();
    for(int y = 0;y<noOfColumns;y++){
    result[i][y]=rs.getString(y+1);
    rs.close;

  • Error while fetching data from OWB Client using External Table.

    Dear All,
    I am using Oracle Warehouse Builder 11g & Oracle 10gR2 as repository database on Windows 2000 Server.
    I facing some issue in fetching data from a Flat File using external table from OWB Client.
    I have perform all the steps without any error but when I try to view the data, I got the following error.
    ======================================
    RA-29913: error in executing ODCIEXTTABLEOPEN callout
    ORA-29400: data cartridge error
    KUP-04040: file expense_categories.csv in SOURCE_LOCATION not found
    ORA-06512: at "SYS.ORACLE_LOADER", line 19
    java.sql.SQLException: ORA-29913: error in executing ODCIEXTTABLEOPEN callout
    ORA-29400: data cartridge error
    KUP-04040: file expense_categories.csv in SOURCE_LOCATION not found
    ORA-06512: at "SYS.ORACLE_LOADER", line 19
         at oracle.jdbc.driver.SQLStateMapping.newSQLException(SQLStateMapping.java:70)
         at oracle.jdbc.driver.DatabaseError.newSQLException(DatabaseError.java:110)
         at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:171)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:455)
         at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:413)
         at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:1030)
         at oracle.jdbc.driver.T4CStatement.doOall8(T4CStatement.java:183)
         at oracle.jdbc.driver.T4CStatement.executeForDescribe(T4CStatement.java:774)
         at oracle.jdbc.driver.T4CStatement.executeMaybeDescribe(T4CStatement.java:849)
         at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1186)
         at oracle.jdbc.driver.OracleStatement.executeQuery(OracleStatement.java:1377)
         at oracle.jdbc.driver.OracleStatementWrapper.executeQuery(OracleStatementWrapper.java:386)
         at oracle.wh.ui.owbcommon.QueryResult.<init>(QueryResult.java:18)
         at oracle.wh.ui.owbcommon.dataviewer.relational.OracleQueryResult.<init>(OracleDVTableModel.java:48)
         at oracle.wh.ui.owbcommon.dataviewer.relational.OracleDVTableModel.doFetch(OracleDVTableModel.java:20)
         at oracle.wh.ui.owbcommon.dataviewer.RDVTableModel.fetch(RDVTableModel.java:46)
         at oracle.wh.ui.owbcommon.dataviewer.BaseDataViewerPanel$1.actionPerformed(BaseDataViewerPanel.java:218)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
         at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
         at javax.swing.AbstractButton.doClick(AbstractButton.java:302)
         at javax.swing.AbstractButton.doClick(AbstractButton.java:282)
         at oracle.wh.ui.owbcommon.dataviewer.BaseDataViewerPanel.executeQuery(BaseDataViewerPanel.java:493)
         at oracle.wh.ui.owbcommon.dataviewer.BaseDataViewerEditor.init(BaseDataViewerEditor.java:116)
         at oracle.wh.ui.owbcommon.dataviewer.BaseDataViewerEditor.<init>(BaseDataViewerEditor.java:58)
         at oracle.wh.ui.owbcommon.dataviewer.relational.DataViewerEditor.<init>(DataViewerEditor.java:16)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
         at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
         at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
         at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
         at oracle.wh.ui.owbcommon.IdeUtils._tryLaunchEditorByClass(IdeUtils.java:1412)
         at oracle.wh.ui.owbcommon.IdeUtils._doLaunchEditor(IdeUtils.java:1349)
         at oracle.wh.ui.owbcommon.IdeUtils._doLaunchEditor(IdeUtils.java:1367)
         at oracle.wh.ui.owbcommon.IdeUtils.showDataViewer(IdeUtils.java:869)
         at oracle.wh.ui.owbcommon.IdeUtils.showDataViewer(IdeUtils.java:856)
         at oracle.wh.ui.console.commands.DataViewerCmd.performAction(DataViewerCmd.java:19)
         at oracle.wh.ui.console.commands.TreeMenuHandler$1.run(TreeMenuHandler.java:188)
         at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
    ===========================
    In the error it is showing that file expense_categories.csv in SOURCE_LOCATION not found but I am 100% sure that file is very much there.
    Is anybody face the same issue?
    Do we need to configure something before loading data from a flat file from OWB Client?
    Any help would higly appreciable.
    Regards,
    Manmohan Sharma

    Hi Detlef / Gowtham,
    Now I am able to fetch data from flat files from OWB Server as well as OWB Client.
    One way I have achieved as suggested by you
    1) Creating location on the OWB Client
    2) Samples the files at client
    3) Created & Configured external table
    4) Copy all flat files on OWB Server
    5) Updated the location which I created at the client.
    Other way
    1) Creating location on the OWB Client
    2) Samples the files at client
    3) Created & Configured external table
    4) Copied flat files on the sever in same drive & directory . like if my all flat files are on C:\data at OWB Client then I copied flat file C:\data on the OWB Server. But this is feasible for Non-Windows.
    Hence my problem solved.
    Thanks a lot.
    Regards,
    Manmohan

  • Facing prolem  in Dashboard 4.1, while fetching data from Bex Query

    Hi Exports,
    I am facing an error message  " Failed to (de-)serialise data. (Xsl 000004)"  while fetching data in Dashboard from Bex Query.
    The query is getting connect. while drag n drop some dimensions and measures then going for Refesh or Run Query, geting this error.
    The same query is working fine with other comp like webi n crystal.
    Anybody having solution for this please let me know. I am stuck somewhere.
    Thank You

    Hi,
    Check the data in the infoProvider.Reduce the  Bex query Characteristics & Key figure fields.Try to identify due to which characteristsic adding in Bex Query ,are you facing the issue.Check that characteristic data in the infoProvider.
    Regards,
    Venkat

  • GetListItems CAML query using Lookup fields

    Hi,
    I am struggling to find the correct CAML query syntax to use for GetListItems where I need to return an item ID based on a query involving both a lookup field (lookup is to a column within the same list) and a text field.
    For Example (but changing one of the below to a lookup field):-
    <soap:Body>
        <m:GetListItems>
          <m:listName>ListName</m:listName>
          <m:query>
    <Query>
      <Where>
        <And>
          <Eq>
            <FieldRef Name="LevelOne" />
            <Value Type="Text">"test1"</Value>
          </Eq>
          <Eq>
            <FieldRef Name="LevelTwo' />
            <Value Type="Text">"test2"</Value>
          </Eq>
        </And>
      </Where>
    </Query>
    </m:query>
    <m:viewFields>
    <FieldRef Name ="ID" />
    </ViewFields>
    </m:viewFields>
    </m:GetListItems>
    </soap:Body>
    Any help appreciated!

    When you query a lookup column, you can choose to either query by text value or by lookup ID number (that is, the ID of the item being looked up).
    Here are examples of both:
    <FieldRef Name="MyLookupColumn" />
    <Value Type="Lookup">Thriggle</Value>
    <FieldRef Name="MyLookupColumn" LookupId="TRUE" />
    <Value Type="Lookup">100</Value>

  • Fetch Data from Face Book using Facebook API

    HI,
    I am working on .NET application to fetch user/friend details from face book using API. I am expecting the user details such as
    user_photos,email,user_location,user_birthday,first_name,last_name,gender.
    I can able to find the values for first_name, last_name, gender only.
    I couldn't find the values of user_photos, email, user_location, user_birthday.
    I have used the URL below to fetch data :
    string
    url = @"https://graph.facebook.com/"+
    fbUserId + "?fields=first_name,last_name,email,gender&method=GET
    Please suggest me to retrieve the remain values.
    Thanks in Advance.
    Pearl

    Have you opened the sample in
    https://github.com/facebook-csharp-sdk/facebook-windows8-sample ?
    I read the code is close what you need actually.
    chanmm
    chanmm

  • I want to open a txt file and output data through an AO-using DAQmx for PXI

    I have a PXI running a 8145RT CPU. I have a PX6040E Multifunction DAQ card installed in the PXI. I want to program an application where I open a txt file (existing in one of the the RT machines' folders), read the first row, and output its data through an AO channel. The drivers I should use is DAQmx v7.1, and the Labview RT v.7
    Any idea?

    What exactly are you having problems with? Reading a text file can be done a number of ways. Look at the File I/O palette and check out Read Lines From File or Read Characters From File. There are string to number conversion functions on the string palette (i.e. Scan From String). There are also numberous shipping examples on using DAQmx for analog out. If you have a specific problem or question, please post back with additional details.

  • Hey guys how to fetch data from db table using subroutine

    hi guys,
                   I am fetching data from db table "mcha". now in the follwing code i get it in "HSDAT1_DATE."
                   now when i read out_tab with key "HSDAT1". it wont come in out_tab-value.plz tell me what is wrong whether some key condition in out_tab or any thing else.
    and what should i write in changing && in script.
    thanks in advance
    FORM DATE_MGF TABLES IN_TAB STRUCTURE ITCSY
                         OUT_TAB STRUCTURE ITCSY.
    tables :MCHA ,QALS.
      DATA : WERKS1 LIKE QALS-WERK.
      DATA : HSDAT1 LIKE MCHA-HSDAT.
      DATA : DATE(2),
             MONTH(2),
             YEAR(4).
    DATA : HSDAT1_DATE(10).
      READ TABLE IN_TAB WITH KEY 'QALS-WERK'.
      LOOP AT IN_TAB.
        IF SY-TABIX EQ 1.
          WERKS1 = IN_TAB-VALUE.
          IF WERKS1 NE SPACE.
            EXIT.
          ENDIF.
        ENDIF.
      ENDLOOP.
      SELECT SINGLE HSDAT INTO HSDAT1
                          FROM MCHA
                                    WHERE  WERKS = WERKS1.
      DATE = HSDAT1+6(2).
      MONTH = HSDAT1+4(2).
      YEAR = HSDAT1+0(4).
      CONCATENATE DATE '.' MONTH '.' YEAR INTO HSDAT1_DATE.
      READ TABLE OUT_TAB WITH KEY 'HSDAT1' .
      IF SY-SUBRC = 0.
        OUT_TAB-VALUE = HSDAT1.
        MODIFY OUT_TAB INDEX SY-TABIX.
      ENDIF.

    Hi,
    Let me understanf clearly what you want.
    initally mine out_tab is blank
    According to you, your table out_tab is blank. And you need to add out_tab-value = HSDAT1_date.
    READ TABLE OUT_TAB WITH KEY 'HSDAT1' .
      IF SY-SUBRC = 0.
        OUT_TAB-VALUE = HSDAT1.
        MODIFY OUT_TAB INDEX SY-TABIX.
      ENDIF.
    So, if your table is blank, then read statement will fail.
    Please let me know if your table out_tab in blank when you are reading the table and if this table contains any field called HSDAT.
    Basically i would like to know your internal table out_tab declaration.
    Thanks,
    Archana

  • Which Data-Types can be used as Widget Parameters?

    Hi,
    I have been playing about with widgets (specifically widget parameters) for a while now.
    I've got to wondering, exactly which data-types can Captivate turn into widget parameters?
    So far I know that you can use:
    Numbers,
    Strings,
    Arrays,
    Objects
    and Booleans,
    as parameters.
    Which ones am I missing?
    I know some don't work, because I tried storing a MovieClip as a parameter and that didn't work.

    Hi Eccles,
    You can set all basic data types supported in flash viz.,
    1)Numbers
    2)Strings
    3)Arrays
    4)Objects
    Since in Action script , an Object can be anything (array , array of objects , array of objects which by themselves are array of objects and so on ) , you can virtualy send anything as widget params
    But there are two caveats to this
    1)Object References
    -Object References do not have any meaning once the swf is closed.But the widget params have to be stored across sessions.So If you send a reference as part of widget params it is not going to work.
    This is why sending a Movie Clip (which is actually a reference to an Object ) does not work
    If you want to send such things you will have to 'serialize' the object.
    2)Size of the Object that you send
    The size of the object that you send can have an impact on performance.And since any object that you send has to be converted into XML , objects like bitmaps can turn out to be huge and difficult to handle.
    This brings us down to this - you can send any object across as widget param as long as it is small and serialized.

  • How to fetch data to APEX Report using stored procedure?

    hi all,
    i am making a report in APEX. user selects two dates and clicks GO button - i have a Stored Procedure linked to that result region so Stored Procedure gets called.
    my stored procedure does the following -
    using specified dates (IN) i do query and put data into a table (this table has been created only for this report) -
    i want to show all these data i entered into the table on my APEX report in the same procedure call. can i use ref cursor to return? how to do that?
    currently, i use another button in APEX which basically fetches all data from table. basically, user clicks one button to generate report and then another button to get report. which is not desirable at all :(
    i m using APEX      3.1.2.00.02 and Oracle 10 database.
    pls let me know if you need further clarification of the problem. thanks in advance.
    regards,
    probashi
    Edited by: porobashi on May 19, 2009 2:53 PM

    Thanks Tony.
    I am not sure what you meant by >> change the report to be based off of a query returning sql statement, no need to keep that table around.... >>
    Here's my stored procedure
    create or replace
    PROCEDURE ABC_PROC (
    START_DATE IN DATE,
    END_DATE IN DATE
    AS
    RULE_REC MTG_OFFICER_FORECAST%ROWTYPE;
    TYPE REF_CURSOR IS REF CURSOR;
    TCUR REF_CURSOR;
    BEGIN
    DELETE FROM ABC_REPORT;
    OPEN TCUR FOR
    SELECT ABC_FORECAST.*
    from MTG_OFFICER_FORECAST , MTG_USERS
    WHERE MTG_OFFICER_FORECAST.NBR_OFFICER = MTG_USERS.NBR_OFFICER AND
    MTG_OFFICER_FORECAST.NBR_INSTITUTION = MTG_USERS.NBR_INSTITUTION;
    LOOP
    FETCH TCUR INTO RULE_REC;
    EXIT WHEN TCUR%NOTFOUND;
    INSERT INTO ABC_REPORT( NBR_OFFICER, OFFICER_NAME, FORECAST_NBR_LOANS, FORECAST_LOAN_AMT, FORECAST_FEES,
    ACTUAL_NBR_LOANS, ACTUAL_LOAN_AMT, ACTUAL_FEES, RATIO_NBR_LOANS, RATIO_LOAN_AMT, RATIO_FEES, NBR_INSTITUTE )
    VALUES ( RULE_REC.NBR_OFFICER, RULE_REC.NAME_LOAN_OFFICER, RULE_REC.NBR_LOANS, RULE_REC.AMT_LOAN, RULE_REC.AMT_FEES,
    ACTUAL_NBR_LOANS, ACTUAL_LOAN_AMOUNT, ACTUAL_FEES, SUCCESS_RATIOS_NBR_LOANS_PERC, SUCCESS_RATIOS_LOAN_AMT_PERC, SUCCESS_RATIOS_FEES_PERC, RULE_REC.NBR_INSTITUTION );
    END LOOP;
    CLOSE TCUR;
    END ABC_PROC;
    Thanks,
    Probashi
    Edited by: porobashi on Jun 2, 2009 11:43 AM

Maybe you are looking for

  • How do I combine multiple pdf's into the one document?

    A Printer told me awhile ago when i bought in some stuff, that I can combine the pdfs all into the one pdf. Can anyone tell me how you do that and also can I do this with pdf's that are different document sizes? I am making an inviation, program, pla

  • Event Handling in C API

    Does Internet Directory C API supply the event handling like those in JNDI? Actually Netscape Directory/IBM Secuway Directory supply this features for C SDK, why Oracle Directory Server do not supply it? Thanks, Peter

  • Connecting Fire Wire to a G4 400 PCI to Use Migratiion Assistant

    I get a window saying the the fire Wire will not connect to the G4. I want to transfer the Data from the G4 to the iMac, but it won't connect through Fire Wire.

  • Tab button - How to use it in Hyperion IR 9.3.1

    Hi All, I got a requirement from my client. He wants to use the Tab key functionality on the dashboard for the different command buttons. I have used command button for process, export and print report. I am not able to set the Tab key property on th

  • Repeating successful uploads - procedure to delete all the requests/packets

    Hi friends, I have a sort of hypothetical question, so never mind if this makes sense in real life (actually, I can think of a few situations where it makes sense, but only as a last resort). Let's say I want to repeat the upload that was successful