-2

我在 oracle 中运行以下查询,我面临错误ORA-06553

select cast(cbdev.cbchr(utl_raw.substr(4500, 5, 26)) AS DECIMAL (14, 2)) as grant_held 
  from bs_transaction 
 where account_coid = 'TS 0014 T8324J3L2V' 
   and txn_id = 21;

当语法似乎正确时,不确定为什么 substr 会引发错误。有人可以帮我解决这个问题。

4

1 回答 1

0

尝试以下操作:

select cast(cbdev.cbchr(utl_raw.substr('4500', 5, 26)) AS DECIMAL (14, 2)) as grant_held 
  from bs_transaction 
 where account_coid = 'TS 0014 T8324J3L2V' 
   and txn_id = 21;
于 2018-12-28T08:26:47.090 回答