14. What built in functions can be used with the Group By statement? 15. What is
ID: 3716301 • Letter: 1
Question
14. What built in functions can be used with the Group By statement?
15. What is the SQL statement HAVING used for?
16. Be able to normalize a table to 4th normal form?
17. Be able to write SQL statements that will provide information from a DB using specific dates and time.
18. Be able to do an INNER and OUTER JOIN sql statements.
19. Be able to provide information about a customers that did not purchase a particular item
20. Give SQL statements for creating a Table
21. Be able to write stored procedures
22. What is an N-Ary association?
Explanation / Answer
14. Having clause is an built in function used in Group By statement.
15. Having clause is used as filter in SQL statement. It can be used with Group By clause only. Since having can be used with aggregate function only. Below is syntax:
SELECT column_name(s)
FROM table_name
GROUP BY column_name(s)
HAVING condition;
16. 4th normal form is not available in relational database.
17. We need to use '''WHERE' clause to get special data related to Date And Time. Below is symsyn
SELECT column_name(s)
FROM table_name
WHERE date_column_name ='2018-04-01 22:44:30.012'
18. INNER JOIN and OUTEEJOIN can be done only when common columns available in both joining tables. Below is syntax:
Select columns from table1 t1 inner join table2 t2 on t2.colum =t2.column
19. In order to find customer who not purchased particular item, we need to use NOT IN condition in WHERE clause. Below is example.
Select * from customer where customerid not in (select customerid from item where itemname='givename');
20. Create table TABLENAME ( column1 data type, column2 data type, column3 datatype)
Example:
CREATE TABLE Persons (
PersonID int,
LastName varchar(255),
FirstName varchar(255),
Address varchar(255),
City varchar(255)
);
22. Create Procedure insertdata AS
Begin Insert into person values (1,'John','jeddy','1 balah 491','burbank') END;
22. An association exist between 2 or more classes is know as N-Ary association.
Related Questions
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.