ZKX's LAB

初始化数据库得到data目录 如何初始化mysql数据库

2021-04-27知识5

thinkphp 添加数据库字段 怎么初始化data $data=$model->;field('all_point')->;where('username=$s')->;select();var_dump($data);

如何在windows下手动初始化PostgreSQL数据库 1、创建用户postgres,密码同样是postgres:net user postgres postgres /add2、在数据库根目录下建立data目录:C:\\Program Files\\PostgreSQL\\9.3>;md data3、去掉administrator对data目录的权限:C:\\Program Files\\PostgreSQL\\9.3>;cacls data/e/t/r administrator处理的目录:C:\\Program Files\\PostgreSQL\\9.3\\data4、将e68a84e8a2ad62616964757a686964616f31333361323634data目录的权限赋给postgres用户:C:\\Program Files\\PostgreSQL\\9.3>;cacls data/e/t/g postgres:C处理的目录:C:\\Program Files\\PostgreSQL\\9.3\\data5、用postgres用户打开cmdC:\\Program Files\\PostgreSQL\\9.3>;runas/user:postgres cmd.exe输入 postgres 的密码:试图将 cmd.exe 作为用户\"SURE-PC\\postgres\"启动.6、进行初始化,初始化用户为postgres,字符集为utf8,locale为C:C:\\Program Files\\PostgreSQL\\9.3\\bin>;initdb.exe-D./data-E utf8-locale C-UpostgresThe files belonging to this database system will be owned by user\"postgres\".This user must also own the server process.The database cluster will be initialized with locale\"C\".The default text search 。

unbantu中怎么初始化mysql数据库 ubuntu下mysql的常用命令,MySQL数据库的基本操作命令一、mysql服务操作0、查看数据库版本 sql->;status;1、net start mysql //启动mysql服务2、net stop mysql //停止mysql服务3、mysqlh主机地址-u用户名-p用户密码/进入mysql数据库4、quit/退出mysql操作5、mysqladmin-u用户名p旧密码 password 新密码/更改密码6、grant select on 数据库.*to 用户名@登录主机 identified by密码\"/增加新用户exemple:例2、增加一个用户test2密码为abc,让他只可以在localhost上登录,并可以对数据库mydb进行查询、插入、修改、删除的操作(localhost指本地主机,即MYSQL数据库所在的那台主机),这样用户即使用知道test2的密码,他也无法从internet上直接访问数据库,只能通过MYSQL主机上的web页来访问了。grant select,insert,update,delete on mydb.*totest2@localhost identified by\"abc;如果你不想test2有密码,可以再打一个命令将密码消掉。grantselect,insert,update,delete on mydb.*to test2@localhost identified by\";二、数据库操作1、show databases;列出数据库2、usedatabase_name/使用database_name数据库3、create database data_name创建名为。

#初始化数据库得到data目录

随机阅读

qrcode
访问手机版