Special Character to convert to Space

I have a field in BI "zpustreg" which has values with - and # which is not allowing me to load the data to cube so I am writing this code in transformation to convert any special character to space. but it is having error if you can help me fix the code below would really appreciate it
Abap Code to Load ZPUSTREG
METHOD compute_ZPUSTREG.
IMPORTING
request type rsrequest
datapackid type rsdatapid
SOURCE_FIELDS-/BIC/ZPUSTREG TYPE /BIC/OIZCUSTREG
EXPORTING
RESULT type tys_TG_1-/BIC/ZPUSTREG
DATA:
MONITOR_REC TYPE rsmonitor.
$$ begin of routine - insert your code only below this line -
... "insert your code here
*DATA:Monitor_REC TYPE rsmonitor.
DATA:L_D_OFFSET LIKE sy-index.
CONSTANTS:c_allowed(60) TYPE c.
Value `ABCDEFGHIJKLMNOPQRSTUVWXYZ!"%&'()*+,-/:;<=>?_0123456789_’.
RESULT = SOURCE_FIELDS-/BIC/ZPUSTREG
TRANSLATE RESULT TO UPPER CASE
DO 60 TIMES.
L_d_offset = sy-index – 1.
IF RESULT+1_offset(1) CO c_allowed.
Else.
RESULT+1_d_offset(1) = ` ’.
ENDIF.
ENDDO.
ENDMETHOD.
E:Statement "VALUE" is not defined. Check your spelling. spelling.
E:Unable to interpret "C". Possible causes of error: Incorrect spelling
Thanks
Soniya

Also, you'll need to change in this line:
RESULT+1_d_offset(1) = ` ’.
the ` for a  ’
Have you maintained the RSKC transaction? If you put ALL_CAPITAL there it should allow you to use those characters.
Regards,
Diego

