![background image](http://html1.mh-extra.com/html/oracle/5-0/5-0_reference-manual_16461961203.webp)
SHOW
Syntax
1183
The
SHOW COUNT(*) ERRORS
statement displays the number of errors. You can also retrieve this
number from the
error_count
[450]
variable:
SHOW COUNT(*) ERRORS;
SELECT @@error_count;
SHOW ERRORS
and
error_count
[450]
apply only to errors, not warnings or notes. In other
respects, they are similar to
SHOW WARNINGS
and
warning_count
[507]
. In particular,
SHOW
ERRORS
cannot display information for more than
max_error_count
[468]
messages, and
error_count
[450]
can exceed the value of
max_error_count
[468]
if the number of errors
exceeds
max_error_count
[468]
.
For more information, see
Section 13.7.5.37, “
SHOW WARNINGS
Syntax”
.
13.7.5.15.
SHOW FUNCTION CODE
Syntax
SHOW FUNCTION CODE
func_name
This statement is similar to
SHOW PROCEDURE CODE
but for stored functions. See
Section 13.7.5.25,
“
SHOW PROCEDURE CODE
Syntax”
.
SHOW FUNCTION CODE
was added in MySQL 5.0.17.
13.7.5.16.
SHOW FUNCTION STATUS
Syntax
SHOW FUNCTION STATUS
[LIKE '
pattern
' | WHERE
expr
]
This statement is similar to
SHOW PROCEDURE STATUS
but for stored functions. See
Section 13.7.5.26, “
SHOW PROCEDURE STATUS
Syntax”
.
13.7.5.17.
SHOW GRANTS
Syntax
SHOW GRANTS [FOR
user
]
This statement lists the
GRANT
statement or statements that must be issued to duplicate the privileges
that are granted to a MySQL user account. The account is named using the same format as for the
GRANT
statement; for example,
'jeffrey'@'localhost'
. If you specify only the user name part
of the account name, a host name part of
'%'
is used. For additional information about specifying
account names, see
Section 13.7.1.3, “
GRANT
Syntax”
.
mysql>
SHOW GRANTS FOR 'root'@'localhost';
+---------------------------------------------------------------------+
| Grants for root@localhost |
+---------------------------------------------------------------------+
| GRANT ALL PRIVILEGES ON *.* TO 'root'@'localhost' WITH GRANT OPTION |
+---------------------------------------------------------------------+
To list the privileges granted to the account that you are using to connect to the server, you can use
any of the following statements:
SHOW GRANTS;
SHOW GRANTS FOR CURRENT_USER;
SHOW GRANTS FOR CURRENT_USER();
As of MySQL 5.0.24, if
SHOW GRANTS FOR CURRENT_USER
(or any of the equivalent syntaxes) is
used in
DEFINER
context, such as within a stored procedure that is defined with
SQL SECURITY
DEFINER
), the grants displayed are those of the definer and not the invoker.
SHOW GRANTS
displays only the privileges granted explicitly to the named account. Other privileges
might be available to the account, but they are not displayed. For example, if an anonymous account
exists, the named account might be able to use its privileges, but
SHOW GRANTS
will not display them.
SHOW GRANTS
requires the
SELECT
[578]
privilege for the
mysql
database, except to see the
privileges for the current user.
13.7.5.18.
SHOW INDEX
Syntax
Содержание 5.0
Страница 1: ...MySQL 5 0 Reference Manual ...
Страница 18: ...xviii ...
Страница 60: ...40 ...
Страница 396: ...376 ...
Страница 578: ...558 ...
Страница 636: ...616 ...
Страница 844: ...824 ...
Страница 1234: ...1214 ...
Страница 1426: ...MySQL Proxy Scripting 1406 The following diagram shows an overview of the classes exposed by MySQL Proxy ...
Страница 1427: ...MySQL Proxy Scripting 1407 ...
Страница 1734: ...1714 ...
Страница 1752: ...1732 ...
Страница 1783: ...Configuring Connector ODBC 1763 ...
Страница 1793: ...Connector ODBC Examples 1773 ...
Страница 1839: ...Connector Net Installation 1819 2 You must choose the type of installation to perform ...
Страница 1842: ...Connector Net Installation 1822 5 Once the installation has been completed click Finish to exit the installer ...
Страница 1864: ...Connector Net Visual Studio Integration 1844 Figure 20 24 Debug Stepping Figure 20 25 Function Stepping 1 of 2 ...
Страница 2850: ...2830 ...
Страница 2854: ...2834 ...
Страница 2928: ...2908 ...
Страница 3000: ...2980 ...
Страница 3122: ...3102 ...
Страница 3126: ...3106 ...
Страница 3174: ...3154 ...
Страница 3232: ...3212 ...