SetWhereClause not working for standard view object

Hi All,
We are trying to customize one standard page and for that we have add extra where conditions in the standard view object. In th standard view object query is null which is actually getting executed in vo impl using setQuery as follows:
Please refer setUpQuery Method:
Below is the controller code from where it is getting fired:
if(oapagecontext.getParameter("SearchButton") != null)
                        oapagecontext.putParameter("CurrAction", "SEARCH");
                        validateCategoryCriteria(oapagecontext, oawebbean);
                        SupplierSearchVOImpl suppliersearchvoimpl = (SupplierSearchVOImpl)suppliersearchamimpl.findViewObject("SupplierSearchVO");
                        if(flag)
                            suppliersearchvoimpl.setupQueryForRequestedSupplier(oapagecontext, oawebbean);
                        else
                            suppliersearchvoimpl.setupQuery(oapagecontext, oawebbean);
                        suppliersearchvoimpl.executeQuery();
                        oapagecontext.setForwardURLToCurrentPage(null, true, "S", (byte)99);
                        break label0;
As in the seeded condition setForwardURLToCurrentPage is getting fired we have added additional where condition in the processRequest of the extended controller as follows:
public void processRequest(OAPageContext pageContext, OAWebBean webBean) {
super.processRequest(pageContext, webBean);
    pageContext.writeDiagnostics(this, "inside PR",1);
    OAApplicationModule am = (OAApplicationModule)pageContext.getApplicationModule(webBean).findApplicationModule("SupplierSearchAM");
   // OAViewObject vo = (OAViewObject)am.findViewObject("SupplierSearchVO");
    SupplierSearchVOImpl vo = (SupplierSearchVOImpl)am.findViewObject("SupplierSearchVO");
    //String voQuery = vo.getQuery();
    //pageContext.writeDiagnostics(this, "SupplierSearchVO Query : "+voQuery, 1);
    //String whereClause1 = vo.getWhereClause();
    //pageContext.writeDiagnostics(this, "SupplierSearchVO Where Clause : "+whereClause1, 1);
    //pageContext.writeDiagnostics(this, "vo count "+vo.getRowCount(),1);
    //vo.setWhereClauseParams(null);
     pageContext.writeDiagnostics(this, "sessionVal PR"+pageContext.getSessionValue("sessionVal"),1);
    if (pageContext.getSessionValue("sessionVal")!=null) {
       if(pageContext.getSessionValue("sessionVal").equals("NO")) {
           if(vo!= null){
          // vo.setWhereClause("QRSLT.vendor_id = :2");
          // vo.setWhereClauseParam(1,1486622);
             //  vo.setWhereClause("vendor_id = 1486622");
              String voQuery = vo.getQuery();
              StringBuffer stringbuffer = new StringBuffer(" ");
                  stringbuffer.append("SELECT select_flag,vendor_id,vendor_name,asl_entry,trading_partner_id,\n" +
                      "Po_Hold_Switcher_Col,po_docs_totals,tot_invited_negs,tot_awarded_negs,requested_supplier_id from (");
                  stringbuffer.append(voQuery);
                  stringbuffer.append(") where vendor_id = 1486622" );
                  String str = stringbuffer.toString();
               vo.setQuery(null);
               vo.setFullSqlMode(vo.FULLSQL_MODE_AUGMENTATION);
                      pageContext.writeDiagnostics(this, "new query string==>" + str,1);
               vo.setQuery(str);
                      pageContext.writeDiagnostics(this, "new query after vo==>" + vo.getQuery(),1);
               pageContext.writeDiagnostics(this, "new query ready toexecute==>" + vo.isPreparedForExecution(),1);
           if(vo.isPreparedForExecution()) {
               vo.executeQuery();
           else {
               vo.setPreparedForExecution(true);
               vo.executeQuery();
               pageContext.writeDiagnostics(this, "vo count "+vo.getRowCount(),1);
               pageContext.writeDiagnostics(this, "new query "+vo.getQuery(),1);
* Procedure to handle form submissions for form elements in
* a region.
* @param pageContext the current OA page context
* @param webBean the web bean corresponding to the region
public void processFormRequest(OAPageContext pageContext,
OAWebBean webBean) {
     // sessionVal="No";
      pageContext.putSessionValue("sessionVal","NO");
      pageContext.writeDiagnostics(this, "sessionVal PFR"+pageContext.getSessionValue("sessionVal"),1);    
super.processFormRequest(pageContext, webBean);
pageContext.writeDiagnostics(this, "ProcessFormRequest called...", 1);
OAApplicationModule am = (OAApplicationModule)pageContext.getApplicationModule(webBean).findApplicationModule("SupplierSearchAM");
//if (pageContext.getParameter("SearchButton")!=null)
//  pageContext.writeDiagnostics(this, "inside serach button custom",1);
//super.processFormRequest(pageContext, webBean);
//    SupplierSearchVOImpl vo = (SupplierSearchVOImpl)am.findViewObject("SupplierSearchVO");
//OAViewObject vo = (OAViewObject)am.findViewObject("SupplierSearchVO");
//String voQuery = vo.getQuery();
//pageContext.writeDiagnostics(this, "SupplierSearchVO Query : "+voQuery, 1);
//String whereClause1 = vo.getWhereClause();
//pageContext.writeDiagnostics(this, "SupplierSearchVO Where Clause : "+whereClause1, 1);
//pageContext.writeDiagnostics(this, "vo count "+vo.getRowCount(),1);
//vo.setWhereClauseParams(null);
//vo.setWhereClause("vendor_id = :1");
//vo.setWhereClause("city = :2");
// vo.setWhereClause("vendor_id = :1");
//vo.setWhereClauseParam(0, "1486622");
// vo.executeQuery();
  // pageContext.writeDiagnostics(this, "new query after execute ==>" + vo.getQuery(),1);
   // vo.executeQuery();
//pageContext.writeDiagnostics(this, "vo count "+vo.getRowCount(),1);
// SupplierSearchAMImpl suppliersearchamimpl = (SupplierSearchAMImpl)pageContext.getApplicationModule(webBean).findApplicationModule("SupplierSearchAM");
// boolean flag = "PROSPECTIVE".equals(pageContext.getParameter("SupplierStatus"));
  //  if(pageContext.getParameter("SearchButton") != null)
       // pageContext.putParameter("CurrAction", "SEARCH");
       // validateCategoryCriteria(pageContext, webBean);
       // SupplierSearchVOImpl suppliersearchvoimpl = (SupplierSearchVOImpl)am.findViewObject("SupplierSearchVO");
       // if(flag)
       //     suppliersearchvoimpl.setupQueryForRequestedSupplier(pageContext, webBean);
       // else
        //    suppliersearchvoimpl.setupQuery(pageContext, webBean);
        //suppliersearchvoimpl.customExecuteQuery();
       // oapagecontext.setForwardURLToCurrentPage(null, true, "S", (byte)99);
       // break label0;
  We have tried setting both where clause and query but the issue is condition is getting added in the query when I am printing getQuery but while executing it is executing the old vo query only.
So can anyone help us on this?

When you post a question, please use the Advanced Editor and paste the code with appropirate syntax. It will make it easy to read. Otherwise your question might get ignored by others as it is very very difficult to read.
What is the output you are getting for the below diagnostic messages  ? Is it returning the correct query and correct count ?
pageContext.writeDiagnostics(this, "vo count "+vo.getRowCount(),1);
pageContext.writeDiagnostics(this, "new query "+vo.getQuery(),1);
Cheers
AJ

Similar Messages

  • View link not working for programatic view objects

    Dear All,
    I have created 2 vo that is programatically populated from the stored procedures, which runs perfectly.
    I created a view link between these 2 vo which has 1-many relationships. when i run AM then the destination VO is not getting filtered based on source vo. but it displays all records for all the records in source table. Is there any work around for this problem....?
    Regards,
    Santosh.
    Component     Version
    =========     =======
    ADF Business Components     11.1.1.59.23
    Java(TM) Platform     1.6.0_21
    Oracle IDE     11.1.1.4.37.59.23
    Versioning Support     11.1.1.4.37.59.23

    beep.

  • Export to powerpoint not working for certain views

    Hi All,
    I am in the process of implementation of STVN 2.1 Pre EHP3 version of Nakisa OrgChart for one of my clients.
    During testing, it is observed that export to powerpoint object is not working for the following views.
    1. Condensed Org. Chart
    2. Compressed OrgChart -Only works when we expand at least one position
    3. Horizontal OrgChart - Condensed children-Only works when we expand at least one position
    In all the other views the export to Powerpoint object are working fine.
    Export of powerpoint image is working in all the scenarios. We are facing issue only with powerpoint object.
    I have implemented Export Pack 3.0 for OrgChart.
    J. Thomas

    Hi Luke,
    Thanks for the response.
    Yes...I have installed SP1.0. I have also applied Export Pack 3.0.
    The following features are working fine.
    1) Export to PDF
    2) Export to JPEG
    3) Export to Powerpoint Image.
    Export to Powerpoint Object is also working fine if the style is 'Vertical'. The issue is only in case of 'Condensed', 'Compressed' and 'Horizontal OrgChart - Condensed children' sytles. Here again, if we expand at least one position, the export is working.
    The error message that is flashed for the user is the usual one....pasted below.
    Object Variable or With Blovk Variable Not Set.
    Export To PowerPoint 
    Compatibility 
    We currently support:
    Microsoft PowerPoint 2000 / 2002
    Microsoft PowerPoint 2003
    Note: To ensure compatability, you may be prompted to install "Service Pack 6 for Visual Basic Runtime." If so, you must accept the installation and once installed it may ask for a system reboot which you may ignore. 
    ActiveX Security 
    Depending on your browser settings, you may be prompted to install 'Nakisa Office Components.cab'. This is our ActiveX component that will allow you to use our Exporting functionality.
    You may also be prompted to allow the ActiveX to run. If so, you must select 'Yes' to continue.
    Note: If you are not prompted and the export fails to occur, please verify your Microsoft Office installation and verify your browser's ActiveX settings are set to 'Enable' or 'Prompt'.
    In the log file, the following error message is displayed.
    ERROR: ChartingXMLProcessor : generateLayoutXML : Unexpected XML declaration. The XML declaration must be the first node in the document, and no white space characters are allowed to appear before it. Line 1, position 5081.
    Warm regards,
    J. Thomas

  • Gmail Options button not working in standard view for Firefox 4

    Since upgrading to Firefox 4 gmail does not work correctly in standard view. I can't select my username or options at the top right or select emails to delete or perform any actions on. I use IE and everything works fine. I tried restarting in safe mode and still same problem. I also cleared all recent history.

    A little bit more detail... I am also having this issue, but I think it's more widespread than just google. My desktop is experiencing this issue (Vista x64) but my laptop isn't (Win 7 x64). Both are running Firefox 4.
    Anyway: the problem seems to be with dynamic webpage content, javascript, html5, or something like that.
    As amc-1 mentioned, the two buttons at the top right of google pages aren't doing anything in firefox 4.
    In addition to the settings thing on google pages, in Facebook, if I type in a name into the search bar, suggestions pop up, but if I click on them, nothing happens.
    In google maps, I can get it to open the directions section, but when I click "get directions," nothing happens there either.
    I've tried starting in safe mode. Not working there either.
    '''Edit''': I can confirm that this is fixed by creating a new profile. However, I would like to avoid this if at all possible.
    Possibly relevant info from Troubleshooting Information in help menu: http://pastebin.com/uNUxsp2d

  • All the properties are not displying for the View Object

    i my one of the view Object it is only showing the properties
    Values
    Lable
    Render values
    I want to use text box (Input box )...but it is not showing in the property window
    why it is not showing the all the properties for the that view Object.
    Is it a read only view object ? if so then how to change it

    This question is confusing.
    You talk about properties, suggesting attribute properties are not showing up in the view object editor. Then you talk about a read-only view object, which suggests you talk about a running application?
    Normally a view object is updatable when it is based on an entity object and when on the entity object tab of the view object editor (the page in which you select the entity object) the updatable checkbox has been checked.
    But being updatable as such is not why attributes would not show up in a screen.
    Can you be more specific, and also tell us what JDeveloper version you are working with?
    Jan Kettenis

  • Dependencies (references) tab not working for materialized views.

    I am using SQL Developer version 1.2.0 Build 29.98. I also had this problem with version 1.1.
    I have created some materialized_views that are used by assorted packages, some of which are in other schema than the one that owns the materialized_view. When I select the specific materialized_view, then click on the 'Dependencies' tab, two displays appear. the first, 'Dependencies' is populated. The second 'References' is not. When I click on 'Refresh', nothing happens. I wrote my own query to see if there was a problem with the underlying data. The query shows me that the linkage data is there, linked to the TABLE object created to support the materialized_view object.
    SELECT
    i.owner AS input_owner,
    i.object_name AS input_name,
    i.object_id AS input_id,
    o.owner,
    o.object_name,
    o.object_id,
    o.TIMESTAMP,
    o.status
    FROM dba_objects i
    INNER JOIN
    public_dependency p
    ON (referenced_object_id = i.object_id)
    INNER JOIN
    dba_objects o
    ON (p.object_id = o.object_id)
    WHERE i.owner = :owner
    AND i.object_name = :object_name

    We finally got Office Web Apps installed and now the Most Popular is working.  Of course that means only when the documents are viewed in the Office Web App are they recorded for the Most Popular report.  We've done some testing and opening the
    file directly in the desktop application, or even editing the file directly in the desktop application are never recorded.  My one disclaimer with this is we are using Office 2010, I'm curious if Office 2013 perhaps records views and edits using the desktop
    application?
    Luckily the latest OWA patch now allows PDF's to open in the Word Office App as well, so those views are recorded.  If you have any non office or non PDF in the library, views will not be recorded for these items unfortunately.
    I can't believe how this isn't documented anywhere. 
    Nick Hurst

  • Search spec not working for Multiple Business Object in Siebel

    Hi,
    In Siebel Applicaiton Specified Search spec in Administration - BI Reports->Standard Templates-> integtion Object. the Specified Search spec is not returning particular record. It's seems returning all records. below we are using search spec as [Row Id] = [Quote.BillingaccountId].
    for testing purpose specified how code value : [Row Id]='1-wXR8'(some BillingaccountId in our application from Quote Object).
    Does anybody worked on Searchspec for MultipleBusienssObjects and is the search spec syntax is correct.
    Thanks
    -Chakri

    Hi Ravi..
    thanks for replay. with SR you provided getting no search results. If you have already can you please email me at [email protected]
    And also mention format as IO1.Field1=IO2.Field2. Need to give IO.fieldname i.e Integration Object Name .Field name or IC.Fieldname.. Can you please correct.
    Thanks
    -Chakri

  • Export to Excel is not working for List View Web Part after filtering using Query String parameters in SharePoint 2010

    Hi, 
    I am filtering SharePoint list view web part based on Query string parameter and I am doing Export to Excel by using following code.
    <a href="#" onclick="javascript:window.location='../_vti_bin/owssvr.dll?CS=109&Using=_layouts/query.iqy&List=0DC67399-BE11-48F3-ADFC-E911FB8B5845&View=54671412-3EFE-4281-835A-9EF747AE774E&CacheControl=1'"><img
    alt="Excel" src="/_layouts/images/icxlsx.gif" border="0"/>&nbsp;Export to Excel</a>
    Issue: Able to do Export to Excel when there are no filters applied on list view web part but if applied filters on web part and do export to excel , only header fields are displaying in the excel sheet.
    I don't know why owssvr.dll is behaving like that .
    Please share your ideas.
    Thanks in Advance.

    Hi,
    According to your post, my understanding is that you wanted to create hyperlink to export to excel.
    The URL to execute the export is as follows:
    {Site URL}/_vti_bin/owssvr.dll?CS=109&Using=_layouts/query.iqy&List={List GUID}&View={View GUID}&CacheControl=1
    After getting the GUID, you  need to “decode” the list GUID.
    Replace %7B with {
    Replace %2D with –
    Replace %7D with }
    More information:
    Create Link to Export Library Contents to Excel
    SharePoint - Create a link to export to Excel
    Best Regards,
    Linda Li
    Linda Li
    TechNet Community Support

  • BPM Worklist: Searching in custom views does not work for protected flexfields !

    Hello,
    Have mapped few protected attributes in my .task file. Also created the corresponding labels on target SOA server. I am able to create custom views using these protected flex fields.
    But what I have observed is keyword based search is not working for custom views using protected fiexfields.. however it works fine with public fiexfields.
    Any pointers on this? Am I missing something in the configuration?
    Thanks..

    Can anyone help me?

  • How to use SPEL for Dynamic View Objects?

    Hi Gurus,
    In Benefits Self Service particularly in the Designate Beneficiaries page, we have a requirement to set the row for Self designation as Read Only. What this means for any plan that you're eligible and that requires beneficiary designation, you are not allowed to designate yourself. Unfortunately this is an intended functionality and the only way to achieve our requirement is thru Personalization. I was able to accomplish this successfuly thru the SPEL functionality. However the view object corresponding to each plan that requires beneficiary designation is somewhat dynamic. For example, Plan A corresponds to BeneficiaryPeopleVO1, Plan B corresponds to BeneficiaryPeopleVO2, Plan C corresponds to BeneficiaryPeopleVO3, etc. The Personalization Page only allows me to use the SPEL for only one view object at a time. So if an employee is eligible for 3 plans that require beneficiary designation and my SPEL points to BeneficiaryPeopleVO1, it will only set the Read Only in Plan A. Plan B and Plan C would still allow self designation. Is there a way I could use the SPEL to work for all View Objects?
    Thanks,
    Ronaldo

    jeanluca wrote:
    I've seen things like this in scripting languages, so I was wondering if things like this are possible in java. Here is an not working example:
    Is something like this possible ?AFAIK, it is only possible in a very limited way as noted above and is nearly always not recommended and definitely not necessary. The variable name has little importance, but OTOH the object reference has great importance. Instead learn about arrays, Lists, and Maps.

  • Flash Player does not work with Standard User, but will work when browser is "Run as Administrator"

    I don't understand why this is happening, but Flash Player will not work when a Standard User is using the browser. It will only work when the browser is run as an administrator. Any way to fix this? I've tried to uninstall, and reinstall the player, and it still wouldn't work.
    The user is on Windows 7, 64-bit. Using IE 10.
    Flash not working for Standard User - YouTube

    Any update to provide at all here guys?  Again, in my situation, it's very much rights-related as a standard user doesn't even report that the flash player exists when testing it on the Adobe Flash Version Detection website (despite it showing up in Control Panel and under Add/Remove Programs).  I've already tried giving the C:\Windows\System32\Macromed and files/subfolders appropriate permissions for the standard user and still nothing.  If I either give the user in question full local admin rights or logon as the domain admin, then the Adobe Flash Version Detection website says Flash is installed and Flash works fine.
    Thoughts???

  • Filtering not working for newly added child objects in master-detail table

    Hi,
    I am using Jdeveloper 11.1.1.4 version.
    Problem scenario:
    Filtering of records is not working for newly created child objects in a master-detail scenario.
    Steps to reproduce this issue using HR Schema (using LOCATIONS and DEPARTMENTS table ) :
    1. Create Business components (EO's & VO's ) for LOCATIONS & DEPARTMENTS table)
    1. Create a .jspx page and insert a readonly master table of Locations
    2. Insert a child table (inline-edit table) of Departments and enable filtering
    4. For the child table, drag and drop CreateInsert operation as a toolbar button .
    5. Create a new child record using the toolbar button and enter data .
    6. Filtering on the newly created child record's attributes does not work.
    Please note that the same filter works for existing child records.
    Any suggestions for resolving this issue?
    Thanks,
    Vikas

    Found from Fusion Developer's Guide the following snippet about QBE functionality :
    "+When you create data controls, all data collections will automatically include a Named Criteria node with an All Queriable Attributes criteria. This is the default view criteria that includes all the searchable attributes or columns of the data collection. You cannot edit or modify this view criteria+. "
    So, the question is if the implicit view criteria cannot be edited, how else to set the query execution mode to "Both" ?
    Shouldn't ADF BC support this by default? Is this a bug?
    Note:- If you create a maste-detail table using POJO datacontrols, filter works correctly for newly created child records also .
    This seems to be an issue with ADF-BC datacontrols only.
    Thanks,
    Vikas

  • Triger extract is not  working for USERDETAILS object.

    Dear MI experts,
    I am doing custom client integration. In that we have faced a problem.
    Trigger extract is not  working for USERDETAILS object in SWCV SAP BASIS 7.10.
    1. I have assign the SWCV SAP BASIS 7.10, user define SWCV to device.
    2. I have checked the SMQR all queues(extract queues) are in register mode.
    But if I delete the users and reassign the same user, then it is sending deletes and insert to the outbound queue.
    please help to resolve the issue.
    Regards
    lakshman balangu

    Dear ananth,
    Thanks for ur replay.
    Actually as soon as the device is registered, automatically the USERDETAILS and USER_AUTHORIZATION Objects should
    go to the Outbound queue from the pending extract
    I have tried what you have suggested.
    1.I have taken device which is in initial state and I have assigned the 'user' and 'user define SWCV'.
    2.I have register the devices with my custom client. After that also SWCV SAP BASICS 7.10 not become operational and automatic extract not happend for USERDETAILS.
    my doubt is, any thing i need to send from client to make SWCV SAP BASICS 7.10 operational?
    (or) is it problem with system?
    Regards
    lakshman balanagu

  • Brushes app question: does anyone know how to upload a brushes painting as a video? "Brushes Viewer" is not working for me ;-(

    Brushes app question: does anyone know how to upload a brushes painting as a video? "Brushes Viewer" is not working for me.
    Thanks! KAR

    Hi, Dave.
    If you're using the BlackBerry browser, you can't configure anything to bypass the RIM servers.  I believe you may do so by using the Opera browser, but I haven't tried it myself so cannot comment with authority.
    I hope that clears up the issue for you. 
    - If my response has helped you, please click "Options" beside my post and mark it as solved. Clicking the "thumbs up" icon near the bottom of my response would also be appreciated.

  • My Help Viewer is not working for mac help

    My Help viewer is not working for mac help. Everytime i choose mac help the window opens then closes. But when i open another help like safari help it opens and works fine. If i switch it back to mac help the window just closes and the application quits.
    If you know how to fix please telll!

    noname212,
    Using "Search Discussions" with the term "Help Viewer" you will lead you to numerous posts which refer to Troubleshooting Help Viewer by Dr. Smoke.
    Good Luck
    ;~)

Maybe you are looking for