Strange Behavior: VO query result shown in UI different from backend

Hi Experts,
I have an issue with one of the VOs in my application. The VO uses an expert query.
The application uses ADF faces for the front end. The UI is created by dragnDrop method from ViewCriteria(Datacontrol for this VO) to the page.
I would expect the page to always show the data which I would get when I execute the query from the backend.
But the data that comes up in the UI(through the VO and queryPanel, af:table) is different from the data set if I execute the query directly from backend. (Oracle 11G Database)
The issue occurs for one set of data and not for another set of data.
I tried the following:
In VOImpl, the executeQuery method is overridden to add additional filters.
Just before super.executeQuery, captured the getQuery() result.
The query got this way, I am running from back-end(SQLPLUS/Toad) returns expected results, whereas when the Application is run, the UI table shows duplicate data for one set alone.
Please share pointers on how to debug this issue further.
Please note that this post is not about the query but I am illustrating the query here just in case its needed.
The query is something like this:
Fetch rows from maintable that belong to either the set mapping to :bindvariable1 or the set mapping to bindvariable2. This could be represented as a union between the two selects as well.
select
col1,col2,col3...
from main_table, table1, table2
where
(main_table.idcolumn =:bindvariable1
and table1.referencecolumn =:bindvariable1
and table2.referncecolumn =:bindvariable1)
or
(main_table.idcolumn =:bindvariable2
and table1.referencecolumn =:bindvariable2
and table2.referncecolumn =:bindvariable2)
and
maintable.idcolumn2=table1.idcolumn
and maintable.idcolumn3=table2.idcolumn
Thanks for your time and help.
Ganesh Iyer

Do you have a security policy associated with the table?
Oracle 8i supports virtual private database where the server can dynamically modify a query.
The query 'SELECT * FROM EMP' could be modified by the server to 'SELECT * FROM EMP WHERE DIVISION = 'AIRCRAFT' by putting a security policy on the EMP table.
You, as a user, would never know it happened.
A security policy based on some arcane rule such as the time of day could cause the problem you are describing.
The only other way I know of is if you logged in as two different users and each user has different privileges on the table.
Good luck!
null

