Help: How to use the Case statement in the ODI11g Interface?

Hello
My basic source I get 'Year' values and I want that these values result code in the interface and after translation want to push on the target system.
Example:
Database source, I get value for
Year
2010
2011
2012

When I get the year 2010 I want to change the value in "FY10".
When I get year 2011 I want to change the value in "FY11.
and even for the year 2012 to "FY12.
I've tried to make the Case statement, but had no success.
I don't want to create the lookup table in the source system.
Any help in this matter.

Thank you

Concerning
Sher

Published by: Sher Ullah Baig on August 26, 2012 17:52

CASE
WHEN source_column = '2010' THEN 'FY10.
WHEN source_column = '2011' and THEN 'FY11.
WHEN source_column = '2012' and THEN 'FY12.
END

Tags: Business Intelligence

Similar Questions

  • How to use a "Case" statement in the negative

    I am pulling data in the form:

    SELECT
    group_num,
    co_id,
    pr_id,
    Co_id CASE
    WHEN '5N' THEN ON 'YES '.
    WHEN NOT '5N' THEN 'NO '.
    END AS prod_type
    FROM table1

    I want to get a 'YES' result when co_id is '5N' and all co_id who are not '5N' a value of 'NO '...

    I get an error "Missing Expression" and its pointing to the line 'IS NOT', so I obviously don't have the correct syntax.

    Any help would be appreciated...

    Published by: user12296489 on November 10, 2010 11:22

    Hello

    You're right: CASE can't compare NULL in the same way, it compares the values. My mistake.

    I think that the searched CASE expression is what is needed here:

    CASE
        WHEN  co_id  = '5N'  THEN 'YES'
        WHEN  co_id != '5N'  THEN 'NO'
    END   AS prod_type
    

    If co_id is NULL, it returns null.

  • using the function - how to use the values of the input variables on the table select statement names

    Hello community, I have a problem when creating a function. The purpose of this function is to check the table of weather gave yesterday or not. We must check this on different tables on different sachems. We are creating a function with input variables.

    CREATE OR REPLACE FUNCTION IN_SCHEMA.IS_YDAYDATA_TO_TABLE

    (

    in_schema IN VARCHAR2,

    in_tablename IN VARCHAR2,

    in_datefield IN VARCHAR2,

    )

    RETURNS INTEGER

    AS

    -Declaring variables

    v_is_true INTEGER.

    BEGIN

    SELECT

    CASE

    WHEN MAX (in_datefield) = TRUNC(SYSDATE-1)

    THEN 1

    ON THE OTHER

    0

    END

    IN

    v_is_true

    Of

    in_schema.in_tablename

    ;

    RETURN v_is_true;

    END;

    /

    When creating, I got error: [error] ORA-00942 (44:19): PL/SQL: ORA-00942: table or view does not exist

    How to use the values of the input variables on the table select statement names?

    Hello

    Here's a way you can use dynamic SQL statements for this task:

    CREATE OR REPLACE FUNCTION IS_YDAYDATA_TO_TABLE

    (

    in_schema IN VARCHAR2,

    in_tablename IN VARCHAR2,

    in_datefield IN VARCHAR2,

    in_first_date DATE DEFAULT SYSDATE - 1,.

    in_last_date DATE by DEFAULT NULL

    )

    RETURNS INTEGER

    AS

    -IS_YDAYDATA_TO_TABLE returns 1 if in_schema.in_tablename.in_datefield

    -contains all the dates in the in_first_date of the range through included in_last_date

    - and it returns 0 if there is no such lines.

    -If in_last_date is omitted, the search only the data on in_first_date.

    -If in_first_date is omitted, it defaults to yesterday.

    -Time parts of the in_first_date and in_last_date are ignored.

    -Declaring variables

    sql_txt VARCHAR2 (1000);

    v_is_true INTEGER.

    BEGIN

    sql_txt: = 'SELECT COUNT (*).

    || 'FROM ' | in_schema | '.' || in_tablename

    || 'WHERE ' | in_datefield | ' > =: d1'

    || «AND» | in_datefield | '< >

    || 'AND ROWNUM = 1';

    dbms_output.put_line (sql_txt |) '= sql_txt in IS_YDAYDATA_TO_TABLE");  -For debugging

    Sql_txt EXECUTE IMMEDIATE

    IN v_is_true

    With the HELP of TRUNC (in_first_date) - d1

    TRUNC (NVL (in_last_date

    in_first_date

    )

    ) + 1                -- d2

    ;

    RETURN v_is_true;

    END is_ydaydata_to_table;

    /

    DISPLAY ERRORS

    If you must use dynamic SQL statements, put all the SQL statement in a single string variable, such as sql_txt in the example above.  In this way, you can easily see exactly what will be executed.  Comment out the call to dbms_output under test is completed.

    Try to write functions that will address not only the question that you have now, but similar questions that you may have in the future.  For example, now that interest you only to the verification of the data of yesterday, but later, you might want to check another day or range of days.  The above function combines the convenience of a function simple (looks like yesterday data if you don't tell him otherwise) with the power of a more complex function (you can use the same function to check any day or range of days).

  • No links to the local area network connection. But how to use the Internet again, please help establish a LAN connection.

    Original title: no local network connection

    No links to the local area network connection. But how to use the Internet again, please help establish a LAN connection.

    Hi H.mustafaakyurek,

    ·         What operating system is installed on your computer?

    You can view the following items on the creation of a network connection:

    Setting up a network home

    http://Windows.Microsoft.com/en-us/Windows7/setting-up-a-home-network

     

    Start here to set up a home network in Windows 7

    http://Windows.Microsoft.com/en-us/Windows7/start-here-to-set-up-a-home-network-in-Windows-7

     

    Setting up a wireless network

    http://Windows.Microsoft.com/en-us/Windows7/setting-up-a-wireless-network

    Also see the following articles on the connection of an Internet connection:

    What do I need to connect to the Internet?

    http://Windows.Microsoft.com/en-us/Windows7/what-do-I-need-to-connect-to-the-Internet

     

    Allows to connect to the Internet mobile broadband

    http://Windows.Microsoft.com/en-us/Windows7/use-mobile-broadband-to-connect-to-the-Internet

    Hope this information helps.

  • Help... How to use the recovery on Pavilion g4 2014tx partition

    Hi all... Would like to ask how to use the recovery partition and what is the effect if I used it... ?

    Thank you...

    Hello:

    You normally start the PC, and at the beginning of the HP welcome screen, you press the F11 key to start the Recovery Manager program.

    Then follow the instructions to restore your PC to its state of software "out of the box.

    In so doing you re-partition and reformat the hard drive.

    All THE data you have on the PC will be lost.

    So make sure that you copy the files that you want to keep on a portable hard drive before proceeding.

    It is also for if you have created a storage partition. You must copy all the files from that too.

    All partitions are erased and redone.

  • I have a purchased copy of PhotoShop Elements 9.  When I run it now I get an error message - error: 213:19.  What does that mean?  How to use the software I paid?  Thanks a lot for your help!

    I have a purchased copy of PhotoShop Elements 9.  When I run it now I get an error message - error: 213:19.  What does that mean?  How to use the software I paid?  Thanks a lot for your help!

    See here:

    In Photoshop Elements license error

  • Need help on how to use the conference room in adobe connect

    I need help on how to use the conference room in adobe connect?

    I would recommend you start here: Getting Started with Adobe Connect - Adobe Connect user community

  • How to use the Type of Oracle Table values in the Select statement.

    Hello

    I get the initial set of values in the Table of Type Records of the Oracle and want to use the list of values in the Select statement.

    For example, try something like the following:

    TYPE t_record () IS RENDERING
    ID TABLEA.ID%type,
    NO TABLEA.NO%type

    );
    v_record t_record;
    T_table TYPE IS the v_record TABLE % TYPE;
    v_table t_table;

    -Code to fill the values of v_table here.

    SELECT ID, NO, COLLECT in BULK IN < some other table variabes here > FROM TABLEA
    WHERE ID IN (i) v_table USER.USER;

    I want to know how to use the Type of Oracle Table values in the Select statement.

    Something like this:

    create or replace type t_record as  object (
    id number,
    no number
    )
    /
    
    CREATE or replace type t_table AS TABLE OF t_record;
    /
    
    set serveroutput on
    declare
    
      v_table t_table := t_table();
      v_t1 t_table := t_table();
    
    begin
    
      v_table.extend(1);
      v_table(1).ID := 1;
      v_table(1).No := 10;
    
      v_table.extend(1);
      v_table(2).ID := 2;
      v_table(2).ID := 20;
    
      SELEC t_record (ID,NO) BULK COLLECT INTO v_t1
      from TableA
      FROM TABLEA
      WHERE ID IN (select t.ID from table(v_Table) t);
    
      for i in 1..v_t1.count loop
        dbms_output.put_line(v_t1(i).ID);
        dbms_output.put_line(v_t1(i).No);
      end loop;
    end;
    /
    

    No test!

    P;

    Published by: bluefrog on March 5, 2010 17:08

  • I'm not clear how to use the recovery CD

    I added all the space using my HDD is it comes about 12 GB, I have 27.9 GB of disk space, but my drive has only 1.80 left disk space. I made clear to solve this problem. Basket is empty, I ran disk cleanup.

    A computer expert suggested that Windows might have become confused and cannot recognize what place I save, it might be because I ran a program called Cyberscrub often. His solution is to reload Windows XP home. My laptop came with recovery discs, everything else is already loaded. I have so much I don't want to lose on my laptop. If I use the recovery discs, I will lose everything on my computer, am I better off buying Windows XP home and re-load, in which case I will not lose my job?

    Also I am not clear how to use the recovery discs, I can't find instructions on what you are doing.
    The only person who could help me went to travel and not reachable.
    Any help greatly appreciated
    Lorraine Hart

    It of a very simple to recover the laptop.
    Just boot from the recovery CD and follow the instructions on-screen ;)

    I put t know what version recovery CD you have, but the older one provides the standard and expert mode. In expert mode, you can choose you partition where the OS is to be installed.
    So in this case only the selected partition will be formatted!

    But have you checked the size of the HARD disk in disk management?
    Simply click on the my icon my computer and choose manage.

    Of course, you could remove the internal HARD disk and it could connect to the external USB HDD controller. Then, connect the drive HARD to the second PC and you record data on another HARD drive.

  • Liquid Z 3 How to use the small screen-receving-phone-call?

    Hello

    I would like to know how to use the small screen that appear in a case to receive a phone call.

    There are two types of screen wen we receive a phone call. I know how to use a larger. But not for the little ones. Aid for the small indicates that we have to drag the green phone symbol that I guess, but to fall on what? The manual doesn't explain it at all, it is not obvious!

    Thank you very much for your help!

    With "appellant float" activated, simply to press the Red or green button, no need to call, if the "small screen" is that of the attachment

  • I am runing vista and do not know how to use the fax machine

    I am runing vista and do not know how to use the fax machine

    Here's how to set up Windows Fax and Scan: http://windows.microsoft.com/en-us/windows-vista/Set-up-your-computer-to-send-and-receive-faxes.  Navigate the reference links on the right for more information on how to send faxes and other information.  If you do this on every page you just, you can see all the articles on how to fax and scan and configure the system and solve problems, and many other subjects that may be necessary, useful or informative.  After that, you must be an expert on this subject.

    Here is a quick and easy way to send a fax in Vista: http://www.ehow.com/how_2029566_send-fax-vista.html.

    Unfortunately, the foregoing is available in Business, Enterprise, and Ultimate - not Basic or Home Premium.  In the latter, you need a 3rd party program.  If this is the case, here are some options:

    With the compliments of Bob F. http://www.vistax64.com/vista-print-fax-scan/127986-how-do-i-download-windows-fax-scan.html:

    Not available in Vista Home Premium Basic FAX. It is available in complete edition,
    Extreme and business.

    You might want to consider Snappy Fax at a low cost:
    http://www.snappysoftware.com/

    or the free version of BVRP:
    http://www.usr.com/BVRP/bvrp.asp

    or a full BVRP Classic Phone Tools 9: $29.90
    http://www.shop.Avanquest.com/USA/PR...S_CPT_homepage

    Look screen kinda gross but the product Snappy fax
    actually, is quite rich in features and works very well. BVRP also works very well,
    screen looks a bit better. Other that that, there are minor differences
    performance between the two.

    I hope this helps.

    Good luck!

    Lorien - MCSA/MCSE/network + / has + - if this post solves your problem, please click the 'Mark as answer' or 'Useful' button at the top of this message. Marking a post as answer, or relatively useful, you help others find the answer more quickly.

  • How to use the camera application

    original title: using the camera application

    According to me, that there is a photo on Metro Screen App.  Is there a documentation or a tutorial on how to use it and what it is for?

    When I click it, I see three small icons in the bottom right...  Camera, Timer and video options.  I don't know what to do with them.

    I see me, looking me in the opposite direction, that seems odd.  I found a folder in my pictures, to my surprise, with pictures of me and two videos! I think that pictures should occur when I click on the screen, but I have no idea how I created a video or how to do it again.

    This looks like a fun app but I need help to use.  I couldn't find anything in the help files.

    Any help would be greatly appreciated.

    MaryLou

    Note: I probably don't not select the category of app so if not, please move this where it needs to go.

    Dena, regardless on the computer because it is an external Kodak camera.  I know how to use the camera itself, but the camera application that appears on the screen of metro is NOT just easy to use.  It shows 3 small icons, one is a timer, the other is for the videos and I forgot what the other one was for.

    In any case, I finally thought to it.  To use the camera, you click on it, then you must click on the screen to start the camera going.   I'm not sure that the timer is for, but again, once you click on the timer icon, you click on the screen to start the timer.

    My camera screen is not screen mode have won 8 metro.  The camera works fine via desktop applications.  I have it working in the version of Win 8 of Skype as well.

    I like to win 8 but it is so lacking in the documentation that it is difficult to learn to use the new ways of doing.

    Thanks for the reply but as I said... has been resolved.

  • After replacing the motherboard of PC how can use the license package, is the same hard drive.

    Mr President, our pc is repaired & change the motherboard and now how to use the product under license of photoshop

    It could be cleaner if you uninstall the products in question, using the CS cleanup tool and then contact Adobe technical support via chat and ask to reset your activations before install and activate the software again.

    Adobe Creative Suite cleanup tool

    helps resolve installation for CS3 thru CS6 and creative cloud problems

    http://www.Adobe.com/support/contact/cscleanertool.html

    To the link below, click on the still need help? the option in the blue box below and choose the option to chat...

    Make sure that you are logged on the Adobe site, having cookies enabled, clearing your cookie cache.  If it fails to connect, try to use another browser.

    Serial number and activation support (non - CC) chat

    https://helpx.Adobe.com/contact.html?step=PHSP-PHXS_downloading-installing-setting-up_lice nsing-activation_stillNeedHelp

    Before you uninstall, you can see if you can extract the serial number in case you don't have it at hand.

    If it's a Windows machine, and then try running Belarc Advisor

    http://www.Belarc.com/free_download.html

    For a Mac, you can try:

    https://Mac-product-key-Finder.com/

  • Oracle: how to use the max() function in expression box

    How to use the max() function in the case where expression, please explain with an example

    Hope this helps and should be explicit

    with t as
    (select 1 col,100 col2 from dual union
    select 2 ,100 from dual union
    select 2 ,200 from dual union
    select 3,100  from dual union
    select 3,200  from dual  )
    select col, case when max(col2)=100 then 'with 100 range'
    when  max(col2)=200 then 'with 200 range' end  from t group by col
    
  • How to use an if statement of javascript code

    Hello

    I have a lot of script transformation to search for text "signature of the employee" on each page in a multiple page and file for then the list in the console all pages that do not have the text of the "Signature of the employee" included.

    The script is still functional as one if statement must be included.

    Can someone advise please how to use an if statement in javascript code?

    var this.numPages = NUMPAGES;
    for (var i = 0; i < numpages; i ++)

    Search.Query ("Signature of the employee", "ActiveDoc");
    Console.println ("Pages that do not include a signature of the employee:" + this.pageNum + "");

    Any help will be most appreciated.

    "The signature of the employee" are the 2 words and not one. The method that you use to get the word gets only a single word. You also want to identify the "not true" found for the situation of the page and not the "real" found on the page.

    var ckWords; pair of words to test
    var bFound = false; Logical state of the words found
    Browse through the pages
    for (var i = 0; i)< this.numpages;="" i++="" )="">
    bFound = false; all found false
    numWords = this.getPageNumWords (i); number of words on the page
    loop through the words on the page
    for (var j = 0; j)< numwords;="" j++)="">
    get the pair of words to test
    ckWords = this.getPageNthWord (i, j) + ' ' + this.getPageNthWord (i, j + 1); test words
    do a check to see if the pair of words is string "Signature of the employee.
    If (ckWord == 'Signature of the employee') {}
    bFound = true; indicate the logical value found
    Console.println ("Pages that includes a signature of the employee:" + (this.pageNum + 1) +' ' "");
    break; no need to test more to this page
    } / / end of Signature of the employee
    } / / end of Word loop
    a test to see if the words not found
    if(Bfound == false) {}
    Console.println ("Pages that do not include a signature of the employee:" + (this.pageNum + 1) +' ');
    } / / end not found on the page
    } / / end of page loop

Maybe you are looking for

  • Why machine did transfer spontaneously inbox the last 15 days in a folder named Archive / 2015?

    I got lucky that I could find where the machine had hidden messages the last 15 days.Am I punished for having too many messages in the box at, or what?

  • C315 Kodak printer-documents coming out blank

    I have problems with my printer. If I send a document to my Kodak C315 to print out blank? Moved from feedback Original title: printer problems

  • Unable to set the security type.

    Hi guys,. Recently, I reset my router and access 192.168.1.1. I put a different SSID that default "linksys" and then walked to the Wireless Security tab. When I try to choose the type of security so that I can enter a password, really fast page refre

  • I can't find my original question.

    Recently, I posted a question on the Site community but most watched checking the box that would allow me to be notified if someone replies to this post. The issue was the partitioning of a hard disk in W.7 and W.10. I have looked in my 'box', but ca

  • Bought a new computer

    Wife bought me a computer for my birthday, he had 8 installed windows I don't like not had the option of paying an additional amount of $140 for windows pro installed it turns out be a bad choice. I go to essential windows and to the low load, also a