Strange behavior of LENGTH command - ORACLE

前端 未结 3 1850
既然无缘
既然无缘 2021-01-04 12:43

I\'ve encountered here an inusited situation that I couldn\'t understand. Nor the documentation of the functions that I will write about has something to light up this thing

3条回答
  •  甜味超标
    2021-01-04 13:41

    The 'nlssort' function's documentation does not state that the output string will be a normalization of the input string, or that they will have same length. The purpose of the function is to return data that can be used to sort the input string.

    See http://docs.oracle.com/cd/E11882_01/server.112/e26088/functions113.htm#SQLRF51561

    It is tempting to use it to normalize your string since apparently it works, but you are gambling here...

    Heck, it could even yield a LENGTH(b)=200 and still be doing what it is supposed to do :)

提交回复
热议问题