select vend_name || '(' || vend_country || ')'--把这两列调出来并且country加()
from Vendors
order by vend_name;
--同上的作用,会去掉中间所有的空格
select RTRIM(vend_name) || '(' || RTRIM(vend_country) || ')'
from Vendors
order by vend_name;
select RTRIM(vend_name) || '(' || RTRIM(vend_country) || ')'--赋予列别名
as vend_title
from vendors--不区分大小写
order by vend_name;
--执行计算
select prod_id,quantity,item_price,
quantity*item_price AS expanded_price
from OrderItems
where order_num =20008;
无聊的6.9
最新推荐文章于 2020-12-23 06:10:50 发布