Other 70-442GB2312 Exams :

70-442GB2312 Exam

PRO:Design & Optimize Data Access by Using MS SQL Serv 2005

  • Exam Number/Code : 70-442GB2312
  • Exam Name : PRO:Design & Optimize Data Access by Using MS SQL Serv 2005
  • Questions and Answers : 91 Q&As
  • Update Time: 2011-03-30
  • Price: $ 150.00 $ 99.00

Free 70-442GB2312 Demo Download

pass999.info offers free demo for Microsoft Licensing 70-442GB2312 exam (PRO:Design & Optimize Data Access by Using MS SQL Serv 2005). You can check out the interface, question quality and usability of our practice exams before you decide to buy it. We are the only one site can offer demo for almost all products.

Download 70-442GB2312 Exam Testing Engine


70-442GB2312 Exam Description

It is well known that latest 70-442GB2312 exam test is the hot exam of Microsoft certification. pass999.info offer you all the Q&A of the 70-442GB2312 real test . It is the examination of the perfect combination and it will help you pass 70-442GB2312 exam at the first time!

 
 
Exam : Microsoft 70-442GB2312
Title : PRO:Design & Optimize Data Access by Using MS SQL Serv 2005


1. 您是公司的数据库开发人员。一个名为 Articles 的表包含报纸文章,其设计如下所示。
ArticleID (PK)
Title
ArticleXml
CategoryID (FK)
int
nvarchar(50)
xml
int
ArticleXml 列中的 XML 文档如下所示。
<article>
<paragraph>...</paragraph>
<image>...</image>
...
<image>...</image>
...
</article>您需要设计一个查询,该查询将按照 CategoryID 值显示图像的总数。
您应该使用哪个查询?
A. SELECT
CategoryID
,COUNT(ArticleXml.value('count(/article/image)',
'INT')) AS NumberOfImages
FROM Articles
GROUP BY CategoryID;
B. SELECT
CategoryID
,COUNT(ArticleXml.exist('/article/image')
AS NumberOfImages
FROM Articles
GROUP BY CategoryID;
C. SELECT
CategoryID
,SUM(ArticleXml.value('count(/article/image)', 'INT'))
AS NumberOfImages
FROM Articles
GROUP BY CategoryID;
D. SELECT
CategoryID
,SUM(ArticleXml.exist('/article/image')
AS NumberOfImages
FROM Articles
GROUP BY CategoryID;
Answer: C

2. 您是公司的数据库开发人员。在您的数据库中,Employees 表包含大约 1,000 行,Orders 表包含数百万行。
Employees 表设计为如下所示。
EmployeeID (PK)
Firstname
Lastname
...
int
nvarchar(30)
nvarchar(30)
...
Orders 表设计为如下所示。
OrderID (PK)
SoldByEmployeeID (FK)
OrderDate
...
int
int
datetime
...
您需要编写一个查询,该查询返回每位员工所下的订单数。
您应该使用哪个查询?
A. SELECT e.Firstname, e.Lastname, COUNT(*)
FROM Employees AS e
LEFT OUTER JOIN Orders AS o
ON o.SoldByEmployeeID = e.EmployeeID
GROUP BY e.Firstname, e.Lastname
B. SELECT e.Firstname, e.Lastname, COUNT(*)
FROM Employees AS e
LEFT OUTER JOIN Orders AS o
ON o.SoldByEmployeeID = e.EmployeeID
GROUP BY e.EmployeeID, e.Firstname, e.Lastname
C. SELECT e.Firstname, e.Lastname, COUNT(o.OrderID)
FROM Employees AS e
LEFT OUTER JOIN Orders AS o
ON o.SoldByEmployeeID = e.EmployeeID
GROUP BY e.EmployeeID, e.Firstname, e.Lastname
D. SELECT e.Firstname, e.Lastname, COUNT(o.OrderID)
FROM Employees AS e
LEFT OUTER JOIN Orders AS o
ON o.SoldByEmployeeID = e.EmployeeID
GROUP BY e.Firstname, e.Lastname
Answer: C

3. 您是公司的数据库开发人员。现必须优化 Stockholm 市订单的处理例程,以获得更好的性能。
当前例程如以下代码段所示。
...
DECLARE OrderCursor CURSOR FOR
SELECT OrderID, City, CustomerID FROM Orders;
OPEN OrderCursor;
FETCH NEXT FROM OrderCursor INTO @OrderID, @CustomerID, @City;
WHILE(@@FETCH_STATUS = 0)
BEGIN
IF(@City <> 'Stockholm')
GOTO Next;
<Code for processing order>
Next:
FETCH NEXT FROM OrderCursor INTO
@OrderID, @CustomerID, @City;
END
...
您需要优化该例程以获得最佳性能。
您应该怎么办?
A. 将游标更改为以 DYNAMIC 形式声明。
B. 将游标更改为以 KEYSET 形式声明。
C. 将游标更改为以 STATIC 形式声明。
D. 更改游标中的 SELECT 语句以包括 WHERE City = 'Stockholm'。
E. 将 IF 语句更改为检查 @City = 'Stockholm',从而避免使用 GOTO 语句。
Answer: D

4. 您是公司的数据库开发人员。您负责在公司新的 SQL Server 2005 计算机上将名为 DB1 和 DB2 的两个现有 SQL Server 2000 数据库合并为一个名为 NewDB 的数据库。
以下查询在用于访问 DB1 数据库的旧应用程序中可以正常工作。
SELECT * FROM Customer WHERE FaxNumber = NULL
但是,该查询在新的 SQL Server 2005 计算机上运行时将不会返回任何行,即使 FaxNumber 列中存在 NULL 值。
您需要解决该问题,以使该查询在 SQL Server 2005 计算机上能正常工作。您需要确保您的解决方案不会影响 DB2 中表和查询的行为。
您应该怎么办?
A. 使用 ISNULL 函数,而不是 = NULL。
B. 将 = NULL 更改为 IS NULL。
C. 将 = NULL 更改为 = 'NULL'。
D. 在查询前面添加以下命令:SET ANSI_NULLS ON
E. 使用 ALTER DATABASE 命令将 ANSI_NULLS 数据库选项更改为 ON。
Answer: B

5. 您是公司的数据库开发人员。有一个将订单项保存到 OrderItems 表的过程。如果该项不存在,则应执行插入。如果该项存在,则应执行更新。OrderItems 表设计为如下所示。
OrderID (PK, FK)
ProductID (PK, FK)
Quantity
int
int
int
您需要开发一个使用最少量资源的例程。
您应该使用哪个例程?
A. BEGIN TRY
UPDATE OrderItems SET Quantity = @Quantity
WHERE OrderID = @OrderID
AND ProductID = @ProductID;
END TRY
BEGIN CATCH
INSERT OrderItems (OrderID, ProductID, Quantity)
VALUES (@OrderID, @ProductID, @Quantity);
END CATCH
B. IF EXISTS (SELECT * FROM OrderItems
WHERE OrderID = @OrderID
AND ProductID = @ProductID
)
UPDATE OrderItems SET Quantity = @Quantity
WHERE OrderID = @OrderID
AND ProductID = @ProductID;
ELSE
INSERT OrderItems (OrderID, ProductID, Quantity)
VALUES (@OrderID, @ProductID, @Quantity);
C. IF NOT EXISTS (SELECT * FROM OrderItems
WHERE OrderID = @OrderID
AND ProductID = @ProductID
)
INSERT OrderItems (OrderID, ProductID, Quantity)
VALUES (@OrderID, @ProductID, @Quantity);
ELSE
UPDATE OrderItems SET Quantity = @Quantity
WHERE OrderID = @OrderID
AND ProductID = @ProductID;
D. UPDATE OrderItems SET Quantity = @Quantity
WHERE OrderID = @OrderID AND ProductID = @ProductID;
IF(@@ROWCOUNT = 0)
INSERT OrderItems (OrderID, ProductID, Quantity)
VALUES (@OrderID, @ProductID, @Quantity);
Answer: D

What's pass999.info and what pass999.info can do?

pass999.info provides high quality IT exam practice questions and answers. Especially, Cisco CCNA CCDA CCNP CCIE, Checkpoint CCSE, CompTIA A+ Network+ certification practice exams and so on. We promise that you can pass any IT exam at the first try using pass999.info Testing Engine, or else give you a FULL REFUND. In pass999.info, you also can find latest exam releases about real certification exam resources from most famous IT companies, and we recommend some hot exams for you.

About Microsoft 70-442GB2312 exam

There are many ways to prepare for your 70-442GB2312 Certification Exam. pass999.info provides the most reliable training tools to prepare for your next 70-442GB2312 Certification Exam. Our 70-442GB2312 Certification Study Material includes 70-442GB2312 test questions, 70-442GB2312 practice exam, 70-442GB2312 Practice Testing Software, 70-442GB2312 Audio Learning and Preparation Labs. We will meet the needs of all about IT certification in pass999.info.

The 70-442GB2312 test questions give you possibility to work in any country of the world because they are acknowledged in all countries equally. This pass999.info 70-442GB2312 torrent certificate helps not only to improve your knowledge and skills, but it also helps your career, gives a possibility for qualified usage of pass999.info 70-442GB2312 exam products under different conditions.

Once you purchase our 70-442GB2312 PDF,we will offer you the best service.After you purchase we will offer free update in time for 90 days.No matter any questions you have we will help you solve it. And in 3 weeks we will offer you free updates,so please pay attention our site at all times.