Jump to content
  • 0

Проблема с БД


Pavel_html
 Share

Question

Вот есть такой запрос:

$zag=mysql_escape_string($zag);
$krat=mysql_escape_string($krat);
$body=mysql_escape_string($body);
$str_sql="UPDATE blog SET header='$zag', krat='$krat', body='$body' WHERE id=$id";
if(!mysql_query($str_sql, $link)){
print mysql_error();
}

и функция mysql_error() мне выдает следущее собщение:

You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 1

пытался перевести гуглом переводчиком но он мне какую то дребедень выдает...

У вас есть ошибка в Вашем SQL синтаксиса; проверять вручную, что подходит для вашего MySQL-сервера версия для синтаксиса право на использование около''на строке 1

Уважаемые Гуру! В чем дело??

Link to comment
Share on other sites

7 answers to this question

Recommended Posts

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  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.

 Share

×
×
  • 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. See more about our Guidelines and Privacy Policy