If you are using Access 2016, do the following. Add a field to the Client table named AvailableCredit. Set the field to currency. Create a data macro associated with the After Update event for the Client table. When a user updates the Balance field, the macro should subtract the new balance from the credit limit and place that value in the AvailableCredit field. Create a data macro associated with the After Delete event for the OrderLine table. When a user deletes a record because it is complete or cancelled, the macro should look up the order number in the WorkOrders table and delete it there as well. Use the For Each Record in the WorkOrders table. Hint: You can use the OLD keyword in the Where Condition: [Old].[OrderNum] = [WorkOrders].[OrderNum]. Test the data macro by deleting a record from the OrderLine table and ensuring that the record also is deleted from the WorkOrders table.

A Guide to SQL
9th Edition
ISBN:9781111527273
Author:Philip J. Pratt
Publisher:Philip J. Pratt
Chapter7: Database Administration
Section: Chapter Questions
Problem 6TD: Perform the following tasks: a. Create an index named ITEM_INDEX1 on the ITEM_NUM column in the...
icon
Related questions
icon
Concept explainers
Question
  1. If you are using Access 2016, do the following.
    1. Add a field to the Client table named AvailableCredit. Set the field to currency.
    2. Create a data macro associated with the After Update event for the Client table. When a user updates the Balance field, the macro should subtract the new balance from the credit limit and place that value in the AvailableCredit field.
    3. Create a data macro associated with the After Delete event for the OrderLine table. When a user deletes a record because it is complete or cancelled, the macro should look up the order number in the WorkOrders table and delete it there as well. Use the For Each Record in the WorkOrders table. Hint: You can use the OLD keyword in the Where Condition: [Old].[OrderNum] = [WorkOrders].[OrderNum]. Test the data macro by deleting a record from the OrderLine table and ensuring that the record also is deleted from the WorkOrders table.
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 3 steps

Blurred answer
Knowledge Booster
Query Syntax
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
Recommended textbooks for you
A Guide to SQL
A Guide to SQL
Computer Science
ISBN:
9781111527273
Author:
Philip J. Pratt
Publisher:
Course Technology Ptr
Programming with Microsoft Visual Basic 2017
Programming with Microsoft Visual Basic 2017
Computer Science
ISBN:
9781337102124
Author:
Diane Zak
Publisher:
Cengage Learning
Oracle 12c: SQL
Oracle 12c: SQL
Computer Science
ISBN:
9781305251038
Author:
Joan Casteel
Publisher:
Cengage Learning
COMPREHENSIVE MICROSOFT OFFICE 365 EXCE
COMPREHENSIVE MICROSOFT OFFICE 365 EXCE
Computer Science
ISBN:
9780357392676
Author:
FREUND, Steven
Publisher:
CENGAGE L
Np Ms Office 365/Excel 2016 I Ntermed
Np Ms Office 365/Excel 2016 I Ntermed
Computer Science
ISBN:
9781337508841
Author:
Carey
Publisher:
Cengage
CMPTR
CMPTR
Computer Science
ISBN:
9781337681872
Author:
PINARD
Publisher:
Cengage