How to compare the date value with the date datatype column?

Hi,
I am executed a query to get output for the particular date in two different database.
I got output in one db environment, but in the another environment i didnt get the output.
APP_DECISION_DATE column contains date datatype
ex:
SQL> select DECISIONED_STAGE_ID,DECISIONED_STAGE_USER_ID from naap10_application where APP_DECISION_DATE = TO_DATE('23-JAN-07',
'DD-MON-YY'); 2
DECISIONED_STAGE_ID DECISIONED_STAG
2006060106 SYSTEM
DATABASE - II
SQL> select DECISIONED_STAGE_ID,DECISIONED_STAGE_USER_ID from naap10_application where APP_DECISION_DATE=
TO_DATE('31-JAN-2007','DD-MON-RRRR') and application_id=2007010028552;
no rows selected
in the same db i got the output while i used the TO_DATE(APP_DECISION_DATE)
SQL> select DECISIONED_STAGE_ID,DECISIONED_STAGE_USER_ID from naap10_application where TO_DATE(APP_DECISION_DATE)=
TO_DATE('31-JAN-2007','DD-MON-YYYY') and application_id=2007010028552; 2
DECISIONED_STAGE_ID DECISIONED_STAG
2006060113 SYSTEM
is it necessary to use TO_DATE function while i am using the data datatype column in the WHERE CLAUSE?
Thanks in advance.
siva

Sorry & thanks sathish,
Now i got the result.
SQL> select DECISIONED_STAGE_ID,DECISIONED_STAGE_USER_ID from naap10_application where APP_DECISION_DATE BETWEEN TO_DATE ('31.01.2007 00:00:00', 'DD.MM.YYYY HH24:MI:SS') AND TO_DATE ('31.01.2007 23:59:59', 'DD.MM.YYYY HH24:MI:SS')
2 and application_id=2007010028552;
DECISIONED_STAGE_ID DECISIONED_STAG
2006060113 SYSTEM
================================
But one doubt,
When i created the column with the date datatype how it gets the time value,
And in one environment db i got the result but in another environment i dont get,
Shall i want to change any session status of date?

