Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Append Query Question

Status
Not open for further replies.

jeremy0028

Technical User
Oct 9, 2005
37
US
I have a table and form called patient info. It has Account # which is auto number And is P/K, first name, last name, address, city, state, zip, phone, DOB

I also have a table and form called add charge. In the table i have Patient acount, date of service from, date of service to, procedure, fee.

On the add charge form i have a combo box called patient account when using the wizard i selected info from the patient info table in the following manner, last name, first name, date of birth, account number. when all is done displays 3 columns last name, first name, DOB
and is stored into the patient account field in the add charge table

The combo box row source property is this
SELECT [Patient Info].[Account#], [Patient Info].[Last Name] & ", " & [Patient Info].[First Name] & " " & [Patient Info].MI, [Patient Info].[Date Of Birth] FROM [Patient Info];

I also have a table called payments which has the following patient account, date of service from, date of service to, procedure, modifer, fee

I'm trying use the append query using the add charge table
and append the fields to the payments table

In the query displays like this Patient account(last name, first name as one field) date of service from, date of service to, procedure, modifer, fee.

When i appen those fields into the payments table it only displays patient account# in the the patient account in the payments table. . Is there any way that to display patient name instead like it does in the query.







 
Hi
You say "In the query displays like this Patient account(last name, first name as one field)". You should have the name as "last name, first name as two fields" in an append query. Is this what you mean?

However, I wonder about the set up of your database. Have you seen this?
 
it's suppose to only store the patient's account number in the payments table. If you need to display the patient's name also, you need to write a query that joins into the Patient table:

SELECT FirstName, LastName, Payments.AccountID FROM Payments INNER JOIN Patients ON Payments.AccountID = Patients.AccountID

You should also read Understanding SQL Joins

Leslie

Anything worth doing is a lot more difficult than it's worth - Unknown Induhvidual

Essential reading for anyone working with databases: The Fundamentals of Relational Database Design
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top