Ask a question from expert

Ask now

SQL Query Using SQLite - PDF

6 Pages399 Words84 Views
   

Added on  2020-05-16

SQL Query Using SQLite - PDF

   Added on 2020-05-16

BookmarkShareRelated Documents
Running head: SQL QUERY USING SQLITESQL Query Using SQLiteName of the StudentStudent IDSubject Code
SQL Query Using SQLite - PDF_1
SQL QUERY USING SQLITE1Part A:Query 1:SELECT * FROM vendor WHERE v_state = '';Query 2:SELECT * FROM Customer WHERE CUS_BALANCE>300 ANDCUS_BALANCE<400;Query 3:SELECT DISTINCT (cus .CUS_FNAME || ' ' || cus .CUS_LNAME) As 'Customer Name'FROM Customer cus INNER JOIN Invoice i ON cus.CUS_CODE = i.CUS_CODE;Query 4:SELECT MAX(CUS_BALANCE) AS ‘Maximum Balance’ FROM Customer;
SQL Query Using SQLite - PDF_2
SQL QUERY USING SQLITE2Query 5:SELECT DISTINCT CUS_CODE FROM Customer cus WHERE NOT EXISTS(SELECT * FROM Invoice i WHERE cus.CUS_CODE = i.CUS_CODE);Query 6:SELECT DISTINCT (cus .CUS_FNAME || ' ' || cus .CUS_LNAME) As 'Customer Name'FROMCUSTOMER cus WHERE NOT EXISTS (SELECT * FROM Invoice i WHEREcus.CUS_CODE = i.CUS_CODE);Query 7:SELECT cu.CUS_CODE, COUNT(l.INV_NUMBER) AS 'Invoices_generated' FROMCustomer cu INNER JOIN invoice i ON cu.CUS_CODE = i.CUS_CODE INNER JOIN Line lON i.INV_NUMBER=l.INV_NUMBER GROUP BY cu.CUS_CODE;
SQL Query Using SQLite - PDF_3

End of preview

Want to access all the pages? Upload your documents or become a member.

Related Documents
SQL Query Assignment - Using SQLite
|7
|395
|245

SQL Query Assignment- Using SQLite
|5
|423
|49

SQL Assignment: SQL Queries Using Workbench
|14
|432
|147

SQL Statement and Result Assignment
|12
|1135
|69

Use assignment5 to show sums of line totals for each invoice
|13
|559
|82

(Solved) SQLite3 Query - Assignment
|6
|531
|66