Can anyone tell me ?.When i try to run the following query it says syntax error(missing operator) in query expression ic_ItemID.itemID =Ic_Itembarcode.ItemID Inner join dbo.IC_Itemdefaultprices p on Ic_ItemID.ItemID=P.ItemID.
Code:
SELECT IC_Itembarcode.itemID,
IC_Itembarcode.Barcode,
IC_Itembarcode.Serial1,
IC_Itembarcode.Serial2,
IC_Itembarcode.Serial3,
IC_Itembarcode.Serial4,
IC_Itembarcode.SerialCombination,
IC_ItemID.L1Description,
IC_ItemID.L2Description,
IC_ItemID.ExtraL1Description,
IC_ItemID.ExtraL2Description,
MIN(Price) As Price,
Max(StartDate) As StartDate
From IC_ItemID
INNER JOIN IC_Itembarcode ON IC_ItemID.itemID=IC_Itembarcode.itemID
INNER JOIN dbo.IC_ItemDefaultPrices p ON IC_ItemID.itemID= P.itemID
WHERE P.STARTDATE = (Select Max(StartDate) from dbo.IC_ItemDefaultPrices As B Where B.ItemID Like 'BUR304*' and b.startdate <= '2011-12-28') and IC_ItemID.ItemID Like 'BUR304*' GROUP BY IC_Itembarcode.itemID, IC_Itembarcode.Barcode, IC_Itembarcode.Serial1, IC_Itembarcode.Serial2, IC_Itembarcode.Serial3, IC_Itembarcode.Serial4, IC_Itembarcode.SerialCombination, IC_ItemID.L1Description, IC_ItemID.L2Description, IC_ItemID.ExtraL1Description , IC_ItemID.ExtraL2Description
Last edited: