thefrstgatsby
Technical User
I have a sql database, and I'm trying to pull records from tables a main table related to to other tables, where records from those two tables must be in another table as well.
Here is a diagram
Clients (table A) Service Prov (table b)
Name Transaction IDc Provider Transactionsp ID
------ --------------- -------- ----------------
Joe 434 Mary 434
Transactions table
Transaction IDt
---------------
434
Not doing business Anymore
--------------------------
Client Name Provider Name
----------- -------------
Joe Mary
So I need to pull all transactions from the Transactions table with the same transaction code, but only if there is a record in the Not Doing Business Anymore Which is related to the client and service provider tables via Client name and Provider Name. Plus I need to pull the record from the not doing business anymore as well.
How do I do this?
Here is a diagram
Clients (table A) Service Prov (table b)
Name Transaction IDc Provider Transactionsp ID
------ --------------- -------- ----------------
Joe 434 Mary 434
Transactions table
Transaction IDt
---------------
434
Not doing business Anymore
--------------------------
Client Name Provider Name
----------- -------------
Joe Mary
So I need to pull all transactions from the Transactions table with the same transaction code, but only if there is a record in the Not Doing Business Anymore Which is related to the client and service provider tables via Client name and Provider Name. Plus I need to pull the record from the not doing business anymore as well.
How do I do this?