问题描述
嗨,
有没有办法为代理连接设置Pro * C USERID预编译器选项?
例如,我有一个经过操作系统身份验证的用户GEORGE,他被授予 “通过” 用户GEORGE_P的连接,并且可以在SQL * Plus中执行与GEORGE_P的代理连接:
> whoami
乔治
> sqlplus/
SQL> 显示用户
用户是 “乔治”
SQL> 连接 [乔治 _ p]/
连接。
SQL> 显示用户
用户是 “乔治 _ p”
User 乔治 also needs to run the Pro*C precompiler against the database objects (tables, etc.) that GEORGE_P owns, but must not know GEORGE_P's password. Is there a way to set the USERID Pro*C precompiler option in order to achieve this?
> whoami
乔治
> proc INAME = sample1.pc错误 = 是用户id = ?????SQLCHECK = 满
谢谢!
有没有办法为代理连接设置Pro * C USERID预编译器选项?
例如,我有一个经过操作系统身份验证的用户GEORGE,他被授予 “通过” 用户GEORGE_P的连接,并且可以在SQL * Plus中执行与GEORGE_P的代理连接:
> whoami
乔治
> sqlplus/
SQL> 显示用户
用户是 “乔治”
SQL> 连接 [乔治 _ p]/
连接。
SQL> 显示用户
用户是 “乔治 _ p”
User 乔治 also needs to run the Pro*C precompiler against the database objects (tables, etc.) that GEORGE_P owns, but must not know GEORGE_P's password. Is there a way to set the USERID Pro*C precompiler option in order to achieve this?
> whoami
乔治
> proc INAME = sample1.pc错误 = 是用户id = ?????SQLCHECK = 满
谢谢!
专家解答
你只是使用相同的语法,例如
SQL> alter user scott grant connect through "XPS13\CONNOR"; User altered. C:\temp>sqlplus [scott]/ SQL*Plus: Release 12.2.0.1.0 Production on Fri Sep 15 10:51:13 2017 Copyright (c) 1982, 2016, Oracle. All rights reserved. Last Successful login time: Fri Sep 15 2017 10:11:57 +08:00 Connected to: Oracle Database 12c Enterprise Edition Release 12.2.0.1.0 - 64bit Production SQL> show user USER is "SCOTT" SQL> exit Disconnected from Oracle Database 12c Enterprise Edition Release 12.2.0.1.0 - 64bit Production C:\temp>touch x.pc C:\temp>proc userid=[scott]/ sqlcheck=full iname=x.pc oname=x.c Pro*C/C++: Release 12.2.0.1.0 - Production on Fri Sep 15 10:52:12 2017 Copyright (c) 1982, 2017, Oracle and/or its affiliates. All rights reserved. System default option values taken from: C:\oracle\product\12.2.0.1\precomp\admin\pcscfg.cfg C:\temp>proc userid=[blah]/ sqlcheck=full iname=x.pc oname=x.c Pro*C/C++: Release 12.2.0.1.0 - Production on Fri Sep 15 10:52:20 2017 Copyright (c) 1982, 2017, Oracle and/or its affiliates. All rights reserved. System default option values taken from: C:\oracle\product\12.2.0.1\precomp\admin\pcscfg.cfg PCC-F-02104, Unable to connect to Oracle复制
「喜欢这篇文章,您的关注和赞赏是给作者最好的鼓励」
关注作者
【版权声明】本文为墨天轮用户原创内容,转载时必须标注文章的来源(墨天轮),文章链接,文章作者等基本信息,否则作者和墨天轮有权追究责任。如果您发现墨天轮中有涉嫌抄袭或者侵权的内容,欢迎发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。
评论
相关阅读
Oracle DataGuard高可用性解决方案详解
孙莹
426次阅读
2025-03-26 23:27:33
Oracle RAC 一键安装翻车?手把手教你如何排错!
Lucifer三思而后行
385次阅读
2025-04-15 17:24:06
墨天轮个人数说知识点合集
JiekeXu
364次阅读
2025-04-01 15:56:03
XTTS跨版本迁移升级方案(11g to 19c RAC for Linux)
zwtian
357次阅读
2025-04-08 09:12:48
Oracle SQL 执行计划分析与优化指南
Digital Observer
329次阅读
2025-04-01 11:08:44
Oracle 19c RAC更换IP实战,运维必看!
szrsu
296次阅读
2025-04-08 23:57:08
风口浪尖!诚通证券扩容采购Oracle 793万...
Roger的数据库专栏
293次阅读
2025-03-24 09:42:53
切换Oracle归档路径后,不能正常删除原归档路径上的归档文件
dbaking
287次阅读
2025-03-19 14:41:51
oracle定时任务常用攻略
virvle
286次阅读
2025-03-25 16:05:19
3月“墨力原创作者计划”获奖名单公布
墨天轮编辑部
272次阅读
2025-04-15 14:48:05