How to trim spaces from string in BMM layer?

Hi friends,
I need to trim spaces from the string. can you please give me syntax with example.
Thanks

Hi
I have tried the below option , but it did not work . PS_D_PERSON
PERSON_ID is char type in the data base oracle , and it is defined as varchar on the physical layer .
So the table is loaded with space , i am not able to remove the space using trim both
Thanks
Sridhar.N

Similar Messages

  • Trim Space from a string

    Hello All,
    I need to trim space from beginning and end of a string.
    For example -
    astring = ' hello123 '.
    I need to get astring as 'hello123'.
    Thanks in advance.
    Viren

    Hi Viren,
    You can code like this
    WRITE ASTRING TO ASTRING NO-GAP.
    Hope this will help.
    Regards,
    Ferry Lianto

  • Help :how to remove spaces in string

    could any body please help me in removing spaces from string suppose i have written vivek chhabra and i want to remove spaces in this string and want a string vivekchhabra then how this could be done
    anybody help me please
    vivek

    String string = "Hello - This is a test!";
    String result = string.replaceAll(" ", "");
    System.out.println(result);This code results the following output:
    Hello-Thisisatest!

  • Is trim(both from string) is the same as trim(string)...

    trim(both from string) is the same as trim(string)...
    like in
    SELECT trim(both from STRING_COLUMN) "A" , trim(STRING_COLUMN) "B" from TEXT_TABLE
    will "A" and "B" will be same
    I know this was asked in previous threads , but wanted clarify ..Thanks in advance

    Yes, they are the same
    (See the syntax diagram here http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96540/functions153a.htm#SQLRF06149)

  • How to get substring from string starting from the end of string

    Hi
    How to cut from string:
    $A=C:\ClusterStorage\Volume1\WXP-plwropc300\Virtual Hard Disks\WXP-PLWROPC300_EE20E00F-315E-4781-A6DE-68497D4189B8.avhdx
    this substring (name of VHD file): WXP-PLWROPC300_EE20E00F-315E-4781-A6DE-68497D4189B8.avhdx
    This script should be universal so the best way to be cut all leters from the end of string $A till get the first mark \
    Thank you for help.
    Tomasz
    Kind Regards Tomasz

    PS > Split-Path 'C:\ClusterStorage\Volume1\WXP-plwropc300\Virtual Hard Disks\WXP-PLWROPC300_EE20E00F-315E-4781
    -A6DE-68497D4189B8.avhdx' -leaf
    WXP-PLWROPC300_EE20E00F-315E-4781-A6DE-68497D4189B8.avhdx
    PS >
    That is what "Split-Path" is for:
    ¯\_(ツ)_/¯

  • How to get InputStream from String ?

    Hi !
    I want to get InputStream object from String.
    String str = "balabalabala";
    InputStream stream = getInputStream(str);
    How to realize getInputStream(str) function ?
    Thanks!

    The preferred method nowadays is to use Readers and Writers for String data - hence StringReader(String). If you're going to operate on the InputStream directly, then I'd modify your code to use the Reader calls and go that route.
    If, however, you need to pass the InputStream to some other piece of API that requires an InputStream instead of a Reader, then the ByteArrayInputStream is probably your best bet. StringBufferInputStream is deprecated because it doesn't work reliably in the face of many character encodings.
    Speaking of encodings - never call Strng.getBytes() - always use the getBytes(character-encoding) version, so you KNOW what encoding you're getting!
    Grant

  • How to get substring from string using index?

    hi,
    here i am having string ,
    i want the pullareddy from below line ,
    i know how to get from substring.
    but i want to get the above using "index",
    can any help how to do it?
    String str1="janapana,pullareddy, in malaysia";
    jpullareddy

    get the start index with indexAt("pullareddy")
    get the end index with adding the length of the word to the start
    get the char[] of str1 with toCharArray()
    make a new string with the chars from start to end index.

  • How do I unflatten from string to an array of strings in labwindows

    New to Labwindows so please forgive.  I am trying to use STM to read messages from an existing LabView program.  I am using ClientTCPCB from the example that came with the STM library, but it reads in doubles, I want to read in strings.  I can see that I have the correct number of elements in my receive buffer, but I can't figure out how to convert the receive buffer into an array of char arrays (or strings as it were) something like labview's "unflatten from string" with 1-d array of strings as the type.

    So I figured it out... from the lack of info on the web and forums I doubt it will be useful to anyone else, but will post a brief solution.
    So I dumped the raw bytes to a file to look at how they are packed.  The first 4 bytes (int) is the number of strings in the message.  The next 4 bytes (int) are the number of chars that follow, then the corresponding chars, sans any null term character, then the very next int would be the number of chars in the next string and so on and so forth.  So I ended up writing my own charArrUnflatten function.  Anyway, after all this I might try to recode everything to use network vars.  Cheers.

  • How to trim data from column

    Morning gurus
    I have two tables, with column matching data, BUT i need to trim the columns of one of the tables
    the data appears in xpq_log table as follows
    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_06In printpdf table as follows
    PDF_REPORT     PDF_DESCRIPTION
    IN002C                     STOCK FILE PURGE - PRINT WH CONTROLHow can i trim data from column(log_hdr) to match column(pdf_report)?
    Any help will be much appreciated

    Alberto,
    Even we can use regexp_substr to something fix string( Known part of a string).
    Like:-
    SQL> ed
    Wrote file afiedt.buf
      1  WITH xpq_log AS
      2  (
      3     SELECT '0609IN002C_06' log_hdr FROM DUAL
      4  )
      5* SELECT REGEXP_SUBSTR(log_hdr,'[[:alnum:]]+[C$]',1,1) PDF_REPORT FROM xpq_log
    SQL> /
    PDF_RE
    IN002C
    Thanks!                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • How to remove space from satrting

    help me please
    i have 16 digit field ,  so in output i have only 5 digit and left  11 digit is comming blank
    so please tell me how to reduse space form starting
    my field is coming like this   -- Rs:            78,999.00 
    so i want to reduse space between Rs and amount
    thanks

    you can either use condense statement
    condense <field name>.
    You can also use the following function module.
    CALL FUNCTION 'CONVERSION_EXIT_ALPHA_OUTPUT'
      EXPORTING
        INPUT         = <FIELD NAME>
    IMPORTING
       OUTPUT        = <FIELD NAME>.

  • How to remove space from a variable in a smartform

    Hi,
    I have a problem in displaying a variable in a smartform..The variable shows some blank space that preceeds the data.
    for eg:,
    variable =        18.000.
    How to remove space before 18.000?

    To remove the decimal places for quantity and rate/quantity , use the syntax to restrict the number of digits after decimal places. The syntax is
    &symbol(.N)&
    where N is number of decimal places.
    Since you dont want decimals use &symbol(.0)&
    For the other case it depends on how the currency is represented , any way try using the syntex &symbol(T)&
    Please give me reward point If it is useful
    Thanks
    Murali Poli

  • How to delete Spaces in String

    Can somebody help to modify my source, cos i want to delete certain space. Thanks
    private static String printStar(int SpaceForStar){
        String sDelOneSpace =" ", sAddOneSpace=" ", star ="*", sTtlSpace ="";
        for(int i=0; i<numSpace; i++){
          sTtlSpace += sAddOneSpace;    
        for(int i =0; i<8; i++){
          sTtlSpace = sTtlSpace - sDelOneSpace;   // seem that not working.. can somebody help Thanks
        return sTtlSpace+star;
      }Thanks in advance
    jas

    What you are trying to do will not work - subtraction of Strings does not make any sense.
    To remove spaces, I suggest you use a StringTokenizer with space as dividing token. Lop trough the tokens and add them to a new String, like this:
        public static void main (String[] args) throws Exception {
            String withSpace = "aaa sss bbb";
            System.out.println(removeSpaces(withSpace));
        static String removeSpaces(String withSpaces) {
            java.util.StringTokenizer t = new java.util.StringTokenizer(withSpaces, " ");
            StringBuffer result = new StringBuffer("");
            while (t.hasMoreTokens()) {
                result.append(t.nextToken());
            return result.toString();
        }This will remove all spaces, and print "aaasssbbb". If you only want to remove the first or the last space, you can use indexOf() or lastIndexOff to find the space, and then substring to pick the text before and after that space and concatenate those two strings to a new string without the space:
        static String removeFirstSpace(String withSpaces) {
            int spaceIndex = withSpaces.indexOf(' '); //use lastIndexOf to remove last space
            if (spaceIndex < 0) { //no spaces!
                return withSpaces;
            return withSpaces.substring(0, spaceIndex)
                + withSpaces.substring(spaceIndex+1, withSpaces.length());
        }

  • How to create logical fact table in BMM layer ?

    Hello,
    I have 3 Dimension table - 2 are in one schema and last is another schema. Using this 3 dimension tables, I need to create a logical fact table.
    So, my question is whether we can create this fact table by joining these 3 dimension table which are in 2 different schema s ?
    Thanks

    Fiaz,
    you are correct. We can use tables from different subject area to create a report. However, my question was related to rpd design. Sorry, I was not very clear about the queries earlier.
    Here is the whole scenario in the physical layer of the rpd
    Table name      Databse name      Connection pool name      Schema name
    AV          AV_PXRPAM     AVAILABILITY          CRMODDEV
    OUTAGE          AV_PXRPAM     AVAILABILITY          CRMODDEV
    COMPANY          PXRPAM          PXRPAM_POOL          CRMODDEV
    AV and OUTAGE have the joins already. I want to make a join between COMPANY with OUTAGE. And then I want to include a column from each of above tables to the logical fact table in the BMM layer. then I want to do a star schema with the logical fact table to the above 3 tables in the BMM layer.
    Thanks

  • How to handle spaces in string?

    Hi,
    I am trying to filter out servers and certain OS from my powershell line below but I am getting an error. I think it is because of the Mac OS X line with spaces?:
    The string is missing the terminator: '
    $AllADClientObjects=@(Get-ADComputer -Filter "operatingSystem -notlike '*server*'" -and "operatingSystem -notlike '*"'Mac OS X'*'" -ErrorAction SilentlyContinue)

    Try this:
    $AllADClientObjects = @(Get-ADComputer -Filter "operatingSystem -notlike '*server*' -and operatingSystem -notlike '*Mac OS X*'")
    You shouldn't need the -ErrorAction SilentlyContinue when using filter because if it doesn't find anything, it will not throw an error like if you used -Identity.
    Boe Prox
    Blog |
    Twitter
    PoshWSUS |
    PoshPAIG | PoshChat |
    PoshEventUI
    PowerShell Deep Dives Book

  • Flash Builder 4 List controls trimming spaces from XML node values

    I'm trying to migrate my Flex 3 application to Flash builder 4.  One issue that I have is that one of my datasources returns a list of cities and regions.  To get the regions to display in the correct order in Flex 3, a space was added to to their name in the database (ie. "West", "Northwest" are stored in the database as " West" and " Northwest" so that when sorted by the sql query they would appear at the top and gets translated to XML to fill in a list box or combo box in my Flex 3 application.  I have functions that take that selected city or region value from the combo box and queries the database for various performance metrics.  In migrating to Flash Builder 4, I noticed that the spaces in the region names no longer appear in the combo boxes.  When I show the data in a datagrid, the spaces are still there but when populating a combo box or list box, the leading space gets trimmed.  This is an issue since if a user selects the value "West", it doesn't find it in the database since it is listed as " West".  This wasn't an issue in Flex Buider 3.  Is there a work around or parameter that I can set to force the combo box or list box to show the data as-is versus having it trim off the leading spaces for my regions?
    Also, a stupid question, in Flex 3, you were able to find the select value of a combo box by using comboBox.text.  What is the equivalent in Flash Builder 4?  Do I need to do comboBox.selectedItem.Region.toString() now or is there a shortcut to pull the text from the combo box?

    I think you want this:
    private function onLoadPortfolioData(event:ResultEvent):void
        var obj:XMLList = event.result.img as XMLList;
        if (obj.length > 0)
            _imgCollection = new XMLListCollection(obj);
            pictureList.dataProvider = _imgCollection;
    If this post answers your question or helps, please mark it as such. Thanks!
    http://www.stardustsystems.com
    Adobe Flex Development and Support Services

Maybe you are looking for

  • Why can't I get the Audi-video chat started?

    My step-daughter and I have iSight cameras and Macintosh Computers with iChat installed. On Friday afternoon we tried to start a video-chat. I heard by phone, that we were both trying to get in touch with each other at the same time. • I was able to

  • Adobe Photoshop CS5.1

    Where to download Adobe Photoshop CS5.1

  • Is OS X Server right for me?

    Hiya- I work at a smallish print shop (about 70 employees). We are looking at getting an in-house server to primarily handle email (about 20 email accounts), as well as FTP and probably hosting a very small website. Most of the "pros" we've consulted

  • SAP REx 3.2 Predefined list of activities for visit type while creating visit on iPad

    Colleagues, our customer wants to have a different predefined list of activities for different visit types while creating a visit on iPad. I have seen such functionality in SAP Demo for REx 3.2 on iPad. Could you tell me what I should do to have such

  • Upgrading from 4.0 to 4.1

    Hello All, we are on Business Objects 4.0 SP6 Patch 3 and planning to move to Business Objects 4.1 SP2. Whats the best way to go about this process 1. I read upgrading from 4.0 to 4.1 has many issues. any suggestions? 2. Separate install of 4.1 is re