How to update past due column date?

Hello

I created a project with start_date, Target_Date, Past_Due columns table.
Past_Due = SYSDATE - Target_Date
How can I update Past_Due column for each row in the table?
-What can be a better way than to the refresh report page whenever it opens?
-Where to write the code? In the procedure or page or article?

Thank you
Guy

>

WHAT CASE G = NULL THEN NULL OTHER CASE (F = NULL AND G < sysdate)="" then="" sysdate="" -="" g="" else="" when="" case="" (f=""> <> NULL AND F > G) THEN F - G END OTHERWISE NULL

This is not the right format for a CASE statement. See http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28370/controlstructures.htm#i2866.

In addition, you cannot validly compare NULL values, you can check if a ' IS NULL.

Tags: Database

Similar Questions

  • Online update of the column data in the sql statement

    Hello Experts,

    I created a sql report
    select apex_item.checkbox(1,RES_RTNG_ID) as "RATING ID",RES_ID,SKILL_SET_ID, to_char(EVALUATION_DATE,'DD-MM-YYYY') d, EVALUATOR, RATE_TYPE, RATING ,REMARKS
    from HRMS_RESOURCE_RATING
    where TRAINING_ID = :P51_TRNG_PLN_ID
    I have a box that is used to delete rows in the report.
    and I want features to update the data in the column of the report.
    Please help me how to do this.

    Thank you
    Jitendra

    Hi all

    I did it with inline sql reports updated. Those who want to implement online update of sql reports

    Please see the link below:
    http://roelhartman.blogspot.in/2009/11/UPDATEABLE-interactive-report-websheets.html?z

    Thank you
    Jitendra

  • How to retrieve xml soap column data into a clob table

    Hello

    I'm trying to retrieve the value of the clob column XML tag.

    Name of the table = xyz and column = abc (clob data type)

    data stored in the column to abc is as below

    "" < soapenv:Envelope xmlns:soapenv = "http://schemas.xmlsoap.org/soap/envelope/" xmlns:head ="http://www.abc.com/gcgi/shared/system/header" xmlns:v6 = "http://www.abc.com/gcgi/services/v6_0_0_0" xmlns ="http://www.abc.com/gcgi/shared/system/systemtypes" > ""

    "< soapenv:Header xmlns:wsa = 'http://www.w3.org/2005/08/addressing' > '.

    "< RqHeader soapenv:mustUnderstand ="0"xmlns ="http://www.abc.com/gcgi/shared/system/header">."

    < DateAndTimeStamp > 2011-12-20T 16: 02:36.677 + 08:00 < / DateAndTimeStamp >

    < UUID > 1000002932 < / UUID >

    6_0_0_0 < version > < / Version >

    < ClientDetails >

    < Org > CBA < / Org >

    < OrgUnit > CBA < / OrgUnit >

    < channelId% > HBK < / ChannelID >

    < TerminalID > 0000 < / TerminalID >

    < SrcCountryCode > SG < / SrcCountryCode >

    < DestCountryCode > SG < / DestCountryCode >

    < UserGroup > HBK < / UserGroup >

    < / ClientDetails >

    < / RqHeader >

    < wsa: action >/SvcImpl/Bank /.

    SOAPEndpoint/AlertsService.serviceagent/OpEndpointHTTP/AlertDeleteInq < / wsa: action > < / soapenv:Header >

    < soapenv:Body >

    < v6:AlertDeleteInqRq >

    < v6:Base >

    < v6:VID > 20071209013112 < / v6:VID >

    <!-in option: - >

    < v6:Ref > CTAA00000002644 < / v6:Ref >

    < / v6:Base >

    < / v6:AlertDeleteInqRq >

    < / soapenv:Body >

    < / soapenv:Envelope >

    And I want to retrieve the values of tag

    < channelId% > and < v6:VID >

    can help someone, I tried with extractvalue but not able to get the values

    e210e26a-5109-4E16-9e40-d6c719094b0d wrote:

    Select x.* esb_output_temp t

    , xmltable (xmlnamespaces ('http://schemas.xmlsoap.org/soap/envelope' as "soapenv"))

    'http://www.abc.com/gcgi/shared/system/header', 'head ',.

    ( http://www.abc.com/gcgi/services/bank/alerts/v6_0_0_0' as 'v6')

    ,'/ soapenv:Envelope' to xmlparse (document t.med_req_payload)

    columns ChannelID varchar2 (10)

    path ' soapenv: / header/head: RqHeader / head: ClientDetails / head: ChannelID'

    , Path of varchar2 (30) VID ' soapenv:Body / v6:AlertDeleteInqRq / v6:Base / v6:VID'

    ) x ;

    Get the error:

    ORA-19112: error raised during the evaluation:

    XVM-01003: [XPST0003] syntax error in ' soapenv:'

    1 declare namespace soapenv is http://schemas.xmlsoap.org/soap/envelope;. Statement

    .

    ^

    If you do not run the exact query I posted. Why?

    You have changed the uri of namespace associated with the prefix of 'http://schemas.xmlsoap.org/soap/envelope/' to 'http://schemas.xmlsoap.org/soap/envelope' soapenv, see the difference?

    and there is a syntax error in the expression of path ChannelID: soapenv: / header

    See my example again once, you need not to tamper with it, at least not until you understand what you are doing.

  • How to load several files column data into essbase using the rule of load.

    Hello

    I need to load a file of data into essbase, which includes data from several columns.

    Here is a sample file.


    Year, Department, account, Jan, Feb, Mar, Apr, may, June, July, August, Sept, Oct, Nov, Dec
    FY10, ministere1, account1, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12
    FY10, agencies2, account1, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12
    FY10, ministere3, account1, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12


    Thank you
    Sirot

    But this isn't an error as such, that is to say that no data values have been changed so that they possible already exist in the database.
    If there is no release, they should be in a file of errors.

    See you soon

    John
    http://John-Goodwin.blogspot.com/

  • How to cut the column data

    Gurus in the morning

    I have two tables with the data in the corresponding column, BUT I need to cut the columns in a table
    the data is displayed as follows in table xpq_log
    LOG_DATE                     LOG_PTR     LOG_HDR
    01/06/2011 00:00:00     0609pro     0609IN002C_06
    04/06/2011 00:00:00     0609pro     0609IN002C_06
    05/06/2011 00:00:00     0609pro     0609IN002C_06
    06/06/2011 00:00:00     0609pro     0609IN002C_06
    07/06/2011 00:00:00     0609pro     0609IN002C_06
    09/06/2011 00:00:00     0609pro     0609IN002C_06
    10/06/2011 00:00:00     0609pro     0609IN002C_06
    12/06/2011 00:00:00     0609pro     0609IN002C_06
    01/06/2012 00:00:00     0609pro     0609IN002C_06
    02/06/2012 00:00:00     0609pro     0609IN002C_06
    03/06/2012 00:00:00     0609pro     0609IN002C_06
    06/06/2012 00:00:00     0609pro     0609IN002C_06
    07/06/2012 00:00:00     0609pro     0609IN002C_06
    08/06/2012 00:00:00     0609pro     0609IN002C_06
    09/06/2012 00:00:00     0609pro     0609IN002C_06
    In the table of printpdf as follows
    PDF_REPORT     PDF_DESCRIPTION
    IN002C                     STOCK FILE PURGE - PRINT WH CONTROL
    How can I cut the column data (log_hdr) to match column (pdf_report)?

    Any help will be much appreciated

    user11978142 wrote:
    Yes the code always starts with an alphabetic character and always ends before the underscore character and the prefix is always digital.

    And Yes to the second comment WRT 1 to many relationship.

    WRT the duplicates I want the info displayed even if there is no matching printpdf

    You talk a LEFT OUTER JOIN, then:

    See the example below (the statement are just to reproduce the paintings, just use the last query):

    WITH xpq_log AS
    (
       SELECT '0499SYS003A_06' log_hdr FROM DUAL UNION ALL
       SELECT '0612PV410W1_06' log_hdr FROM DUAL UNION ALL
       SELECT '0609IN002C_06' log_hdr FROM DUAL UNION ALL
       SELECT '2201PA100D1_30' log_hdr FROM DUAL
    )
    , printpdf AS
    (
       SELECT 'SYS003A' pdf_report, 'STOCK FILE PURGE - PRINT WH CONTROL' description FROM DUAL UNION ALL
       SELECT 'PV410W1' pdf_report, 'Description 2' description FROM DUAL
    )
    SELECT a.log_hdr, REGEXP_SUBSTR (a.log_hdr, '[[:alpha:]][^_]*') AS pdf_report
         , b.description
      FROM xpq_log a LEFT OUTER JOIN printpdf b
           ON pdf_report = REGEXP_SUBSTR (a.log_hdr, '[[:alpha:]][^_]*');
    
    Output:
    LOG_HDR        PDF_REPORT     DESCRIPTION
    -------------- -------------- -----------------------------------
    0499SYS003A_06 SYS003A        STOCK FILE PURGE - PRINT WH CONTROL
    0612PV410W1_06 PV410W1        Description 2
    2201PA100D1_30 PA100D1
    0609IN002C_06  IN002C                                           
    

    Kind regards.
    Al

  • Don't know how it happened but my file deleted is past the last date in an alphabetical list.

    Don't know how it happened but my file deleted is past the last date in an alphabetical list. How ti to return with the last date in?

    original title: deleted file.

    If you mean the trash in Explorer mode, simply click on the column heading "Date deleted" until the most recent appears first on the list. If you do not have this column, do a right click No matter what column header and click to put a check on 'Delete Date' in the context menu that appears.

  • How to read the two columns of data from the Port series

    Hello

    I'm reading two columns of data from the serial port.

    Example:

    52439 52430

    52440 52437

    52209 52214

    51065 51070

    52206 52390

    I use the serial of Visa service and I can read the first column of data from the serial port, but I can't understand how to read the second column.

    I want to both sets of chart data.

    I enclose my VI.

    Thank you for your help.

    The analysis of string function takes a "Format string" on top (with the right button of the function and choose Help, which explains all the entries).  In particular, you can say 'Give me two numbers separated by a tab' and the output will be two numbers (whole or floating, depending on the chosen format).  In particular, %d\t%d specifies a decimal integer, , whole decimal.

  • Please tell me how do to permanently change the date of a file "update"

    Please tell me how do to permanently change the date of a file "update". The file is a JPG image copied from a digital camera. After that I rotate image his 'Date Modified' goes from January 20, 2011 to September 1, 2011. As a result of the date change, the image no longer appears in the correct position when the directory is sorted. I have a program that creates a file HTML images. The software sorts images according to their creation date. The bad images appear at the end of the table.

    Date manipulation attributes of a file can be done directly through the graphical interface of Windows.  There are, however, various third party utilities that have this capability.

    This article has a good discussion on the topic and includes links to some public services.  The article is quite old, however, and I don't check to see if the links are still valid.  If not, you should be able to find something useful here: http://www.google.com/#sclient=psy&hl=en&source=hp&q=edit+file+accessed+date&pbx=1&oq=edit+file+accessed+date&aq=f&aqi=&aql=&gs_sm=e&gs_upl=1857l7979l0l8482l23l23l0l2l2l0l267l4165l0.10.11l21l0&bav=on.2,or.r_gc.r_pw.&fp=74e371c96a48f4b&biw=1024&bih=649

  • I tried to download a pdf and convert them into excel, but the data in excellent is always to the image format.  How can I get the pdf data into the columns and rows?

    I tried to download a pdf and convert them into excel, but the data in excellent is always to the image format.  How can I get the pdf data into the columns and rows so that I can do the calculations?

    If you start the https://forums.adobe.com/welcome Forums Index

    You will be able to select a forum for the specific Adobe products you use

    Click on the symbol "arrow down" on the right (where it is said to see all our products and Services) to open the drop-down list and scroll

  • How to update a field date in a form based on a table

    I created a form (FOO). This form has a column called LAST_UPDATE_DATE. I want to update the value of the column with the date and time when the user makes a change to the line. I'm running into some difficulties doing this work.

    I updated the source of the default database column type this field. The value of the source or the expression has the value "LAST_UPDATE_DATE". I also set the default value (TO_CHAR (SYSTIMESTAMP, "DD-MON-YYYY HH24"); The first time, this line is being updated field is updated correctly the current date/time. However, on later changes to the line, the field does not have the most recent date/time value.

    Any recommendations on what I am doing wrong or what might be the right way to address the issue?

    Thank you
    John

    John,

    You can also just do a process that fires after the automatic line, which defines the update_by and the update_date of check processing.

    or conversely, you might have a process just before you automatic line treatment for set the update_time systimestamp element fire. in this way the actual insertion/update is managed by the transformation of the auto line.

    In addition, if you are worried about forgetting the trigger, I always do an installation script and add new items to it because they are necessary. Then, you add the installation script in your support items if she lives with the application.

    See you soon,.

    Janet Tyson

  • How can I get a PHP include to update automatically after a date?

    Hi guys,.

    I maintain a number of site Web for athletes and sports on their websites, inclusion of their next event - just a small PHP file with when and where the next event is.

    After each test, I have to manually update the include at the next event of the customer, who is a bit of pain and a lot of time.

    Is there a way I can implement the script include to update automatically with another file to be included after a date?

    Or, better yet, can I configure the include itself to display the content updated after a specific date?

    That's what the include contains...

    <img class="event" src="/images/eventPicture.png" />
    <p class="nextEvent">Location<br />
    Series<br />
    1-3 January 2013</p>
    

    Thank you very much and I hope to hear from you!

    SM

    Its easier than establishing a database... I've been dabbling. You will still need to use a language such as php server-side.

    First establish the date by adding the service to date get to the page:

    <>

    $date = date('d-F-Y');

    ?>

    Then add the below little php in the position where you want the "include" to appear. (so if you April 19, event_3.php to appear):

    <>

    If ($date == "April 19, 2013") {? >}

    It is not economic for many dates of the event, but if you have a little it will do as a solution.

    It's not great because you would need to add below, changing to include it on the date you want to show that will replace the previous event.

    <>

    If ($date == "April 19, 2013") {? >}

    <>

    If ($date == "May 30, 2013") {? >}

    <>

    If ($date == "June 4, 2013") {? >}

  • Identify the weekend and the days of the week a date and update the empty column

    Hi, I look at previous posts that are similar to my question, but nothing helps.

    I have a column called incident_date that is in this format and comes from the Nov_Final table
    01-JUL-2009 20.10
    04-NOV-2009 17.00
    16-DEC-2009 16.00
    In Nov_Final, I created a column called weekend

    What I want to do is to perform an update, something like this:
    Update Nov_Final
    
    SET Weekend=(case when Incident_date ='WEEKEND' THEN 'Y' ELSE 'N' END)
    Banner:
    Oracle Database 11 g Release 11.2.0.2.0 - 64 bit Production
    PL/SQL Release 11.2.0.2.0 - Production
    "CORE 11.2.0.2.0 Production."
    AMT for Linux: Version 11.2.0.2.0 - Production
    NLSRTL Version 11.2.0.2.0 - Production
    Weekend would be Saturday or Sunday. 
    In short I need to find out if the incident_date falls on a weekend and if it does update the weekend column as 'Y' else 'N' if it's not.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            

    You can use TO_CHAR function with a format mask as "fmDAY" to your needs:

    with t_data
    as
    (
    select sysdate + level as col1 from dual connect by level <= 7
    )
    SELECT
        col1,
        TO_CHAR(col1,'fmDAY') col_day,
        CASE
            WHEN TO_CHAR(col1,'fmDAY') IN ('SATURDAY','SUNDAY')
            THEN 'Y'
            ELSE 'N'
        END AS weekend_ind
    FROM
        t_data;
    
    COL1                      COL_DAY                     WEEKEND_IND
    ------------------------- --------------------------- -----------
    08-NOV-11 07:54:12        TUESDAY                     N
    09-NOV-11 07:54:12        WEDNESDAY                   N
    10-NOV-11 07:54:12        THURSDAY                    N
    11-NOV-11 07:54:12        FRIDAY                      N
    12-NOV-11 07:54:12        SATURDAY                    Y
    13-NOV-11 07:54:12        SUNDAY                      Y
    14-NOV-11 07:54:12        MONDAY                      N           
    
    7 rows selected
    
  • Classic generic column report - update the list column

    Consider a dynamic pivot statement as follows (as described by the AMIS) which

    select * from table( pivot(  'select deptno,  job, count(*) c from scott.emp group by deptno,job' ) )
    
    
    
    

    I used this as a SQL source for the classic report, by selecting "use generic column names.

    The report looks like

    dp_full.png

    I can set up the data displayed with a selection list and including a clause where clause

    where job =v(''P39_JOB'') or v(''P39_JOB'') is null
    
    
    
    

    List select not PPR on the region,demonstrated here:

    https://Apex.Oracle.com/pls/Apex/f?p=73000:39:

    Note: , and all swivel jobs are still visible in the form of columns, data is limited

    -other jobs are empty

    -departments with no clerks are not shown

    dp_clerk.png

    Let's say you have another list of selection than the work of groups, say the "Présidents" and "close".

    How can you update the region to exclude certain jobs?

    Reload the page with the value of P39_JOB already set will not affect the result, while including a literal string made.

    It seems maybe ODCI function analyzes the query on Lees null, and then fills with actual results.

    Does anyone have any suggestions?

    Update: it seems a workaround is to inject the value as a substitution string, for example:

    and employment as ' & P39_CEO. »

    where P39_CEO is lacking in session state %

    I've only had this concept works in my client application (4.2, 11 2 GR), not my demo (5.0, 12 c), to even try to meet the relevant quotes and when null. I kept getting

    error report: ORA-1403: no data found

    I could not work how to correctly apply sys.dbms_assert.enquote_literal)

    Scott

    Hi Scott

    What approach I described in this post: matrix report?

    It eliminates the need for any dynamic SQL and I think filtering options might be implemented using SQL/XML features.

  • Addition of days for the column date of OBIEE

    Hi gurus,

    I have a date column, date alert and based on this column, I need to create another column to date, due date. The formula will be like,
    Due date alert = date + 30 days. I found a function, TimeStampAdd when you change the column formula but not sure how to use it. Pls help me to implement this.

    Thanks in advance.

    TIMESTAMPADD(SQL_TSI_DAY,30,alertdate)

    TIMESTAMPADD (interval, intExpr, timestamp)

    e.g:TIMESTAMPADD (SQL_TSI_DAY, 3, TIMESTAMP'2000-02-27 14:30:00 ')

  • How to view graphical waveform Excel data

    I have a file .csv with 4 data column.  I found something for another thread that allows me to display data from an Excel file in a table.  I have a problem with the following:

    (1) I need to display column data 4 but I can't seem to find a way to add other elements to the Invoke node so I'm stuck with power display only 2 columns of data.

    (2) why can't take my output and put it in a table, and then view it on a waveform graph?

    Please take a look at the attached VI.  I took notes in the block diagram.  When I try to join the Excel data to a chart, it indicates that the source type is a string, while the sink type is double.  How can this be when the Excel file has only whole?

    Help, please.

    Thank you.


Maybe you are looking for