A Guide to SQL
A Guide to SQL
9th Edition
ISBN: 9781337668880
Author: Pratt
Publisher: Cengage
Expert Solution & Answer
Book Icon
Chapter 8, Problem 6SCG

Explanation of Solution

a.

Deleting query in the table “OWNER”:

Public Function Owner_Delete(I_OWNER_NUM)

    Dim strSQL As String

    strSQL = "DELETE FROM OWNER WHERE OWNER_NUM = '"

    strSQL = strSQL & I_OWNER_NUM

    strSQL = strSQL & "'"

    DoCmd.RunSQL strSQL

End Function

 Explanation:

  • Create a function named as “Owner_Delete” and pass an argument “I_OWNER_NUM”.
  • Set the strSQL string variable to “DELETE FROM OWNER WHERE OWNER_NUM = '” and make everything necessary in the command including the single quotation mark preceding the order number...

Explanation of Solution

b.

Updating query:

Public Function Owner_Update(I_OWNER_NUM, I_LAST_NAME)

    Dim strSQL As String

    strSQL = "UPDATE OWNER SET LAST_NAME = '"

    strSQL = strSQL & I_LAST_NAME

    strSQL = strSQL & "' WHERE OWNER_NUM = '"

    strSQL = strSQL & I_OWNER_NUM

    strSQL = strSQL & "'"

    DoCmd.RunSQL strSQL

End Function

 Explanation:

  • Create a function named as “Owner_Update” and pass the arguments “I_OWNER_NUM” and “I_LAST_NAME”.
  • Set the strSQL string variable to “UPDATE OWNER SET LAST_NAME = '” and make everything necessary in the command including the single quotation mark preceding the order number...

Explanation of Solution

c.

Retrieving the list in the table “CONDO_UNIT”:

Public Function Find_Condos(I_SQR_FT)

    Dim rs As New ADODB.Recordset

    Dim cnn As ADODB.Connection

    Dim strSQL As String

    Set cnn = CurrentProject.Connection

    strSQL = "SELECT LOCATION_NUM, UNIT_NUM, CONDO_FEE, OWNER_NUM FROM CONDO_UNIT WHERE SQR_FT = "

    strSQL = strSQL & I_SQR_FT

       rs.Open strSQL, cnn, adOpenStatic, , adCmdText

    Do Until rs.EOF

        Debug.Print (rs!LOCATION_NUM)

        Debug.Print (rs!UNIT_NUM)

        Debug.Print (rs!CONDO_FEE)

        Debug.Print (rs!OWNER_NUM)

        rs.MoveNext

    Loop

End Function

 Explanation:

  • Create a function named as “Find_Condos” and pass an argument “I_SQR_FT”...

Blurred answer
Students have asked these similar questions
Ideal MOSFET Current–Voltage Characteristics—NMOS Device and draw the circuit
1. Create a Person.java file. Implement the public Person and Student classes in Person.java, including all the variables and methods in the UMLS. Person -name: String -street: String -city: String +Person(String name, String, street, String, city) +getName(): String +setName(String name): void +getStreet(): String +setStreet(String street): void +getCity(): String +setCity(String City): void +toString(): String Student -Id: int +Person(String name, String, street, String, city, int Id) +getId(): int +setId(int Id): void +toString(): String 2. Create a StudentTest.java file. Implement a public StudentTest class with a main method. In the main method, create one student object and print the object using System.out.println(). Your printing result must follow the example output: name: Mike, street: Morris Ave, city: Union, Id: 1000 Hint: You need to modify the toString methods in the Student class and Person class!
1) Apply the Paint Blue algorithm discussed in class to the following Finite Automata. a a a b b a COIS-3050H-R-W01-2025WI-COMB Formal Languages & Automata a b Show the status of the Finite Automata at the conclusion of the Paint Blue Algorithm (mark the visited states with an X and only include edges that have not been followed). 2) Use the pumping lemma to prove the following language is nonregular: L= {ab} = {abbb, aabbbbbb, aaabbbbbbbbb, ...}
Knowledge Booster
Background pattern image
Similar questions
SEE MORE QUESTIONS
Recommended textbooks for you
Text book image
A Guide to SQL
Computer Science
ISBN:9781111527273
Author:Philip J. Pratt
Publisher:Course Technology Ptr
Text book image
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:9781337508841
Author:Carey
Publisher:Cengage
Text book image
Oracle 12c: SQL
Computer Science
ISBN:9781305251038
Author:Joan Casteel
Publisher:Cengage Learning
Text book image
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:9781337102124
Author:Diane Zak
Publisher:Cengage Learning
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781305627482
Author:Carlos Coronel, Steven Morris
Publisher:Cengage Learning
Text book image
Database Systems: Design, Implementation, & Manag...
Computer Science
ISBN:9781285196145
Author:Steven, Steven Morris, Carlos Coronel, Carlos, Coronel, Carlos; Morris, Carlos Coronel and Steven Morris, Carlos Coronel; Steven Morris, Steven Morris; Carlos Coronel
Publisher:Cengage Learning