SQL> select lengthb('长度') from dual;LENGTHB('长度')
---------------
              4

解决方案 »

  1.   

    The LENGTH function accepts a string in the form of a CHAR or VARCHAR2 as its input and returns a number that is equal to the string's length. If the input is CHAR, trailing blanks are counted, with VARCHAR2, they are ignored. If the string specified is a null, a null is returned. The LENGTHB function performs the same function but only for single byte character sets. Where LENGTH returns a number of characters, LENGTHB returns a number of bytes. For single byte character sets, LENGTH and LENGTHB are equivalent.