I would like to delete the columns

Hello
with dummy as ( select 2526 Column1, 1 Column2, 2 Column3, 3 Column4 from dual union all
                        select 2526 Column1, 4 Column2, 5 Column3, 6 Column4 from dual union all
                        select 4711 Column1, 1 Column2, 1 Column3, 3 Column4 from dual union all
                        select 4711 Column1, 3 Column2, 2 Column3, 1 Column4 from dual)
select * from dummy
/

   COLUMN1    COLUMN2    COLUMN3    COLUMN4
---------- ---------- ---------- ----------
      2526          1          2          3
      2526          4          5          6
      4711          1          1          3
      4711          3          2          1
I would like to have the following result.
   COLUMN1    COLUMN2    COLUMN3    COLUMN4
---------- ---------- ---------- ----------
      2526          1          2          3
      2526          
      4711          1          1          3
      4711          
Does anyone have an idea?

Try this,

WITH dummy AS ( SELECT 2526 Column1, 1 Column2, 2 Column3, 3 Column4 FROM dual UNION ALL
                        SELECT 2526 Column1, 4 Column2, 5 Column3, 6 Column4 FROM dual UNION ALL
                        SELECT 4711 Column1, 1 Column2, 1 Column3, 3 Column4 FROM dual UNION ALL
                        SELECT 4711 Column1, 3 Column2, 2 Column3, 1 Column4 FROM dual)
SELECT column1,
       DECODE (rn, 1, column2) column2,
       DECODE (rn, 1, column3) column3,
       DECODE (rn, 1, column4) column4
  FROM (SELECT d.*, ROW_NUMBER () OVER (PARTITION BY column1 ORDER BY column2) rn
          FROM dummy d)

OUTPUT
-------------

   COLUMN1    COLUMN2    COLUMN3    COLUMN4
---------- ---------- ---------- ----------
      2526          1          2          3
      2526
      4711          1          1          3
      4711

SQL> 

G.

Tags: Database

