一.基本的查询语句,特殊符号||。制定列的别名AS,唯一标示distinct
1.字符连接符“||”与“+”符
oracle:select 列名||’111111111111111′ from 表名sql:select 列名+’111111111111111′ from 表名T
2“AS”符号oracle:select 列名 as 新列名 from 表名 (空格,不能有as)新表名sql:select 列名 as 新列名 from 表名T as(as可有可无) 新表名
二.数据排序与数据
【1】 以XML 返回 (1)未定义属性的 select logisticsId,logisticsName from LogisticsCompany for xml auto,elements (2)定义属性节的 代码如下: SELECT TOP 21 AS Tag, NULL AS Parent, title_id AS [titles!1!title_id], title AS [titles!1!title!element], type AS [titles!1!type] FROM