- 浏览: 753290 次
- 性别:
- 来自: 杭州
文章分类
最新评论
-
lgh1992314:
a offset: 26b offset: 24c offse ...
java jvm字节占用空间分析 -
ls0609:
语音实现在线听书http://blog.csdn.net/ls ...
Android 语音输入API使用 -
wangli61289:
http://viralpatel-net-tutorials ...
Android 语音输入API使用 -
zxjlwt:
学习了素人派http://surenpi.com
velocity宏加载顺序 -
tt5753:
谢啦........
Lucene的IndexWriter初始化时的LockObtainFailedException的解决方法
mysql> use test; Database changed mysql> select @@version; +-----------+ | @@version | +-----------+ | 5.5.15 | +-----------+ 1 row in set (0.00 sec) mysql> select @@sql_mode; +----------------------------------------------------------------+ | @@sql_mode | +----------------------------------------------------------------+ | STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION | +----------------------------------------------------------------+ 1 row in set (0.00 sec) mysql> show column from mytable; ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'column from mytable' at line 1 mysql> show columns from mytable; +-------+----------+------+-----+---------+-------+ | Field | Type | Null | Key | Default | Extra | +-------+----------+------+-----+---------+-------+ | a | int(11) | NO | PRI | NULL | | | b | char(18) | NO | | NULL | | +-------+----------+------+-----+---------+-------+ 2 rows in set (0.01 sec) mysql> use mysql; Database changed mysql> show index from db; +-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+ | Table | Non_unique | Key_name | Seq_in_index | Column_name | Collation | Cardinality | Sub_part | Packed | Null | Index_type | Comment | Index_comment | +-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+ | db | 0 | PRIMARY | 1 | Host | A | NULL | NULL | NULL | | BTREE | | | | db | 0 | PRIMARY | 2 | Db | A | NULL | NULL | NULL | | BTREE | | | | db | 0 | PRIMARY | 3 | User | A | 0 | NULL | NULL | | BTREE | | | | db | 1 | User | 1 | User | A | 0 | NULL | NULL | | BTREE | | | +-------+------------+----------+--------------+-------------+-----------+-------------+----------+--------+------+------------+---------+---------------+ 4 rows in set (0.00 sec) mysql> show privilges; ERROR 1064 (42000): You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'privilges' at line 1 mysql> show create table user; +-------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | Table | Create Table | +-------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | user | CREATE TABLE `user` ( `Host` char(60) COLLATE utf8_bin NOT NULL DEFAULT '', `User` char(16) COLLATE utf8_bin NOT NULL DEFAULT '', `Password` char(41) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT '', `Select_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Insert_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Update_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Delete_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Create_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Drop_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Reload_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Shutdown_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Process_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `File_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Grant_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `References_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Index_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Alter_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Show_db_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Super_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Create_tmp_table_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Lock_tables_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Execute_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Repl_slave_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Repl_client_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Create_view_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Show_view_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Create_routine_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Alter_routine_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Create_user_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Event_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Trigger_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `Create_tablespace_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N', `ssl_type` enum('','ANY','X509','SPECIFIED') CHARACTER SET utf8 NOT NULL DEFAULT '', `ssl_cipher` blob NOT NULL, `x509_issuer` blob NOT NULL, `x509_subject` blob NOT NULL, `max_questions` int(11) unsigned NOT NULL DEFAULT '0', `max_updates` int(11) unsigned NOT NULL DEFAULT '0', `max_connections` int(11) unsigned NOT NULL DEFAULT '0', `max_user_connections` int(11) unsigned NOT NULL DEFAULT '0', `plugin` char(64) COLLATE utf8_bin DEFAULT '', `authentication_string` text COLLATE utf8_bin, PRIMARY KEY (`Host`,`User`) ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Users and global privileges' | +-------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ 1 row in set (0.00 sec) mysql> show privileges; +-------------------------+---------------------------------------+-------------------------------------------------------+ | Privilege | Context | Comment | +-------------------------+---------------------------------------+-------------------------------------------------------+ | Alter | Tables | To alter the table | | Alter routine | Functions,Procedures | To alter or drop stored functions/procedures | | Create | Databases,Tables,Indexes | To create new databases and tables | | Create routine | Databases | To use CREATE FUNCTION/PROCEDURE | | Create temporary tables | Databases | To use CREATE TEMPORARY TABLE | | Create view | Tables | To create new views | | Create user | Server Admin | To create new users | | Delete | Tables | To delete existing rows | | Drop | Databases,Tables | To drop databases, tables, and views | | Event | Server Admin | To create, alter, drop and execute events | | Execute | Functions,Procedures | To execute stored routines | | File | File access on server | To read and write files on the server | | Grant option | Databases,Tables,Functions,Procedures | To give to other users those privileges you possess | | Index | Tables | To create or drop indexes | | Insert | Tables | To insert data into tables | | Lock tables | Databases | To use LOCK TABLES (together with SELECT privilege) | | Process | Server Admin | To view the plain text of currently executing queries | | Proxy | Server Admin | To make proxy user possible | | References | Databases,Tables | To have references on tables | | Reload | Server Admin | To reload or refresh tables, logs and privileges | | Replication client | Server Admin | To ask where the slave or master servers are | | Replication slave | Server Admin | To read binary log events from the master | | Select | Tables | To retrieve rows from table | | Show databases | Server Admin | To see all databases with SHOW DATABASES | | Show view | Tables | To see views with SHOW CREATE VIEW | | Shutdown | Server Admin | To shut down the server | | Super | Server Admin | To use KILL thread, SET GLOBAL, CHANGE MASTER, etc. | | Trigger | Tables | To use triggers | | Create tablespace | Server Admin | To create/alter/drop tablespaces | | Update | Tables | To update existing rows | | Usage | Server Admin | No privileges - allow connect only | +-------------------------+---------------------------------------+-------------------------------------------------------+ 31 rows in set (0.00 sec) mysql>
发表评论
-
mysql的复制设置详解
2013-06-18 09:44 1137原文链接:http://www.javaarch.ne ... -
MySQL Events详解
2013-06-06 12:28 769原文链接:http://www.javaarch.net/ ... -
分布式唯一主键生成策略的一种开销比较小的方法
2013-06-05 09:26 1302原文链接:http://www.javaarch.net/ ... -
Oracle删除重复记录的几种方式
2013-06-05 09:26 706原文链接:http://www.javaarch.net/ ... -
Oracle 11G 虚拟列 Virtual Column介绍
2013-06-04 09:31 1242原文链接:http://www.javaarch.net/ ... -
Oracle Skip Locked
2013-06-04 09:30 856原文链接:http://www.javaarch.net/ ... -
各个数据库获取随机列的语法
2013-06-04 09:30 674原文链接:http://www.javaarch.net/ ... -
如何重置mysql的密码
2013-06-04 09:30 731原文链接:http://www.javaarch.net/ ... -
使用Mysqldump 备份数据库
2013-06-04 09:29 735原文地址:http://www.javaarch.net/ ... -
MySQL 全文搜索支持
2013-06-03 00:06 642原文地址:http://www.javaarch.net/ ... -
怎么重置mysql的自增列
2013-06-03 00:06 728原文链接:http://www.javaarch.net/ ... -
使用ssd硬盘加速 mysql index查询
2013-05-30 18:28 1514使用ssd硬盘加速 mysql index查询 更 ... -
mysql修改表默认字符集可能带来的隐患
2013-05-29 13:28 1116原文链接:http://www.javaarch.net/j ... -
Mysql 5.5分区特性增强深度解析
2013-05-22 13:49 1478原文链接:http://www.javaarc ... -
mysql常用监控脚本命令列表
2013-04-07 09:15 1300#/bin/sh #检测mysql server是否 ... -
hsqldb源码分析系列6之事务处理
2013-01-20 15:20 1706在session的 public Result ... -
hsqldb源码分析系列5 查询引擎之查询操作
2013-01-18 17:27 2310执行过程先分析select语句的解析过程: ... -
hsqldb源码分析系列4 查询引擎之查询操作
2013-01-18 00:27 1017查询过程前面解析类似insert,最终调用是在 ... -
hsqldb源码分析系列3 执行引擎分析 插入过程分析
2013-01-17 21:43 1388我们看看insert语句的执行过程, 如 ... -
hsqldb源码分析系列2 解析器分析
2013-01-17 17:22 1122在server类的handleC ...
相关推荐
在本篇文章中,我们将详细介绍几个基本且重要的MySQL命令,帮助读者更好地理解和操作MySQL数据库。 ### MySQL数据库命令介绍 #### 1. `mysqld-nt-remove` 该命令用于移除MySQL服务。当您不再需要MySQL服务在系统...
这两个命令都可以用来查看指定表的列信息,包括字段名、数据类型、是否为主键等。这对于理解表结构非常有帮助。 - **命令**: `SHOW COLUMNS FROM table_name;` 与`DESCRIBE`类似,这条命令也可以用来查看表的列...
在本文中,我们将探讨几个鲜为人知的MySQL特殊技巧,这些技巧可以帮助数据库管理员和开发人员更高效地管理和操作数据库。 首先,MySQL允许用户以XML格式查看查询结果。这对于需要将查询结果与其他应用程序集成的...
- 使用命令行工具(如cmd或PowerShell),以管理员身份运行,然后用以下命令分别创建两个版本的MySQL服务: - 对于MySQL5.x:`mysqld --install MySQL5x --defaults-file="C:\ProgramData\MySQL\MySQL Server 5.x\...
除了以上介绍的基础命令外,还有许多其他有用的MySQL命令: 1. **显示数据库列表**:使用`SHOW DATABASES`命令可以查看所有可用的数据库。 ```sql SHOW DATABASES; ``` 2. **选择数据库**:使用`USE`命令切换...
首先,让我们了解MSF中与MySQL相关的几个主要插件: 1. **auxiliary/scanner/mysql/mysql_login**:此模块用于扫描内网中的MySQL服务器,尝试使用不同用户名和密码进行登录测试。这在确定潜在的弱凭证或未授权访问...
在本教程中,我们将深入探讨几个关键知识点,包括如何使用mysql客户端,连接和断开与服务器的连接,以及创建和管理数据库。 首先,mysql客户端程序是与MySQL服务器进行交互的主要工具,它允许用户运行SQL查询并查看...
几乎所有的任务都可以用命令提示符下的mysqladmin 和mysql命令来完成,但是MySQL Administrator再下列方面将是非常的有优点。 1. 它的图形化的用户界面为用户提供了非常直观的接口。 2. 它提供了较好的...
### MySQL常用命令详解 #### 一、退出MySQL操作界面:`quit` ...通过以上几个命令的应用,我们可以更加高效地管理和维护数据库,同时确保数据的安全性和准确性。希望这些基本的MySQL命令能对您有所帮助!
### MySQL常用命令详解 #### 一、启动与退出MySQL 1. **进入MySQL**:启动MySQL Command ...这些命令涵盖了数据库的基本操作,对于日常开发和维护工作非常有用。熟练掌握这些命令可以帮助您更高效地管理MySQL数据库。
在 MySQL 5.6 版本中,有以下几个关键知识点: 1. **InnoDB 存储引擎优化**:MySQL 5.6 对 InnoDB 引擎进行了大量改进,提升了事务处理性能。其中包括更快的行锁定机制、更高的并发性、以及对 InnoDB 的缓冲池进行...
以下是Nagios中几个常用的MySQL监控插件: - **NRPE(Nagios Remote Plugin Executor)**:NRPE允许远程主机执行本地插件,这对于跨服务器监控MySQL特别有用。 - **MySQL Nagios Plugins**:这些是专门为MySQL设计...
文档中提到了几个关键的函数和过程,包括mysql_init, mysql_real_connect以及mysql_query等。下面我们详细地解析这些知识点。 首先,文档中提到了mysql_init函数,它用于初始化一个MYSQL结构体,该结构体是后续所有...
总的来说,PHP与MySQL的结合使用涉及到以下几个核心知识点: 1. MySQL数据类型的理解和选用,以适应不同的数据存储需求。 2. 掌握MySQL的基本命令,如创建/删除数据库、操作表及记录,便于数据库管理和维护。 3. ...
游标的使用通常包括以下几个步骤: 1. **声明游标**:首先需要声明一个游标,并指定该游标将使用的SQL语句。 2. **打开游标**:使用`OPEN`命令来打开游标,使它准备好读取数据。 3. **获取数据**:通过`FETCH`命令...
在使用MySQL数据库的过程中,有时可能会遇到不小心忘记MySQL root用户密码的情况。这无疑会给数据库管理和操作带来困扰,但不用担心,有几种方法可以帮助你...同时,了解这些应急恢复方法对于应对类似问题非常有用。
安装MySQL 5.5.62-winx64通常包括以下几个步骤: 1. 下载并解压“mysql-5.5.62-winx64.zip”压缩包,这将提供所有必要的二进制文件和配置脚本。 2. 安装服务:通过执行“bin”目录下的“mysqld.exe”并指定相应的...