sql技术
文章平均质量分 71
chyonglong
这个作者很懒,什么都没留下…
展开
-
sql server里用到数组
insert #array select CChessas str union all select Digas str union all select GoBangas str union all select LandLordas str union all select Majiangcreate proc [dbo]转载 2007-04-15 10:53:00 · 970 阅读 · 0 评论 -
SQL查找按字段分组且组中最小的所有该表的所有属性
①利用临时表,先存储按分组和每组最小的数据,再和表连接,查找表所有属性create table #array (EmployeeID int,min_OrderID int)insert #array select EmployeeID,min(OrderID) from orders group by EmployeeIDselect * from #arrays原创 2007-04-15 11:01:00 · 994 阅读 · 0 评论 -
游标的使用--从游标提取数据
USE NorthwindGO--声明一个游标DECLARE toolbar_cursor CURSOR FOR SELECT ProductID,ProductName,CategoryIDFROM Products where CategoryID=2 --打开游标OPEN toolbar_cursor --定义接收游标属性的变量declare @Product原创 2007-04-18 12:59:00 · 4073 阅读 · 1 评论 -
(转)怎样建立全文索引
微软的SQL Server数据库是一个在中低端企业应用中占有广泛市场的关系型数据库系统,它以简单、方便、易用等特性深得众多软件开发人员和数据库管理人员的钟爱。但SQL Server 7.0以前的数据库系统由于没有全文检索功能,致使无法提供像文本内容查找此类的服务,成为一个小小的遗憾。从SQL Server 7.0起,到如今的SQL Server 2000终于具备了全文检索功能,使用户可以高效地检索转载 2007-06-19 11:44:00 · 600 阅读 · 0 评论 -
sql一些语句
1.按姓氏笔画排序:Select * From TableName Order By CustomerName Collate Chinese_PRC_Stroke_ci_as2.数据库加密:select encrypt(原始密码)select pwdencrypt(原始密码)select pwdcompare(原始密码,加密后密码) = 1--相同;否则不相同原创 2008-07-09 19:52:00 · 355 阅读 · 0 评论