can we use alias name in the case statement?

Select sal,

Sal case

When 500 then 'low '.

When 5000 can 'high '.

of another "medium".

cases of termination

EMP;

OUTPUT

case of SAL

-----   --------

4587 way

5000 high

.. .so I have worn instead of cases at the exit?

Yes. Contrary to the statements of CASE in PL/SQL, SQL CASE expressions like this ends with 'end', not 'end of case. Your use of the terminal 'deal' was just an alias the column as the 'CASES '.

select
  sal,
  case sal
    when 500 then 'low'
    when 5000 then 'high'
    else 'medium'
  end range
from
  emp;

Tags: Database

Similar Questions

  • Can I use my name on the account and CC my wife to Fact?

    Can I use my name on the account and CC my wife to Fact?

    N ° your name must match the credit card used.

    Since you are using his credit card, why not to use his name?

  • Required: a portable charger for an iPhone 4 that can be used in Germany and the United States

    Required: a portable charger for an iPhone 4 that can be used in Germany and the United States

    Does anyone have recommendations?

    The original charger is International, all you need is a converter of pin code.

  • Can we use Chargers MagSafe in the United States in India

    MagSafe charger the usa can be used in India. Do we need a separate voltage converter? Or just a socket converter is sufficient?

    Just the sleeve-end converter.  The block itself automatically detects voltage.

  • Can we use repository variables in the SQL statement of the guest of the column?

    Hi guys,.
    This is the query
    SELECT '-End Date '. " End year"OF"The consumer sector"WHERE ("-End Date "." ") End of year' = valueof (current_year)) or ("-End Date". "") (Year-end' = valueof (current_year) - 1).
    When you use this sql prompt of criteria being of error.
    Please suggest.

    Thanks.Sri

    Appreciate if you score as correct on the suggestion

    Also your old messages, at least let us know your comments ;)

  • in Outlook Express, how can I send the same message to a group important (in the address book already), but have to each recipient can only see his name (not the Group)

    In Outlook Express, how can I send the same message to the large group (already in the address book), but have to each recipient can only see his name (not the Group)?

    To use the functionality of the BCC (Blind Carbon Copy), in a new message window, click View | All headers and type the addresses separated by a; Or: Click the button to. You will see your list of contacts and the choice to put them in the To, CC, or BCC field. Click on an address, and then click BCC to add it. Repeat for all of the contacts you want. (Note: most of the providers have limits as to how many messages you can send both a. 25 is common, but it varies).

    Put your own address in the box to. That's the only name/address that any recipient will see. If you leave the field empty, some people may not receive e-mail because of message rules they put in place, or restrictions imposed by their ISP.

    You can also make an entry in the address book using your e-mail address, but put something like the mailing list in the area of the display.

    *********************

    You can also create groups if you send e-mail to the same people often.

    To create a group of contacts:

    You can create a single group name (or alias) to use when sending a message to several contacts at the same time. Just create a group name and add individual contacts to the group. Then just type the name of the group in the box for when you send mail.

    1. in the address book, select the folder in which you want to create a group. Click New in the toolbar, and then click New Group.
    2. the Properties dialog box opens. In the group name box, type the name of the group.
    3. There are several ways to add people to the Group:
    a. to add a person from your address book list, click Select members, and then click a name in the address book list.
    (b) to add a person directly to the group without adding the name to your address book, type the person's name and e-mail address at the bottom of the Properties dialog box and then click Add.
    to add a person to both the Group and your address book, click New Contact and enter the appropriate information.
    (d) to use a directory service, click Select members, and then click search. Select a directory service in the drop-down list at the end of the text box. After finding and selecting an address, it is automatically added to your address book.
    4. Repeat for each addition until your group is defined.

    Note

    a. to view a list of your groups separately from the list of address book in the address book on the view menu, make sure that folders and groups is selected.
     
    b. you can create multiple groups, and contacts can belong to several groups.

    If you want to send to a group without addresses are displayed for each recipient, open the address book and make a new entry. Enter the name of the group in the area of the display, but use your address. (Some Internet service providers require a legitimate address in the line to and recipients will know it's from the Group).

    Click on the button to. Enter the name of the group using your address. Enter the group in the BCC field.

  • Can I use automator to change the modified time of a file as its content?

    I use automator to rename a series of images.

    The problem is whenever I change a change of time of amending records file.

    Can I use automator to change the modified time of a file as its content?

    I know that I can use the Terminal to change a date but I have no idea how to do to automate this process

    As you say you know the command to use in the Terminal, and then with Automator, use the Action run the Shell Script after the name change.  The new file name will be passed to the Action run a Shell Script, and from there, you can use touch - r to set the time of the file at the time the name of the new file

  • I can't use windows Explorer or the network drive mapping to access my NAS drive more.

    original title: strange NAS problem

    Hi everyone I can't seem to fix this strange problem.

    I can't use windows Explorer or the network drive mapping to access my NAS drive more.
    I am running windows 7 Professional 32-bit on my PC, and until about a week ago she accessed from my PC very well.

    The location could not be reached and have not been able to run since said today that I went to update it and the drive mapped. I'm at my wits end.

    Here is some info.

    I can access to other computers and devices on my network.

    I can access the internet.
    I have a windows XP PC in the House who can always connect to my fine NAS drive (even if it's not mine).
    I PING the NAS drive.
    The NAS drive will do the same if connected via cable or by wireless.

    UPDATE: after the implementation of a shared folder on a Windows XP computer on the same network I am also unable to acsess the part of my PC. So I can assume that I can't browse all share folders or NAS drives on my local network.

    Help, please.

    Thanks for the help, but I fixed my problem

    Here's what I did in case anyone wants to know.

    I went into Device Manager and went to network adapters.
    I then expanded this section and under view changed to display hidden items.
    Several hundred elements appears (for most 6to4 adapters) and I deleted all the.
    Then click scan for new hardware.
    And... everything works again! YAY!

  • How can I put my name at the bottom of my outgoing mail?

    Original title: Hot Mail

    How can I put my name at the bottom of my outgoing mail without entering each time?

    Hi Lance,.

    Are you facing issue while using the account Hotmail on Mail app?

    You must change the options to add outgoing signature is automatically sends in the settings of the program by e-mail.

    If you use the Mail application in Windows 8, you can see the article to change the settings for Mail app to use email signatures.

    Settings that apply to all accounts

    If you try to edit while using Hotmail like webmail, you must change the parameters into account Hotmail itself.

    You can check the thread and check:

    How can I add an AutoSignature to a Hotmail address?

    You must post your query in the Forums Windows Live itself.

    Windows Essentials Forums

    Hope the helps of information. Let us know if you need help with Windows related issues. We will be happy to help you.

  • can we use different SID at the adcfgclone on dbTier

    Hello

    I want to know if adcfgclone on dbTier and appsTier can we use different SID at the adcfgclone?

    Suppose that my production is PROD and I want to keep the target as a TEST so I use the SID with a different name? or is it necessary to use the same SID as the source environment?

    Thank you.

    Of course, you can!

    You can change the SID, the location of database files, etc..

    Kind regards

    Bashar

  • How can I use a video for the preview looks like instead of the fixed image?

    How can I use a video for the preview looks like instead of the fixed image? I use android lollipop.

    Hi Ali,

    Video preview for looks is not currently supported on Android. Your feature request was noted by the team.

    In the meantime, there is a video on the device you want to use as an overview, I would recommend taking a perforated CAP and still image as loading preview.

    Best,

    Bronwyn

  • using the case statement


    Hello

    How can I convert a code for the below sql case statement:

    If)

    (length of (tmp_co_orig_val) < = 0 OR tmp_co_orig_val < = 0 OR tmp_co_orig_val == 1 OR tmp_co_orig_val > = 9999999)

    OR

    ((tmp_co_orig_val == 999999 AND (length of (tmp_rcr_orgn_ltv_rt) < = 0 OR tmp_rcr_orgn_ltv_rt < tmp_rcr_orgn_ltv_rt > 1.3 GOLD 0.15)))

    Start

    tmp_collatvalue = «»

    tmp_msg_cd = 115

    end

    Is the case statement below that I wrote is correct. I don't have an environment now to test.  Please advice.

    BOX WHEN (CHAR_LENGTH (tmp_co_orig_val) < = 0 OR tmp_co_orig_val < 0 OR tmp_co_orig_val = 1 OR tmp_co_orig_val = > = 9999999)

    OR (tmp_co_orig_val = 999999 AND (CHAR_LENGTH (tmp_rcr_orgn_ltv_rt) < = 0 OR tmp_rcr_orgn_ltv_rt < tmp_rcr_orgn_ltv_rt > 1.3 GOLD 0.15))

    THEN tmp_collatvalue IS NULL AND tmp_msg_cd = 115

    END

    Hello

    937454 wrote:

    Thanks Frank. Really helps. But I have to write a sql statement

    But can you also specify, if I made a mistake in my code, or it's ok.

    There are no CASES reported in Oracle SQL.

    Oracle SQL has BOX expressions, but they only return a single value.  You cannot set 2 columns in the same expression BOX.

    Perhaps the best thing to do in pure SQL for you is to write a CASE expression, very similar to the CASE statement above, in a subquery and use the results of this in 2 separate expressions of BOX (very simple) in a Super application.

  • can I use ipencil to paint the pictures on ipadpro?

    can I use ipencil to paint the pictures on ipadpro?

    If you have an application that supports it, of course.

  • Can I use my iPhone for the load

    Can I use my iPhone for the load?

    Yes

  • How can I remove my name from the top right of the screen. I have a 2015 13 "MacBook Pro running 10.11.4

    How can I remove my name from the top right of the screen. I have a 2015 13 "MacBook Pro running 10.11.4

    At the top right of the menu bar shows the current user who is logged in and allows quick change of user accounts.

    You can disable the display of menu bar in system preferences > users and groups. Or order just drag it out of the bar.

Maybe you are looking for

  • hp officejet pro 8600 premium

    Hp officejet pro 8600 premium allows to print without the lower plate? I want to buy the premium because of the extra ink & OCR software, but the additional target makes the printer higher than I can use.

  • Need help to organize Excel files with several data

    Hello everyone! I'm working on a project consisting of a full acquisition system. I have great finisheda part of my program and now my guardian's ask me something else. In you project I have several datas: Move, force, speed, time,... And he would li

  • Save the files to an e-mail account e-mail, you intend to close

    How records of yousave full of historical emails to documents or office or thumb drive

  • Inability to access the network home "You are not allowed..." »

    On my home network as well with Win 7, my desktop pc can see and access the shared files on the laptop.  On the laptop, the shared files are visible, but when the "shared desktop" is clicked on the message says "Windows cannot access \ yadayda.» You

  • Creative cloud update failed - no error message

    Started about 01:00 it not start 03:30 by selecting just update. Asked for the password, started the download, disappeared and looking at my iMac Activity Monitor, it says the installer creative cloud (no response). Once again. I think I restarted as