Is it possible to exclude white space from creating records using UNPIVOT

SELECT
        FROM
            Table1
            UNPIVOT EXCLUDE NULLS
                NEW_COLUMN
                FOR COLUMN_NAME IN
                   FIELD1, field2, --------------FIELD20
            )I don't want to create row for whitespace (empty value) in any of field1-field20 columns. Row should create for each of value present in any of FIELD1-FIELD20. Is it possible to exclude white space from creating records using UNPIVOT? I am just looking for syntax if there any. thanks

Hi,
Sorry, it's very unclear what you want.
Whenever you have a question, please post a little sample data (CREATE TABLE and INSERT statements, relevant columns only) for all the tables involved, and the results you want from that data.
Explain, using specific examples, how you get those results from that data.
Always say what version of Oracle you're using (e.g. 11.2.0.2.0).
See the forum FAQ {message:id=9360002}
Have you tried the the UNPIVOT EXCLUDE NULLS option? See the SQL Language manual for details.
It that doesn't do what you want, then you may need to UNPIVOT in a sub-query, generating more rows than you want, and use a WHERE clause in the main query to remove the unwanted rows.

Similar Messages

  • How to remove white spaces from XML content using Coldfusion?

    Hi,
    Can anybody help me in removing white spaces in between the tags from the below XML content using coldfusion?
    XML content:
    <?xml version="1.0" encoding="UTF-8"?> <chart showdates="true" today="08/12/2009"> <phases> <phase color="CCFFCC" name="Funded"/> <phase color="CDCD67" name="Concept"/> <phase color="99CCFF" name="Feasibility"/> <phase color="0099FF" name="Development"/> <phase color="0099FF" name="Development"/> <phase color="CC99FF" name="Close-out"/> <phase color="909090" name="Sustaining"/> </phases><program name=""> <project enddate=" 30/03/2007 " id="43250" startdate=" 28/02/2006 "> <version enddate=" 30/03/2007 " number=" 1" startdate=" 28/02/2006 "> <phase color="CCFFCC" currentdate="23/03/2006" name="Project Start" plandate="28/02/2006" type="phase"/> <phase color="99CCFF" currentdate="04/04/2006" name="Feasibility Closure" plandate="31/05/2006" type="phase"/> <phase color="0099FF" currentdate="29/03/2007" name="Commercialization" plandate="30/12/2006" type="phase"/> <phase color="CC99FF" currentdate="30/03/2007" name="Project Closed" plandate="30/03/2007" type="phase"/> <phase color="909090" currentdate="" name="Obsolescence" plandate="" type="phase"/> </version> </project> </program> </chart>
    Output I am expecting is like below,
    <?xml version="1.0" encoding="UTF-8"?><chart showdates="true" today="08/12/2009"><phases><phase color="CCFFCC" name="Funded"/><phase color="CDCD67" name="Concept"/><phase color="99CCFF" name="Feasibility"/><phase color="0099FF" name="Development"/><phase color="0099FF" name="Development"/><phase color="CC99FF" name="Close-out"/><phase color="909090" name="Sustaining"/></phases><program name=""><project enddate=" 30/03/2007 " id="43250" startdate=" 28/02/2006 "><version enddate=" 30/03/2007 " number=" 1" startdate=" 28/02/2006 "><phase color="CCFFCC" currentdate="23/03/2006" name="Project Start" plandate="28/02/2006" type="phase"/><phase color="99CCFF" currentdate="04/04/2006" name="Feasibility Closure" plandate="31/05/2006" type="phase"/><phase color="0099FF" currentdate="29/03/2007" name="Commercialization" plandate="30/12/2006" type="phase"/><phase color="CC99FF" currentdate="30/03/2007" name="Project Closed" plandate="30/03/2007" type="phase"/><phase color="909090" currentdate="" name="Obsolescence" plandate="" type="phase"/></version> </project></program></chart>
    Thanks in advance,
    Regards,
    Manoz.

    Daverms,
    Thanks for the quick turn around..
    I have applied the solution what you suggested above (<cfprocessingdrirective suppresswhitespaces="yes"), still whitespaces are existing in my output.
    The output what I am getting is,
    (blue color part is my output & red color indicates whitespaces)
    <?xml version="1.0" encoding="UTF-8"?>
    <chart showdates="true" today="09/12/2009">
    <phases>
    <phase color="CCFFCC" name="Funded"/>
    <phase color="CDCD67" name="Concept"/>
    <phase color="99CCFF" name="Feasibility"/>
    <phase color="0099FF" name="Development"/>
    <phase color="0099FF" name="Development"/>
    <phase color="CC99FF" name="Close-out"/>
    <phase color="909090" name="Sustaining"/>
    </phases>
    <program name="">
    <project enddate=" 01/01/2010 " id="12059" startdate=" 20/06/2003 ">
    <version enddate=" 01/01/2010 " number=" 1" startdate=" 20/06/2003 ">
            <phase color="CCFFCC" currentdate="20/06/2003" name="Project Start" plandate="20/06/2003" type="phase"/>
            <phase color="CDCD67" currentdate="" name="Concept Closure" plandate="" type="phase"/>
            <phase color="99CCFF" currentdate="20/06/2003" name="Feasibility Closure" plandate="20/06/2003" type="phase"/>
            <phase color="F0FF00" currentdate="" name="Alpha Test" plandate="" type="milestone"/>
            <phase color="F0FF00" currentdate="26/07/2004" name="Beta Test" plandate="31/05/2004" type="milestone"/>
            <phase color="0099FF" currentdate="29/06/2005" name="Commercialization" plandate="08/12/2004" type="phase"/>
            <phase color="CC99FF" currentdate="24/02/2006" name="Project Closed" plandate="01/01/2010" type="phase"/>
            </version>
    <subproject enddate=" 16/10/2008 " id="11809" name="espWatcher Pricing Toolkit" startdate=" 01/08/2003 ">
    <version enddate=" 16/10/2008 " number=" 1" startdate=" 01/08/2003 ">
            <phase color="CCFFCC" currentdate="01/08/2003" name="Project Start" plandate="01/08/2003" type="phase"/>
            <phase color="99CCFF" currentdate="" name="Feasibility Closure" plandate="" type="phase"/>
            <phase color="0099FF" currentdate="15/06/2005" name="Commercialization" plandate="08/12/2004" type="phase"/>
            <phase color="CC99FF" currentdate="16/10/2008" name="Project Closed" plandate="16/10/2008" type="phase"/>
            </version>
    </subproject>
    <subproject enddate=" 31/12/2070 " id="35704" name="espWatcher version 2 (2005)" startdate=" 01/01/2005 ">
    <version enddate=" 31/12/2070 " number=" 1" startdate=" 01/01/2005 ">
            <phase color="CCFFCC" currentdate="01/01/2005" name="Project Start" plandate="01/01/2005" type="phase"/>
            <phase color="99CCFF" currentdate="01/07/2005" name="Feasibility Closure" plandate="01/07/2005" type="phase"/>
            <phase color="0099FF" currentdate="31/03/2006" name="Commercialization" plandate="31/03/2006" type="phase"/>
            <phase color="CC99FF" currentdate="31/12/2070" name="Project Closed" plandate="31/12/2070" type="phase"/>
            </version>
    </subproject>
    </project>
    </program>
    </chart>
    However this solution removes most of the whitespaces, I want exact output as flash file is expecting so..
    Where ever I am calling the CF functions, there I am getting the whitespaces. like below cases.
    startdate="#getProjectStartDate(sProjectIdList)#" -> output I am getting for this statement is -> " 12/09/2009 "
    Please assist me...
    Regards,
    Manoz.

  • Is it possible to exclude single contacts from the mute? For example: I want to hear when I recieve an SMS alert even if I mute my iPhone 4.

    Is it possible to exclude single contacts from the mute? For example: I want to hear when I recieve an SMS alert even if I mute my iPhone 4 (I am a fireman).

    No iPhone apps have access to the necessary API's to do so...they're all sandboxed.

  • How do I remove the white space from the bottom and side of my document?

    How do I remove the white space from the bottom and side of my document? (I'm not talking about printing, just viewing it on the screen.) There are about 6 inches of white space at the bottom and at the right hand side. I don't like this. On a blank new spreadsheet it's triple that amount of white space.

    The infinite canvas convention doesn't make a lot of sense for Numbers. When I'm viewing a spreadsheet and mistakenly scroll into white, empty space I think, "this is ridiculous - all of my content is fits on one screen. there's nothing over there."
    A (relatively) infinite canvas is logical for Microsft Excel because it's one big table. There are 256(?) columns by default and hundreds of rows on a sheet - there are cells outside what a user is looking at to see. However, when viewing a Numbers spreadsheet with a single 10 column 10 row table that fits on the screen, there's nothing else on it to scroll to.
    Numbers should distinguish between viewing a spreadsheet and editing one. When I'm just viewing, when there's no content outside the window it shouldn't scroll there. This window behavior is beyond annoying for Numbers on my iPad and iPhone.
    (Adding user-defined canvas size setting to my view mode / edit mode thinking would probably be the most complete solution to this now that I think about it.)
    Until now the way scrolling worked in Numbers has defied logic. Actually it still does lol. That said, thank you Yellowbox for providing a clear explanation. Much appreciated.

  • Is it possible to restrict the user from creating a sibling and allow him to ONLY create child nodes in DRM?

    When in a hierarchy, a user right clicks on a node to crate a new node, he has two options
    -Child
    -Sibling
    Is it possible to restrict the user from creating a sibling and allow him to ONLY create child nodes?
    Business cases:
    1. different level nodes need to have different prefixes.
    - Thus, the default prefix property definition uses the level number to assign a prefix
    - Also, a validation, to ensure the correct prefix, uses the level number
    But if the user can create a child and a sibling then the default prefix will only be right for a single case and not both.
    Thanks

    If the images are exactly the same size then make sure the layer with the mask
    is the active layer and in the other documents go to Select>Load Selection and choose
    your document with the layer mask under Source document and under channel choose the layer mask.
    After the selection loads press the layer mask icon at the bottom of the layers panel.
    MTSTUNER

  • Is it possible to prevent a user from creating and approving a JV

    Hi,
    Is it possible to prevent a user from creating and approving a JV.  We have a rule that one user cannot do both.  What happens is user#1 creates the JV, then some other user#9 approves the JV.  Both user#1 and user#9 need to be able to create a JV and approve someone else's JV.
    The transactions in question are...
    F-02  General Posting - enter Journal Voucher (create & post)
    F-65  Enter General Document - Parking (create)
    FBV0  Post or Delete a Parked Document (approval)
    Please let me know the details.
    Thanks in advance,
    regrads,
    Chaks

    Hi,
    Requisition is submitted.....it means Requisition is saved or it means Requisition is Released..?
    Regards,
    manish

  • I have a Cisco/Linksys WRT-54G wireless router and 2 Airport Extremes (the small ones that plug directly into the wall). Is it possible to extend the network from the router using these two AEs? I have a DVD player and Ext HD plugged into the router too..

    I have a Cisco/Linksys WRT-54G wireless router and 2 Airport Extremes (the small ones that plug directly into the wall). Is it possible to extend the network from the router using these two AEs? I have a DVD player and Ext HD plugged into the router too. Any ideas? I'm guessing the only way is to do what I've seen in these community pages which states that it can be done but it will drop the bandwidth by 50%. Thoughts?? Thanks!

    The Cisco/Linksys WRT-54G was one of the very few routers said to be compatible with Apple's implementation of WDS (Wireless Distribution System) settings.
    The info that I have on file indicates that only the WRT-54G versions 4 and under were compatible, so that would be one bridge to cross.
    Even if you find that your Cisco/Linksys might be the right version, Apple never published instructions on how to configure the Express devices with other manufactures, so users were left to their own devices to try to figure out how to get things working. Apple's instructions to connect to other Apple devices are in the link below:
    WDS network
    If you were hoping to use 2 Express devices in this type of configuration...even if it works...the bandwidth penalties will be extremely severe.
    The first Express drops the bandwidth (and speed) on the entire network in half and the second halves everything again. So, the result, in effect would be a "g" wireless network running at 25% speed. Few users would consider installing this type of network.
    At this point, it becomes one of those things where the fact that you might be able to do something does not mean that there would be much value in doing so. But, it is your decision to decide if you want to try to proceed.

  • Is it possible to insert white space that will track like other characters?

    I'm working with Indesign CS3, and have a problem with white space, inserted as a special character - in this case, a sixth space, used for the space between initials of a cited author: A. B. White, or whatever. Between the point after A and the B, I've inserted sixth-spaces in each instance. But when the automatic tracking sets the text, those white spaces don't seem to be adjusted in the same way as the rest. So when a line is unusually tight, the space in question looks too large, and vice versa.
    Is it possible - either in CS3 or, as a matter of interest, in CS4 or 5 - to insert white space that will track automatically as lines are adjusted?
    Many thanks in advance...
    MH

    Well, here's a classic:
    1) Set some type in French. Use a thin space or a 1/6 space before punctuation. (That's what you are supposed to do in French - there's always a space before many kinds of punctuation.)
    2) Hand off the file to someone else.
    3) "Someone else" tracks the paragraph to -40 (without understanding that the paragraph is now barely legible).
    If it's a fixed thin space, there is still a space in front of the punctuation. Due to the tracking abuse, it's now roughly the same size as a "normal" space-bar space. If it's not a fixed-width space, it has now disappeared. Tracking of -40 is ugly, but no space in front of punctuation in French is out-and-out wrong.

  • Extra White Space from Hidden Menu Bar

    This seems to be a problem introduced by LV 2013. I have a VI that runs with the menu bar hidden. When I hit ctrl-m to see how it looks in run mode, it looks fine. When I run the VI, instead of fully hiding the menu bar, it leaves white space. This only seems to be a problem when the VI is the top level. When the VI is opened from another VI, it looks fine. I've attached screenshots when the VI is running as a top level, ctrl-m is used and running when launched from another VI. This was not an issue in LV 2012. It's only been a problem since switching to 2013.
    Solved!
    Go to Solution.
    Attachments:
    Settings Screen Running Dev.png ‏86 KB
    Settings Screen CTRL-m.png ‏84 KB
    Setting Screen - Launch as SubVI.PNG ‏107 KB

    Greetings thutch79,
    I replicated the settings shown at Window Appearance Dialog.png on a new VI, ran it, and did not reproduce the problem.
    I wonder if you experience the same behavior with a new VI? If not, you can copy paste the code to a new VI to fix a potential corruption issue.
    Regards,
    Alejandro | Academic Program Engineer | National Instruments
    Attachments:
    Window Appearance.JPG ‏119 KB
    Running VI.JPG ‏21 KB

  • Remove extra white space from an image

    I want to remove the extra white space in my image while writing it into a jpeg file using JPEGImageEncoder.
    Any help is welcome .

    ok.. Am having a JPanel whose width is set to 77000. But almost 60% of right hand side of the Panel is empty. I will create a BufferedImage from this component and then write it into a file using JPEGImageEncoder.
    The empty portion of the panel is coming as a white space in the image.
    Now how to remove this ? Was that clear enough ?

  • Is it possible to exclude a HOST from  DRS.

    Hi, I want to know if it possible (maybe in DRS advances options) to exclude a Host from the DRS.
    I got one cluster with 8 hosts. I want to let the DRS on the cluster for all the host except one.
    I don't want to create a rule to exclude VMs from the host.
    I want the DRS to continue to work on the cluster but I want it to not considered a specific host.
    Thanx

    All our hosts in the cluster are the same except for one.
    9 x HP Proliant DL580 G5 (16CPUs x 2.933GHz)
    1 x HP Proliant DL580 G7 (24CPUs x 2.663 GHz)
    The DRS seems to have difficulty to balance efficiently the charge on this one. For example, all other servers are at 30% CPU and Memory at 70%. At the same time, the G7 keeps having a charge at 50% CPU and 92% memory, no-mater which VM is on it.
    So what I would have like to do was to exclude this specific host from the DRS and control his charge manually. At least to test it.
    I know that the best practice recommend to have all the same hardware, but it's not always possible.

  • Possible to enlarge white space by changing page size?

    Greetings.  I'm using Acrobat 10 pro now, but in 9  it was possible to enlarge the white space around the text by changing the page size as part of the crop command.  This was very handy for creating an area large enough for text box comments.  I can't find this capability in 10.  Am I, hopefully, mistaken?

    Select: Tools > Pages > Crop
    and then double-click on the page. You'll then get the Crop dialog and you can select a larger page size in the CHange Page Size area.

  • How to extract ALL text on a line, including extra white space, from PDF?

    I have written my first scripts to parse thru PDF files and successfully locate the beginning and ending of text portions that I wish to copy/extract.  For example, one of the scripts reads thru PDF files and locates patterns that allow me to copy/extract a lengthy Title that spans several lines on the page.  My remaining problem is that sometimes the text I wish to copy/extract has tabs or lots of white space between the words, and I need to retain ALL the "white space" between words.  Basically, I am successful at using getPageNthWord(j, i, false) along with "Quad coordinate sets" to get a word-at-a-time for all the words on the multiple lines but it seems to be skipping over the tabs and extra white spacing beetween the words.   Another way to say this is that I need to extract/copy a full line at a time, including all white space, instead of being limited to just a word at a time. 
    Can anyone help me with an algorithm to extract/copy text, not just the words but also including tabs and other extra white space characters? Is there some type of Regular Expression I should be using, or maybe some additional parameter used for getPageNthWord that would retain all the extra white space?
    Thanks in advance,
    Ted L

    Did you try setting the bStrip parameter of getPageNthWord to false? It will
    preserve some of the whitespace, but not all of it.
    As far as I know, that's the only way to do it via a script.

  • Stripping extra white space from a string

    I am trying to strip extra spaces from a string, so it there are 2 or more spaces between a word I want to remove all but one. I am trying the following code
    getStringTwo().replaceAll("/\s+/is","");
    but all I get is an error saying Invalid escape sequence
    Thanks
    G

    >
    This strips out all the whitespace. I ended up
    getting round it by walking through the string and
    checking the values of each char and comparing that
    to the next value. What a wast of effortt A small modification of my earlier post gives -
    public class Test040320a
        public static void main(String[] args)
            String str = "this    is       a \t test";
            str = str.replaceAll("\\s+"," ");
            System.out.println(str);
    }

  • How to auto-crop empty area (white space) from a scanned image

    I have a image scan operation thru' which the user can scan a A4-size paper, but the actual data on the scanned image is a small area.
    Any way that we can programatically crop the white area from the scanned image?
    Does JAI have any apis for doing this ?

    If you look at the constructor for BufferedImage, you can create an image of a size you specify. After creating the image, you can draw on it by obtaining its Graphics via the createGraphics() method. Now, you can draw the source image on the target image using something like
    imageGraphics.drawImage(sourceImage, 0, 0, targetImage.getWidth(), targetImage,getHeight, sourceUpperLeftX, sourceUpperLeftY, sourceUpperLeftX + targetImage.getWidth(), sourceUpperLeftY + targetImage.getHeight(), observer);
    now, your BufferedImage has the cropped image on it. Dispose of the graphics (good habit to release resources it used) and you are done.

