易截截图软件、单文件、免安装、纯绿色、仅160KB

url存入mysql数据库前的时候要进行什么处理?

SQL code:
UPDATE `footballmatch`.`promote` SET `pr_ballhype` = http://ballhype.com/post/url/?url=http%3A//www.allfootballtv.com/%3Fp%3D369&league=8 WHERE `promote`.`fm_post_id` =369


以上sql语句存入mysql中的时候提示错误:
1064: 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 '://ballhype.com/post/url/?url=http%3A//www.allfootballtv.com/%3Fp%3D369&league=8' at line 2


pr_ballhype 字段类型为varchar

请问该如何修改呢?


varchar型看看字符是否足够用。
UPDATE `footballmatch`.`promote` SET `pr_ballhype` = 'http://ballhype.com/post/url/?url=http%3A//www.allfootballtv.com/%3Fp%3D369&league=8'  WHERE `promote`.`fm_post_id` =369 //分号少不了!

htmlspecialchars(),

引用
varchar型看看字符是否足够用。
UPDATE `footballmatch`.`promote` SET `pr_ballhype` ='http://ballhype.com/post/url/?url=http%3A//www.allfootballtv.com/%3Fp%3D369&league=8'  WHERE `promote`.`fm_post_id` =369 //分号少不了!


确实是加个引号就行了,谢谢了


相关问答:

mysql的连接超时时间怎么设置 - VC/MFC / 数据库

我是用mysql自带的C API
if(mysql_real_connect(&mysql,"125.0.0.108","root","root","home",3306,NULL,0))

AfxMessageBox("数据库连接失败") ......

紧急求助:mysql创建索引出问题了

大家好,我在创建索引时,出现错误提示,代码如下:

create uique index stu_cou_index on student_info.results (student_id, course_id);
show index from student_info.results;

保存为index.s ......

没有可以查找mysql 数据库里面全有内容的工具

如果我输入一个关键字,如果有一个工具,可以在指定数椐库中查寻所有表并列出找到的结果,


不知道有没有这种类型的MYSQL 数据库工具


如果我下载了一个程序,它的脚注FOOT 是写在数据中的如果有一 ......

MySql问题

MySql中插入当前时间的该怎么写啊?
now()

SQL code:

sql里是:
getdate()

引用
now()


学习

SQL code:
select now();

SQL code:
TODAY()
?

SQL code:
select now();
/* ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号