wvandenberg
Technical User
I am wondering if it is possible to use a SELECT statement in a table validation rule. Alternatively, can or would it be better to use a custom defined function as a table rule?
This is the rule I would like to implement:
Thanks in advance,
Wendy
This is the rule I would like to implement:
Code:
IIf([Replicate]=True,[RepSampleID]=(SELECT P.pkSampleID, c.pkSampleID, c.SampleName FROM tblSamples AS P INNER JOIN tblSamples AS c ON P.pkSampleID = c.RepSampleID WHERE (((c.pkSampleID)=[pkSampleID]) AND ((c.SampleName)=[SampleName]) AND ((c.fkpkSiteID)=[P].[fkpkSiteID]) AND ((Int([c].[StartDate]))=Int([P].[StartDate])))),[RepSampleID] Is Null)
Thanks in advance,
Wendy