Displaying items based on Query record count

I have a special requirement.
Assume col1 that I am selecting from table temp.
select col1 from temp;
Now if query fetches 9 records.
Each column I want to show like this.
1 2 3 4 5 6
7 8 9
If query fetches 15 records.
Each column I want to show like this.
1 2 3 4 5 6
7 8 9 10 11 12
13 14 15.
That means items displayed on screen chages based on output of
query.
Pls. suggest some solution.
null

You can't do this with the custom search portlet.
You can use Omniportlet to display the items - using the SQL datasource (new in the July PDK) to query the content repository views. You could use the parameter form portlet provided with Omniportlet to build the selection list.
Regards,
Jerry
PortalPM

Similar Messages

  • Displaying items based on Query record count (Forms 4.5)

    I have a special requirement.
    Assume col1 that I am selecting from table temp.
    select col1 from temp;
    Now if query fetches 9 records.
    Each column I want to show like this.
    1 2 3 4 5 6
    7 8 9
    If query fetches 15 records.
    Each column I want to show like this.
    1 2 3 4 5 6
    7 8 9 10 11 12
    13 14 15.
    That means items displayed on screen chages based on output of
    query.
    Pls. suggest some solution.
    null

    When i made the above query a view and created an oracle portal form. I get this error when I try to retrieve all the records in that view i made above.
    An unexpected error occurred: ORA-01445: cannot select ROWID from a join view without a key-preserved table (WWV-16016)
    What does the "key-preserved table" mean?

  • Display items based on Orderby field

    HI,
    I have a custom list, in which I have columns like "DisplayOrder", "Title", "Value". I am showing the contents of the list in a div in a custom webpart (javascript client object model).
    The data are loading, but is not following the "DisplayOrder".
    Example: In the custom list, I have data as below:
    Title Value DisplayOrder
    One ab 2
    Two cd 3
    Three ef 1
    I have used the below code in Javascript client object model:
    function loadConfigData() {
    var configquery = new SP.CamlQuery();
    configquery.set_viewXml('<View> <Query> <OrderBy><FieldRef Name="DisplayOrder" /></OrderBy> </Query> <ViewFields><FieldRef Name="Title" /><FieldRef Name="Value" /><FieldRef Name="DisplayOrder" /></ViewFields> </View>');
    this.Allitems = oSubList.getItems(configquery);
    clientContext.load(Allitems);
    clientContext.executeQueryAsync(Function.createDelegate(this, this.NewConfigsuccess), Function.createDelegate(this, this.Configfailed));
    function NewConfigsuccess() {
    var right = 30;
    var count = this.Allitems.get_count();
    if (count >= 1) {
    var configenumerator = this.Allitems.getEnumerator();
    while (configenumerator.moveNext()) {
    var currentItem = configenumerator.get_current();
    var iTitle = currentItem.get_item('Title');
    var iValue = currentItem.get_item('Value');
    var newText = "";
    if (iTitle!= null && iTitle != "" && iValue != null & iValue != "") {
    newText = '<table class="tblContent"><tr><td class="tblLeftContent"><a style="color:white;" href="' + captionURL + '"> <img src="/_layouts/15/Images/bannertest.png" alt="' + iTitle + '"/></a></td>';
    newText = newText + '<td class="tblRightContent"><div class="middlecontent"><a style="color:white;" href="' + iValue + '">' + iTitle+ '</a></td></div></tr></table>';
    listdata = listdata + '<div class="BottomTitleBanner" style="right:' + right + 'px;">' + newText + '</div>';
    right = right + 105;
    Here, I want the data to load as "Three", "One" , "Two".
    How to fix this?
    Thanks

    function GetListItem() {
    $.ajax({
    type: "GET",
    headers: {
    "accept": "application/json;odata=verbose",
    "content-type": "application/json;odata=verbose",
    url: "http://XXXXXX/_api/web/Lists/getbytitle('OrderList')/Items?$select=Title,Test&$orderby=Test asc",
    success: function (data) {
    $.each(data.d.results, function (index, item) {
    $('#oDataSuppliers').append("<li>" + "<h1>" + item.Test + "</h1>" + "</li>");
    failure: function (data) { console.log(data); }
    You can get the column order like this

  • Need help displaying item based on pl/sql anonymous block

    This is probably something really simple but I'm stuck.....
    On purchase order, I want to show related parent project name and ID. What is the best way to do it? I have created a region based on pl/sql anonymous block, and that works, but the data is above where I want it. I want the project name and ID to show up in the region w/ all the other fields.
    I have created an item in the region that has other form fields, item is based on pl/sql anonymous block, w/ same code as above region, and the item doesn't find the data. What's the difference? Is it because the item doesn't save state? In order to choose for the item to be based on pl/sql anon block, APEX made me choose Display as Text (based on PLSQL, does not save state).
    Please see this picture:
    http://farm3.static.flickr.com/2391/2658673285_04f157a3fa_o.png
    thanks!
    ~Darby

    this is weird.. Now it is working. I didn't change anything! What the heck?
    http://farm3.static.flickr.com/2010/2659557520_73e54b67ea_o.png

  • Conditionally display items based on null LOV value

    Hello,
    I've seen several examples that do what I'd like to do but with different implementations. Perhaps someone can steer me in the right direction...
    I have a pop-up lov that pulls a list of names from various places. If, however, the name cannot be found I'd like to display a few text boxes where the user can enter a new name.
    For my list of values I have configured the following:
    Display Null: Yes
    Null Return Value: -1
    Null Display Value: Not Found
    My HTML Form Element Attributes has: onchange="doSubmit()";
    My Source section has:
    Source Used: Only when current value in session state is null
    Source Type: Static Assignment (value equals source attribute)
    My entry text boxes have a condition specified:
    Value of Item In Expression1 = Expression 2
    Expression 1: P4_LOOKUP_NAME
    Expression 2: -1
    I also have an unconditional branch to this same page (Page 4) that sets the value of P4_LOOKUP_NAME to P4_LOOKUP_NAME.
    I cannot seem to get this item to display though...any thoughts?
    Thanks in advance for your suggestions!

    jhammer,
    I like the concept. This would require a custom popup lov - something that can be a little tricky/time consuming the first time around. The popup lov would probably have to create new entries via Ajax to be able to pass back the correct ID/display values to the parent window on close.
    Regards,
    Dan
    http://danielmcghan.us
    http://sourceforge.net/projects/tapigen
    You can reward this reply by marking it as either Helpful or Correct ;-)

  • Php check all records in database then display results based on chosen record

    I have a form that is checking the database to see if a record exists .
    If it does exist then it needs to perform one of two tasks, either subtract or multiple.
    This part is working but the part that is not working is it is only checking the first record of the database and it should be checking all records as each record will give a different result
    the sql is
    mysql_select_db($database_lotties, $lotties);
    $query_rsVoucher = "SELECT * FROM LOTTIE_vouchercode";
    $rsVoucher = mysql_query($query_rsVoucher, $lotties) or die(mysql_error());
    $row_rsVoucher = mysql_fetch_assoc($rsVoucher);
    $totalRows_rsVoucher = mysql_num_rows($rsVoucher);
    // then check
    if (isset($_POST['vouchCode']) && $_POST['vouchCode'] == $row_rsVoucher['VCode']) {
      $mycode = $row_rsVoucher['VCode'];
      $spos = strpos($mycode, "f");
      if ($spos !== false) {
        $myvalue = substr($mycode, $spos+1);
        $myvalue = $XCart_sumTotal * $myvalue / 100;
      } else {
        $spos = strpos($mycode, "p");
        if ($spos !== false) {
          $myvalue = substr($mycode, $spos+1);
      $myTotal = $XCart_sumTotal - $myvalue;
      $_SESSION['vouchCode'] = $myvalue;
    } else unset($_SESSION['vouchCode']);
    the form is
    <form action="<?php echo $editFormAction; ?>" method="post" name="form2" id="form2">
    <input type="text" name="vouchCode" value="<?php echo @$_POST['vouchCode']; ?>" size="32" />
    <input type="submit" value="update" />
    </form>
    then the results are displayed
    <?php if (isset($myvalue)) { ?>
    <?php echo DoFormatCurrency($myvalue, 2, ',', '.', '£ ', ''); ?>
    <?php } ?>
    i am getting really desperate with this so any help would be appreciated
    thanks

    Jonathan Fortis wrote:
    >>You really should hire someone to write your server side code as you still don't understand programming basics.
    i did but he passed away. And i am getting an understanding just still cant get the hang of loops
    jonathan, jonathan, jonathan,
    Condolences to your deceased php developer. Was he the only professional php developer in the world? I don't think so! Enough with your excuses already. Find a professional php developer that is currecntly living then and stop looking for free professional work for your specific, profitable development requirements on a forum.
    best,
    Shocker

  • Populate multi record display item

    Hellou gurus!
    I have forms 10g and i need to populate display item in enter query mode. My problem is that I have table T1 with some static values. Table T2 is through ID connected (reference) to table T1 1:1 cardinality and T2 table also have reference to T3 table.
    I have block B2 based on table T2 and in this block I have multirecord item for inserting and updating new values for T2, but in this block ii also have no DB, multi record display item (because i don't want to allow editting in T1 table records) for diplaying static values for table T1. I want to display all static values from T1 next to the editable values in T2 (T2 multi record field is not insert yet). I tried for loop, select into but it not work. T1 values need to be selected before I started to inserting values into T2 items, but off course they need to be referenced It is hard to explain but i belive you understand.
    Can you help me how I can populate multi record item??

    You have to write the code again for your second list item....
    group_id RecordGroup;
    list_id Item  := Find_Item('button.tyear');
    list_id1 Item  := Find_Item('button.tperiod');
    status NUMBER;
    rg_name varchar2(40) := 'recgroup';
    BEGIN
    ----------------------------- LIST
    clear_list(list_id);
    group_id := Find_Group(rg_name);
    IF NOT id_null(group_id) then
        Delete_Group(group_id);
    End if;
    group_id := Create_Group_From_Query(rg_name,
    'select vm_year, vm_year from fwqgl.vouchermaster
    group by vm_year');
    status := Populate_Group(rg_name);
    Populate_List(list_id, group_id);
    /* --------------------SECOND LIST ITEM...BUT REC. GRP NAME CAN BE SAME,better to use another name if you need to retrieve list and store qry..other wise the fol. code is enuf-----------------------*/
    clear_list(list_id1);
    group_id := Find_Group(rg_name);
    IF NOT id_null(group_id) then
        Delete_Group(group_id);
    End if;
    group_id := Create_Group_From_Query(rg_name,
    'select vm_period, vm_period from fwqgl.vouchermaster
    group by vm_period');
    status := Populate_Group(rg_name);
    Populate_List(list_id1, group_id);
    END;Edited by: Dora on Dec 5, 2009 10:41 AM

  • How to display a record count in a text field?

    I am trying to return a record count of a query and place that count in a text field on my search page in APEX. I have that text field defined under Items on the search page. How do I get a query record count to display in my text field?
    Thanks,
    John
    Edited by: user7381760 on Jan 22, 2009 3:47 PM

    Hi Dan,
    Thank you for your reply and yes I was able to select "Source Type" and "SQL Query". The SQL expression I used was:
    SELECT COUNT(ID) FROM master_table;
    This worked great to count the total number of records from the master_table. However what I am trying to do is to get a record count each time I complete a search from my search page. I have input fields on this page and a GO button which executes the query. The SQL query is location in one place under Regions/Display Point. My display field on my search page is named P16_COUNT2 and I was trying to make this work inside the main query code. I tryed something like this, COUNT(ID) INTO :P16_COUNT2, to pass the record count each time I execute the GO botton to P16_COUNT2 field. This I could not get to work. Any ideas how to proceed?
    Regards,
    John

  • Query to display all records count of all tables in a schema

    Hi,
    I need to count all the records of all my tables in a certain schema and display the max amount of the record count. Do you have a script for this one??

    SQL> create function countrec(in_tab in varchar2) return number is
      2  retval number;
      3  begin
      4    execute immediate 'select count(*) from '||in_tab into retval;
      5    return retval;
      6  end;
      7  /
    Function created.
    SQL> select table_name, countrec(table_name)
      2  from tabs;
    TABLE_NAME                     COUNTREC(TABLE_NAME)
    QUERY_TOOL_DATA_COLLECTION                        5
    TEST01                                            0
    T1                                               14
    EMP                                              14
    SALGRADE                                          5
    FILES                                             0
    PROVA                                             0
    TEST                                              0
    T_MASTER                                          1
    T_CHILD                                           3
    TAB_ONE                                          30
    TAB_TWO                                          10
    A                                                 3
    B                                                 4
    C                                                 3
    D                                                 3
    BONUS                                             0
    DEPT                                              4
    18 rows selected.Max

  • How to set default settings to display record count in multi record block

    Hi All
    Whenever I query my multi record block, I get 1/? as record count at the console in standard Oracle Applications. Is there any setting so that it displays 1/50 (in case total record queried is 50). I don't want to set query all property of block as I don't have any control in standard Apps forms.
    Thanks in advance
    Navdeep

    Check out the next_navigation_item option for the get_item_property procedure. If you use this you can do the process without having to navigate from one item to the next.
    You can do something like this (untested) to move and resize the items (other than the first in the block):
    PROCEDURE move_and_resize(p_item IN ITEM, p_width IN PLS_INTEGER) IS
      prev_item ITEM := Get_Item_Property(p_item, PREVIOUS_NAVIGATION_ITEM);
    BEGIN
      Set_Item_Property(p_item, WIDTH, Get_Item_Property(p_item, WIDTH) + p_width);
      Set_Item_Property(p_item, X_POS, Get_Item_Property(prev_item, WIDTH) +
                                       Get_Item_Property(prev_item, X_POS));
    END move_and_resize;
    move_and_resize(myitem, -30);

  • Report : To display VBRP details based on BSID Records

    Dear All,
           I have to display the Item details from VBRP based on the BSID Table. So Now I am selecting the VBRP details based on the VBELN in BSID. But For some BSID records there is no vbeln value. Then
    1 )  How can I display the item details of that records.
    2 ) Where it is stored.
    3 )  Is it something related to type 'RV' ?
    Please help me...
    Thanks in Advance..
    Regards,
    Lijo

    Dear  LIJO JOHN,
    U will get VBELN i.e Billing Document field only for "RV' document type in BSID & for all rest others u will get blank.
    Regards
    SWAPNIL

  • How to Display Record Count on Search page?

    Hi
    I am new to OAF and one of the requirement is to display record count on Search page . I followed the same steps in Emp Search page as an example and created my search page.
    I followed the following steps
    1) I created a transietn Attribute in VO by name RecordCount
    2) I had written a method in AMImpl
    public void getRecordCount() {
    OAViewObject vo = getXXG2SourceAcctSearchVO1();
    int fetchedRowCount = vo.getFetchedRowCount();
    String msg = fetchedRowCount + " are retrived by query ";
    System.out.println(msg);
    String xfetchedRowCount = Integer.toString(fetchedRowCount);
    System.out.println("xfetchedRowCount : " + xfetchedRowCount);
    OARow reportRow = (OARow)vo.createRow();
    System.out.println("in set attribute");
    reportRow.setAttribute("RecordCount",xfetchedRowCount); // I am using this way and trying to display record count into RecordCount view Attribute
    }//getRecordCount
    3) on the SearchPG, I created a new messageStyledtext by name RecordCount and assinged VO and viewAttribute accordingly
    I am not able to see record count when i run the page ?
    Am i missing any steps ?
    I see the messages in the log file but not in Record count box ?
    Any suggestions?
    Thanks
    Ravi

    Hi Anoop
    i made the code change according to you and because of the following condition, it is createing a" new row" in the search page
    Row row = vo.createRow();
    vo.insertRow(row);
    For every search it is creating a new blank row in search page .
    I did some more research and modified my code as
    public void getRecordCount() {
    OAViewObject vo = getXXG2SourceAcctSearchVO1();
    int fetchedRowCount = 0;
    fetchedRowCount = vo.getFetchedRowCount();
    String msg = fetchedRowCount + " are retrived by query ";
    System.out.println(msg);
    //vo.setMaxFetchSize(0);
    //vo.executeQuery();
    if (fetchedRowCount == 0 )
    Row row = vo.createRow();
    //row = (OARow)vo.first();
    row.setAttribute("RecordCount", "0");
    else
    String xfetchedRowCount = Integer.toString(fetchedRowCount);
    System.out.println("xfetchedRowCount : " + xfetchedRowCount);
    Row row = vo.createRow();
    //vo.insertRow(row);
    row.setNewRowState(Row.STATUS_INITIALIZED);
    // Set the primary key value for this single-row VO.
    row = (OARow)vo.first();
    row.setAttribute("RecordCount", xfetchedRowCount);
    and in AM , I am calling this method in PFR as follows
    public void processFormRequest(OAPageContext pageContext, OAWebBean webBean)
    super.processFormRequest(pageContext, webBean);
    OAApplicationModule am1 =
    (OAApplicationModule)pageContext.getApplicationModule(webBean);
    am1.invokeMethod("getRecordCount");
    now i see the record count on the search page . but after 2-3 searches, the record count value is not populating the correct value. its weird
    Any suggestions
    Thanks
    Ravi

  • CAML Query to Sort SharePoint list items based on Modified date

    hi ,
    can we sort sharePoint list items based on 'Modified' column, the sorting should be done up to milliseconds level.
    currently i am using CAML query as below
    <OrderBy><FieldRef Name='Modified' Type='DateTime' IncludeTimeValue='TRUE' Ascending='False'/></OrderBy>but its not considering milliseconds while sorting.
    Thanks and Regards,
    venkatesh.

    Veda, thanks but I'm not really a hardcore C# coder.
    We found more elegant solution was to create a List View which returns all records that should be deleted, based on our own custom deletion criteria, and then create an very simple SSIS Package in Visual Studio using the
    Sharepoint Connectors for SSIS to delete all Sharepoint List Items returned from that List View. The Sharepoint Destination Connector has a delete operation.
    This worked for us and didn't require any coding.

  • Updating a value of a text item in a multi record block based on a change

    Hi,
    I need to change the value of a text item in a multi record block based on a change to another item's value in the same block.
    Suppose there's a text item in a multi record block called dt1 which is of type date, which is changed in a particular record. I want to change the values of the another item in the same multi record block, for all other records by running a loop through all the records in multi record block. I dont want to do it on the press of a button, it should do automatically on change. Help me resolve this issue.

    Hi,
    I need to change the value of a text item in a multi record block based on a change to another item's value in the same block.
    Suppose there's a text item in a multi record block called dt1 which is of type date, which is changed in a particular record. I want to change the values of the another item in the same multi record block, for all other records by running a loop through all the records in multi record block. I dont want to do it on the press of a button, it should do automatically on change. Help me resolve this issue.

  • How can I get record count with a query?

    In Client/Server pplication,the client send a query to server.
    How can server get record count by oracle call interface?
    Is it need execute "select count(*) from ...."?

    Yes.
    Either that or increment a counter for each record fetched and
    loop round until you hit the last record.
    The first method would be more efficient on large datasets.

Maybe you are looking for

  • Bluetooth status icon in the wrong place?

    Well I turn on the MacBook Pro this morning to find that the bluetooth status icon is now between the clock and spotlight. Usually it was next to the airport status icon. On my old powerbook it was always next to the airport status icon. So i thought

  • How does one set a password a start-up?

    My mac book pro with retina display is operating on OS X Version 10.9.2 and it was built in 12/2012.  How do I set a password at start-up?  The answers I find on line are for older mac book pros and haven't helped me.  Thanks in advance.

  • Exiting a taskflow on page unload

    HI, Jdeveloper/ADF (11.1.1.5) I have a singe page application with multiple task flows as region. We found that everytime user refreshes the browser, managed beans in pageflow scope of these regions never gets released. Only when the user signs out o

  • Non-consecutive element in collection

    Hello Every one, How can i process non-consecutive element in the forall loop to update the table . i can not use .exists method as if in not allowed in forall syntax. So please can anyone give me example how to process in forall loop. in 10g we can

  • Safari 6.1 on MacOS 10.8.5 not play quicktime movies

    Trying to view quicktime movies in Safari brings up the Quicktime Q graphic with a big question mark. Safari->Help-> Installed Plug-Ins includes: QuickTime Plug-in 7.7.1 The QuickTime Plugin allows you to view a wide variety of multimedia content in