mysql中的mysql_real_connect连接参数设置
日期:2007年4月6日 作者: 查看:[大字体 中字体 小字体]-
在前一篇文章中,讲述了如何进行mysql源程序代码的编译链接,但是没有讲述运行情况,在按照上一篇文章代码下进行编译运行后,发现无法链接数据库文件,显然是在mysql_real_connect()函数中出现了问题。在mysql的英文手册中找到关于mysql_real_connect()的如下描述:
//函数原型描述 MYSQL *mysql_real_connect(MYSQL *mysql, const char *host, const char *user,
const char *passwd, const char *db, unsigned int port, const char *unix_socket,
unsigned long client_flag)Description
mysql_real_connect() attempts to establish a connection to a MySQL database engine
running on host. mysql_real_connect() must complete successfully before you can
execute any other API functions that require a valid MYSQL connection handle structure.The parameters are specified as follows:
*
The first parameter should be the address of an existing MYSQL structure. Before
calling mysql_real_connect() you must call mysql_init() to initialize the MYSQL
structure. You can change a lot of connect options with the mysql_options() call.
See Section 17.2.3.47, “mysql_options()”.
*The value of host may be either a hostname or an IP address. If host is NULL or the
string "localhost", a connection to the local host is assumed. If the OS supports sockets
(Unix) or named pipes (Windows), they are used instead of TCP/IP to connect to the server.
*The user parameter contains the user's MySQL login ID. If user is NULL or the empty
string "", the current user is assumed. Under Unix, this is the current login name. Under
Windows ODBC, the current username must be specified explicitly. See Section 18.1.9.2,
“Configuring a MyODBC DSN on Windows”. - [1] [2] [3] [4] [5] [6] 下一页
-
- mysql中的mysql_real_connect连接参数设置 相关文章:
- ·QQ龙珠连锁之20连以上的创造方法
- ·.Net中如何连接到ODBC数据源
- ·连连看绝望玩法的11点个人看法
- ·连连看中级进阶技术技巧的提高
- ·姐,幸福下去,连我的份一起
- ·TOMCAT的内存和连接数配置详解
- ·Windows Vista与XP实现局域网连通
- ·实现Win vista与XP局域网互连互通
- ·PHP连接远程MYSQL和MYSQL5.1中文乱码处理方法
- ·实战:Vista与XP实现局域网连通
- mysql中的mysql_real_connect连接参数设置 相关软件
- ·阿达连连看 2007
- ·【连环画】铁道游击队 01 血染洋行(沪美版)
- ·快乐成语连连看
- ·“天亿”连珠王
- ·QQ 连连看助手
- ·醒狮连连看
- ·《连连看》豪华兼容版
- ·《连连看》v4.1 简体中文精装版
- ·《英雄连》1.70-1.71中文版升级补丁
- ·《连连看》v4.1 简体中文完全版
- 特别声明:本站除部分特别声明禁止转载的专稿外的其他文章可以自由转载,但请务必注明出处和原始作
- 者.文章版权归文章原始作者所有.对于被本站转载文章的个人和网站,我们表示深深的谢意。如果本站转
- 载的文章有版权问题请联系编辑人员,我们尽快予以更正. 转载请注明来源:http://www.hackhome.com
精品推荐
热点TOP10
- ·MySQL数据库学习手册之从MySQL得到最大的性能
- ·mysql中的mysql_real_connect连接参数设置
- ·讲解Ubuntu下MySQL数据库安装后初步设置
- ·详细介绍优化mysql性能的十个参数
- ·MySQL管理工具SQLyog最新6.1下载
- ·怎样测试 MySQL安装是否成功?
- ·MySQL中LOAD DATA LOCAL安全问题
- ·一个简单的MySQL备份恢复数据指令
- ·修改MYSQL数据库,数据表,字段的编码(解决JSP乱码)
- ·让Windows在IIS支持PHP和MySQL
- ·快速掌握 MySQL数据库中触发器的应用
- ·数据从MySQL迁移到 Oracle的注意事项
- ·mysql导入数据库文件最大限制的修改方法
- ·SQL Server 2008 几项新特性概述
- ·MySQL安装的故障诊断与排除(Windows环境)
- ·快速掌握 SQL Server 的任务调度
- ·PHP5对Mysql5的任意数据库表的管理代码示例
- ·怎样从Windows命令行启动MySQL?
- ·轻松掌握MySQL中实施info()函数
- ·了解MySQL数据库中的结果字符串
特别推荐
- ·修改MySQL的默认密码
- ·初学MYSQL应知道:Mysql参数优化
- ·数据库安全应用 使用MySQL的23个注意事项
- ·入门:MYSQL基础
- ·轻松描述Windows上安装多个Mysql的步骤
- ·安装与卸载MySQL数据库系统服务的常见问题
- ·Mysql 安全注意事项
- ·初学MySql5 所应了解的知识和常见问题
- ·MySQL数据库学习手册之安装MySQL
- ·无法远程登入MySQL数据库的三种解决办法
- ·讲解Ubuntu下MySQL数据库安装后初步设置
- ·MySQL数据库管理员迅速回答常见问题汇总
- ·详细介绍优化mysql性能的十个参数
- ·MySQL中执行SQL语句时的两个注意点
- ·帮助你如何迅速优化你MySQL数据库性能
- ·PHP+MYSQL建设网站程序需要注意两点
- ·资深专家手把手教你安装MYSQL数据库
- ·实战经验:PHP+MySQL数据库论坛简易通
- ·MySQL的启动方法(windows 平台)
- ·修改MYSQL数据库,数据表,字段的编码(解决JSP乱码)
