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 IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Select all data or Automate Export?

Status
Not open for further replies.

psheff

MIS
Dec 23, 2003
4
GB
I have a payment report with a 13 digit reference. The last 7 digits of this is a staff number. I have a table of staff numbers with staff details. I used the following formula:

Mid ({payment_report},7 ,7 )={staff details_staff number}.

This provided me a list of all staff numbers, where payment was received, where there was a match in the staff details db. What this didn't show was where we had a staff number that we didn't any records for. Is there anything I can add to the code to do this?

I then tried setting up a report which would pull down the staff numbers first and exporting to excel. I then used this file and was able to use a left inner join to ensure all staff numbers appeared

Is there any way I can automate the export to the excel file?

Or is there another way to achive my goal?

Many thanks


 
If you have a table with all employee names, create a left join FROM that table to the PaymentReport table, linking on employeeID. Then add the employee name or staff number from the left table and the payment records from the Payment Report table.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top