标签:ar 使用 sp bs as new nbsp sql ui
在SQLServer中使用该sql语句可以生成GUID:select cast(NEWID() as varchar(36)) as uuid
通过一下语句将GUID中的‘-‘字符去掉:
select SUBSTRING(uuid,1,8)+SUBSTRING(uuid,10,4)+SUBSTRING(uuid,15,4)+
SUBSTRING(uuid,20,4)+SUBSTRING(uuid,25,12) from (select cast(NEWID() as varchar(36)) as uuid ) s
在oracle中使用select sys_guid() from dual;可以获得guid。
标签:ar 使用 sp bs as new nbsp sql ui
原文地址:http://www.cnblogs.com/toSeeMyDream/p/4140365.html