Getting Started with Adobe After Effects - Part 6: Motion Blur


Upload Image Close it
Select File

Browse by Tags · View All
SQL Server 119
#SQLServer 88
Oracle 70
#SQL SERVER 35
BRH 31
SQL Server 2012 29
denali 23
#TSQL 19
TSQL 19
C# 15

Archive · View All
October 2011 31
November 2011 30
September 2011 30
August 2011 18
December 2011 15
July 2011 13
June 2011 8
May 2012 4
April 2012 3
January 2010 3

Day 50: Sys_Context function of Oracle

Nov 2 2011 11:26PM by Niladri Biswas   

Let Us Learn Oracle - Part 50 of N [ Sys_Context Function of Oracle 10g ]

Purpose: This function retrives information about Oracle Environment.

Syntax: Sys_Context(Namespace,parameter [,length])

Where,

Namespace => Oracle namespace to be use.If we use 'UserEnv' as the namespace, we can get information about the current Oracle session.

Parameter => Valid attribute for the session

Length => Length of return value in bytes. It is optional

Example1 : Get the current Database Name

SQL> Select Sys_Context('UserEnv','DB_Name') "Current DB Name"
  2  From Dual;

Current DB Name
----------------
orcl

Example2 : Get the name of Current User

SQL> Select Sys_Context('UserEnv','Current_User') "Curent User"
  2  From Dual;

Curent User
-----------
SCOTT

Example3 : Get the name of host machine

SQL> Select Sys_Context('UserEnv','Host') "Host Machine"
  2  From Dual;

Host Machine
---------------------
WORKGROUP\NILADRI-PC

Example4 : Get the date format for the current session

SQL> Select Sys_Context('UserEnv','NLS_Date_Format') "Current Date Format"
  2  From Dual;

Current Date Format
-------------------
DD-MON-RR

References :

Hope this was useful.Thanks for reading

Tags: SQL Server, Oracle, #SQL SERVER,


Niladri Biswas
7 · 21% · 6710
1
 
0
Lifesaver
 
0
Refreshed
 
0
Learned
 
0
Incorrect



Submit

Your Comment


Sign Up or Login to post a comment.

"Day 50: Sys_Context function of Oracle" rated 5 out of 5 by 1 readers
Day 50: Sys_Context function of Oracle , 5.0 out of 5 based on 1 ratings
    Copyright © Rivera Informatic Private Ltd Contact us      Privacy Policy      Terms of use      Report Abuse      Advertising      [ZULU1097]