I have this query:
SELECT A.*, AppointmentCost - Nz((SELECT SUM(PaymentAmount) FROM tblPayment P WHERE A.AppointmentId = P.AppointmentId),0) AS AppBalance, Date()-AppointmentDate AS DaysOutstanding
FROM tblAppointment AS A;
When I run it shows:
AppointmentID
PaymentID
AppointmentCost
AppBalance
DaysOutStanding
I would like the first and last names of patients to show up in this query
I have a table called tblPatient which has these two fields in it.
Colud you please show how to do this, if it is even possible?
SELECT A.*, AppointmentCost - Nz((SELECT SUM(PaymentAmount) FROM tblPayment P WHERE A.AppointmentId = P.AppointmentId),0) AS AppBalance, Date()-AppointmentDate AS DaysOutstanding
FROM tblAppointment AS A;
When I run it shows:
AppointmentID
PaymentID
AppointmentCost
AppBalance
DaysOutStanding
I would like the first and last names of patients to show up in this query
I have a table called tblPatient which has these two fields in it.
Colud you please show how to do this, if it is even possible?