Can anyone see the error I am getting in this expression in a query:
LastNo: DMax("[BookingFormNo]","DetailNewQuery","[Organisation] = " & [Organisation])
I have a [BookingFormNo] field in the "DetailNewQuery" Query which also has an [Organisation] field. There are about 40 Organisations.
What I am trying to do is get the latest BookingFormNo for the relevant Organisation, but all I get is #Error.
It is the last expression that is causing the problem, because if I enter "[Organisation] = 'Bridge Club'" it works perfectly.
Any ideas
Thanks
David
LastNo: DMax("[BookingFormNo]","DetailNewQuery","[Organisation] = " & [Organisation])
I have a [BookingFormNo] field in the "DetailNewQuery" Query which also has an [Organisation] field. There are about 40 Organisations.
What I am trying to do is get the latest BookingFormNo for the relevant Organisation, but all I get is #Error.
It is the last expression that is causing the problem, because if I enter "[Organisation] = 'Bridge Club'" it works perfectly.
Any ideas
Thanks
David