Entries Tagged ‘mysql’:

Fatal error: Call to undefined function mysql_connect()

今天第一次用cakephp框架,想试一下里面的脚本生成器console,发现在dos下执行出现错误:
Fatal error: Call to undefined function mysql_connect()
原来是我的php环境的问题,需要在php.exe相同目录下存在php配置文件php.ini
还有提醒一点的是php.ini里的extension=php_mysql.dll必须启动
cakephp的脚本生成器console挺强大、挺方便的

Tags: , ,

Leave a Comment

error: No curses/termcap library found

今天在centos下把原来的mysql给rpm -e –nodeps了,然后下了个mysql-5.1.28
./configure –with-plugins=sphinx –prefix=/usr/local/mysql-search/ –enable-assembler –with-extra-charsets=complex –enable-thread-safe-client –with-big-tables –with-readline –with-ssl -with-embedded-server –enable-local-infile
时,出现错误:
checking for termcap functions library… configure: error: No curses/termcap library found
网上大都说是缺少ncurses,我rpm -qa |grep ncurses了一下发现已经安装了ncurses
后来发现原来少的是:ncurses-devel
到光盘里找到
rpm -ivh ncurses-devel-5.5-24.20060715.i386.rpm
发现不在提示上述错误了

Tags:

Leave a Comment

Data truncated for column

昨天在自己的电脑上用php往mysql数据库里写入东西的时候发现怎么也写不进去,后来打开错误提示发现是Data truncated for column ’sex’ at row 1,但奇怪的是把程序放到linux的服务器上,却能正常写进MySQL数据库。
上网查了查说是编码的问题。
…..

Tags: ,

Leave a Comment