🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: pl.comp.bazy-danych
Article #195473

[mysql] upewnienie się dla ON DUPLICATE KEY UPDATE

#195473
From: Borneq
Date: Tue, 30 Jan 2018 00:25
11 lines
1075 bytes
Mam
INSERT INTO flags
(number, flag1, flag2, flag3)
VALUES (350, 1, 0, 0)
ON DUPLICATE KEY UPDATE
flag1=1

number mam klucz primary

czy wstawia jako nowy wiersz 1,0,0
ale gdy istnieje to nie rusza flag2 i flag3?
Technical Details
Message-ID: <p4oe1r$puk$1@node1.news.atman.pl>
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!newsfeed2.atman.pl!newsfeed.atman.pl!.POSTED!not-for-mail

Show Full Headers
Complete Article Headers
Path: mbox-mo1.pugleaf.net!news-archive.icm.edu.pl!news.icm.edu.pl!newsfeed2.atman.pl!newsfeed.atman.pl!.POSTED!not-for-mail
From: Borneq <borneq@antyspam.hidden.pl>
Newsgroups: pl.comp.bazy-danych
Subject: [mysql] upewnienie się dla ON DUPLICATE KEY UPDATE
Date: Tue, 30 Jan 2018 01:25:32 +0100
Organization: ATMAN - ATM S.A.
Lines: 11
Message-ID: <p4oe1r$puk$1@node1.news.atman.pl>
NNTP-Posting-Host: public-gprs350495.centertel.pl
Mime-Version: 1.0
X-Trace: node1.news.atman.pl 1517271931 26580 37.47.0.96 (30 Jan 2018 00:25:31 GMT)
X-Complaints-To: usenet@atman.pl
NNTP-Posting-Date: Tue, 30 Jan 2018 00:25:31 +0000 (UTC)
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2
X-Mozilla-News-Host: news://news.atman.pl:119
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit