普遍的 SQL GRANT 语法
我已经在谷歌上搜索了半个小时,似乎找不到正确的地方...
如何添加用户并授予该用户访问数据库中所有表的权限?找到了一些 GRANT 片段,但没有提到密码,所以我认为只能对现有用户完成......但是添加该用户和密码识别怎么样?
PS:不确定它是否更属于这里,或者服务器故障(都没有这个答案)...所以请随意移动它,如果它应该在服务器故障上。
I've been Googling for half an hour now, and can't seem to find the right place...
How do I add a user and grant that user access to all tables in the database? Found some GRANT snippets, but there is no mentioning of a password, so I assume that can be done on existing users only... But what about adding that user, and password identification?
PS: Not sure if it belongs more here, or on serverfault (neither has this answer already)... So feel free to move it, if it should be on serverfault instead.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这也是 Pervasive SQL 中的两个命令。
有关两者的完整文档位于 SQL 语法参考指南。
需要注意的一件事是,大多数 PSQL 数据库默认情况下没有启用安全性,并且不需要用户登录。如果您尝试在未启用安全性的数据库上运行 CREATE USER 和 GRANT 语句,它们将返回错误。
It is two command in Pervasive SQL as well.
Full documentation on both are in the SQL Syntax Reference guide on Pervasive's site.
One thing to note, most PSQL databases do not have security enabled by default and do not require a user to login. The CREATE USER and GRANT statements will return an error if you try to run them on a database that does not have security enabled.
它有 2 个命令:CREATE USER 和 GRANT after。
摘自 MySQL 5.0 参考手册
通常,数据库管理员
首先使用 CREATE USER 创建一个
帐户,然后 GRANT 定义其
特权和特征。为了
示例:
参考
It's 2 commands: CREATE USER and GRANT after.
From MySQL 5.0 Reference Manual
Normally, a database administrator
first uses CREATE USER to create an
account, then GRANT to define its
privileges and characteristics. For
example:
Reference