1、修改参数

2、创建两个用户

  • 创建a1

create
user a1 connection limit-1 password '123456';

alter user a1 SUPERUSER;

grant create
on
database "test" to "a1" with grant option;

grant temporary on
database "test" to "a1" with grant option;

grant temp on
database "test" to "a1" with grant option;

grant connect on
database "test" to "a1" with grant option;

  • 创建a2

create
user a2 connection limit-1 password '123456';

alter user a2 SUPERUSER;

grant create
on
database "test" to "a2" with grant option;

grant temporary on
database "test" to "a2" with grant option;

grant temp on
database "test" to "a2" with grant option;

grant connect on
database "test" to "a2" with grant option;

3、在a1和a2下创建各自模式

create schema a1schema;

create table a1schema.t1(id int);

create schema a2schema;

create table a2schema.t2(id int);

insert into a2schema.t2 values(111111111);

4、a1访问a2下的t2表

  • 创建视图

CREATE VIEW "a1".v_t2 AS select id from a2.t2;

  • 创建同义词

create synonym t2 for v_t2;

  • 访问t2

selet * from t2

最新文章

  1. 【Java EE 学习 16 上】【dbcp数据库连接池】【c3p0数据库连接池】
  2. 使用ping钥匙临时开启SSH:22端口,实现远程安全SSH登录管理就这么简单
  3. C# .net中cookie值为中文时的乱码解决方法
  4. cocos2dx 3.x(定时器或延时动作自动调用button的点击响应事件)实现自动内测
  5. java maven诡异的错误no class found
  6. db2安装及卸载
  7. oracle sql 语句优化
  8. 一份完整的nginx配置
  9. 【重要】ASCII码表
  10. [C程序设计语言]第二部分
  11. Android控件之AutoCompleteTextView(自动匹配输入的内容)
  12. Maven Build Life Cycle--reference
  13. Latex 去掉行号
  14. DataTable克隆行
  15. 高可用集群之keepalived+lvs实战-技术流ken
  16. 【转】C++标准转换运算符const_cast
  17. centos7 yum安装ffmpeg,以及ffmpeg的简单用法
  18. sdn的相关学习系列之一mininet的安装
  19. ubuntu下tensorflow 报错 libcusolver.so.8.0: cannot open shared object file: No such file or directory
  20. [C++]QString方法集

热门文章

  1. 锂电池3.7V转3V,1.5V的稳压和降压芯片
  2. python中文件操作相关基础知识
  3. 持续发烧,试试Dart语言的异步操作,效率提升500%
  4. MSTN CE和MSTN SDK安装经验及技巧
  5. 关于如何在C#中调用C++的DLL,以及如何在C++中调用C#的DLL
  6. 时钟同步服务器ntp安装文档
  7. 如何在 Nuxt 3 中使用 wavesurfer.js
  8. 动力节点——day07
  9. 除了Navicat和DBeaver,还有没有免费又好用的数据库管理/SQL工具推荐
  10. 【学习笔记】开源库之 - sigslot (在解决浅拷贝问题的基础上增加信号拦截功能)