update memberpoint set memberpoint.memberpoint = a013072552.PSD_QTY*pointofproduct.POINT1 where a013072552.PSH_MBCODE = member.MB_CODE and member.MB_CODE = memberpoint.membercode and a013072552.PSD_KEYIN = pointofproduct.BARCODE
update a013072552,member,memberpoint,pointofproduct set memberpoint.memberpoint = memberpoint.memberpoint+(a013072552.PSD_QTY*pointofproduct.POINT1) where a013072552.PSH_MBCODE = member.MB_CODE and a013072552.PSD_KEYIN = pointofproduct.BARCODE and member.MB_CODE = memberpoint.membercode
update a013072552,member,memberpoint,pointofproduct set memberpoint.memberpoint = memberpoint.memberpoint+(a013072552.PSD_QTY*pointofproduct.POINT1) where a013072552.PSH_MBCODE = member.MB_CODE and a013072552.PSD_KEYIN = pointofproduct.BARCODE and member.MB_CODE = memberpoint.membercode
แก้เป็น query
SELECT memberpoint.memberpoint, a013072552.PSD_QTY, pointofproduct.POINT1
FROM a013072552,member,memberpoint,pointofproduct
WHERE
a013072552.PSH_MBCODE = member.MB_CODE and a013072552.PSD_KEYIN = pointofproduct.BARCODE and member.MB_CODE = memberpoint.membercode
ทดสอบใน phpmyadmin หรือ mysql gui tool ดูครับว่าได้ข้อมูลอะไรมาบ้างครบทุกแถวที่ต้องการหรือเปล่า