I've a problem in getting a record from 3 tables:
There are two conditions for getting the records,'project number' and 'current month'.I used this statement
to get the records but it results in 3 times the actual record.
Any help would be appreciated.
"INSERT INTO patempTable SELECT [pay_roll].[project number],[pay_roll].[employee number],[pay_roll].[current month],[pay_roll].[net pay]," & _
"[allowance].[net allowance],[per_diem_accomodation].[net] FROM [pay_roll],[allowance],[per_diem_accomodation] " & _
"WHERE [pay_roll].[project number]='P07' AND [allowance].[project number]='P07' AND [per_diem_accomodation].[project number]='P07' AND " & _
"MONTH([pay_roll].[current month])='6' AND MONTH([allowance].[current month])='6' AND MONTH([per_diem_accomodation].[current month])='6' AND " & _
"YEAR([pay_roll].[current month])='2014' AND YEAR([allowance].[current month])='2014' AND YEAR([per_diem_accomodation].[current month])='2014'"