IF YOU GIVE ME YOUR EMAIL, I CAN SEND YOU THE ENTIRE MS ACCESS database so you c
ID: 3548954 • Letter: I
Question
IF YOU GIVE ME YOUR EMAIL, I CAN SEND YOU THE ENTIRE MS ACCESS database so you can better see how to create the queries SO YOU CAN SEE ALL IT INFORMATION NOT ENOUGH. THE STUDENT SECTION ALONE MAY BE LACKING
MY EMAIL IS steveyorks100@yahoo.com AND THATS WHERE YOU WILL SEND ME THE MS ACCESS DATABASE
create a SQL query to satisfy each of the tasks below.
Save each SQL query using the name associated with the task in the table below
MAKE SURE IN MS ACCESS, THE QUERIES YOU CREATE NEED TO THE REQUIREMENTS AND DEMAND OF TASKS ASKED. YOU WILL ONLY CREATE A QUERY SECTION THAT WHEN EXECUTED IN MS ACCESS, WILL RETURN THE RESULTS OF TASKS ASKED. you must create an sql code for each tasks and ensure when executed in ms access will return results of each of qjuestion asl. you should have 10 queries
Explanation / Answer
Write a SQL statement to display Students' First and Last Name.
SELECT LAST_NAME,FIRST_NAME
FROM STUDENT;
Write a SQL statement to display the Major of students with no duplications. Do not display student names.
SELECT DISTINCT MAJOR
FROM STUDENT;
Write a SQL statement to display the First and Last Name of students who live in the Zip code 88888
SELECT LAST_NAME,FIRST_NAME
FROM STUDENT
WHERE ZIP='88888';
Write a SQL statement to display the First and Last Name of students who live in the Zip code 88888 and have the major of Biology.
SELECT LAST_NAME,FIRST_NAME
FROM STUDENT
WHERE ZIP='88888' AND MAJOR='BIOLOGY';
Write a SQL statement to display the First and Last Name of students who live in the Zip code 88888 or 88808. Do not use IN.
SELECT FIRST_NAME,LAST_NAME
FROM STUDENT
WHERE ZIP='88888' OR ZIP='88808';
Write a SQL statement to display the First and Last Name of students who have the major of Biology or Math. Use the SQL command IN
SELECT FIRST_NAME,LAST_NAME
FROM STUDENT
WHERE STUDENT_ID IN ((SELECT STUDENT_ID
FROM STUDENT
WHERE MAJOR='BIOLOGY')
UNION
(SELECT STUDENT_ID
FROM STUDENT
WHERE MAJOR='MATH'));
Write a SQL statement to display the First and Last Name of students who have the Status greater than 1 and less than 10. Use the SQL command BETWEEN.
SELECT FIRST_NAME,LAST_NAME
FROM STUDENT
WHERE STATUS BETWEEN 1 AND 10;
Write a SQL statement to display the First and Last Name of students who have a last name that starts with an S.
SELECT FIRST_NAME,LAST_NAME
FROM STUDENT
WHERE LAST_NAME LIKE S%;
Write a SQL statement to display the First and Last Name of students having an a in the second position in their first names
SELECT FIRST_NAME,LAST_NAME
FROM STUDENT
WHERE FIRST_NAME LIKE _a%;
Write a SQL expression to display the Status and a sum of the Status of each Status value as SumOfStatus. Group by Status and display the results in descending order of SumOfStatus.
SELECT STATUS,SUM(STATUS) AS sumofstatus
FROM STUDENT
GROUP BY STATUS
OREDR BY DESC(sumofstatus);