getting “comma-separated list near 'xx.yy' invalid” with dbms_utility.comma_to_table

后端 未结 2 961
说谎
说谎 2020-12-01 20:34

I have string like this: str:=\'ac_Abc.88,ac_Abc.99,ac_Abc.77\'. I need to get first element after splitting with comma(,). So im using using like this:

str          


        
2条回答
  •  青春惊慌失措
    2020-12-01 21:13

    It is because (Oracle doc reference)

    COMMA_TO_TABLE Procedures

    These procedures converts a comma-delimited list of names into a PL/SQL table of names. The second version supports fully-qualified attribute names.

    A "name" referred to here is a valid Oracle (DB object) identifier, for which all naming rules apply. ac_Abc.88 is not a valid name, because in Oracle you can't have an identifier starting with a digit.

    To resolve your problem with parsing strings of comma-delimited values, use the solution of Lalit Kumar B's.

提交回复
热议问题