Jump to content

Recommended Posts

i'm trying to get this statement to work but it don't work.

How do you get "$username" part to work.

What i'm trying to do is update the publictb from multiple user tables.

$result = mysql_query("UPDATE $username, publictb SET scriptref='$scriptref' AND scripture ='$scripture' AND WHERE id='$id' AND scriptref='$scriptref' AND scripture ='$scripture'")

Link to comment
https://forums.phpfreaks.com/topic/144950-update-mysql-problem/
Share on other sites

Show us what it should say without a variable.

 

Also, you don't use AND in your SET function, use a comma.

Don't use AND before your WHERE.

 

$result = mysql_query("UPDATE $username, publictb SET scriptref='$scriptref', scripture ='$scripture' WHERE id='$id' AND scriptref='$scriptref' AND scripture ='$scripture'")

Link to comment
https://forums.phpfreaks.com/topic/144950-update-mysql-problem/#findComment-760750
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.