开发者

How to format Oracle SQL query

I have this excursie

Write the query, showing prices of all products in one column with the following condition: "The price [Product Na开发者_如何学JAVAme] is [Price] lv.

The table looks like this

How to format Oracle SQL query


If I understood your question correctly, what you are looking for is the concatenation operator ||

You can produce the product name and price in one column like this

SELECT 'The price of [' || PRODNAME || '] is [' || PRODAJNACENA || '] lv' 
FROM your_table_name;
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