• Visitors can check out the Forum FAQ by clicking this link. You have to register before you can post: click the REGISTER link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below. View our Forum Privacy Policy.
  • Want to receive the latest contracting news and advice straight to your inbox? Sign up to the ContractorUK newsletter here. Every sign up will also be entered into a draw to WIN £100 Amazon vouchers!

Oracle double byte space...

Collapse
X
  •  
  • Filter
  • Time
  • Show
Clear All
new posts

    #11
    They are definitely spaces, thanks for the help everyone, I've got the ClientCo to assign a permie in the US to the issue, meanwhile the IT manager out here is going to try to extract the data from their AS/400 without the spaces and send it to me again to upload.
    …Maybe we ain’t that young anymore

    Comment


      #12
      AS/400, blimey if it actually says that on the box it make a ZX81 look youthful.

      Comment


        #13
        IBM i now....

        Comment


          #14
          Originally posted by stek View Post
          IBM i now....
          It was renamed iSeries in 2000, keep up grandad.

          Like calling your laptop now "an IBM PC compatible".

          Comment


            #15
            Originally posted by WTFH View Post
            They are definitely spaces, thanks for the help everyone, I've got the ClientCo to assign a permie in the US to the issue, meanwhile the IT manager out here is going to try to extract the data from their AS/400 without the spaces and send it to me again to upload.
            Notepad ++ may tell a different story as eek has suggested
            The Chunt of Chunts.

            Comment


              #16
              Dump might tell you what you're looking at.

              https://www.techonthenet.com/oracle/functions/dump.php

              Comment


                #17
                Originally posted by MrMarkyMark View Post
                Notepad ++ may tell a different story as eek has suggested
                Offloading it to some poor sod not on cuk sounds like a far better plan and I heartedly approve of wtfh's approach
                merely at clientco for the entertainment

                Comment


                  #18
                  Originally posted by WTFH View Post
                  It looks like this:


                  ド                                                  ||


                  Code:
                  ド                                                 ||

                  (I've added a || at the end to make it easier to see)
                  I copied your string into SQL Developer and those aren't spaces:

                  Code:
                  WITH xyz AS ( SELECT 'ド                                                  ' txt FROM DUAL
                                UNION
                                SELECT '1          ' from dual
                                UNION
                                SELECT '2                                                  ' txt FROM DUAL
                              )
                  SELECT txt
                  ,      LENGTH(txt)
                  ,      RTRIM(txt)
                  ,      LENGTH(RTRIM(txt))
                  ,      TRIM(txt)
                  ,      LENGTH(TRIM(txt))
                  ,      ASCIISTR(txt)
                  FROM   xyz;
                  Your string includes UNICODE characters:

                  Code:
                  \30C9\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000\3000
                  So the last character is a space but the rest of them aren't. You could include a REPLACE to remove those non-ASCII characters if that would help:

                  Code:
                  RTRIM(REPLACE(txt,UNISTR('\3000'),' '))
                  Last edited by RonBW; 1 December 2016, 13:09.
                  First they ignore you, then they laugh at you, then they fight you, then you win. But Gandhi never had to deal with HMRC

                  Comment


                    #19
                    Ah, now that makes sense - Unicode character 3000 is an ideographic space. Tomorrow I will have a play in SQL.

                    Thanks!
                    …Maybe we ain’t that young anymore

                    Comment


                      #20
                      Originally posted by WTFH View Post
                      They are definitely spaces, thanks for the help everyone, I've got the ClientCo to assign a permie in the US to the issue, meanwhile the IT manager out here is going to try to extract the data from their AS/400 without the spaces and send it to me again to upload.
                      Originally posted by MrMarkyMark View Post
                      The other possible thing is he could have unknown characters in there, also.
                      I had this once and only realised they were there after I had looked at the data in a hexadecimal editor.

                      Originally posted by RonBW View Post
                      I copied your string into SQL Developer and those aren't spaces
                      A little bit of advice............in future do yourself a favour and pay for the true professionals to come in, I'm quite cheap, all told, really
                      The Chunt of Chunts.

                      Comment

                      Working...
                      X