This action might not be possible to undo. Are you sure you want to continue?
a) Only One b) All that apply c) all Referenced d) None
2. Which statement is valid when removing procedures? a) Use a drop procedure statement to drop a standalone procedure b) Use a drop procedure statement to drop a procedure that is part of a package. Then recompile the package specification. c) Use a drop procedure statement to drop a procedure that is part of a package. Then recompile the package body. d) For faster removal and re-creation, do not use a drop procedure statement. Instead, recompile the procedure using the alter procedure statement with the REUSE SETTINGS clause. 3. You query the database with this command SELECT name FROM employee WHERE name LIKE ‘_a%’; Which names are displayed? a) Names starting with ?a? b) Names starting with ?a? or ?A? c) Names containing ?a? as second character. d) Names containing ?a? as any letter except the first. 4. Which of these is the default character for specifying runtime variable in SELECT statement a) Ampersand b) Ellipses c) Quotation marks d) Asterisk
You want to execute a procedure from SQL plus. p_amount OUT NUMBER(10. stored procedures and functions within SQL*Plus a) DBMS_DISPLAY b) DBMS_OUTPUT c) DBMS_LIST d) DBMS_DESCRIBE 8.2)) 6.p_amount OUT NUMBER) d) CREATE OR REPLACE FUNCTION tax_amt(p_id NUMBER) RETURN NUMBER(10.5. Which Oracle supplied package can you use to output values and messages from database triggers. Which command will display to show the argument list? . Which of the program declarations are correct for a stored program unit? (choose 2) a) CREATE OR REPLACE FUNCTION tax_amt(p_id NUMBER) RETURN NUMBER b) CREATE OR REPLACE PROCEDURE tax_amt(p_id NUMBER) RETURN NUMBER c) CREATE OR REPLACE PROCEDURE tax_amt(p_id NUMBER. However you are not given the argument list for the procedure. Which procedure can be used to create a customized error message? a) RAISE_ERROR b) SQLERRM c) RAISE_APPLICATION_ERROR d) RAISE_SERVER_ERROR 7.2) e) CREATE OR REPLACE PROCEDURE tax_amt(p_id NUMBER.
11. a) TRUE b) FALSE .What should you do after each fetch statement in PL/SQL block? a) Open the cursor b) Close the cursor c) Initialize the loop d) Test for the rows using the cursor attribute.a) DESCRIBE b) SHOWLIST c) SHOW ARG_LIST d) SHOW PROCEDURE 9. Which data dictionary views gives you the names and the source code of the procedure that you have created? a) USER_SOURCE b) USER_OBJECTS c) USER_PROCEDURES d) USER_SUBPROGRAMS 10.Can you use a commit statement within a database trigger? a) TRUE b) FALSE 12.SQL%ISOPEN for implicit cursor is always evaluate to false.
first_name from emp where last_name=upper(‘smith’). sal. Which clause will cause an error? .sal.*12 from emp. The SAL column stores the monthy salary of the employee. d) SELECT ename.12*sal+100 from emp. first_name from emp where upper(last_name)=’smith’. d) Select last_name. b) Select last_name. c) Select last_name.You want to display the details of employess whose lastname is smith. Which change must be made to the above syntax to calculate the annual compensation as “monthly salary plus a monthly bonus of $100. Creating a foreign key constraint between columns of two tables defined with two different datatypes will procedure an error. 14.00 c) Group by “Product ID”. Which statement will list all the employees whose last name is smith? a) Select last_name. 15. (12*sal)+100 from emp. 12*(sal+100) from emp. c) SELECT ename.sum(price) “Price” a) From products b) Where price>60.sal. first_name from emp where last_name=’smith’.13. a) True b) False 16.Select product_id “Product_ID”. first_name from emp where lower(last_name)=’smith’.Evaluate this SQL statement: SELECT ename. d) Order by sum(price). multiplies by 12’? a) No change is required to achieve the desired results b) SELECT ename.sal+100. But you are not sure in which case last names are stored.
c) An index is a special way to join 2 or more tables. to describe the column. . 19. b) TRUNCATE * FROM TABLE Sales c) TRUNCATE TABLE Sales.Which of the following SQL statements is correct? a) TRUNCATE Sales TABLE. d) Defines the tables we are selecting or deleting data from. separated by a comma. d) Place the alias at the end of the statement to describe the table. 18. d) An index is a database row attribute. which speeds up data search within a table. b) Is used with the INSERT SQL keyword only.How to specify a column alias? a) Place the alias at the beginning of the statement to describe table b) Place the alias after each column. c) Determines if a value matches any of the values in a list or a sub query. separated by white space.What is an Index? a) An index is a database table attribute. d) TRUNCATE * FROM COLUMN Sales 20.17. which speeds up data search within a table.The IN SQL keyword a) Is used with the DISTINCT SQL keyword only. c) Place the alias after each column. b) An index is the same as alias. describe the column.
The LIKE SQL keyword is used along with a) WHERE clause b) ORDER BY clause c) JOIN clause d) GROUP BY clause 22. Which single command will perform this? a) DROP table student. 23.21. Which of the following lines will produce an error? a) Create or replace function vat (vat_rate IN NUMBER. b) A group function produces a one results from each row in the table.In this PL/SQL statement. e) Delete * from student KEEP STRUCTURE.Which statement describes the use of a group function? a) A group function produces a group of results from one row. price IN NUMBER) b) Declare c) L_vat NUMBER. b) Truncate table student. 24.You have decided to permanently remove all the data from the STUDENT table and you need the table structure in the future. c) A group function produces a one results from many d) A group function produces many of results from many rows. d) Truncate table student KEEP STRUCTURE. d) Begin . c) Delete * from student.
%notfound. d) Specifies the attributes to retrieve rows from.Functions for error trapping are contained in which section of a PL/SQL block? a) HEADER b) DECLARATIVE c) EXECUTABLE d) EXCEPTION 26. .%found b) %found.What does the SQL FROM clause do? a) Specifies a search condition.e) No Error 25. 28.%rowcount c) %rowtype. b) We are joining two tables only c) We are joining more than 2 tables d) We are joining table to itself.%toomanyrows. c) Specifies the columns we are retrieving.%notfound d) None of the Above e) All of the above 27. b) Specifies the tables to retrieve rows from.We refer to a join as a self join when… a) We are using left and right join together.Which three definitions are associated with implicit cursors? a) %rowtype.%rowcount.
Which SQL statement selects all rows from table called contest. a) NULL b) NOT NULL c) Function NVL2 is not defined d) 0None of the above . NULL) from dual.What output is the following statement produce ? Select NVL2(NULL.2006? a) Select * from Contest HAVING ContestDate>=’05/25/2006’ b) Select * from Contest WHERE ContestDate<’05/25/2006’ c) Select * from Contest GROUP BY ContestDate>=’05/25/2006’ d) Select * from Contest WHERE ContestDate>=’05/25/2006’ 30. which column contestDate having Values greater or equal to MAY 25.29.What is a Trigger? a) A Trigger is a special kind of procedures excuted when certain event occurs b) A trigger defines relations between tables.If you don’t specify ASC or DESC after a SQL ORDER BY clause following is used by default: a) There is no default value. c) A trigger is part of data extraction process 32. c) ASC. b) DESC. d) Random 31. ‘NOT NULL’.
b) Locking is a process of database authentication. 36.What does the term ‘locking’ refer to? a) locking is a process. c) Locking is a process preventing users from reading data being changed by other users.What is the database cursor? a) A blinking vertical line that indicates the location of the next input on the display screen. in which TWO of the following cases: a) When SELECT statement returns no rows b) When SELECT statement returns more than one row c) When the datatypes of SELECT clause and INTO clause do not match d) When INTO statement is missing in the SELECT statement 34.33.Which of the following statements about an SQL statement are not correct? . 35. which logs database usage. c) Cursor is acronym for current Set Of Records and is a database object pointing to a d) Currently selected set of records.PL/SQL raises an exception.Which section of a PL/SQL block would most likely contain a RAISE statement? a) Header b) Declarative c) Executable d) Exception 37. b) A cursor is SQL keyword specifying a retrieved data order. and prevents concurrent users from changing the same data at the same time.
b) To return the absolute. d) Keywords can be abbreviated. b) A special way of selecting data. c) SQL statements are ot case-sensitiv. d) To return the minimum value of a numeric expression. c) To return the average value of a numeric expression. unless indicated. which removes redundancy and ambiguity.When there is failure in fetching the rows from a cursor….Can you use both HAVING and WHERE SQL clauses in one SQL statement? a) TRUE b) FALSE 41. 40.What is the ABS SQL function used for? a) To return the maximum value of a numeric expression. 38. 42. positive value of a numeric expression. b) Keywords cannot be split across lines.The table rows are also known as… a) Records b) Fields c) Attributes 39.Normalization is… a) The process of arranging information stored in a database in a way. .a) SQL statements can be on one or more lines. c) The process of adding primary key to a table.
Which of the following can be a valid column name ? .What best describes the relationship between indexes and SQL performance? a) Indexes are only used in special cases b) Indexes are used to make table storage more efficient c) Indexes rarely make a difference in SQL performance d) Indexes exist solely to improve query speed.a) %isopen b) %notfound c) %found d) %rowcount 43.’|| address2 “Address” FROM employe a) 1 b) 2 c) 3 d) 0 e) 4 45.Which of the following statements does count the rows in the ‘Sales’ table? a) SELECT COUNT (*) FROM Sales b) SELECT COUNTER (*) FROM Sales c) SELECT NUM () FROM Sales d) SELECT COUNT(*) IN Sales 44.’||address2||’.How many columns are presented after excuting this query: SELECT address1||’. 46.
COUNT(CustomerName) FROM Orders Order BY CustomerName b) SELECT CustomerName.salary FROM employee WHERE dept_number FROM department WHERE location in (‘CHICAGO’. COUNT(CustomerName) FROM Orders Group BY CustomerName. COUNT(CustomerName) FROM Orders. c) SELECT CustomerName.a) Column b) 1966_Invoices c) Catch_#22 d) #Invoices e) None of the above 47.Which character function can be used to return a specified portion of a character string? a) INSTR b) SUBSTRING .’NEWYORK’)) Why does this statement return an error? a) A multiple row subquery returns an error? b) A single row subquery returns more than one row c) A multiple column subquery returns one column d) A multiple row query uses a single row subquery 49.emp_number.Which of the following SQL statements is correct? a) SELECT CustomerName. 48.Consider the following SELECT statement: SELECT ename.
To produce a meaningful result set without any Cartesian products. which is the minimum number of conditions that should appear in the WHERE clause of a four-table join? a) 8 b) 2 c) 3 d) 4 .c) SUBSTR d) POS 50.
This action might not be possible to undo. Are you sure you want to continue?
We've moved you to where you read on your other device.
Get the full title to continue reading from where you left off, or restart the preview.