Question
I am not sure on how to query this situation. Why would I need 2 Update queries? I dont have to have this query solved
I am not sure on how to query this situation. Why would I need 2 Update queries? I dont have to have this query solved but I need some help understanding the logic of this query. NOTE: VENDORS table and INVOICES table are related by the VENORS_ID column, which is a foreign key in the INVOICES table.
Update the default_terms_id column for the vendors table who have credit account yet there were no payment on the system to match the terms_id column in invoices table
1. You will hardcode the default_terms_id in the update statement. But you need to write first a select query to show only the records that will be changed.
2. Update records (two update queries)
3. Use select statement to show the updated records (VENDORS.vendor_name, VENDORS.default_terms_id, INVOICES.terms_id, INVOICES.invoice_number, INVOICES.invoice_total, INVOICES.credit_total, INVOICES.payment_total)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started