P
Paul LeBlanc
I'm having a problem with the following statement
SOURCE:
IIf(Mid$([TblProp]![SOURCE],1,2)=[TblSTAGE]![STAGE],[TblSTAGE]![STAGENAME])
When I added it to the SQL statement
SELECT TblPROP.CODE, VARIETY.NAME, TblPROP.PLOT, TblPROP.DATEIN,
TblPROP.DATEOUT, TblPROP.QTY, TblPROP.LOC, TblPROP.SEQ,
IIf([Qty]<315,1,Int([QTY]/315)) AS [ROWS],
IIf(Mid$([TblProp]![SOURCE],1,2)=[TblSTAGE]![STAGE],[TblSTAGE]![STAGENAME])
AS SOURCE, "*" &
SOURCE:
IIf(Mid$([TblProp]![SOURCE],1,2)=[TblSTAGE]![STAGE],[TblSTAGE]![STAGENAME])
When I added it to the SQL statement
SELECT TblPROP.CODE, VARIETY.NAME, TblPROP.PLOT, TblPROP.DATEIN,
TblPROP.DATEOUT, TblPROP.QTY, TblPROP.LOC, TblPROP.SEQ,
IIf([Qty]<315,1,Int([QTY]/315)) AS [ROWS],
IIf(Mid$([TblProp]![SOURCE],1,2)=[TblSTAGE]![STAGE],[TblSTAGE]![STAGENAME])
AS SOURCE, "*" &
Code:
& [PLOT] & [LOC] & [SEQ] & "*" AS BC
FROM TblSTAGE, TblPROP INNER JOIN VARIETY ON TblPROP.CODE = VARIETY.ItemCode
WHERE (((TblPROP.DATEIN)=[STICK WEEK ?]))
ORDER BY TblPROP.LOC, TblPROP.SEQ;
I get thousands of results, most with the source field null but always with
one that is right