Strange problem in a query

Hello all,
I'm facing a non-sense problem in a query, I hope you could help me.
I have defined a structure in the rows of my query. Inside the structure, I have defined several selections and formulas. Selections are basically account intervals and formulas are additions of some selections.
Some formulas are correct, adding amounts properly but others aren't. Instead of the addition, a * appears.
Even if I copy and paste now one correct formula and show both in the execution, the first one appears correctly and the second one shows a *. How is it possible?
I need some suggestions about what to do. Thank you in advance. I will assign points.

Thank you for your answers!
I have followed Mustafa advice in SPRO and now I don't see any *.
But there is a thing I can't understand now. As said before, I created a formula based on selections and it shows correctly the amount and the unit.
Then I have copied the formula and pasted after the first one. Both of them show the same value but only the first one is showing the amount.
What do you think? How is it possible if both have been defined identically?

Similar Messages

  • Strange problem with SQL query in toad.

    Guys,
    My colleague is up with a strange problem with an SQL query that if it is run in toad encounters the "ORA-03113: end-of-file on communication channel" problem,but if run in SQL plus executes just fine.
    Do anyone have thoughts about this strange error in toad?
    Thanks!!!!
    Regards,
    Bhagat

    Not sure what version of TOAD you have but it may have shipped with SQLMonitor which montiors SQL sent from Windows apps . Navigation should be similar to;
    Start~Programs~Quest Software~TOAD for Oracle~Tools~SQLMonitor
    or
    C:\Program Files\Quest Software\Toad for Oracle\SQLMonitor.exe
    To use it, start TOAD and connect, start SQLMonitor and click the checkbox for TOAD.exe, then execute the query. SQLMonitor will show you the actual query that TOAD sent to the client. It may be exactly what you sent or it may contain some extras.

  • Very strange problem: Error for Overall result  due to a custom infocube?

    Hi,
    I have a strange problem:
    In my query the sumgt function doesn't work for the calculation of a percentage (es: 'KFA' %A SUMGT 'KFA').
    The coloumn of the formula is full of red X.
    Using Nodiv() the percentage are all zeroes.
    I use a custom infocube for this query that is a copy of an infocube standard with some other infoobject custom. In the infocube standard the formula work and the sumgt is correct!.
    It is possible that there are some parameter to be set at infocube level that make the SUMGT wrong?
    I'm sorry for my poor english,
    Alberto
    Message was edited by:
            Alberto Maggini

    Alberto,
                   Your problem might be a UNIT problem. If you are using key figures in a formula with different units, you will have the "red X" outcome.
                   Try using the NODIM() function in each formula element.
    Regards,
    L. Felipe

  • Strange problem while execution of query....

    Hi Friends
    I am facing a strange problem while executing the query.
    I have one query ,its old one ,till yesterday everday it was working fine ,
    But today i am trying to execute that query ,execution process takes very long time ,finally no response from bw server.
    its an important report in our company
    I checked query , Every thing is ok ,bze i haven't made any changes
    So i need some suggetions  .like where can i check and what can i do?
    ASAP ....  So Please ...its very urgent....
    EVERY THING AND ANY THING WILL BE REWARED
    Thanks in advance
    RK

    Hi
    Stefan
    Thank you for your valuable suggestion
    the problem is solved
    Already i  assigned  points.
    Thnaks & Regards
    RK

  • Strange problem... Query runs faster, but report runs slow...

    Hi Gurus,
    We are using Report 10g on 10g Application server and solaris. we created a report on a table which has 10,000 rows. The report has 25 columns. when we run this query in Toad it took 12 sec for fetching all these 10,000 rows
    But when we run the report with Destype = 'FILE' and Desformat = 'DELIMITEDDDATA', it is taking 5 to 8 minutes
    to open in excel ( we concatenated mimetype=vnd-msexcel at the end of the url if the Destype=FILE). We removed the layout in the report as it is taking 10 to 15 mins to run to Screen with Desformat=HTML/PDF(formating pages taking more time). We are wondering why DELIMITEDDATA format is taking long time as it runs only query.
    Does RWSERVLET take more time of writing the data to the Physical file in the cache dir? Our cache size is 1 GB. we have 2 report servers clustered. Tracing is off.
    Please advise me if there are any report server settings to boost the performance.
    Thanks alot,
    Ram.

    Duplicate of Strange problem... Query runs faster, but report runs slow... in the Reports forum.
    [Thread closed]

  • Strange Problem in dynamically list population with record group

    Hello Room,
    I am dynamically populating a single list with 2 record groups. I am having a strange problem. All the code are written in 2 seperate buttons. The code of every button is given below.
    Button 1 code:-
    DECLARE
    rg_reports RECORDGROUP;
    rg_name VARCHAR2(40) := 'REPORTS';
    vTemp NUMBER;
    BEGIN
    -- Pls make sure Group doesn't already exist
    rg_reports := FIND_GROUP(rg_name);
    -- If it doesn't exist then create it and add ur query to it
    IF Id_Null (rg_reports) THEN
    rg_reports:=CREATE_GROUP_FROM_QUERY(rg_name , 'SELECT companyname,to_char(co) from companymaster order by companyname');
    end if;
    --Populate the Record Group
    vTemp:=POPULATE_GROUP(rg_reports);
    POPULATE_LIST('REPORTS.EXAMPLELIST', rg_name);
    Delete_Group( rg_reports );
    END;
    Button 2 Code:-
    DECLARE
    rg_reports RECORDGROUP;
    rg_name VARCHAR2(40) := 'REPORTS';
    vTemp NUMBER;
    BEGIN
    -- Pls make sure Group doesn't already exist
    rg_reports := FIND_GROUP(rg_name);
    -- If it doesn't exist then create it and add ur query to it
    IF Id_Null (rg_reports) THEN
    rg_reports:=CREATE_GROUP_FROM_QUERY(rg_name , 'SELECT accountname,to_char(co) from accountmaster order by accountname');
    end if;
    --Populate the Record Group
    vTemp:=POPULATE_GROUP(rg_reports);
    POPULATE_LIST('REPORTS.EXAMPLELIST', rg_name);
    Delete_Group( rg_reports );
    END;
    The code is same here only the sql is different in these 2 buttons. Now the problem point.
    when i press button 1, I get the list populated ok. when i try to click on the list item and keep the button pressed the list gets scrolled properly.
    when i press button 2 after that i get account names well populated in the same list item as well, but this time, when i keep the button pressed the list does not scroll below as in button 1. It does not even allow to select different item from the list of button 2 code.
    I tried to clear cache, cookies, exit browser everything and try to run the button 2 first, but still the problem in button 2 code.
    Following are my system details.
    windows 7 professional edition.
    Oracle database 11g on windows 7
    Oracle forms 10g patchset 10.1.2.0.2 on windows 7
    Browser Netscape Navigator with oracle jinitiator 1.3.1.22
    But this form is run by a client side html file where oracle forms 10g is not installed on windows xp. html file is just referring server url to run the module. The file is run on Netscape navigator browser with oracle jinitiator 1.3.1.22
    My question is that is this a bug ? if button 1 gets the list item scrolled, why is the problem with button 2 even though i press it first. Here I am deleting the record group also. after the code is over. Initially I thought this may be the character length problem so I took the maximum character length for that list item as given by the 2 columns in database.
    Why is the list scrolling not happening in button 2 but in button 1 with same codes on both ?
    Anybody please help me.

    The problem is the second query. I would guess that the TO_CHAR(co) is not unique for each account, but is the same for the accounts. And as the second item in the select-list is the listitems values, all your listitem-entries have the same value. therefore, of you select any entry, the list will always go the the first entry again.
    Adjust your query.

  • Problem with spatial query

    Sorry if this is not the right place but I am a GIS student facing trouble with my thesis' programming. I have completed the Ajax user interface with google API. My trouble is in running queries on Spatial Oracle 11g.
    I am using the Oracle SQL Developer together with the georaptor plugin
    (http://georaptor.sourceforge.net/install.xml) just to have some visualisation while evaluating the queries (without the need to execute the bulkier user web interface).
    I will transcode the queries in the interface later on.
    A simple table I have has the following DDL:
    =====================================================
    CREATE TABLE "HR"."RE_POINTS_SDO"
    (     "ID" NUMBER(38,0),
         "NAME" VARCHAR2(20 BYTE),
         "LAT" NUMBER,
         "LNG" NUMBER,
         "DATA" VARCHAR2(40 BYTE),
         "SHAPE" "MDSYS"."SDO_GEOMETRY"
    ) PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "USERS" ;
    CREATE INDEX "HR"."RE_POINTS_SDO_GI" ON "HR"."RE_POINTS_SDO" ("SHAPE")
    INDEXTYPE IS "MDSYS"."SPATIAL_INDEX" ;
    CREATE UNIQUE INDEX "HR"."SYS_IL0000072032C00012$$" ON "HR"."RE_POINTS_SDO" (
    PCTFREE 10 INITRANS 2 MAXTRANS 255
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "USERS"
    PARALLEL (DEGREE 0 INSTANCES 0) ;
    CREATE UNIQUE INDEX "HR"."SYS_IL0000072032C00013$$" ON "HR"."RE_POINTS_SDO" (
    PCTFREE 10 INITRANS 2 MAXTRANS 255
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "USERS"
    PARALLEL (DEGREE 0 INSTANCES 0) ;
    =====================================================
    I am having a rather strange problem (sorry but error messages were in greek
    and I tried to translate them in english):
    =====================================================
    Error starting at line 1 in command:
    SELECT ID,NAME,LAT,LNG,DATA
    FROM RE_POINTS_SDO
    WHERE SDO_NN(shape,MDSYS.SDO_GEOMETRY(2001,null,MDSYS.SDO_POINT_TYPE(0,0,null),null,null))='TRUE'
    AND ROWNUM <=2
    Error report:
    SQL Error: ORA-29903: error while evaluating routine ODCIIndexFetch()
    ORA-13234: failure to access index table of the R-tree []
    ORA-13234: failure to access index table of the R-tree [MDRT Table]
    ORA-29400: error of data add-on (cartridge)
    ORA-01410: unacceptable ROWID
    29903. 00000 - "error in executing ODCIIndexFetch() routine"
    *Cause:    The execution of ODCIIndexFetch routine caused an error.
    *Action:   Examine the error messages produced by the indextype code and
    take appropriate action.
    ===============================
    I dropped the Rtree index and created from scratch (the table had the rows):
    ===============================
    drop index RE_POINTS_SDO_GI force;
    CREATE INDEX succeeded;
    ===============================
    But no change???? I am receiving the same errors:
    ===============================
    Error starting at line 1 in command:
    SELECT ID,NAME,LAT,LNG,DATA
    FROM RE_POINTS_SDO
    WHERE SDO_NN(shape,MDSYS.SDO_GEOMETRY(2001,null,MDSYS.SDO_POINT_TYPE(0,0,null),null,null))='TRUE'
    AND ROWNUM <=2
    Error report:
    SQL Error: ORA-29903: error while evaluating routine ODCIIndexFetch()
    ORA-13234: failure to access index table of the R-tree []
    ORA-13234: failure to access index table of the R-tree [MDRT Table]
    ORA-29400: error of data add-on (cartridge)
    ORA-01410: unacceptable ROWID
    29903. 00000 - "error in executing ODCIIndexFetch() routine"
    *Cause:    The execution of ODCIIndexFetch routine caused an error.
    *Action:   Examine the error messages produced by the indextype code and
    take appropriate action.
    ===============================
    Please help me (I really do not know where to look at).
    Regards from sunny springtime Athens, Greece
    Mike

    Here's some other things you can try..
    I create my indexes differently for more control.
    First put an entry in the user_sdo_geom_metadata table as the HR users.
    INSERT INTO USER_SDO_GEOM_METADATA
    VALUES
    'RE_POINTS_SDO',
    'SHAPE',
    MDSYS.SDO_DIM_ARRAY( MDSYS.SDO_DIM_ELEMENT('X', -180, 180, 0.0005 ),
    MDSYS.SDO_DIM_ELEMENT('Y', -90.0, 90.0, 0.0005 ) ),
    NULL
    Next create the index.
    DROP INDEX hr.re_points_sdo_gi FORCE;
    CREATE INDEX hr.re_points_sdo_gi
    ON hr.re_points_sdo (shape)
    INDEXTYPE IS MDSYS.SPATIAL_INDEX
    PARAMETERS ('sdo_rtr_pctfree=0 LAYER_GTYPE=COLLECTION TABLESPACE=ts_name');
    The COLLECTION type is for shapes, POINT would be for coordinates.
    Next analyze the table
    exec DBMS_STATS.GATHER_TABLE_STATS(OWNNAME => 'HR', TABNAME => 'RE_POINTS_SDO', CASCADE => TRUE);
    The query is asking to find the nearest object to the 0/0 coordinates. SDO_NN doesn't doesn't return the objects in closest order so you need to get the distance and then sort by distance.
    Change the query to this, it will return the 5 closest objects.
    SELECT ID,NAME,LAT,LNG,DATA,sdo_nn_distance(1) dist_in_miles
    FROM RE_POINTS_SDO
    WHERE SDO_NN(shape,MDSYS.SDO_GEOMETRY(2001,null,MDSYS.SDO_POINT_TYPE(0,0,null),null,null),'sdo_num_res=5 unit=mile',1)='TRUE'
    ORDER BY dist_in_miles;

  • Problem in accessing query

    Hi Experts,
    I am facing a strange problem when working with BI 7.0, can you please help me out.
    One user is facing some authorization problem while executing queries, he is using query through BEX.
    In order to analyse when i copy his user id and when i go to BEX I am not able to find those queries which original user is able to see.
    Is there any specific reason for this .
    Regards,
    Rakesh.T

    Hi Rakesh,
    We have an authorization object S_RS_COMP1 which ll provide access to queries based on the owner of the query. In that if the owner field is set to $USER the user can see only the queries created by him.
    When u copy the user all the authorizations will be transferred and now the second user ll be able to see only queries created by him and cannot see the queries built by First user.
    Check if any of the roles assigned to user use this particular authorization object and check the owner field value.
    This could be one reason. If this is not the case, we will check for any other option.
    Regards,
    Jaya.

  • Problem in Bex Query

    Hi Team,
    I am facing a strange problem.
    Some attributes are marked has navigational attribute in the Multiprovider level.
    When I am dragging the same Multiprovider in the Bex to create a query on that, those navigational attributes are missing in the Global definition of that multiprovider in the Query designer.
    Have anyone faced such an issue?
    Kindly help me...
    Regards,
    Debjani...

    HI Vikash,
    We have checked  both the Multiprovider and the cube and also the infoobject level.
    But still I am facing this issue..
    Regards,
    Debjani...

  • Display problem in BEx Query

    Hi All,
    i am having a strange problem when i execute a query in the BEx.
    i am having a Master data infoobject C_PARTNR2  and it is having a compounding Char. C_ATTRIB. 
    Also it has some attributes like 0STREET60 and  C_LINKO and several other characteristics.
    the problem is - when i execute the Query it shows the two attributes ( 0STREET60 and  C_LINKO  )  with ' # ' values.  
    Whereas the data does exist in the P and S table of C_PARTNR2 infoobject. All other attributes are shown properly. but the above two attributes are shown with the ' # ' values.
    Any idea if anybody has come across such a kind of problem ?.
    Thanks in advance.
    regards,
    Lax

    Hello Nagesh,
    Thanks for the reply.
    i am having all the data in all the tables.
    the data is not missing in the tables.
    when the query is executed only those two attributes show the values as ' # '.
    rest of the attributes rare shown properly.
    thanks in advance.
    regards,
    Lax

  • Strange problem with CachedRowSet

    Hi, I got I an strange problem, I got two CachedRowSet in two different classes, it works without problem, but now I need to create more classes that will receive a RowSet, but the problem is that it don't execute, I got a NullPointerException, but when I get this code and put it in the class that works the Cached is executed and the data is displayed right.
    I don't know what's wrong cause the classes are equal, the only difference is the query.
    I tried renaming the beans, but it still doesn't work.
    Help me, please.
    Thanks.

    Suggest to check the server.log for the stack trace of the Null pointer exception.
    If this doesn't help find the problem then try debugging the application by setting a breakpoint where the Null pointer occurs and check the local variables and/or set some watches.
    If still no avail, you can post the Null pointer stack trace here
    John

  • Strange problem with prompts

    Hi,
    I'm having a strange problem occuring in a prompt. The design is this: I have a "search" dashboard page that let's a user search for specific projects (project is a dimension) using a wide variety of multi-select boxes, dropdowns, etc. Once a user chooses these and hits "go", an answers query is run which shows Project IDs and other fields that relate to the prompts chosen.
    On the answers query, the "Project ID" column is set to navigate to a 2nd page. On this second page, I have a dropdown prompt for project ID plus time periods. The time periods dropdown is constrained on the project ID (but note that the project ID prompt is NOT constrained). After the time period is selected and user hits GO on the 2nd page, a BI Publisher result is run (using presentation variables that are set on the 2nd page prompts). Note that I need to have a prompt on the 2nd page in order to allow presentation variables to be set (these set the parameters used by BIP to the selected prompt values)
    This works most of the time. But for some reason, when I get to the 2nd page, there are a few projects that, when I go to pick a time period for, the PROJECT_ID dropdown gets reset back to the first available project ID. This happens even before I hit the "go" button. It's kinda like the project ID is set to "constrainted" - but it isn't. i.e. when the 2nd page comes up, the project ID dropdown will show the project ID that I clicked on in the "search" page. But then if I go to pick the fiscal month using the other field in the prompt, my Project ID gets reset from the one they chose, to the very first project ID available.
    I'm unable to figure out why this is occurring, and why it's intermittent. Some project IDs consistenly have this problem, others do not.
    Any ideas?
    Thanks,
    Scott

    Hi
    i have five prompts together out of which two are year prompts and others are country ->Region->city and if i am now wrong and as per sql query if we are selecting the constrain option for region and city then in sql query it will take year prompts value in where clause as well... and as those two year prompts has different value
    If year has same value then there is no problem as here year has two different values
    the sql query which is getting generated is like this .... the problem is the way year is taking values in where clause
    select region from region_table, time_dim where region_table.time_id = time_dim.time_id and year ='2008' and year='2009'Any suggestion would be appreciated
    thanks & regards
    Edited by: user12035784 on 13-Aug-2010 03:45
    Edited by: user12035784 on 13-Aug-2010 03:58

  • Strange problem when opening word doc situated in WLS virtual dir

    Hi all,
    we have a strange problem when opening word doc
    situated in C:\Oracle\Middleware\as_1\forms\webutil
    we put some word docs there and tried to open from forms using for example web.show_document('http://wp0606:9001/forms/webutil/mug00103.doc', '_blank');
    no problem using FF, however in IE8 the word doc is shown in its binary format, this also happens when we try to open the doc in IE8
    however when we google and search for instance for a test.doc and then click on this url a file save dialog is shown
    that's why we believe that this might be due to a configuration issue of WLS
    any help would be greatly appreciated
    Kr
    Martin

    I think you have 2 ways to go here. Figure out what html is from wherever weblogic gets it, meaning you have to delve into the docs, snoop
    around in directories and find what it must be sending (This is going to be unavoidable if you are going to change what weblogic is doing.
    Sooner or later you have to try to figure out where it gets this stuff from)
    or
    you can experimentally snoop on your url with a tool like wget or curl. These are fundamental web tools.
    The latter is always a useful thing to be able to do. (you need to formulate a query to get the content-type).
    Whoever managed to get weblogic to serve any files in the first place probably can figure this out.

  • Strange problem with ORA-12154 from only one client

    Hi all,
    I have a strange problem.
    I have three 11.2.0.1 databases on three different hosts.
    For simplicity lets say:
    Host1: database ovm1a
    Host2: database ovm7a
    Host3: database ovm8a
    I have a database schema in all three databases named EHJ. In all three databases, there are fixed user
    database links to the other databases. So EHJ in ovm1a has two links, one to ovm7a and one to ovm8a. The EHJ schema in ovm7a has two fixed user links to the EHJ schema in the ovm1a and ovm8a databases. And the same is true for the EHJ schema in the third database, ovm8a.
    If I log into the EHJ schema for each of the three databases, I can successfully select over the database links. I've been using the SQL statement: select count(*) from user_users@dblink_name;
    For each of the two links in each of the three databases, the query returns 1 so I know the database links are working properly and I have my networking setup properly.
    Now, here is the weirdness.
    I have an Oracle Application Server where our Oracle Forms and Reports run. The Oracle client on this install is 10.1.0.5. I've got a tnsnames.ora file setup on this Oracle App server to connect to all three databases ovm1a, ovm7a and ovm8a. I can successfully use the 10.2.0.5 client SQL*PLUS to connect to the EHJ schema in the ovms1, ovms7 and ovms8 databases.
    However, (and only when) connected to the ovm1a database from this client, attempts to select over the link throw the famous error: ORA-12154: TNS:could not resolve the connect identifier specified
    This error happens with both links in the ovm1a database when connected via this one client.
    BUT, if I connect using the same 10.1.0.5 client to the EHJ schema in the ovm7a or ovm8a databases, the database links in those two databases are working just fine.
    I'm pulling my hair out trying to figure this out.
    I've tried using SQL*PLUS from my desktop machine (10g R2 client) connecting to the EHJ schema on all three databases and the db links all work fine.
    Any help in trying to troubleshoot this would be greatly appreciated.
    Cheers

    JSebastian wrote:
    I have an Oracle Application Server where our Oracle Forms and Reports run. The Oracle client on this install is 10.1.0.5. I've got a tnsnames.ora file setup on this Oracle App server to connect to all three databases ovm1a, ovm7a and ovm8a.But the client (and tnsnames.ora) in question here is actually one (each) of the three databases, right? I.e. error is thrown by the db server, acting as client (db link side).
    >
    However, (and only when) connected to the ovm1a database from this client, attempts to select over the link throw the famous error: ORA-12154: TNS:could not resolve the connect identifier specified Connected how, as opposed to when you "successfully select..."?
    This error happens with both links in the ovm1a database when connected via this one client.Does Oracle config files on ovma1 host differ from the other two db hosts?
    Does
    SQL> select property_name,property_value from database_properties
      2  where property_name in ('GLOBAL_DB_NAME','NLS_RDBMS_VERSION');
    SQL> select owner,db_link,host from dba_db_links;return as expected on all three db's?
    I've tried using SQL*PLUS from my desktop machine (10g R2 client) connecting to the EHJ schema on all three databases and the db links all work fine.Make sure you are connecting to correct databases. (Simply, three tns aliases could all be pointing to the same database.)
    Edited by: orafad on May 25, 2011 11:24 PM

  • Strange problem when joining two tables

    Hi,
    I have recently encountered a strange problem on an Oracle 11gR2 database which is optimized for Datawarehouse usage.
    I am using two tables that have a relationship enforced by two fields of type NUMBER(10).
    The problem is that when I am joining these two tables very often I get strange results and when I re-execute the query I get a different result. I saw in the explain plan that the Hash Join is used for joining these two tables.
    select count(*)
    from recharge_history rh, recharge_history_balance rhb
    where rh.recharge_id = rhb.recharge_id
    and rh.recharge_id2 = rhb.recharge_id2
    and trunc(rh.recharge_date_time) between '30-Dec-2012' and '31-Dec-2012'
    If I explicitly set the Join method to some other type through SQL Hints, or if I use to_number function when joining (even though the two fields used for join in both tables are of NUMBER(10) type), I get the correct result, like for example below:
    select /*+ USE_MERGE (rh rhb) */
    count(*)
    from recharge_history rh, recharge_history_balance rhb
    where rh.recharge_id = rhb.recharge_id
    and rh.recharge_id2 = rhb.recharge_id2
    and trunc(rh.recharge_date_time) between '30-Dec-2012' and '31-Dec-2012'
    select
    count(*)
    from recharge_history rh, recharge_history_balance rhb
    where to_number(rh.recharge_id) = t_number(rhb.recharge_id)
    and to_number(rh.recharge_id2) = (to_number)rhb.recharge_id2)
    and trunc(rh.recharge_date_time) between '30-Dec-2012' and '31-Dec-2012'
    Thank you for your time.
    Edrin

    Hi, Edrin,
    961841 wrote:
    Hi,
    I have recently encountered a strange problem on an Oracle 11gR2 database which is optimized for Datawarehouse usage.
    I am using two tables that have a relationship enforced by two fields of type NUMBER(10).
    The problem is that when I am joining these two tables very often I get strange results and when I re-execute the query I get a different result. I saw in the explain plan that the Hash Join is used for joining these two tables.
    select count(*)
    from recharge_history rh, recharge_history_balance rhb
    where rh.recharge_id = rhb.recharge_id
    and rh.recharge_id2 = rhb.recharge_id2
    and trunc(rh.recharge_date_time) between '30-Dec-2012' and '31-Dec-2012'
    Don't try to compare DATEs with VARCHAR2s, such as '30-Dec-2012'. The VARCHAR2 '31-Aug-2012' is between '30-Dec-2012' and '31-Dec-2012'; so are '31-Aug-2013' and '30-Mar-1999'.
    That may not be your only problem, but it's still a problem.
    If you're getting incosistent results, then it sounds like a bug. Start a service request with Oracle support.

Maybe you are looking for