0
更新集與I組有absen
表樣柱,如何通過SQL
我查詢它像,
SELECT count(tgl) AS total, absen.id, absen.status, absen.kondisi,
CASE WHEN (weekday(tgl) <=3) THEN date(tgl + INTERVAL(3 - weekday(tgl)) DAY)
ELSE date(tgl + INTERVAL(3 +7 - weekday(tgl)) DAY)
END AS tglitung
FROM absen
WHERE absen.status = 'm'
GROUP BY absen.id, tglitung
其結果
我想更新e SET kondisi='yes'
,當GROUP BY absen.id='15' AND tglitung='2016-01-14'
如何使用set更新這種情況?