Frage 1
Frage
You have the following table:
Antworten
-
foreign key
-
clustered index
-
nonclustered index
-
foreign key
-
clustered index
-
nonclustered index
Frage 2
Frage
You have the following SQL query SELECT * FROM dbo.ProAthlete WHERE Salary > 500000
The query takes too much time to return data. You need to improve the performance of
the query. Which item should you add to the Salary column?
Antworten
-
Non-null constraint
-
Default constraint
-
Index
-
Foreign key
Frage 3
Frage
This question requires that you evaluate the underlined text to determine if it is correct.
The CREATE TABLE command removes one or more table definitions and all data, indexes,
triggers, constraints, and permission specifications for those tables.
Instructions: Review the underlined text. If it makes the statement correct, select “No
change is needed.” If the statement is incorrect, select the answer choice that makes the
statement correct:
Antworten
-
No change is needed
-
DROP TABLE
-
TRUNCATE TABLE
-
ALTER TABLE
Frage 4
Frage
You have a table named Employee that includes four columns. You execute the following statement:
SELECT * FROM Employee
Which columns are returned?
Frage 5
Frage
Which keyword must be included in a create view statement?
Antworten
-
WHERE
-
ORDER BY
-
UPDATE
-
SELECT
Frage 6
Frage
The Product table contains the following data.
You execute the following statement:
SELECT COUNT(*) FROM Product WHERE Quantity > 18
What is the value returned by this statement?
Frage 7
Frage
You have a table that contains information about all students in your school. Which SQL keyword should you use to change a student’s first name in the table?
Antworten
-
UPDATE
-
CHANGE
-
SELECT
-
INSERT
Frage 8
Frage
Which keyword would you use in a select statement to return rows that meet a specific condition?
Antworten
-
WHERE
-
UNION
-
ORDER BY
-
FROM
Frage 9
Frage
You have the following table definition:
CREATE TABLE Product (ID INTEGER PRIMARY KEY, Name VARCHAR(20), Quantity INTEGER)
The Product table contains the following data.
You execute the following statement:
SELECT Name FROM Product WHERE Quantity IS NOT NULL
How many rows are returned?
Frage 10
Frage
You execute the following statement:
SELECT EmployeeID, FirstName, DepartmentName FROM Employee,
Department This type of operation is called a/an:
Antworten
-
Intersection
-
Outer join
-
Equi-join
-
Cartesian product
Frage 11
Frage
You are writing an SQL statement to retrieve rows from a table. Which data manipulation
language (DML) command should you use?
Frage 12
Frage
which command used to removes all rows from a table without logging the individual row deletions.
Antworten
-
DROP TABLE
-
TRUNCATE TABLE
-
CREATE TABLE
-
ALTER TABLE
Frage 13
Frage
You need to delete a database table. Which data definition language (DDL) keyword should you use?
Antworten
-
ALTER
-
DELETE
-
DROP
-
TRUNCATE
Frage 14
Frage
You need to rename a column in a database table. Which data definition language (DDL)
statement should you use?
Antworten
-
ALTER
-
INSERT
-
CREATE
-
UPDATE
Frage 15
Frage
What are three valid data manipulation language (DML) commands? (Choose three.)
Antworten
-
INSERT
-
COMMIT
-
DELETE
-
OUTPUT
-
UPDATE
Frage 16
Frage
You are writing an SQL statement to retrieve rows from a table. Which data manipulation
language (DML) command should you use?
Frage 17
Frage
17. You have the following table definition:
CREATE TABLE Road (RoadID INTEGER NOT NULL, Distance INTEGER NOT NULL)
The Road table contains the following data:
You execute the following statement:
INSERT INTO Road VALUES (1234, 36)
What is the result?
Frage 18
Frage
You need to enable a new employee to authenticate to your database. Which command should you use?
Antworten
-
ALLOW USER
-
CREATE USER
-
ADD USER
-
INSERT USER
-
ALTER USER
Frage 19
Frage
This question requires that you evaluate the underlined text to determine if it is correct.
Create a query that returns a set of table data by using the UPDATE statement.
Instructions: Review the underlined text. If it makes the statement correct, select “No
change is needed.” If the statement is incorrect, select the answer choice that makes the
statement correct.
Antworten
-
No change is needed
-
INSERT
-
REPLACE
-
SELECT
Frage 20
Frage
You accept an IT internship at a local charity. The charity asks you to keep a record of its
volunteers by using a database table named Volunteer. The table has the following
columns and rows:
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 21
Frage
You have a table that contains product IDs and product names. You need to write an
UPDATE statement to change the name of a specific product to glass. What should you
include in the update statement?
Antworten
-
SET ProduetName = ‘glass’
-
LET ProduetName = ‘glass’
-
EXEC ProduetName = ‘glass’
-
ASSIGN ProduetName = ‘glass’
Frage 22
Frage
You have a table of products with fields for ProductID, Name, and Price. You need to write
an UPDATE statement that sets the value in the InStock field to Yes for a specific ProductID.
Which clause should you use in your update statement?
Antworten
-
THAT
-
WHERE
-
GROUP BY
-
HAVING
Frage 23
Frage
You need to list the name and price of each product, sorted by price from highest to lowest.
Which statement should you use?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 24
Frage
You have a table named Customer. You need to add a new column named District. Which
statement should you use?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 25
Frage
You need to remove a view named EmployeeView from your database. Which statement
should you use?
Antworten
-
DELETE VIEW EmployeeView
-
DELETE EmployeeView
-
DROP EmployeeView
-
DROP VIEW EmployeeView
Frage 26
Frage
On which database structure does an update statement operate?
Frage 27
Frage
You need to populate a table named EmployeeCopy with data from an existing table named Employee.
Which statement should you use?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 28
Frage
You execute the following statement:
SELECT DepartamentName
FROM Departament
WHERE DepartamentID =
(SELECT DepartamentID
FROM Employee
WHERE EmployeeID = 1234
This statement is an example of a/an:
Antworten
-
Subquery
-
Union
-
Outer join
-
Cartesian product
Frage 29
Frage
Which command should you use to add a column to an existing table?
Antworten
-
MODIFY
-
ALTER
-
UPDATE
-
INSERT
-
CHANGE
Frage 30
Frage
Which keyword can be used in a create table statement?
Antworten
-
ORDER BY
-
DISTINCT
-
GROUP BY
-
UNIQUE
Frage 31
Frage
Which statement creates a composite key?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 32
Frage
You are creating a database object named Student to store the following data:
Which syntax should you use to create the object?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 33
Frage
You have a database table named SongInformation as defined below:
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 34
Frage
You accept an IT internship at a local charity. The charity asks you to keep a record of its volunteers by using a database table named Volunteer. When volunteers ask to be removed from mailing lists, the table must be updated. You need to use a transaction to ensure that the database has data integrity and referential integrity. Which statement should you use?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 35
Frage
You have a database table that contains the following columns:
Which two Structured Query Language (SQL) statements can you use? (Choose two.)
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 36
Frage
You have the database table named Cars as defined below:
How many rows are returned by the SQL statement?
Frage 37
Frage
Your database contains a table named Customer. You need to delete the record from the Customer table that has a CusromerID of 12345.
Which statement should you use?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 38
Frage
You have the following table definition:
CREATE TABLE Product (ProductID INTEGER, Name VARCHAR(20))
You need to insert a new product. The product’s name is Plate and the product’s ID is 12345. Which statement should you use?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 39
Frage
Which statement deletes the rows where the employee’s phone number is not entered?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 40
Frage
You need to insert two new products into the Product table. The first product is named Book and has an ID of 125. The second product is named Movie and has an ID of 126. Which statement should you use?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
-
Option E
Frage 41
Frage
You have a table named Product that contains the following data.
The PrcducrID column is the primary key. The CategoryID column is a foreign key to a separate table named Category. You execute the following statement:
INSERT INTO Product VALUES (3296, ‘Table’, 4444)
What is the result?
Antworten
-
a foreign key constraint violation
-
a syntax error
-
a new row in the Product table
-
a primary key constraint violation
-
a new row in the Category table
Frage 42
Frage
You have a table named Employee that includes the following columns:
EmployeeID
Smp1oyeeName
Which statement should you use to return the number of rows in the table?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D
Frage 43
Frage
You have a table named Product. The Product table has columns for ProductDescription and ProductCategory.
You need to change the ProductCategory value for all the spoons in the Product table to 43.
Which statement should you use?
Antworten
-
Option A
-
Option B
-
Option C
-
Option D