/    Sign up×
Community /Pin to ProfileBookmark

Edit MySQL with PHP

I need to know if it is possible to edit multiple fields in a Mysql database table at the same time with php. I know how to edit a single field. So if there is a way to edit multiple fields at one time with php let me know please.

Thanks

to post a comment
PHP

1 Comments(s)

Copy linkTweet thisAlerts:
@MrCoderAug 07.2007 — [code=php]
mysql_query("UPDATE MyTable SET MyField1 = 'MyValue1', MyField2 = 'MyValue2' WHERE MyField3 = 'MyValue3'");
[/code]
×

Success!

Help @monarch_684 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.18,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...