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

MySQL命令

1.连接MySQL数据库
echo on  
cd c:\Program Files\MySQL\MySQL Server 5.2\bin
mysql -uroot -ppass
2、显示数据库列表。
show databases;
3、显示库中的数据表:
use mysql; //打开库,
show tables;
4、显示数据表的结构:
describe 表名;
5、建库:
create database 库名;
6、建表:
use 库名;
create table 表名 (字段设定列表);
7、删库和删表:
drop database 库名;
drop table 表名;
8、将表中记录清空:
delete from 表名;
9、显示表中的记录:
select * from 表名;


相关文档:

mysql与Oracle update的区别

update :单表的更新不用说了,两者一样,主要说说多表的更新
   
       Oracle> Oracle的多表更新要求比较严格,所以有的时候不是很好写,我们可以试试Oracle的游标
               &n ......

mysql 根据英文首字母来查询汉字函数

方法一:建一个拼音表 t_cosler ,存放每个字母开头的第一个汉字的编号和最后一个汉字的编号。
BatchFile code
+------+--------+-------+
| f_PY | cBegin | cEnd |
+------+--------+-------+
| A | 45217 | 45252 |
| B | 45253 | 45760 |
.....
| Z | 54481 | 55289 |
+------+--------+------- ......

解决MySQL不允许从远程访问的方法

解决MySQL不允许从远程访问的方法
2009-06-04 13:11
1。 改表法。可能是你的帐号不允许从远程登陆,只能在localhost。这个时候只要在localhost的那台电脑,登入mysql后,更改 "mysql" 数据库里的 "user" 表里的 "host" 项,从"localhost"改称"%"
Sql代码 复制代码
   1. mysql -u root -pvmwaremysql>us ......

A simple mysql sample

#include <winsock2.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <mysql.h>
#pragma comment(lib,"libmysql")
int _tmain(int argc, _TCHAR* argv[])
{
MYSQL* mysql;
MYSQL_RES* results;
MYSQL_ROW record;
mysql = mysql_init(NULL);
if(! ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号