I have the following statement and am getting an error. I can see why there is an error, but what is the work around.
So essentially I need to set check =1 when customernumber=realmid and the barcode =the barcode from another table...
SET Check1 = 1
WHERE CustomerNumber=@RealmId and Barcode=(SELECT IntuitQboInvoiceId
GROUP BY RealmId, IntuitQboInvoiceId)