关于ORACLE查询列加()or () 报ORA-00923:未找找到要求的FROM关键字

前端之家收集整理的这篇文章主要介绍了关于ORACLE查询列加()or () 报ORA-00923:未找找到要求的FROM关键字前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。

SQL查询列中包含()() 执行的时候会报ORA-00923:未找找到要求的FROM关键字,

ORACLE会默认列中别名非字母汉字的符号为特殊字符,需用" "

例子:

SELECT to_char(t.gmt_create,'YYYYMMDD HH24miss')订单时间,

t.card_name姓名,

t.exchange_amount金额(分),

t.card_index卡索引,

t.core_trans_id交易核心流水,

t.order_no支付核心流水,

t.status交易状态,

t.real_channel_id渠道ID,

t.bank_resp_code银行返回码,

t.bank_resp_msg银行返回信息

FROMfxo_withdraw_apply t

wheret.core_trans_idin(

'O0060005201610260000001287929160'

)orderbyt.core_trans_id;

SELECT to_char(t.gmt_create,

t.bank_resp_msg银行返回信息

FROMfxo_withdraw_apply t

wheret.core_trans_idin(

'O0060005201610260000001287929160'

)orderbyt.core_trans_id;

SELECT to_char(t.gmt_create,

t.card_name姓名,

t.exchange_amount金额(分),

t.card_index卡索引,

t.core_trans_id交易核心流水,

t.order_no支付核心流水,

t.status交易状态,

t.real_channel_id渠道ID,

t.bank_resp_code银行返回码,

t.bank_resp_msg银行返回信息

FROMfxo_withdraw_apply t

wheret.core_trans_idin(

'O0060005201610260000001287929160'

)orderbyt.core_trans_id;



解决方法

SELECT to_char(t.gmt_create,

t.exchange_amount "金额(分)",

t.card_index卡索引,

t.bank_resp_msg银行返回信息

FROMfxo_withdraw_apply t

wheret.core_trans_idin(

'O0060005201610260000001287929160'

)orderbyt.core_trans_id;

猜你在找的Oracle相关文章