Similar Messages

  • Problem in Smartform convert to PDF with special character

    Hi ABAP Guru,
    While convert smartforms to pdf.Some special character like ( - ) convert to ( # ).In development server there is no problem but the problem arise in quality.Please help

    Hi Palash,
                  Please use PDF! in print preview command field.. it will convert pdf file.
    regards,
           Thangam.P

  • Problem with CONVERT_OTF, special character '-' printing not properly

    Hi experts,
    when printing PO item text; in Print Preview, text displays correctly. But in program by using 'CONVERT_OTF' FM output is converting into PDF and this PDF is send it to the PO creator through mail,   In the PDF present in the mail, the special character ' - ' is not displaying properly; i.e the special character ' - ' is replaced by '  ' space. For the text we are using Text editor and Font family is 'COURIER' , device type is 'PDF'.   And also i tried with different Font fammilies, for that it beheaves differently but not displays as it is the special character ' - '.
    Thanks and regards
    Aumprakasharya T

    Hi,
    Which device type is used to create the PDF? i.e. which deivce type is used in the OTF data that is converted to PDF? If you use device type PDFUC or SWINCF, then it should work fine. (see SAP not #999712 about unicode PDF conversion)
    Regards,
    Aidan

  • Validation to avoid special character in material & vendor no

    Hi Experts,
    We receive material & vendor creation request through E-portal. Once user send request on portal it gets recorde at its backend i.e MDM
    Please guide me how to give validation in MDM to avoid special character '*' ',' '&' 'space' in material no. & incase of vendor code these same character & numeric code is not allowed.
    Please guide in deatail step by step procedure.
    Regards,
    Gaurang

    Hi Gaurang,
    How to give validation in MDM to avoid special character '' ',' '&' 'space' in material no. & incase of vendor code these same character & numeric code is not allowed*
    For this, you can write two validations one for Material number and other for Vendor Code and need to set both of these validations to Automatic Execution = Error
    Expression for Material No as given below:
    IF(FIND(Material No, "*") OR FIND(Material No, ",") OR FIND(Material No, "&") OR FIND(Material No, " ") , FALSE, TRUE)
    Expression for Vendor Code as given below:
    IF(FIND(Vendor Code, "*") OR FIND(Vendor Code, ",") OR FIND(Vendor Code, "&") OR FIND(Vendor Code, " ") , FALSE, TRUE)
    So both above validations will fail if they find any Special character among Asterisk ("*"), Ampersand ("&"), Space (" ") and Comma (","). Kindly revert with result.
    Regards,
    Mandeep Saini

  • LSMW: Convertion of special character turn into #

    Hi all,
    Ich am Ulpoading a file in the step 'READ DATA' in LSMW and when I check the result in the next step 'DISPLAY READ DATA' I see that the upload (i do not know if LSMW make an WS_UPLAOD or GUI_UPLOAD or another function) converts a special character that we use in Portugal
    in the file:           Fabricação
    in LSMW after Upload:  Fabrica##o
    The file was an Excel which I saved as txt (tab delimited)
    Who can help??????
    Thanks
    Picasso

    Hi Picasso,
    LSMW is having 'GUI_UPLOAD' function module to upload data.
    GUI_UPLOAD FM is having import parameter CODEPAGE.Whose functinality is to take care of such special character.
    Include which is called for READ DATA step, you can very wel find out that the codepage is not suitable for your Portuguese language.
    Do one thing write an BDC...Call GUI_UPLOAD FM and then Pass CODEPAGE number.
    codepage number you will get from  tcp00 table.
    here is example to take care of special Japanese character:
    CALL FUNCTION 'GUI_UPLOAD'
        EXPORTING
          filename                = l_ws_path
          filetype                = 'ASC'
          has_field_separator     = '#'
          codepage                = '6300'
        TABLES
          data_tab                = i_aenr
        EXCEPTIONS
          file_open_error         = 1
          file_read_error         = 2
          no_batch                = 3
          gui_refuse_filetransfer = 4
          invalid_type            = 5
          no_authority            = 6
          unknown_error           = 7
          bad_data_format         = 8
          header_not_allowed      = 9
          separator_not_allowed   = 10
          header_too_long         = 11
          unknown_dp_error        = 12
          access_denied           = 13
          dp_out_of_memory        = 14
          disk_full               = 15
          dp_timeout              = 16
          OTHERS                  = 17.

  • Special character not being converted to upper case

    Hi all,
    I have an issue with special characters and upper/lower case.
    The character "ü" is in one of the values of an InfoObject and when loading we get an error message for this value. The character "Ü" is in RSKC, but still we are getting an error when loading.
    We are converting the values to upper case in the transfer rules, but this special character is not being converted to upper case...
    We start with the value "Heüringen" and after conversion we have the value "HEüRINGEN" where we want to have "HEÜRINGEN".
    Do you have any idea why this characer is not being converted?
    Any ideas are welcome!
    Best regards,
    TMV

    Hi Praveen,
    What does this module actually do? What kind of characters will the special chars be replaced with?
    Br,
    TMV

  • CS2/MAC/Applescript: XML Export problem with Special Character (thin space).

    Hi,
    I just have noticed that the base XML export of Indesign doesnt encode/keep the unicode value of Thin Space in the exported XML. Strangely, a non-breaking space is encoded ( ) and a few other higher range unicode values (well not encoded, it's in the text data just like any other character).
    The thin space is converted to a char 63 (?). I have tried utf8 and utf16.
    Is this behavior documented somewhere? There is no option in the export window.
    Does it mean that the only complete and reliable way to export text data is to have another script to export the tagged page item text content? (i definitively can do this, but it's remove alot of the simplicity of using the base XML export) [and make any simple xml/text roundtrip unfunctionnal]
    Anyone having experience with XML workflow can confirm if i have just met a known limitation of Indesign??
    Thanks,
    Eric

    Oups! I was able to find something here on the same subject:
    http://www.adobeforums.com/webx/.59b561c7/0

  • Special character (Space) coming in excel output

    Hi,
    I am using rtf to develop a XML report. The output type is excel so I am using force Ltr property to allign few fields. But I am getting special character when I copy and paste a value of the O/P in the notepad. When I don use Force LTR the problem is not there but the allignment goes for a toss. So is there any way by whcih the issue can be resolved keeping the force LTR.?

    This seems to be a BUG, please share if there is any workaround for the above issue.
    I have tried below approach in order to retain leading zeros.
    Excel Output From BI Publisher or XML Publisher is Trimming Leading Zeros [ID 417811.1]
    Thanks in advance.

  • Special Character And Extra Spaces

    Hi All,
    This may be a simple problem to fix (i hope) but my searching
    has found nothing.
    When i publish documents from word to contribute i get extra
    gibberish in the place of extra spaces and special characters like
    dash(–).
    extra space = Â
    dash = –
    Hopefully theres a setting i'm missing that will fix the
    problem.
    I am working with big documents that contain garphics so
    exporting to txt format isn't an option.
    Thanks in advance for the help.
    Cheers
    David

    After further experimentation and a close fix i have found
    the the pages look fine with a html extension but contain the
    gibberish when they have a cfm extension.
    Obviously when the files go through the coldfusion server
    something happens.
    Any help would be greatly appreciated.

  • Request.getParameter(): special character handling problem

    Hello, there:
    This should be an easy question for the gurus in here.
    I use a string attached to the url as the parameter string, which includes spaces. the system automatically converts them to %20, but when I receive them in my servlet using request.getParameter, a special character, &Acirc; appears; I couldn't proceed with it.
    I suppose this is a common problem but seems that I didn't find topics about it on this forum.
    So anyone can help? Any encoder/decoder APIs to handle it?
    Thanks a lot,
    Sway

    hi,
    escape can solve ur problem
    use js function to submit form like
    function subForm()
    var any_spcl_value ="kdfhjdf$%@#$% 2FGSFG @%@#%@# V";
    mainForm.action = "index.jsp?value="+ escape(any_spcl_value);
    mainForm.submit();
    and use request.getParameter("value");
    u ll get kdfhjdf$%@#$% 2FGSFG @%@#%@# V as it is.
    AE

  • Looking for a name with special character

    Hi Gurus,
    In our HR system we use multiple language (eg: polish, french, german, english, finns, ...).  All those languages have some specific characters, like german with ß.
    When we use the search help to looking for someone, it seems that only people who have the special character on their keyboard can find directly the correct name.
    For example :
    If I use a german keyboard I can found an employe by completed the correct last name wich contain eg ß .
    if I don t use a german keyboard I have to put a * where the specific characters is.
    I would like to know if somehow it were possible to customize the system in order to do not need to enter a * but the correspondant singular letter.  Is there any function for converting a special character to a singular one to activated ?
    Thank you for all your help
    Best regards
    Hadrien

    indexOf() is used to find where a character or substring appears in a
    given string. What you probably need is charAt() which finds out which
    character is at a given position. Like this:private JTextField reportNameText;
    // something needs to be put in the text field here
    String reportName = reportNameText.getText();
    if(reportName.charAt(0) == ' ') {
            // printing a space isn't a lot of good...
        //System.out.println("first character is"+reportName.indexOf(0));
        System.out.println("first character is a space");
        JOptionPane.showMessageDialog(null,"Report Name should not start with Space", "", JOptionPane.PLAIN_MESSAGE);
    }An even better condition might beif(Character.isWhitespace(reportName.charAt(0))) {This checks for other sorts of space.
    The String methods are described here:
    http://java.sun.com/j2se/1.5.0/docs/api/java/lang/String.html

  • Orchestration exception:Exception occurred when persisting state to the database because of special character ' ' in HL7 message.

    In some scenarios HL7 message is coming with special character ‘’ and HL7 dis-assembler escaping this character with “&#x10;&#x1;”. But while sending out (pass thru pipeline but orchestration trying to persist here at last sendshape.) from orchestration
    this message failing with the error “Exception occurred when persisting state to the database.”
    As per the analysis , Orchestration is unable to convert to xml document from a
    XLANGMessage because of this special character. We have tried to call custom .net class with following code and its failing here as well (I think orchestration also trying to do same way and failing with the message and failing with same error.).
    public void ProcessRequest(XLANGMessage reqMessage)
    XmlDocument xmlDocument = (XmlDocument)reqMessage[0].RetrieveAs(typeof(XmlDocument)); It is failing here with the error
    “ ', hexadecimal value 0x10, is an invalid character. Line 1, position 1865. “
    Note : Please find the special character in the attachment circled in red color. 

    Hi ,
    Please find the xml and the screenshot.
    <OBX_ObservationResult>
      <OBX_1_SetIdObx>3</OBX_1_SetIdObx>
      <OBX_2_ValueType>TX</OBX_2_ValueType>
      <OBX_3_ObservationIdentifier>
        <CE_0_Identifier>P.112</CE_0_Identifier>
        <CE_1_Text>Where pt. will be transported to \T\ where &#x10;&#x1;famly can wait:</CE_1_Text>
      </OBX_3_ObservationIdentifier>
      <OBX_4_ObservationSubId />
      <OBX_5_ObservationValue>Y</OBX_5_ObservationValue>
      <OBX_6_Units>
        <CE_0_Identifier />
      </OBX_6_Units>
      <OBX_7_ReferencesRange />
      <OBX_8_AbnormalFlags />
      <OBX_9_Probability />
      <OBX_10_NatureOfAbnormalTest />
      <OBX_11_ObservationResultStatus>N</OBX_11_ObservationResultStatus>
    </OBX_ObservationResult>

  • A special character in the last column in my external table

    Hello,
    I'v made a external table that looks like this :
    CREATE
    TABLE "REC_XLS"
    "FINANCE_DATE" VARCHAR2(50 BYTE),
    "CREATION_DATE" VARCHAR2(50 BYTE),
    "SENT_DATE" VARCHAR2(50 BYTE),
    "REMARKS" VARCHAR2(200 BYTE),
    "REMAINING_QUANTITY" VARCHAR2(30 BYTE),
    "CODE" VARCHAR2(30 BYTE)
    ORGANIZATION EXTERNAL
    TYPE ORACLE_LOADER DEFAULT DIRECTORY "LOADER" ACCESS PARAMETERS (
    RECORDS DELIMITED BY newline LOAD WHEN CODE!=BLANKS Skip 1 FIELDS
    TERMINATED BY 0X'09' MISSING FIELD VALUES ARE NULL REJECT ROWS
    WITH
    ALL NULL FIELDS ( Finance_date,
    creation_date, sent_date, Remarks,
    remaining_quantity, code) location ( 'Finance.tsv' )
    I exported the result in xls file and I saw in the last column a special character. The result of a copy and paste is prenseted here : "ABE
    You should notice that the last quote is in the upper line instead of at the end of ABE. This means, I think, that there is a carriage return at the end. And the 0X'09' is the tab separator. How can I get rid of this character ?

    my guess is that you run the load on unix server which uses default LF end-of-line character and the file has dos CRLF end-of-line, the easiest option is to change records delimiter in the DDL and replace "RECORDS DELIMITED BY newline" with code below
    RECORDS DELIMITED BY '\r\n'in general end-of-line can be really any character, sample above shows CRLF but it can be TAB, space, | or any other character or set of characters. I have samples of special characters on my blog http://jiri.wordpress.com/2009/01/29/oracle-external-tables-by-examples-part-1/
    hope this helps
    jiri

  • Unprintable special character in RDP file

    We're having strange issue. We use RDP files generated in RDP client, we then sign those using rdpsign.exe.
    Recently after upgrading our infrastructure from W8/2012 to W8.1/2012R2 we noticed that every RDP file generated in RDC 8.1 client contains a special character on first position that is not visible in normal text editor and is only visible in hex editor.
    This character wasn't there in W8/2012. When I create the RDP file manually (typing (copy/pasting) all the options in a text file), it doesn't contain any special character, but when I later sign that file file rdpsign, it adds that character again.
    How do we get rid of it? It's preventing our provisioning system from substituting username.

    Hello MarkosP,
    Thanks for contacting Microsoft.
    These bytes are regular UTF-16 byte order marks. See here:
    http://en.wikipedia.org/wiki/Byte_order_mark#UTF-16
    If the tool you use on the RDP file does not support UTF-16, you can try to convert the file to ASCII. This will probably work for most RDP files, except if some
    string uses some unicode character not present in the ASCII character set. Here is some info (see the powershell section in the first post/question):
    http://stackoverflow.com/questions/64860/best-way-to-convert-text-files-between-character-sets​
    Best regards,
    Sophia Sun
    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.

  • Special character in receiver xml

    Dear All,
    I have a file being moved from SAP to Market end point server. The receiver side is in xml format (no FCC)
    Code page conversion is used - UTF8 TO UTF16LE
    A special character is occurring in the receiver side: [] It is actually new line character and I suupose due to incompatibility it is coming.
    How do we get rid of this character?
    Thanks

    Hi,
    What Kind of mapping do you use? I have explored this behaviour in a XSLT Mapping and i resolved it by using <xsl:strip-space element = "*" />
    Maybe this help?
    Regards,
    Björn

Maybe you are looking for

  • Lot size in MTO

    Hi Experts,                    I am using strategy 20, my FG batch size is 100 and i have a sale order of 120. I want the system to create 2 planned orders of 100 and 20. I tried with lot size EX and maximum lot size 20, but system made a single plan

  • I've lost my Ipod touch 5 Gen. and wanted to ask if there is any possibility to localise my ipod! I've got an Apple-ID, does that help?

    've lost my Ipod touch 5 Gen. and wanted to ask if there is any possibility to localise my ipod! I've got an Apple-ID, does that help?

  • Creating dataset from OracleParameters

    I want to create a dataset from a set of OracleParameters that are returned from my stored procedure. The parameters are all Assoc Arrays. The problem I am having is how to determine what Type to assign the table's columns in the dataset. I know that

  • Output Flatfile, fields alignment

    Dear SAP experts, I have this output flatfile, in which, SALES and TURNO fields were left-justified. PERIO;EAN;ILN;SALES;TURNO;PERFL;SUBSFL;SALUN;%CURRENCY%;STOCK;STOUN;ARTNR;ARKTX 20071215;737052018126 ;4327498000005;1____;10.50____;W;X;ST ;EUR;0000

  • Problem with trial version line over my project

    I have bougth the normal version after trying the trial version. The promblem is that the trial line stays in my project. How can I remove it? thanks fot helping