Similar Messages

  • How to compare text box value with the table data??

    Hello ALL,
    I created one stored procedure in DB,it is as follows:-
    CREATE or replace PROCEDURE chkUser
    u in varchar2,
    p in varchar2,
    ap out varchar2
    is
    begin
    select count(*) into ap from tbuser where loginid = u and password = p;
    end;
    And at the front end I have designed a form with 2 text boxes, now my question is I wanna compare these text box values(which user enters) with the data of the table....??? something like control (may be I am not sure)..... ???
    If anybody can help me out with this issue...... help will be appreciated
    Thank you.
    regards,
    Kumar

    hi Elise,
    I'm always getting the Error Message as "Invalid Creditianls"... let me tell you the whole scenario with sql synatx.
    I have created tables as:-
    CREATE TABLE "TBUSER"
    (     "LOGINID" VARCHAR2(30) NOT NULL ENABLE,
         "PASSWORD" VARCHAR2(30),
         CONSTRAINT "TBUSER_PK" PRIMARY KEY ("LOGINID") ENABLE
    than I created the Procedure on tbuser, it is as:-
    create or replace PROCEDURE logincheck
    u in varchar2,
    p in varchar2,
    ap out varchar2
    is
    begin
    select count(*) into ap from tbuser where loginid = u and password = p;
    end;
    now at the front end side I have created one form with 2 text boxes (P8_USERNAME & P8_PASSWORD) and 2 buttons (Cancel and Submit)
    as per you told me in the above post, I have created 'Validation' procedure with Type as 'Exists' and expression(into Validation Expression1)as:-
    select 1 from tbuser
    where loginid = :P8_USERNAME
    and password = :P8_PASSWORD;
    and
    kept an error message as 'Invalid credentials'.....
    but I don't know what's going wrong..... I do have few data into the table, and when I am entering the same data(with case sensitive) I am getting the Error message, rather than when the credentials are perfect user should be allowed to enter into the current page(where I have created this form and validation procedure)....
    any idea what's going worng and where...????
    thxs.... appreciated..
    regards,
    Kumar

  • Comparing the current value with the previous one in Powershell

    Hi,
    New to scripting and i was wondering how can I compare the current value with the previous value?
    I am having trouble with the loop structure, and I am not sure I am on the right track...
    I am trying to compare the record to next record in the same csv file after import-csv... My code runs fine, but is not giving the right result.
    $FilePath = Get-FileName -initialDirectory "C:\"
    #Testing for null
    If($FilePath)
    $Data = Import-csv -Path $FilePath | Sort-Object BUYER, {[int] $_.PO_NBR}, {[int] $_.LINE_NBR}
    Foreach($fData in $Data)
    $i = $fData
    Foreach($i in $fData)
    if($fData.Buyer -eq $i.Buyer)
    #save all the same buyer name to a new variable
    Write-Host "Same as previous"
    Else
    Write-Host "Variable is null"
    Remove-Item function:\Get-FileName

    Thank you. The Foreach loop is now working properly.
    Can I ask what is the purpose of "-ea 0" in the import-csv? I can't seem to find "-ea" as a parameter for import-csv in help.
    -ea is short for -ErrorAction.
    Don't retire TechNet! -
    (Don't give up yet - 13,225+ strong and growing)

  • How to compare dropdown pre value with post value in sharepoint designer list workflow

    How to compare dropdown pre value with post value in sharepoint designer list workflow

    Hi,
    Can you provide more details about your requirement? It would make others easier to find a solution for you.
    By default, a workflow will be triggered after submitting data in the NewForm or EditForm.
    If you want to monitor the value changed in a drop down menu which is supposed to be in NewForm or EditForm, it would be more appropriate to apply custom JavaScript in the NewForm
    or EditForm page.
    About how to detect the value changed using JavaScript, the demos in this thread would be helpful:
    http://stackoverflow.com/questions/12080098/dropdown-using-javascript-onchange
    Thanks
    Patrick Liang
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • Compare the current value with the previous value in the same column

    Hi all,
    I have to include a statement in a query which allows to compare the current value of column A with the previous value of column A (same column). from there, I need to add a condition in order to have the expected result.
    Let's take an example to illustrate what I want to achieve:
    I have the following columns in table called 'Charges':
    Ship_id batch_nr Order_nr Price
    SID1111 9997 MD5551 50
    SID1111 9998 MD5552 50
    SID1111 9999 MD5553 50
    SID2222 8887 MD6661 80
    SID2222 8887 MD6662 80
    SID2222 8887 MD6662 80
    SID3333 6666 MD7771 90
    I want to check if the ship_id of row 2,3 (and more if available) is equal to the ship_id of row 1.
    If it is the case, then value 'together with the first batch_nr' in row 2 and 3 under Price column. If not, then keep the original value of Price column
    PLease see below the expected result:
    Ship_id batch_nr Order_nr Price
    SID1111 9997 MD5551 50
    SID1111 9998 MD5552 together with 9997
    SID1111 9999 MD5553 together with 9997
    SID2222 8887 MD6661 80
    SID2222 8887 MD6662 together with 8887
    SID2222 8887 MD6663 together with 8887
    SID3333 6666 MD7771 90
    Thanks in advance for your help, it is really urgent.
    Imco20030

    Hi,
    user11961002 wrote:
    Hi,
    Here is the query that I use:
    [ select
    sl.ship_id,
    o.ordnum,
    o.reffld_5 "BatchNR",
    sum(tc1.chrg_amt) "FreightPRC",
    sum(tc2.chrg_amt) "FuelPRC",
    sum (tc1.chrg_amt + tc2.chrg_amt + tc3.chrg_amt) "Total Price"
    from ord_line ol
    join ord o on (ol.ordnum = o.ordnum and ol.client_id = o.client_id)
    join shipment_line sl on (ol.ordnum = sl.ordnum and ol.client_id = sl.client_id and ol.ordlin = sl.ordlin)
    join adrmst a2 on (o.rt_adr_id = a2.adr_id)
    left join tm_chrg tc1 on (tc1.chargetype = 'FREIGHT' and tc1.chrg_role = 'PRICE' and tc1.ship_id = sl.ship_id)
    left join tm_chrg tc2 on (tc2.chargetype = 'FUELSURCHARGE'and tc2.chrg_role = 'PRICE' and tc2.ship_id = sl.ship_id)
    where sl.ship_id = 'SID0132408'
    group by o.client_id, o.ordnum, o.reffld_2, sl.ship_id, a2.adrnam, a2.adrln1, a2.adrpsz, a2.adrcty, a2.ctry_name,
    o.reffld_5, ol.early_shpdte
    order by ship_id
    ]That looks like the query you were using before you started this thread.
    Modify it, using the analytic fucntions FIRST_VALUE and LAG, like I showed you.
    I see that you did simplify the problem quite a bit, and it's good that you did that.
    It doesn't matter that your real problem involves joins or GROUP BY. Analytic functions are calculated on the results after all joins and GROUPS BYs are done. Just substitute your real expressions for the simplified ones.
    For example, in your simplified problem, there was a column called order_nr, but I see now that's it's really called o.ordnum. Where the solution I posted earlier says "ORDER BY order_nr", you should say "ORDER BY o.ordnum".
    Here's a less obvious example: in your simplifed problem, there was a column called price, but I see now that it's really SUM (tc1.chrg_amt + tc2.chrg_amt + tc3.chrg_amt). Where the solution I posted earlier says "TO_CHAR (price)", you should say "TO_CHAR (SUM (tc1.chrg_amt + tc2.chrg_amt + tc3.chrg_amt))". (You can't use an alias, like "Total Price", in the same SELECT clasue where it is defined.)
    I removed some columns from the select as they are not relevant for the wanted action like 'adress details or other references'.
    Now here is the result:
    Shipment ID     Order Number     WMS Batch     Freight      Fuel Price Order Total Price
    SID0132408     MDK-000014-05602649     04641401     110     10 120
    SID0132408     MDK-000014-05602651     04641402     110     10 120
    SID0132408     MDK-000014-05602652     04641363     110     10 120
    as you can see, the 3 orders have the same shipment ID.
    The expected result should be shown under column 'Total Price' as follows:
    Shipment ID     Order Number     WMS Batch     Freight      Fuel Price Order Total Price
    SID0132408     MDK-000014-05602649     04641401     110     10 120
    SID0132408     MDK-000014-05602651     04641402     110     10 tog with 04641401
    SID0132408     MDK-000014-05602652     04641363     110     10 tog with 04641401Okay, so those are the correct results that I asked for, plus the incorrect results you're getting now. Thanks; extra information doesn't hurt.
    But where is the raw data that you're starting with?
    It looks like you tried to format the code (but not the results) by typing this 1 character:
    before the formatted section and this different character
    after the formatted section. To post formatted text on this site, type these 6 characters
    before the formatted section, and the exact same 6 characters again after the formatted section.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How to compare text field length with the length of input characers

    I hae a problem with the length of text field
    I want to fix the length of TextField by taking the length of attribute to, whihc i have to use in text field
    Like i have set the max length of Attribut to 10 and set the length of textfield also 10.
    But the problem is that if i enter 10 'i' it dosn't fill even half the space in TextField
    And opposit if i enter 10 'W'
    I wonder if there is a solution for this problem
    i ma using True Type of Font

    * paint method in your own class that extends Canvas
    * @param g where to paint e.g. printer, screen, ram
    public void paint (Graphics g)
    // display word "today" centred at x,y
    FontMetrics fm = getFontMetrics( g.getFont( ) );
    String wording = "today" ;
    int xadj = fm.stringWidth( wording )/ 2;
    // position bottom left corner of the text
    g.drawString(wording , x-xadj, y );
    // draw a red line from x1,y1 to x2,y2
    g.setColor( Color .red );
    g.drawLine( x1 , y1, x2, y2);
    // draw an pre-existing Image. imX,imY is top left corner of the Image.
    g.drawImage ( image , imX, imY , imWidth, imHeight , this);
    } //end paint

  • Derive Expire date value with the next high effective date next row - 1 day

    Hi
    Trying to fiind a way to derive a new date (EXPIRE_DATE) in a SQL query, the data is ordered by EFF_DATE, How do you derive EXPIRE_DATE column ...
    Sample data:
    ID_NO                EFF_DATE         EXPIRE_DATE
    2004 02/03/2011 Null
    3922 06/04/2010 01/03/2011
    4454 20/06/2009 05/04/2010
    4544 17/02/2008 19/06/2009
    4232 13/07/2006 16/02/2008
    Thanks
    Qwestion

    Give this a shot:
    SELECT id_no
         , eff_date
         , LAG(eff_date) OVER (ORDER BY eff_date DESC) - 1  AS expire_date
    FROM   table_x
    ORDER BY eff_date DESC

  • Updating the characterstic values in the classification view

    Hi,
    We are trying to update the characterstic values in the material master through AUSP table (BDC program). We want to replace the old values with the new values. But the program is appending the new characterstic values to the old values. This is happening inspite of the configuration setting in the characterstic transaction (CT04) such that it allows only a single value. Please suggest us in this regard.
    Thanks
    Ramakanth

    use the following
    Set and Change Values
    Use
    You can use this function as an easy way to change, delete, or create large quantities of assigned characteristic values. Target objects can be classified, or existing assignments can be deleted.
    Prerequisites
    The selected target objects must have the same class type and object type as the template object.
    The characteristics must be the same for the target objects and template object.
    No interval values are processed. No reference characteristics are processed.
    Procedure
    Enter a class type. If the class type is for multiple object types, you see a list of the object types that you can select. Select an object type.
    Enter the characteristics whose values you want to change or set. To find characteristics, display the possible entries. To display all the characteristics of a class, choose Chars of class and enter the class.
    Characteristics: Old and New Values
    You can replace old values with new values. You can set completely new values if no value was assigned before, or delete old values.
    Use the possible entries to select values.
    You can only select one value for each line. If you want to process several values, you must select the same characteristic several times.
    Changing Values with an Operator
    If a characteristic has numeric format, you can use an operator to recalculate values. You can add, subtract, multiply, and divide figures. For character format, the operator fields are grayed out.
    On the Target objs tab, enter the objects to which you want to copy the new values.
    For more details on this procedure, a description of further functions, and information on the log, see the third and fourth steps in Copy Values Assigned to Object.
    On the Assignments tab, you can classify the target objects or delete existing assignments. Enter the class or select one using the possible entries. You can go to class management by choosing  Display class.
    Choose  Carry out a mass change.

  • How to extract the date value of IBOR date="12/12/2009"

    I have the following query, but do not get the date value out:
    WITH ibors AS (
    SELECT xmltype('<?xml version="1.0" encoding="utf-8"?>
    <IBOR date="12/12/2009">
    <LIBOR currency="USD">
    <OneYear>1.38875</OneYear>
    </LIBOR>
    </IBOR>
    ') ibor_xml
    FROM dual
    SELECT i.ibor_date, i.ibor_oneyear
    FROM ibors,
    XMLTABLE(
    '//IBOR'
    PASSING ibors.ibor_xml
    COLUMNS ibor_date VARCHAR2(20) PATH '/IBOR/date',
    ibor_oneyear VARCHAR2(20) PATH '/IBOR/LIBOR/OneYear'
    ) i;
    How to extract the date value of <IBOR date="12/12/2009">?

    Hi,
    The date is an attribute of element IBOR. So you must use "@date" in the xpath expression :
    WITH ibors AS (
    SELECT xmltype('<?xml version="1.0" encoding="utf-8"?>
    <IBOR date="12/12/2009">
    <LIBOR currency="USD">
    <OneYear>1.38875</OneYear>
    </LIBOR>
    </IBOR>
    ') ibor_xml
    FROM dual
    SELECT i.ibor_date, i.ibor_oneyear
    FROM ibors,
    XMLTABLE(
    '//IBOR'
    PASSING ibors.ibor_xml
    COLUMNS
    ibor_date VARCHAR2(20) PATH '/IBOR/@date',
    ibor_oneyear VARCHAR2(20) PATH '/IBOR/LIBOR/OneYear'
    ) i;

  • How to configure  a test sever with the system copy with prd data

    Dear All ,
    I need to configure  a test sever with the system copy with prd data.
    Please any one can suggest the step by step process to do the same configure and  system copy.
    Regards
    kumar

    Dear All,
    I am facing problem in system copy. I want to knoe the way after restore i  can move all the data and server data in one drive .
    Now the error is resolve by changing the initTAT.sap the value tape to disk but now stuck in the drive for restore it is asking which is not there at os level.
    BR0252E Function mkdir() failed for 'M:\oracle\TST\SAPDATA4\PRD33' at location
    BrDirCreate-1
    BR0253E errno 2: No such file or directory
    BR0252E Function mkdir() failed for 'M:\oracle\TST\SAPDATA4\PRD32' at location
    TO solve the above problem i have created ad network drive for this but once all the restore will be completed than how i can i move the data form network drive to on drvie.
    Please suggest
    Regards,
    Kumar
    Edited by: kumarmoh on Jul 21, 2009 1:43 PM

  • Apex flash charts with date values on the x axis

    I am playing around in Apex 4 using flash charts and having a bit of troubles playing with dates on the x axis on a 2d line chart.
    What I am trying to achive is a values plotted across the chart and the date/time values are not a constent (ie not continually say 1 hour apart) hence why I want to use a datatype of date.
    In the SQL below:
    select null as link,  sysdate -2  as value, 0 as label from dual
    union
    select null , sysdate -2+1/24 , 1 from dual
    union
    select null , sysdate -2+2/24 , 2 from dual
    union
    select null , sysdate -2+5/48, 1 from dual
    union
    select null , sysdate -2+3/24, 0 from dual;I get a 2D Line chart but each date/time value is equally space apart (ie sysdate -2, sysdate -2+1/24, sysdate -2+2/24 and sysdate -2+3/24 should be 1 unit apart and sysdate -2+5/48 should be half way between sysdate -2+2/24 and sysdate -2+3/24).
    I think I have to use custom xml. Using http://www.anychart.com/products/anychart/docs/xmlReference/index.html and http://www.anychart.com/products/anychart/docs/users-guide/DateTime-Axes.html I edited the XML and changed:
    <?xml version = "1.0" encoding="utf-8" standalone = "yes"?>
    <anychart>
      <settings>
        <animation enabled="false"/>
        <no_data show_waiting_animation="False">
          <label>
            <text></text>
            <font family="Verdana" bold="yes" size="10"/>
          </label>
        </no_data>
      </settings>
      <margin left="0" top="" right="0" bottom="0" />
      <charts>
        <chart plot_type="CategorizedVertical" name="chart_1614502819445708">
          <chart_settings>
            <title enabled="False" />
            <chart_background>
              <fill type="Solid" color="0xffffff" opacity="0" />
              <border enabled="false"/>
              <corners type="Square"/>
            </chart_background>
            <data_plot_background>
            </data_plot_background>
            <axes>
              <y_axis >
                <scale   mode="Normal"    />
                <title enabled="false" />
                <labels enabled="true" position="Outside">
                  <font family="Tahoma" size="10" color="0x" />
                  <format><![CDATA[{%Value}{numDecimals:0,decimalSeparator:.,thousandsSeparator:\,}]]></format>
                </labels>
                <major_grid enabled="False"/>
    <minor_grid enabled="False"/>
              </y_axis>
              <x_axis>
                <scale  mode="Normal"    />
                <title enabled="false"/>
                <labels enabled="true" position="Outside">
                  <font family="Tahoma" size="10" color="0x" />
                  <format><![CDATA[{%Value}{numDecimals:0,decimalSeparator:.,thousandsSeparator:\,}]]></format>
                </labels>
                <major_grid enabled="True" interlaced="false">
                    <line color="Black" />
                  </major_grid>
    <minor_grid enabled="True">
                  </minor_grid>
              </x_axis>
            </axes>
          </chart_settings>
          <data_plot_settings enable_3d_mode="false" >
            <line_series>
              <tooltip_settings enabled="true">
                <format><![CDATA[{%Name}{enabled:False} - {%Value}{numDecimals:0,decimalSeparator:.,thousandsSeparator:\,}]]></format>
                <font family="Tahoma" size="10" color="0x" />
                  <position anchor="Float" valign="Top" padding="10" />
              </tooltip_settings>
              <label_settings enabled="true" mode="Outside" multi_line_align="Center">
                <format><![CDATA[{%Value}{numDecimals:0,decimalSeparator:.,thousandsSeparator:\,}]]></format>
                <background enabled="false"/>
                <font family="Tahoma" size="10" color="0x" />
              </label_settings>
              <line_style>
                                <line enabled="true" thickness="1" opacity="1" />
              </line_style>
              <marker_settings enabled="True" >
                <marker type="Circle" />
              </marker_settings>
            </line_series>
          </data_plot_settings>
    #DATA#
        </chart>
      </charts>
    </anychart>to
    <?xml version = "1.0" encoding="utf-8" standalone = "yes"?>
    <anychart>
      <settings>
        <animation enabled="false"/>
        <no_data show_waiting_animation="False">
          <label>
            <text></text>
            <font family="Verdana" bold="yes" size="10"/>
          </label>
        </no_data>
        <locale>
          <date_time_format>
            <format>%HH:%mm:%ss %dd/%MM/%yyyy</format>
          </date_time_format>
        </locale>
      </settings>
      <margin left="0" top="" right="0" bottom="0" />
      <charts>
        <chart plot_type="CategorizedVertical" name="chart_1614502819445708">
          <chart_settings>
            <title enabled="False" />
            <chart_background>
              <fill type="Solid" color="0xffffff" opacity="0" />
              <border enabled="false"/>
              <corners type="Square"/>
            </chart_background>
            <data_plot_background>
            </data_plot_background>
            <axes>
              <y_axis >
                <scale   mode="Normal"    />
                <title enabled="false" />
                <labels enabled="true" position="Outside">
                  <font family="Tahoma" size="10" color="0x" />
                  <format><![CDATA[{%Value}{numDecimals:0,decimalSeparator:.,thousandsSeparator:\,}]]></format>
                </labels>
                <major_grid enabled="False"/>
    <minor_grid enabled="False"/>
              </y_axis>
              <x_axis>
                <scale  mode="Normal" type="DateTime"    />
                <title enabled="false"/>
                <labels enabled="true" position="Outside">
                  <font family="Tahoma" size="10" color="0x" />
                  <format><![CDATA[{%Value}]]></format>
                </labels>
                <major_grid enabled="True" interlaced="false">
                    <line color="Black" />
                  </major_grid>
    <minor_grid enabled="True">
                  </minor_grid>
              </x_axis>
            </axes>
          </chart_settings>
          <data_plot_settings enable_3d_mode="false" >
            <line_series>
              <tooltip_settings enabled="true">
                <format><![CDATA[{%Name}{enabled:False} - {%Value}{numDecimals:0,decimalSeparator:.,thousandsSeparator:\,}]]></format>
                <font family="Tahoma" size="10" color="0x" />
                  <position anchor="Float" valign="Top" padding="10" />
              </tooltip_settings>
              <label_settings enabled="true" mode="Outside" multi_line_align="Center">
                <format><![CDATA[{%Value}{numDecimals:0,decimalSeparator:.,thousandsSeparator:\,}]]></format>
                <background enabled="false"/>
                <font family="Tahoma" size="10" color="0x" />
              </label_settings>
              <line_style>
                                <line enabled="true" thickness="1" opacity="1" />
              </line_style>
              <marker_settings enabled="True" >
                <marker type="Circle" />
              </marker_settings>
            </line_series>
          </data_plot_settings>
    #DATA#
        </chart>
      </charts>
    </anychart>and change the SQL series to:
    select link, to_char(value, 'HH24:MI:SS DD/MM/YYYY') as value, label from
    select null as link,  sysdate -2  as value, 0 as label from dual
    union
    select null , sysdate -2+1/24 , 1 from dual
    union
    select null , sysdate -2+2/24 , 2 from dual
    union
    select null , sysdate -2+5/48, 1 from dual
    union
    select null , sysdate -2+3/24, 0 from dual)But the chart changes from a line chart to a bar chart with each value being equally spaced.
    Can anyone see what I am doing wrong or point me in the right direction? Thanks in advance.

    This will be a little bit lengthy answer, but I guess it will be easier to understand what I meant to say.
    I created a table that contains values you used as a data source (just to make my life easier):
    SQL> alter session set nls_date_format = 'dd.mm.yyyy hh24:mi:ss';
    Session altered.
    SQL> select * from test;
    VALUE                    LABEL
    12.10.2010 09:03:45          0
    12.10.2010 10:03:45          1
    12.10.2010 11:03:45          2
    12.10.2010 11:33:45          1
    12.10.2010 12:03:45          0
    SQL> alter session set nls_date_format = 'hh24:mi';
    Session altered.From now on, we'll see only hours and minutes.
    Step 1: current and previous values - difference in number of MINUTES
    SQL> select t.value,
      2         lag(t.value) over (order by t.value) previous_value,
      3         (t.value - lag(t.value) over (order by t.value)) * 24 * 60 minutes_diff
      4  from test t;
    VALUE PREVI MINUTES_DIFF
    09:03
    10:03 09:03           60
    11:03 10:03           60
    11:33 11:03           30
    12:03 11:33           30Step 2: a little bit of calculation:
    - TIME_SPAN: how many minutes are there between MIN and MAX date?
    - MIN_DIFF: what is the minimum time difference (minutes)?
    - SLICES: how many time slices do we want on the x-axis?
    SQL> select
      2    min(x.value) min_val,
      3    max(x.value) max_val,
      4    min(x.minutes_diff) min_diff,
      5    (max(x.value) - min(x.value)) * 24 * 60 time_span,
      6    (max(x.value) - min(x.value)) * 24 * 60 / min(x.minutes_diff) slices
      7  from (select t.value,
      8               lag(t.value) over (order by t.value) previous_value,
      9               (t.value - lag(t.value) over (order by t.value)) * 24 * 60 minutes_diff
    10        from test t
    11       ) x;
    MIN_V MAX_V   MIN_DIFF  TIME_SPAN     SLICES
    09:03 12:03         30        180          6There's 180 minutes between 09:03 and 12:03; minimum time difference in our TEST table is 30 minutes, so - we want to have 6 time slices on the x-axis (180 / 30).
    Step 3: row generator technique: let's create time values that are missing:
    SQL> select y.min_val + (level - 1) * y.min_diff / (24 * 60) val
      2  from (select
      3          min(x.value) min_val,
      4          max(x.value) max_val,
      5          min(x.minutes_diff) min_diff,
      6          (max(x.value) - min(x.value)) * 24 * 60 time_span,
      7          (max(x.value) - min(x.value)) * 24 * 60 / min(x.minutes_diff) slices
      8        from (select t.value,
      9                     lag(t.value) over (order by t.value) previous_value,
    10                     (t.value - lag(t.value) over (order by t.value)) * 24 * 60 minutes_diff
    11              from test t
    12             ) x
    13       ) y
    14  connect by level <= y.slices + 1;
    VAL
    09:03
    09:33
    10:03
    10:33
    11:03
    11:33
    12:03
    7 rows selected.OK, now we have 30 minutes between every time value.
    Step 4: join newly generated time values with the original table. Use OUTER JOIN; missing labels will be 0 (zero):
    SQL> select
      2    null link,
      3    to_char(z.val, 'hh24:mi') new_value,
      4    nvl(t1.label, 0) new_label
      5  from (select y.min_val + (level - 1) * y.min_diff / (24 * 60) val
      6        from (select
      7                min(x.value) min_val,
      8                max(x.value) max_val,
      9                min(x.minutes_diff) min_diff,
    10                (max(x.value) - min(x.value)) * 24 * 60 time_span,
    11                (max(x.value) - min(x.value)) * 24 * 60 / min(x.minutes_diff) slices
    12              from (select t.value,
    13                           lag(t.value) over (order by t.value) previous_value,
    14                           (t.value - lag(t.value) over (order by t.value)) * 24 * 60 minutes_diff
    15                    from test t
    16                   ) x
    17             ) y
    18        connect by level <= y.slices + 1
    19       ) z,
    20       test t1
    21  where t1.value (+) = z.val
    22  order by z.val;
    L NEW_V  NEW_LABEL
      09:03          0
      09:33          0
      10:03          1
      10:33          0
      11:03          2
      11:33          1
      12:03          0
    7 rows selected.Cool, so we have them all. Now, go to Apex and create a chart using a query from step #4.
    I tested it - it displays something which means that it should work for you too (unfortunately, this forum doesn't accept attachments so that you could see it). Now, I can't tell whether that's what you need or not, but - if the idea itself is OK, it can be adjusted (I hope so).

  • I have a large number of photos imported into iPhoto with the dates wrong.  How can I adjust multiple photos (with varying dates) to the same, correct, date?

    I have a large number of photos imported into iPhoto with the dates wrong.  How can I adjust multiple photos (with varying dates) to the same, correct, date?

    If I understand you correctly, when you enter a date in the Adjust Date and Time window, the picture does not update with the date you enter.  If that is the case then something is wrong with iPhoto or your perhaps your library.
    How large a date change are you putting in?  iPhoto currently has an issue with date changes beyond about 60 years at a time.  If the difference between the current date on the image and the date you are entering is beyond that range that may explain why this is not working.
    If that is not the case:
    Remove the following to the trash and restart the computer and try again:
    Home > Library > Caches > com.apple.iphoto
    Home > Library > Preferences > com.apple.iPhoto (There may be more than one. Remove them all.)
    ---NOTE: to get to the "home > library" hold down option on the keyboard and click on "Go" > "Library" while in the Finder.
    Let me know the results.

  • How to set a variable value on the BPC Data Manager

    Hello BPC Experts,
    I'm creating a BPC10 NW version demo environment for our prospect customer.
    I made a data manager to import  BW data into BPC model from BW cube.
    I need to import just one month data into BPC from the BW cube that has more than one month data.
    When I run the data package manually, I can select a member of the time dimension prompt and I can import specific month data I want.
    But, in a case where the program (data manager) runs by JOB monthly,
    I can't select a member of the time dimension prompt manually.
    So I want to know how to set a  variable value to the time dimension prompt from a system date etc. automatically.
    Are there any way to set a variable value to the time dimension prompt on the data manager automatically from a system date?
    Or, do you have any other solution to import just one month data into BPC from the BW cube that has more than one month data  by the data manager running on JOB ?
    (without selecting a member of the time dimension prompt of the data package manually)
    Thanks in advance,
    Keisuke

    Hi Gersh
    Sorry for my late reply and thanks for your helpful information.
    I tried the second way of your information and I could configure it.  
    And I 'll try first way of your information.
    Regards,
    Keisuke

  • My Iphone was sync with Itunes on a computer then this computer broke down and i purchased another one. I was able to extract all the data from the old one. now how can i sync my phone with the new tunes without loosing any data?

    My Iphone was sync with Itunes on a computer then this computer broke down and i purchased another one. I was able to extract all the data from the old one. now how can i sync my phone with the new tunes without loosing any data?

    Yes, windows to Mac too.
    iTunes: How to move [or copy] your music [library] to a new computer [or another drive] - http://support.apple.com/kb/HT4527
    Quick answer if you use iTunes' default preferences settings:  Copy the entire iTunes folder (and in doing so all its subfolders and files) intact to the other drive.  Open iTunes and immediately hold down the Option (alt) key (shift on Windows), then guide it to the new location of the library.
    Windows users see tip at: https://discussions.apple.com/message/18879381

  • How to create array of indicators, with the indicators numeric text value changes as it falls above or below the limit

    Hi,
    I am a newbie here. Just started using Labview for my project. Currently having some difficulties over here. Hopefully someone could enlighten me. I wanted to create an array of 60 indicators, where the indicators value are measured from the PCI card. But now the problem is how to make my indicator values in the array change its numeric text color if it falls below or above the limit set. I've attached the vi together with this. Thanks.
    Regards,
    CH.Ong
    Attachments:
    testing.vi ‏15 KB
    try.vi ‏120 KB

    Maybe, you can try something like this...
    - Partha
    LabVIEW - Wires that catch bugs!
    Attachments:
    To change Boolean Text Color in Array of Clusters.vi ‏18 KB

Maybe you are looking for

  • Can i put pandora on without using credit card

    I'm trying to put Pandora on as a free app but my iphone says I have to use my sign-on thru itunes and then it asks me for a credit card.  I don't want to use a credit card - I only want free apps.

  • Handling Unit not being assigned to TO for an outbound delivery

    Hi All When I create a TO for an outbound delivery then a handling unit is not being assigned to the TO. I cannot confirm the TO as it complains about the non assignment of HU. I have done the following so far: 1. Set up a default packing material w.

  • WD Program calls RFC. How to start external ABAP debugger to see the data

    Hi Experts, I have created WD program which calls RFC. I want to see the value passed from WD to ABAP. I have to see the values once data reaches ABAP. How I can do so? I did following. 1) se 37 . Open the proram. Inside the fucntion near a select st

  • Temporary Fix for Smart Playlist order bug

    I stumbled across a Smart Playlist that was keeping the correct order and discovered why.  It was a Smart Playlist that contained 2 other Smart Playlists.  The original Smart Playlists didn't keep their order but the new one that combined them did. 

  • N79: "File Corrupted" error while installing .sis/...

    Hi: I have been using Nokia N79 since Dec 15, 2008. I am facing problem while installing software with .sis/.sisx extension [for example fringe, putty and so many different softwares]. Everytime it's showing "File Corrupted" error, even if I download