在mysql中,每个命令之间都要留一点空格

如果是这样,

$query = "select * from books where " .$searchtype. "like'%" .$searchterm. "%'";
那么print_r(),就会输出:select * from books where titlelike'%java%',
like 和那些都在一起了,命令有错,
应该是这样:
$query = "select * from books where " .$searchtype. " like '%" .$searchterm. "%'";

print_()输出:select * from books where title like '%java%'1
,成功。。 在like两边都要有空格。。

mysql出现) Notice: Trying to get property of non-object in E:\p错误的 原因的更多相关文章

  1. Property 'submit' of object #<HTMLFormElement> is not a function

    <form action="" type="get" id="form"> <input type="butto ...

  2. 在Vue中使用i18n 国际化遇到 Uncaught TypeError: Cannot assign to read only property 'exports' of object '#<Object>'

    最近用Vue在搭建前端框架,在引用i18n时,运行的时候报错:Uncaught TypeError: Cannot assign to read only property 'exports' of ...

  3. php 报错如下:Notice: Trying to get property of non-object

    参考文档如下解决: https://stackoverflow.com/questions/5891911/trying-to-get-property-of-non-object-in 问题如下: ...

  4. Node中使用MySQL报错:TypeError: Cannot read property 'query' of undefined

    Node中使用MySQL报错: TypeError: Cannot read property 'query' of undefined at /Users/sipeng/Desktop/彭思/201 ...

  5. 在MySQL向表中插入中文时,出现:incorrect string value 错误

    在MySQL向表中插入中文时,出现:incorrect string value 错误,是由于字符集不支持中文.解决办法是将字符集改为GBK,或UTF-8.      一.修改数据库的默认字符集   ...

  6. 2.mongoDB add user in v3.0 问题的解决(Property 'addUser' of object admin is not a func)

    问题:创建mongodb帐户时,出错 > db.addUser('jyu', 'aerohive')  2015-08-05T20:03:02.767+0800 E QUERY    TypeE ...

  7. mysql中You can’t specify target table for update in FROM clause错误解决方法

    mysql中You can't specify target table for update in FROM clause错误的意思是说,不能先select出同一表中的某些值,再update这个表( ...

  8. 深度解析MySQL启动时报“The server quit without updating PID file”错误的原因

    很多童鞋在启动mysql的时候,碰到过这个错误, 首先,澄清一点,出现这个错误的前提是:通过服务脚本来启动mysql.通过mysqld_safe或mysqld启动mysql实例并不会报这个错误. 那么 ...

  9. Vue的报错:Uncaught TypeError: Cannot assign to read only property 'exports' of object '#<Object>'

    Vue的报错:Uncaught TypeError: Cannot assign to read only property 'exports' of object '#<Object>' ...

随机推荐

  1. Atitit.sql where条件表达式的原理  attilax概括

    Atitit.sql where条件表达式的原理  attilax概括 1. 数据查询接口sql api标准化1 2. Sql接口的问题2 2.1. 虽然sql是结构化的dsl,但是任然是编程语言类型 ...

  2. Haskell示例

    i :: Int i = --add, sub :: Int -> Int -> Int add, sub :: (Num a) => a -> a -> a add a ...

  3. 关于linux PPA源问题

    添加PPA: 1.首先进入ubuntu系统,system—>administration—>update manager—>setting,在软件源界面,点击other softwa ...

  4. 最大子矩阵 hdu1081

    To The Max Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 65536/32768 K (Java/Others)Total ...

  5. 利用yum下载rpm离线包

    # 利用yum下载rpm包 ### 简介-----------------------------yum是基于red hat系统的默认包管理器.使用yum可以安装或更新一个rpm包,并且他会自动解决包 ...

  6. 浅谈配置文件:spring-servlet.xml(spring-mvc.xml) 与 applicationContext.xml

    在搭建 spring mvc 的框架时,会有2个配置文件必不可少: spring-servlet.xml 和applicationContext.xml.第一次接触spring mvc的工程师可能会对 ...

  7. linux学习笔记34--命令rcp和scp

    rcp代表“remote file copy”(远程文件拷贝).该命令用于在计算机之间拷贝文件.rcp命令有两种格式.第一种格式用于文件到文件的拷贝:第二种格式用于把文件或目录拷贝到另一个目录中. 1 ...

  8. ID4收藏

    IdentityServer4.Admin https://github.com/skoruba/IdentityServer4.Admin

  9. pycharm 社区版

    这个是免费版.到3.1.13 http://pan.baidu.com/s/1bnvPdtt 没用过idea的商业版,不知道为什么它的更新那么蛋疼,不能增量更新,每次都得手动下载完整的压缩包.

  10. Makefile 实例实践

    本文为原创文章,转帖需指明该文链接 目录结构如下: comm/inc/apue.h comm/errorhandler.c atexit.c Makefile 文件内容如下: apue.h   #if ...