Maybe you are looking for

  • GetSelectedRowKeys() returns more than one on Single Selection Tree Table

    Hi, I found that this issue occurring after PS3 (I think.) I have a tree table component, which allows single row selection. There is a listener on a column of the tree table as follows: public void listenPackageUnit(ValueChangeEvent valueChangeEvent

  • Getting the error while invoking Web services

    Hi, I am getting the error while invoking an webservive method *** follows {color:#3366ff}2009-01-28 04:49:38.994 Error Occured inMesage Now 2009-01-28 04:49:38.994 javax.xml.rpc.ServiceException: Unable to create Service Factory: oracle.j2ee.ws.clie

  • Changed my Apple ID, but iCloud ID no longer works.  How do I get iCloud ID and password to work now?

    I had to terminate my old email address due to excessive SPAM and notes from friends being returned as undeliverable. I set up a new email account at Outlook.com and then changed my Apple Store log-in ID and password (and that works fine).  BUT, iClo

  • Time stamp or get info including seconds

    Hi there, I'm trying to get more specific information about a selection of files - in particular, the seconds (and even milliseconds if possible) relating to the time-stamp for each. I've tried changing the international system prefs to full format b

  • Help with f:validateLength ... /

    Hi, I'm using the <f:validateLength minimum="6" maximum="45"/> tag in a login form to make sure there is something in a username field before looking up a database. The problem is if I don't type anything in the input field <h:inputText id="username"