Similar Questions

  • I have a dualboot (VISTA & XP) in different partitions. I would like to delete the XP partition and stay with Vista.

    I have a dualboot (VISTA & XP) in different partitions. I would like to delete the XP partition and stay with Vista.

    What are the steps to do this?

    Apparently, you have already removed XP, depending on your other Thread.

    http://social.answers.Microsoft.com/forums/en-us/VistaInstall/thread/ed84bf59-1078-42f6-8294-d88cf4f7a9f5

    Answered in another Thread on how to fix the Vista operating system.

    Mick Murphy - Microsoft partner

  • I would like to delete the new window 10, I'll be happy to have my window 7 back.

    Original title: return to old

    I would like to delete the new window 10 on my laptop. Once I did the research where and how, there no trace I can restored back. Also, most of the new system running on 8 GB of RAM and I use 6 GB Rams; and I think that it bogged my system
    I'm operating system of game which is 5 years old. All the previous function jets which has been programmed in, volume, keyboard backlight and brightness screen that all control no longer work and I search by manufacturers where nothing was mentioned.
    My DVD player is broken and I can't use the drive with my product key.
    Any suggestion on solving this problem. I'll be happy to have my window 7 return or upgrade my portable computer time for a new game system with window 10.

    If you upgraded to Windows 7, see:

    How to: restore to a previous version of Windows for Windows 10

    If 10 Windows is preinstalled, see:

    How Downgrade Windows preinstalled 10 for Windows 7/8.1

    4 GB of RAM is more than sufficient to run Windows 10 for everyday computing. I don't think that RAM is the issue. You can update your drivers and applications:

    After you have installed Windows 10

  • I have a user who no longer works for the company.  Someone took his place, the same computer.  She used the same account as the former user.  I would like to delete the old user and assign the new.  It will lose something if I do this?  I shouldn't

    I have a user who no longer works for the company.  Someone took his place, the same computer.  She used the same account as the former user.  I would like to delete the old user and assign the new.  It will lose something if I do this?  I wouldn't reinstall anything, right?

    Hi Greg,.

    You won't lose any application on the computer.

    You can remove a user from the license and assign it to another user according to the help below document:

    Using creative cloud | Manage your creative cloud to the membership of the teams

    Kind regards

    Sheena

  • Satellite P855 and Win8 - would like to delete the recovery partition

    In fact, I would like to remove the recovery on my new P855 Satellite partition using diskpart. Now I have some problems/uncertainty (of course I have already created the recovery DVDs):

    1: when I look in Disk Management on my Windows 8, there are 2 recovery partitions! a small beginning of the disc (450 MB), a bigger at the end of the disc (8,66 GB). I'm a little confused about this. There is not usually a single recovery partition? Are - this two recovery partitions from toshiba for windows 8?

    2: I read somewhere that it can occure problems with the system by deleting the recovery partition. is there a risk if I delete the above two recovery partitions? (not to mention that I don't have the recovery of files on the hard drive more) May - so that it affects the stability or the ability of the system?

    As I don't want to take the risk, I crash my system, I hope that someone knows about it!

    Thank you guys

    see you soon
    kDar

    And why you want to delete the recovery partition?
    Its best to leave it as it is in case, you want to retrieve the computer laptop back to factory settings.

    > 1: Whe I look in Disk Management on my Windows 8, there are 2 recovery partitions! a small beginning of the disc (450 MB), a bigger at the end of the disc (8,66 GB). I'm a little confused about this. There is not usually a single recovery partition? Are - this two recovery partitions from toshiba for windows 8?

    I guess that one was created by Win 8. It contains the files to fix the system in case something would be a mistake of the last partition seems to be Toshiba that contains the recovery image files.

    > 2: I read somewhere that it can occure problems with the system by deleting the recovery partition. is there a risk if I delete the above two recovery partitions? (not to mention that I don't have the recovery of files on the hard drive more) May - so that it affects the stability or the ability of the system?

    Deletion of partition of Toshiba should not (usually) affects the ability of the system to the laptop, but nevertheless, you must create a recovery disk before you remove anything on the HARD drive.
    The recovery disc will return to the factory settings in case, that the system could be confused to the top.

  • I have Windows XP Home Edition and Windows XP Professional on my computer. I would like to delete the XP Home.

    I have Windows XP Home and XP Professional on my computer at home. It creates a nuisance for me and almost every time I restart the computer I need to boot from the CD of XP Professional. I would like to reformat the drive and install only XP Professional only. How do I do that?

    I have already backed up some files I have so I have nothing to lose except the two BONES being problematic nuisance

    You will need the installation CD. Insert the CD in the drive. Turn on the computer and look at the bottom or top for orders of F. If you have an order for the Boot Manager (usually F12) then keep hitting at the time wherever you turn on the computer. Select the option of CD drive to boot from the CD.

    Note: If you do not have a Boot Manager option then you will need to go into your BIOS, sometimes called Setup (key F2 usually). You can get the boot option and change the boot priority. You do not want to move the CD player to the first on this list. Save and restart.

    Follow the instructions and when you get to the screen that talks about partitioning, remove the partitions selected with the D key (it will erase all data on a disk (s)). Format using NTFS on the screen following and all simply continue with the installation after that.

  • I would like to delete the files from recovery

    Hello

    Until I take my computer to get fixed, I did a complete backup of my files, etc.  Because the computer has not crashed as I thought it might, I needed only to recover the portion of the music from my backup.  I ran the restore files and the computer restored a full copy of my hard c drive.  It takes a majority of space on my hard drive and I would like to know if I can delete these files.  They are stored on c: / / System Recovery / and then two cases: c - what is a complete copy of my c drive and the music that is a copy of my music files.

    Thank you

    Hello

    Yes, you can delete the files that you find is not necessary in this case. Make sure that you back up the files you need to another location so that you can use them later if necessary.

    Backup and restore: frequently asked questions
    http://Windows.Microsoft.com/en-us/Windows-Vista/back-up-and-restore-frequently-asked-questions

    Concerning
    Anthony.

  • I would like to remove the account from creative cloud, but I can't. How can I do?

    I would like to remove the account from creative cloud, but I can't. How can I do?

    Hi Cecilias82225568,

    Please help us to better understand.

    You want to remove the creative cloud of your machine?

    https://helpx.Adobe.com/creative-cloud/KB/CC-cleaner-tool-installation-problems.html

    You want to delete your Adobe ID?

    Get in touch with adobe support:

    Pricing plans and creative Cloud membership | Adobe Creative Cloud

    * Be sure to stay connected with your Adobe ID before accessing the link above *.

  • I would like to delete my account

    I would like to delete my account

    Hello

    In order to cancel the order, please contact customer service

    You can check: http://helpx.adobe.com/x-productkb/global/phone-support-orders.html

    For more information on cancellation: cancel your creative cloud membership

  • I would like to delete a short gray border of two images. I need help because I'm still not able to use PhotoShop. Could someone kindly help me with this?

    I would like to delete a short gray border of two images. I need help because I'm still not able to use PhotoShop. Could someone kindly help me with this?

    In order to change a part of an image as needed here, I would use the "Liquify" filter See below, it is quite easy. You just move the lower lip to be more elegant and not like the guys are salivating.

  • I would like to delete you my account as soon as possible

    I would like to delete you my account as soon as possible

    John,

    May 8 we have always offered the 50 post a month plan, so that the e-mail has been delivered properly. I'm surprised that you don't have an email next week, announcing the changes. Have you checked your spam folder? That's what said email:

    In a few weeks, the free accounts of Revel will come with 2 GB of cloud storage instead of the current limit of 50 photos/videos per month. This is great news because it means that you will be able to store and share around 1000 photos with friends and family without worrying about a monthly limit.

    Otherwise, Revel will be the same service that you know and love. If you have questions about this change, click on the link below to learn more. You can also post a question in our customer support forums and a team member will help you.

  • I WOULD LIKE TO DELETE MY ACCOUNT OR SOLVE THIS PROBLEM PLEASE SEE THIS

    VERY URGENT (MY EMAIL IS A LOT OF THESE QUESTIONS

    This is for administrators

    I get many of THEM from your forum site:

    aemme,

    You look at the category "Management system and integration", which was last updated November 11, 2010 04:32:18 by Lichti:

    < http://forums.oracle.com/forums/category.jspa?categoryID=201 >
    or
    <Data Integrator
    or
    <User use Oracle DB function

    For your comfort, the new message is included below:

    I would like to delete my account or solve the problem in another way, as you want.

    I can't delete my accountr for the Control Panel, I do not know how to do it.


    Help, please

    go to your control panel and settings and change the settings of your watches, so that never look you son you create or reply to.

    Or you can choose to receive once a week.

    There is no current ability to not receive emails watch

  • I would like to remove the arrows when scrolling to the bottom of a search page.

    When I do a search in firefox and you present results to get an arrow that I scroll the page down and he jumps a few lines. I would like to remove the arrows and the page myself.

    Are you scroll with the mouse, the scroll bar or with the keyboard?

    I cannot portray the arrow you see. Would it not possible to display a screenshot? If changing the mouse pointer, the screenshot probably include that, but if it is an element of the page, then it should.

    This article has tips on the screenshots. Please remove personal/confidential information before posting (you can attach an image to an answer).

    How to make a screenshot of my problem?

    Not sure it's relevant, but Firefox has a feature of accessibility called the keyboard navigation that moves the cursor in the document. You can disable this option in the Preferences dialog box. Please see this article for more information: Advanced panel - accessibility, navigation, network, updates and other settings in advanced Firefox (it's the first item in the mini general tab, "always use the cursor keys to navigate within pages").

  • I would like to change the name on my devices!

    I would like to change the name associated with my, Pc, Ipod and Ipad.

    Doc54rs wrote:

    I would like to change the name associated with my, Pc, Ipod and Ipad.

    Settings > general > topic > name (you can type the name and change it here)

    Regarding the question of changing the name of your PC, which would be a matter for Windows.

  • I would like to disable the download only history

    Hello

    I would like to disable the download only history, I tried the option 'clear history when firefox closes' check the download only history, but it did not work. the download window is clear, but it's all there in the download history.
    is there a way to disable the download only, history without touching the others intact?

    Thank you
    Rgds
    JP

    The download history is stored as part of the normal history (visited sites/links) and a special annotation identifies it as a download item in the history.

    If you can not separate the two more.

    Note that the classic Download Manager stores its data in a different file, you will need to check both if you have set on remember downloads.

    You can set the browser.download.useToolkitUI pref Boolean true on the topic: config page to restore the old window Download Manager and check all the settings download appear in "tools > Options > general.

    The pref browser.download.manager.retention has no effect with the new download manager and is forced to manual (2).

Maybe you are looking for

  • September 5, 2009, lose of country information

    I've been reviewing Google analytic stats for some websites one manage. On all sites, I noticed that on September 5 there was a break in the traffic of visitors with no country together. Then, I started looking for answers online and found that other

  • Computer laptop flickering

    Hello colleagues HP forum visitors! Since last week, my laptop has been uninterrupted flickering from beginning to close down. The glitter is as a sort of contractions every 4 seconds approximately. They tend to be horizontal lines that occur near th

  • My router is actually secure?

    I'm wondering if what follows what I've done is the best possible, if there is any means possible to improve security: I have a WRT320N SSID: just let it spread. Delete this show will not improve the overal security. SSID will be shown even if you De

  • JSON format - Date and special characters

    Hi all I had a JSON server in which, I have a few text values and date. How can I convert special characters to normal String.e.g. Comma etc. ? How can I convert long date, a string in the format e.g. "1345670466960-0400"? I really appreciate any hel

  • Activate windows build

    Hi, recently I had windows build with BMPs, for whatever reason I disabled it, but now I can't activate windows build once again, how can I build for windows again?