• --:)欢迎访问锋网源码(:--
  • 首页
  • RSS订阅
  • 常用软件
  • 网页模板
  • 网站运作
  • 锋网学院
  • 时代互联
  • 中国红网
  • 中资源!
  • 繁體中文

  • 学院首页
  • 新闻资讯
  • 网站运营
  • 网站开发
  • 美工设计
  • 数据库类
  • 服务器类
  • 网络应用
  • 操作系统
  • 软件教学
编程开发   认证考试   网络安全   文章搜索: 高级搜索
会员登录/控制面版 您的位置: 学院首页 >> 数据库类 >> Oracle >> 文章内容
 

精彩推荐

 
 

本类推荐文章

 
 

本类阅读排行

  • ORACLE学习笔记--性能优化
  • oracle HA应用的方案参考
  • 在UNIX服务器上设置Oracle8i..
  • Oracle 数据库的备份与恢复(..
  • 在UNIX服务器上设置Oracle8i..
  • Oracle 数据库的备份与恢复(..
  • 如何在hp-ux10.20系统中正确..
  • 在一台机器配置两个listener..
  • 如何保持Oracle数据库的优良..
  • Oracle 数据库的备份与恢复
  • Oracle数据库的空间管理技巧
  • 在slackware 10下安装Oracle..
  • 在UnixWare7.1.1上安装Oracl..
  • Oracle 10g导出的数据库能否..
  • 解决Oracle并行服务器的相关..
  • 最影响Oracle系统性能的初始..
  • 正确进行Oracle数据库性能完..
  • 详细介绍Oracle数据库的启动..
  • 在Oracle中添加用户 赋权 修..
  • 讲解SQL与Oracle外键约束中的..
 
 

Oracle 9i SYS_CONTEXT函数的使用方法

  • 日期:2008-07-04     人气:     出处:     作者:
  • 字体大小:
  • 小
  • 中
  • 大

此函数在写一些触发器和函数的时候非常有用处。

 

用法:

SELECT sys_context('USERENV', ' ') FROM dual;

 

第二个参数的可选值:

AUTHENTICATION_DATA

Data being used to authenticate the login user. For X.503 certificate authenticated sessions, this field returns the context of the certificate in HEX2 format.

Note: You can change the return value of the AUTHENTICATION_DATA attribute using the length parameter of the syntax. Values of up to 4000 are accepted. This is the only attribute of USERENV for which Oracle implements such a change.

 

AUTHENTICATION_TYPE

How the user was authenticated:

DATABASE: username/password authentication

OS: operating system external user authentication

NETWORK: network protocol or ANO authentication

PROXY: OCI proxy connection authentication

 

BG_JOB_ID

Job ID of the current session if it was established by an Oracle background process. Null if the session was not established by a background process.

 

CLIENT_INFO

Returns up to 64 bytes of user session information that can be stored by an application using the DBMS_APPLICATION_INFO package.

 

CURRENT_SCHEMA

Name of the default schema being used in the current schema. This value can be changed during the session with an ALTER SESSION SET CURRENT_SCHEMA statement.

 

CURRENT_SCHEMAID

Identifier of the default schema being used in the current session.

 

CURRENT_USER

The name of the user whose privilege the current session is under.

 

CURRENT_USERID

User ID of the user whose privilege the current session is under.

 

DB_DOMAIN

Domain of the database as specified in the DB_DOMAIN initialization parameter.

 

DB_NAME

Name of the database as specified in the DB_NAME initialization parameter.

 

ENTRYID

The available auditing entry identifier. You cannot use this option in distributed SQL statements. To use this keyword in USERENV, the initialization parameter AUDIT_TRAIL must be set to true.

 

EXTERNAL_NAME

External name of the database user. For SSL authenticated sessions using v.503 certificates, this field returns the distinguished name (DN) stored in the user certificate.

 

FG_JOB_ID

Job ID of the current session if it was established by a client foreground process. Null if the session was not established by a foreground process.

 

HOST

Name of the host machine from which the client has connected.

 

INSTANCE

The instance identification number of the current instance.

 

IP_ADDRESS

IP address of the machine from which the client is connected.

 

ISDBA

TRUE if you are logged on as SYS.

 

LANG

The ISO abbreviation for the language name, a shorter form than the existing 'LANGUAGE' parameter.

 

LANGUAGE

The language and territory currently used by your session, along with the database character set, in the form:language_territory.characterset.

 

NETWORK_PROTOCOL

Network protocol being used for communication, as specified in the 'PROTOCOL=protocol' portion of the connect string.

 

NLS_CALENDAR

The current calendar of the current session.

 

NLS_CURRENCY

The currency of the current session.

 

NLS_DATE_FORMAT

The date format for the session.

 

NLS_DATE_LANGUAGE

The language used for expressing dates.

 

NLS_SORT BINARY

or the linguistic sort basis.

 

NLS_TERRITORY

The territory of the current session.

 

OS_USER

Operating system username of the client process that initiated the database session.

 

PROXY_USER

Name of the database user who opened the current session on behalf of SESSION_USER.

 

PROXY_USERID

Identifier of the database user who opened the current session on behalf of SESSION_USER.

 

SESSION_USER

Database user name by which the current user is authenticated. This value remains the same throughout the duration of the session.

 

SESSION_USERID

Identifier of the database user name by which the current user is authenticated.

 

SESSIONID

The auditing session identifier. You cannot use this option in distributed SQL statements.

 

TERMINAL

The operating system identifier for the client of the current session. In distributed SQL statements, this option returns the identifier for your local session. In a distributed environment, this is supported only for remote SELECT statements, not for remote INSERT, UPDATE, or DELETE operations.

(The return length of this parameter may vary by operating system.)

相关文章
  • Oracle 10g新增表空间类型:大文件表空间
  • Oracle 9i在AIX上的性能调整──内存篇
  • 检测Oracle的可用性和表空间容量
  • 数据从MySQL迁移到Oracle的注意事项
  • 使用utl_smtp从Oracle中发送电子邮件
  • Oracle非法数据库对象引起的错误
  • 如何用Oracle创建实例的参数需求
  • 深入了解Oracle数据库后台进程的功能
  • 掌握MIS系统实例中Oracle的安全策略
  • 最影响Oracle系统性能的初始化参数
相关软件

  • 网友评论:
  • 查看所有评论
  • 我要发表评论
 

关于本站 | 广告联系 | 版权声明 | 网站地图 | 加入收藏 | 帮助中心 |

Copyright © 2006-2007 fwvv.net  程序支持:木翼  皖ICP备06004916号  

感谢:点击网络 联网科技 天盈信息  提供服务器及带宽赞助