如何显示查询的结果数据
我正在运行以下 SQL 语句:
SELECT
TS_MESSAGE,
TX_SERVICENAME,
TX_CONFIRMATION "Conf",
TX_SS_MESSAGE,
TX_OMS_MESSAGE,
a.fl_resend_message
from INTF_OMS.LOG_WEB_SERVICE_SS_INITIATED a
where tx_servicename like '%mobileUserForcedToSignOff%'
--and tx_ss_message like '%e50702%'
and tx_ss_message like '%E30046%'
and a.ts_message like '%25-JAN-11%'
order by ts_message asc
我得到了我想要的结果,但是 tx_ss_message 列包含以下信息:
<?xml version="1.0" encoding="UTF-8"?>
<MobileUserForcedToSignOff>
<MessageId></MessageId>
<MessageDate>20110125</MessageDate>
<MessageTime>1853</MessageTime>
<DispatchUserId>E30046</DispatchUserId>
<MobileUserId>e19952</MobileUserId>
</MobileUserForcedToSignOff>
我真正想要的是,当我运行查询时,它只返回 DispatchUserID、MessageDate 和 MobileUserID。
关于如何实现这一目标有什么建议吗?
I am running the following SQL statement:
SELECT
TS_MESSAGE,
TX_SERVICENAME,
TX_CONFIRMATION "Conf",
TX_SS_MESSAGE,
TX_OMS_MESSAGE,
a.fl_resend_message
from INTF_OMS.LOG_WEB_SERVICE_SS_INITIATED a
where tx_servicename like '%mobileUserForcedToSignOff%'
--and tx_ss_message like '%e50702%'
and tx_ss_message like '%E30046%'
and a.ts_message like '%25-JAN-11%'
order by ts_message asc
I get the results I want, however the columns tx_ss_message contains the following information:
<?xml version="1.0" encoding="UTF-8"?>
<MobileUserForcedToSignOff>
<MessageId></MessageId>
<MessageDate>20110125</MessageDate>
<MessageTime>1853</MessageTime>
<DispatchUserId>E30046</DispatchUserId>
<MobileUserId>e19952</MobileUserId>
</MobileUserForcedToSignOff>
What I really want, is when I run the query, is for it to return ONLY The DispatchUserID, MessageDate, and MobileUserID.
Any suggestions on how to accomplish this?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
在您已有的查询之外编写一个查询,用于解析您想要的 3 个项目的 xml
Write a query outside the one you already have that parses the xml for the 3 items you want