Ubuntu下配置网络,安装mysql,jdk
sudo apt-get install mysql-server mysql-client
sudo apt-get install sun-java6-jdk(安装出意外,sudo dpkg -P sun-java6-bin,然后重新安装)
sudo vi /etc/network/interfaces 配置网络
auto eth0
iface eth0 inet dhcp(static)
address 192.168.8.108
netmask 255.255.255.0
gateway 192.168.8.1
:x保存
sudo ifconfig eth0 down (up)关闭和启动
sudo /etc/init.d/networking restart
-----------------------------------
远程授权访问msyql
GRANT ALL PRIVILEGES ON *.* TO 'root'@'192.168.8.108' IDENTIFIED BY '' WITH GRANT OPTION ;
etc/mysql/my.cnf注释掉 bind 127.0.0.1
重新启动mysql :sudo /etc/init.d/mysql restart
---------------------------------------------
相关文档:
To shut down the cluster, enter the following command in a shell
on the machine hosting the management node:
shell> ndb_mgm -e shutdown
The -e
option here is used to pass a command to
the ndb_mgm
client from the shell. (See
Section 4.23, “ ......
1.配置名字为myodbc的数据源
2.在stdafx.h中加上
#import "c:\program files\common files\system\ado\msado15.dll" no_namespace rename ("EOF", "adoEOF")
3.在程序初始化的方法中加上
AfxEnableControlContainer();
// 初始化COM,创建ADO连接等操作
AfxOleInit();
4.在合适的地方加上
public:_ConnectionPt ......
有很多朋友虽然安装好了 MySQL 但却不知如何使用它。在这篇文章中我们就从连接 MySQL、修改密码、增加用户等方面来学习一些 MySQL 的常用命令。
一、连接MySQL。
格式: mysql -h主机地址 -u用户名 -p用户密码
1、例1:连接到本机上的MYSQL。
首先在打开 DOS 窗口,然后进入目录 mysql\bin,再键入命令mysql -u ......
查询语句:
SELECT 字段名 from 表名.
排序 order by 要排序的字段名 desc :以倒序查询.
limit 从第几个开始 查找多少个 :查找指定个数.
同时查询多个字段用","隔开.
如查询表里面的所有数据在字段名处填"*".
如只想显示某字段的前几位字符可以使用LEFT函数.
SELECT 字段名,LEFT(字段名,位数),字段名 from 表名.
COU ......