MySQL Forums
Forum List  »  German

Re: Probleme beim Insert
Posted by: Michael Feske
Date: November 05, 2019 04:26AM

Bist Du sicher mit .*C*ontrollino2 ?
Bei mir funktionieren:
INSERT INTO controllino2 (CID,PORT,Datum,Stunde,Wert) VALUES (1,'A2',DATE(CURDATE()),(SELECT MAKETIME(HOUR(CURTIME()),MINUTE(CURTIME()),'00')),1) ON DUPLICATE KEY UPDATE Wert = Wert + If(VALUES(Wert) = -1,Wert * -1,VALUES(Wert));
INSERT INTO controllino2 (CID,PORT,Datum,Stunde,Wert) VALUES (1,'A1',DATE(CURDATE()),(SELECT MAKETIME(HOUR(CURTIME()),MINUTE(CURTIME()),'00')),0) ON DUPLICATE KEY UPDATE Wert = Wert + If(VALUES(Wert) = -1,Wert * -1,VALUES(Wert));

Options: ReplyQuote


Subject
Views
Written By
Posted
326
November 05, 2019 03:05AM
170
November 05, 2019 04:22AM
141
November 05, 2019 04:48AM
Re: Probleme beim Insert
156
November 05, 2019 04:26AM
143
November 05, 2019 04:51AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.