通行证: 用户 密码 域名空间  下载中心 社区论坛 信息公告 MY小屋
联系我们
设为首页
加入收藏

 

QQ,ASP,PHP,JSP,XML,SQL,.Net,编程 程序 网页图象 建站经验 私服
首页 | 新闻资讯 | 编程开发 | 网页设计 | 图形图象 | 网络媒体 | 网站模板 | 数 据 库 | 投稿
论坛 | 操作系统 | 系统优化 | 网络安全 | 黑客技术 | 硬件学堂 | 硬件报价 | 服 务 器 | 地图
专题 | 应用软件 | 聊天通讯 | Q Q 专栏 | 建站经验 | 在线工具 | 站长Club | 注 册 表 | 旧版
社会 | 游戏娱乐 | 设计欣赏 | 疑难解答 | 社区论坛 | 韩国素材 | 素材图库 | 广告服务 | 服务
当前位置:首页>>数 据 库>>MySQL>>正文 新版上线![旧版]
注:打开慢时请稍等

某外企SQL Server面试题

http://www.iyit.net  日期:2006-6-6 9:16:49  来源:  点击:
参加讨论

Question5: The Fastest Way to Recompile All Stored Procedures
I have a problem with a database running in SQL Server 6.5 (Service Pack 4). We moved the database (object transfer) from one machine to another last night, and an error (specific to a stored procedure) is cropping up. However, I can't tell which procedure is causing it. Permissions are granted in all of our stored procedures; is there a way from the isql utility to force all stored procedures to recompile?

Tips: sp_recompile can recomplie a store procedure each time
Answer 5:在执行存储过程时,使用 with recompile 选项强制编译新的计划;使用sp_recompile系统存储过程强制在下次运行时进行重新编译

Question6: How can I add row numbers to my result set?
In database pubs, have a table titles , now I want the result shown as below,each row have a row number, how can you do that?
Result:
line-no     title_id
----------- --------
1           BU1032
2           BU1111
3           BU2075
4           BU7832
5           MC2222
6           MC3021
7           MC3026
8           PC1035
9           PC8888
10          PC9999
11          PS1372
12          PS2091
13          PS2106
14          PS3333
15          PS7777
16          TC3218
17          TC4203
18          TC7777
Answer 6:
--SQL 2005的写法
select row_number() as line_no ,title_id from titles
--SQL 2000的写法
select line_no identity(int,1,1),title_id into #t from titles
select * from #t
drop table #t

Question 7: Can you tell me what the difference of two SQL statements at performance of execution?
Statement 1:
if NOT EXISTS ( select * from publishers where state = 'NY')
begin
SELECT 'Sales force needs to penetrate New York market'
end
else
begin
SELECT 'We have publishers in New York'
end
Statement 2:
if EXISTS ( select * from publishers where state = 'NY')
begin
SELECT 'We have publishers in New York'
end
else
begin
SELECT 'Sales force needs to penetrate New York market'
end
Answer 7:不同点:执行时的事务数,处理时间,从客户端到服务器端传送的数据量大小

Question8: How can I list all California authors regardless of whether they have written a book?
In database pubs, have a table authors and titleauthor , table authors has a column state, and titleauhtor have books each author written.

本新闻共4页,当前在第2页  1  2  3  4  


编辑:黑鹰 [发送给好友] [打印本页] [关闭窗口] [返回顶部]
上一篇:同步两个SQLServer数据库
下一篇:没有了
转载请注明来源:www.iyit.net
特别声明: 本站除部分特别声明禁止转载的专稿外的其他文章可以自由转载,但请务必注明出处和原始作者。文章版权归文章原始作者所有。对于被本站转载文章的个人和网站,我们表示深深的谢意。如果本站转载的文章有版权问题请联系编辑人员,我们尽快予以更正。

 相关文章
oracle监控数据库性能的SQL汇总 同步两个SQLServer数据库 SQL Server:错误18483
SQL2005其中三个版本的比较 远程连接sql server 2000服务器的解决方 SQL Server中发送邮件的新方式
如何自动发布MS SQL SERVER数据库 SQL Server数据库文件恢复技术 黑客攻破SQL服务器系统的十种方法
SQL Server数据库安全规划全攻略 保护SQL Server数据库的十大绝招 探讨SQL Server中Case 的不同用法
跟我学MS SQL Server(1) 跟我学MS SQL Server(2) 跟我学MS SQL Server(3)
跟我学MS SQL Server(4) 跟我学MS SQL Server(5) 跟我学MS SQL Server(6)
跟我学MS SQL Server(7) 跟我学MS SQL Server(8) 跟我学MS SQL Server(9)
SQL Server中死锁产生的原因及解决办法 Sql server一些Select检索高级用法  SQL Server和Access、Excel数据传输
最新更新 热点排行 推荐新闻
某外企SQL Server面试题
同步两个SQLServer数据库
SQL Server:错误18483
SQL2005其中三个版本的比较
远程连接sql server 2000服务器的解决
ORACLE碎片整理(1)
ORACLE碎片整理(2)
Oracle如何精确计算row的大小
oracle监控数据库性能的SQL汇总
Oracle logminer使用方法总结
某外企SQL Server面试题
同步两个SQLServer数据库
SQL Server:错误18483
SQL2005其中三个版本的比较
远程连接sql server 2000服务器的解决
MYSQL用户帐号管理
MySQL服务器的启动和关闭
MySQL不支持的功能
在Windows上安装MySQL
在MYSQL结果集上执行计算、
QQ最新版下载 2006 beta2 体验新感受 
QQ密码破解程序
Windows XP专业版IIS连接数的更改
QQ密码本地破解
Office2007简体中文版浮出水面 美图抢
Visual Basic 概述
解决暴风影音无法渲染此文件的难题
解决Windows中的explorer.exe出错
exeplorer.exe错误的问题的总结、解决
一个好汉N个帮 Word实用插件集锦
巧用ACDSee 8.0截取QQ表情每一帧
解除瑞星 诺顿遗留下的杀毒兼容问题
第一款开源AJAX安全扫描工具Sprajax
WinRAR人性化功能揭密
在ASP.NET中防止注入攻击
用ASP.NET开发Web服务的五则技巧
Linux操作系统12则经典应用技巧
浅谈Linux优化及安全配置的个人体会
解决局域网不能互相访问之全攻略
WIN 2000简单的入侵常识
 友情链接
设置首 页 - 版权声明 - 广告服务 - 关于我们 - 联系我们 - 友情连接
Copyrights © 2004-2006 iYiT.Net All Rights Reserved.
网站合作、广告联系QQ:147007642、466949678
易特网络技术 点击这里给我发消息