Similar Messages

  • Query result Alternate row with different color   

    hello
    can anyone help me on a query result.
    i wish to have a :
    query result Alternate row with different color .
    ex.
    first row light grey
    second row darker grey.
    and repeats itself up to the last record/row.
    thanks

    <tr> <!------------------------------I replaced with
    <tr bgcolor="<cfif currentrow mod
    2>##D3D3D3<cfelse>##F5F5F5</cfif>">
    <td>
    #MYARRAY[x][2].CNO#
    </td>
    <td align="center">
    #MYARRAY[x][2].CDCDTt#
    </td>
    <td>
    #MYARRAY[x][2].PADESC#
    </td>
    <td align="center">
    #MYARRAY[x][2].INc#
    </td>
    <td align="center">
    #MYARRAY[x][2].Exp#
    </td>
    <cfset thirdArray = MYARRAY[x][3]>
    <cfif NOT arraylen(thirdArray)>
    <td> </td>
    <td> </td>
    <td> </td>
    <td> </td>
    <td> </td>
    <td> </td>
    <cfelse>
    <cfloop index="z" from="1" to="3">
    <cfif z GT arraylen(thirdArray)>
    <td> </td>
    <td> </td>
    <cfelse>
    <td>
    #thirdArray[z][2]# 
    </td>
    <td>
    #thirdArray[z][3]# 
    </td>
    </cfif>
    </cfloop>
    <cfif arrayLen(thirdArray) gt 3>
    <td nowrap="nowrap">
    <cfloop index="z" from="4" to="#arraylen(thirdArray)#">
    #thirdArray[z][2]# - #thirdArray[z][3]#<BR />
    </cfloop>
    </td>
    </cfif>
    </cfif>
    </tr>
    I got this error.
    Variable CURRENTROW is undefined

  • While executing the query the output is completey different from the query

    Dear friends,
    We built a query and loaded the data for that infoprovider.
    While executing the query the output is completey different from the query what we have built.
    Output has no relevance to the query.
    Kindly help the same.
    Regards,
    Sathya

    HI Satya,
    In my opinion the issue is with your front end.
    Results should be identical in RSRT, BEx Analyzer (Workbooks) and the ABAP-Web since all three frontend tools use the "ABAP Runtime layer".
    It may differ In the Portal where the new "Java Runtime layer". (Java-Web.) is used.
    This is given in OSS Note 1296576 - Different Query Behaviour: ABAP - Java.
    So i think the problem lies in your analyser. If you are using Analyzer: BI Add on 7.X (Based on 7.10) try and get support package 8.
    Hope this helps.
    Thanks,
    Rahul

  • Strange behavior in BI Publisher with long column names from BI Answers

    Hello all!
    I have created a BI Answers request with few calculated columns in form of
    case when <condition> then <value if true> else <value if false> end
    Then in BI Publisher Desktop designed a report ttemplate based on saved BI Answers request and noticed that for calculated columns their names look strange:
    CASEWHEN_<condition>THEN...ELSE..._...END__
    Some of the column names are about 100 characters long.
    After running the report from Word found that for these "long length named columns" there's no data in the output.
    Do someone else experience the same? Any workarounds?
    Regards,
    mr.maverick

    This is because the length for the formula is restricted in publisher. you have to either reduce the size of the column name in answers or change the formula. another workaround is completely pasting the formula directly in the word template instead of placing the formula inside the form field. you can add maximum of 300 characters i guess. you can edit the formula for the form field in the form field options formuals menu.

  • Unexpected query results during large data loads from BCS into BI Cube

    Gurus
    We have had an issue occur twice in the last few months but its causing our business partners a hard point.  When they send a large load of data from BCS to the real time BI Cube the queries are showing unexpected results.  We have the queries enabled to report on yellow requests and that works fine it seems the issue occurs as the system is processing the closing of the request and opening the next request.  Has anyone encountered this issue if so how did you fix it?
    Alex

    Hi Alex,
    There is not enough information to judge. BI queries in BCS may use different structure of real-time, basic, virtual cubes and multiproviders:
    http://help.sap.com/erp2005_ehp_02/helpdata/en/0d/eac080c1ce4476974c6bb75eddc8d2/frameset.htm
    In your case, most likely, you have a bad design of the reporting structures.

  • Adding custom navigation rules results in strange behavior

    Hello,
    We'd like to add navigation rules to our application. To avoid post-JHeadstart-generation-steps we created an extra faces-config-custom.xml file which contains the navigation rules. When adding this file to the web.xml and run the aplication we encounter strange behavior
    - Errors are shown in duplicate
    - 'Transaction completed' messages are not shown
    Try adding the underneath faces-config-custom.xml to a standard HR demo project and you will get the same behavior.
    (1) What is the reason of this strange behavior?
    (2) How can we add custom navigation rules, without having to do post creation steps?
    Regards Leon
    [faces-config-custom.xml]
    <?xml version="1.0" encoding="windows-1252" ?>
    <!DOCTYPE faces-config PUBLIC
    "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.1//EN"
    "http://java.sun.com/dtd/web-facesconfig_1_1.dtd">
    <faces-config xmlns="http://java.sun.com/JSF/Configuration">
    <navigation-rule>
    <from-view-id>*</from-view-id>
    <navigation-case>
    <from-outcome>BezwaarVerzoeken</from-outcome>
    <to-view-id>/pages/inboeken/BezwaarVerzoeken.jspx</to-view-id>
    </navigation-case>
    <navigation-case>
    <from-outcome>LosseOpdrachten</from-outcome>
    <to-view-id>/pages/inboeken/LosseOpdrachten.jspx</to-view-id>
    </navigation-case>
    </navigation-rule>
    </faces-config>
    [Add faces-config-custom.xml to web.xml]
    <context-param>
    <param-name>javax.faces.CONFIG_FILES</param-name>
    <param-value>/WEB-INF/faces-config-custom.xml,...

    Leon,
    When you perform a drag and drop operation, JDeveloper adds the following lines to the faces-config.xml:
    <lifecycle>
    <phase-listener>
    Oracle.adf.controller.faces.lifecycle.ADFPhaselistener
    </phase-listener>
    </lifecycle>
    However, JHeadstart uses its own subclass of ADFPhaselistener, and defines the lifecycle element in JhsCommon-beans.xml. Due to a bug in ADF, ADF does not look for the lifecycle element in other files than faces-config, and adds its own element in faces-config.xml If you remove these lines, everything works fine again.
    To prevent this from happening again, you can move the following entry from JhsCommon-beans.xml to faces-config.xml:
    <lifecycle> <phase-listener>oracle.jheadstart.controller.jsf.lifecycle.JhsADFPhaseListener</phase-listener>
    </lifecycle>
    And then make a custom template for JhsCommon-beans.vm where you remove this entry.
    Steven Davelaar,
    JHeadstart team.

  • Report gives strange behavior

    Hi Gurus,
    I am facing strange problem with my oracle report 10GR2 release. Problem is, when user runs a report in early part of the morning from application server, the report runs normally and it generates the PDF file with proper data. But when the same user runs the same report in later part of the day with the same parameters as he gave in the morning, the report doesn't shows any result on generated PDF file.
    At the same time if we run the report query in the data base from sqlplus, it gives the proper output. I have checked the server log and the report trace file also but I didn't found any special and abnormal thing in the log file. I have asked the application DBA also to look into this problem but they are not able to identify the problem.
    The problem occurs only in production database in acceptance and test I am not able to simulate the condition.
    Do any one knows the strange behavior of the report on the application server? If more information is required then please ask.
    Thanks in advance.

    When you say that the PDF is not generated what exactly happens
    a. The report is not generated at all and a blank page is shown up even after a prolonged period of time
    or
    b. Some error is thrown (REP errors)
    Apart from this, what is the value set of maxConnect attribute in reports server configuration file located in <ORACLE_HOME>\reports\conf directory.
    Edited by: Anand on Nov 20, 2010 9:43 AM

  • Strange Behavior of af:inputListOfValues

    Hi,
    I've tried the demo for How-to build Oracle Forms style List-of-Values in ADF Faces RC at [http://www.oracle.com/technology/products/jdev/tips/fnimphius/lov/listOfValues.html|http://www.oracle.com/technology/products/jdev/tips/fnimphius/lov/listOfValues.html] .
    As it's shown in the example if you enter SA_ the JobId field in the LOV is filled with SA_%.
    Yes this happens only the first time you enter a value. After the first time, the result is a blank field.
    Does anybody know how to solve this strange behavior?
    I'm using JDeveloper 11g build 5188.
    Regards,
    JavaDeVeLoper

    Hi,
    I see this too. However, the source code works and it seems to be a refresh issue with the applied criteria
    Frank

  • Strange behavior of Grapher 2.0

    Hello everyone,
    I have a problem with vector fields in Grapher.
    My Grapher 2.0 (running on Mac OS X 10.5.2 ) shows the following strange behavior:
    When I create a new 2D-vector field in any document, it is shown correctly. All vector arrows point in the direction I expect.
    When I now save the document and open it again, first the vector field is shown correctly, but one or two seconds later the field collapses and all the vectors are aligned parallel to the x- axis. After reentering the formula describing the field, I get the correct result again.
    In the Grapher examples are two items including vector fields. One of them has the same behavior like my own documents, the other has not, but it‘s working well.
    I have already deleted the preferences (com.apple.grapher.plist) , but without any success. The program behavior is unchanged.
    Does anyone know the cause of this problem, and what I can do to avoid it?
    regards woopecker

    This is bug nr. 4/22 in my personal Grapher's bugs list. Exists in 2D & 3D.
    To restaure a saved .gcx vector field, make a minor change in its equation (e.g. cancel one letter), Return touch, repair the equation, Return touch, your vector field becomes OK !

  • Strange behavior of Content area

    Hello everybody,
    I'm working with Portal 3.0.8. I've installed czech language on it.
    What did I do is:
    1) I made new look for my navigation bar (new image and basic items). And it worked fine. I worked in English!
    2) Change language to Czech.
    3) Show my content area and there were old items on navigation bar. But style was new. If I navigate to any sub-folder, the look is OK. In the root folder I can't change anything. I can add new items only, though it is possible to see them only when I work in English.
    Does anybody know the reason of this strange behavior and what I should do? Thanks for your help!
    Petra :-)
    P.S.: You can use this email address: [email protected]

    Sorry for copy paste problem. b1 should be replaced with y1 and c1 with z1.
    Here is the correct code.
    create table xmltab of XMLType XMLTYPE store as binary xml;
    Table created.
    insert into xmltab values('<x><y>y1</y><z>z1</z></x>');
    1 row created.
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' and
    extractValue(x.object_value,'/x/z')='z1' ;
    OBJECT_VALUE
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    The following query doesn't return any row!!
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' and
    extractValue(x.object_value,'/x/z')='z1' for update;
    no rows selected
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' for update;
    OBJECT_VALUE
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/z')='z1' for update;
    OBJECT_VALUE
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    The following one returns correct result !!
    select x.object_value, extractValue(x.object_value,'/x/y'), extractValue(x.object_value,'/x/z')
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' and
    extractValue(x.object_value,'/x/z')='z1' ;
    OBJECT_VALUE
    EXTRACTVALUE(X.OBJECT_VALUE,'/x/y')
    EXTRACTVALUE(X.OBJECT_VALUE,'/x/z')
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    y1
    z1
    I get expected result for all the cases if the table is created in the following way
    create table xmltab of XMLType;
    Can anyone tell me why does select for update behaves in this strange way for binary xml table?

  • Strange behavior of explain plan

    Hello i don't know if this is the correct category for posting my issue.
    I ma facing a strange behavior of the explain plan. What i mean!
    I have a query which runs very fast and it is well optimized. the explain plan shows very good results in cost and execution time.
    when i am running the query for a second or a third time is appearing a different explain plan with not such a good cost and execution time.
    Could you please guide me what it might be wrong???
    thanks a lot

    HI i found the correct category
    thanks

  • Strange behavior of select for update

    I observed a strange behavior of "select .. for update" statement in binary xml table. Here is the piece of code:
    create table xmltab of XMLType XMLTYPE store as binary xml;
    Table created.
    insert into xmltab values('<x><y>y1</y><z>z1</z></x>');
    1 row created.
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' and
    extractValue(x.object_value,'/x/z')='z1' ;
    OBJECT_VALUE
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    The following query doesn't return any row!!
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' and
    extractValue(x.object_value,'/x/z')='z1' for update;
    no rows selected
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='b1' for update;
    OBJECT_VALUE
    <x>
      <y>b1</y>
      <z>z1</z>
    </x>
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/z')='z1' for update;
    OBJECT_VALUE
    <x>
      <y>b1</y>
      <z>z1</z>
    </x>
    The following one returns correct result !!
    select x.object_value, extractValue(x.object_value,'/x/y'), extractValue(x.object_value,'/x/z')
    from xmltab x
    where extractValue(x.object_value,'/x/y')='b1' and
    extractValue(x.object_value,'/x/z')='z1' ;
    OBJECT_VALUE
    EXTRACTVALUE(X.OBJECT_VALUE,'/x/y')
    EXTRACTVALUE(X.OBJECT_VALUE,'/x/z')
    <x>
      <y>b1</y>
      <z>z1</z>
    </x>
    b1
    c1
    I get expected result for all the cases if the table is created in the following way
    create table xmltab of XMLType;
    Can anyone tell me why does select for update behaves in this strange way for binary xml table?

    Sorry for copy paste problem. b1 should be replaced with y1 and c1 with z1.
    Here is the correct code.
    create table xmltab of XMLType XMLTYPE store as binary xml;
    Table created.
    insert into xmltab values('<x><y>y1</y><z>z1</z></x>');
    1 row created.
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' and
    extractValue(x.object_value,'/x/z')='z1' ;
    OBJECT_VALUE
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    The following query doesn't return any row!!
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' and
    extractValue(x.object_value,'/x/z')='z1' for update;
    no rows selected
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' for update;
    OBJECT_VALUE
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    select x.object_value
    from xmltab x
    where extractValue(x.object_value,'/x/z')='z1' for update;
    OBJECT_VALUE
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    The following one returns correct result !!
    select x.object_value, extractValue(x.object_value,'/x/y'), extractValue(x.object_value,'/x/z')
    from xmltab x
    where extractValue(x.object_value,'/x/y')='y1' and
    extractValue(x.object_value,'/x/z')='z1' ;
    OBJECT_VALUE
    EXTRACTVALUE(X.OBJECT_VALUE,'/x/y')
    EXTRACTVALUE(X.OBJECT_VALUE,'/x/z')
    <x>
      <y>y1</y>
      <z>z1</z>
    </x>
    y1
    z1
    I get expected result for all the cases if the table is created in the following way
    create table xmltab of XMLType;
    Can anyone tell me why does select for update behaves in this strange way for binary xml table?

  • Strange behavior when compiled with Visual C++ 2005 Express Edition

    I wrote a program for Berkeley DBXML 2.2.13 on Windows XP that executes a query 5 times and prints out the runtime for each execution. When I run the program using the Debug version of the libraries the queries take about the same time to execute for all 5 executions. When I run the program using the Release version of the libraries the execution time of the queries degrades significantly between each execution. One query takes 2 seconds to execute the first time and 20 to execute the last. I have tried recompiling the Release version without optimization and the strange behavior persists. I have run both the Release and Debug versions several times and gotten the same results, so I doubt it is a program running in the background that is slowing the execution.
    This behavior does not happen when I compile the program under Unbuntu using g++, so I assume it is caused by some flag set in the Release version of Visual C++. Has anyone else experienced this behavior and know what flags I should or should not set?
    Thanks for your time.
    Lauren

    Hi Lauren,
    We've had users experience this before, and it seems to be a bug/"feature" of the default windows heap allocator. Please see this post for a bit more explanation and a solution:
    Re: Performance Issue caused by XmlResults.next().asString();
    John

  • Service Offering, Query Results question.

    Hi,
    I got a question about the Service Offering, Query Results criteria page.
    As shown in the Picture below i have a Query based on the Active Directory User Class.
    The background is that i got alot of accounts more than 2000. The token "String" is used to narrow down the search. I also got some accounts that i dont want to show in the portal for the end users (The ones who
    ends with "Z" in the pager).
    Generally i would say that the "OR" would be "AND" (due to it is an logical operator, i want both conditions to be true) between the two UserPager properties, but i havent found any way to change that. I suspect that it is not possible
    to change "OR" to "AND" when making criterias against the same values more than 1 time.
    The Query below will return all accounts under that Distinguished name, even if i wrote something in the String prompt.  Removing the Criteria Pager ends on "Z" makes the String prompt work. But it will not exclude those objects ending with
    Z. Is this a normal behavior or am i thinking/doing sometime wrong?

    This is how all criterias work in service manager. If the same property is included more than once it puts an OR inbetween. You would have to export the MP that contains the query result and edit the criteria manually to AND.
    Cheers,
    Anders Spælling
    Senior Consultant
    Blog:  
    Twitter:   LinkedIn:
    Please remember to 'Propose as answer' if you find a reply helpful

  • How can I architect my data layer to yield query result pages to the application as SQL Server prepares them?

    I tried to make the question as explicit as possible.
    Refer to Sql Server Management Studio's Results view.  Depending upon the structure of the execution plan, the Results pane may begin displaying results while the query is still executing.  Can someone point me in a direction for architecting a
    data layer (I am tech and framework agnostic for this task. Any solution will suffice) that will begin receiving pages of the set before SQL Server has completed the entire query?
    The call from the data layer to SQL Server will obviously have to be asynchronous, but is there any additional ceremony that I need to be aware of when issuing OPTION (FAST x) to the query optimizer?

    Thanks for the reply. (I actually meant to put this in the SQL Data Access forum, not the T-SQL forum)
    "Generally the last step is ORDER BY in a
    query, so nothing can start before that executes."
    I would imagine you cannot ORDER BY and yield results as they are fetched because of the execution plan that would be generated.  For the purposes of this post, please assume that sorting will be done purely client side
    "Can you post your query?"
     For purposes of discussion, let's assume that the query is
    select *
    from information_schema.columns
    and also assume that you have "lots" of columns to display.
    This was an exploratory question to see what would be necessary to replicate the behavior of Management Studio's Query Result view in a custom application. 
    I would imagine that there's going to be a lot of analysis of the execution plans that get generated in order for the OPTION (FAST x) optimizer hint to do any good, but apart from general tuning concerns that would allow SQL SERVER to yield a page of data
    "fast", I was wondering if there was anything else required of the calling client to force it to yield return its first page.
    After thinking about this (and phrasing it the way I did in the last sentence) perhaps this is the incorrect forum for this question.  I imagine that my concerns are better addressed in forums dedicated to the technology of the calling client (which
    would be a .NET assembly)
    Be that as it may, if there is any ceremony that SQL Server imposes on clients in order to yield return, I would expect that my question would be in the scope of SQL Server discussions (even though I intended this to be in a different SQL Server forum)

Maybe you are looking for