It is possible to get NULL in SYS_CONTEXT('USERENV','OS_USER') .?

Hi ,
I am using below query in my procedure. Can it possible below query give NULL. If yes then which Case...?
SELECT SYS_CONTEXT('USERENV','OS_USER')
FROM DUAL
Thanks lot..
Edited by: user8568838 on Mar 1, 2011 2:05 AM
Edited by: user8568838 on Mar 1, 2011 2:27 AM

BluShadow wrote:
smon wrote:
Please apologize and remove the word 'Urgent'.lol, lighten up!It's not about lightening up, it's about people coming here and being rude by assuming everyone should drop what they're doing to help them "urgently". You would consider it rude if you were busy talking to people in a room and someone came in demanding your urgent attention without consideration for what you're doing.
I've now edited the subject line to remove the "urgent" from it.That isn't the intention, to get everyone to drop what they're doing. Marking it as urgent just means the clocks ticking at his end, he isn't haughtily making demands of me, you or anyone else.
The meeting room analogy doesn't work, as the poster isn't barging in and disturbing us from whatever else we're doing. He's passively posting on a forum, and we're actively looking for his, or anyone elses posts, to read and reply to. If I'm busy doing something else, then the poster with the urgent problem isn't disturbing me, because I'm not on the forum.

Similar Messages

  • Parameter in SYS_CONTEXT('USERENV'

    Hi,
    is there any parameter in SYS_CONTEXT('USERENV' that shows the name or IP adresse of database server ( machine on which DB is running) ?
    many thanks.
    I know the followings but non lets know (but if I'm wrong).
    SYS_CONTEXT('USERENV','TERMINAL') terminal,
    SYS_CONTEXT('USERENV','LANGUAGE') language,
    SYS_CONTEXT('USERENV','SESSIONID') sessionid,
    SYS_CONTEXT('USERENV','INSTANCE') instance,
    SYS_CONTEXT('USERENV','ENTRYID') entryid,
    SYS_CONTEXT('USERENV','ISDBA') isdba,
    SYS_CONTEXT('USERENV','NLS_TERRITORY') nls_territory,
    SYS_CONTEXT('USERENV','NLS_CURRENCY') nls_currency,
    SYS_CONTEXT('USERENV','NLS_CALENDAR') nls_calendar,
    SYS_CONTEXT('USERENV','NLS_DATE_FORMAT') nls_date_format,
    SYS_CONTEXT('USERENV','NLS_DATE_LANGUAGE') nls_date_language,
    SYS_CONTEXT('USERENV','NLS_SORT') nls_sort,
    SYS_CONTEXT('USERENV','CURRENT_USER') current_user,
    SYS_CONTEXT('USERENV','CURRENT_USERID') current_userid,
    SYS_CONTEXT('USERENV','SESSION_USER') session_user,
    SYS_CONTEXT('USERENV','SESSION_USERID') session_userid,
    SYS_CONTEXT('USERENV','PROXY_USER') proxy_user,
    SYS_CONTEXT('USERENV','PROXY_USERID') proxy_userid,
    SYS_CONTEXT('USERENV','DB_DOMAIN') db_domain,
    SYS_CONTEXT('USERENV','DB_NAME') db_name,
    SYS_CONTEXT('USERENV','HOST') host,
    SYS_CONTEXT('USERENV','OS_USER') os_user,
    SYS_CONTEXT('USERENV','EXTERNAL_NAME') external_name,
    SYS_CONTEXT('USERENV','IP_ADDRESS') ip_address,
    SYS_CONTEXT('USERENV','NETWORK_PROTOCOL') network_protocol,
    SYS_CONTEXT('USERENV','BG_JOB_ID') bg_job_id,
    SYS_CONTEXT('USERENV','FG_JOB_ID') fg_job_id,
    SYS_CONTEXT('USERENV','AUTHENTICATION_TYPE')
    authentication_type,
    SYS_CONTEXT('USERENV','AUTHENTICATION_DATA')
    authentication_data,
    SYS_CONTEXT('USERENV','CURRENT_SQL') current_sql,
    SYS_CONTEXT('USERENV','CLIENT_IDENTIFIER') client_identifier,
    SYS_CONTEXT('USERENV','GLOBAL_CONTEXT_MEMORY')

    We have 10g and 9i DBs. We should be able to know to which machine user is connected.
    Thank you.
    On 9i I tested :
    SQL> select SYS_CONTEXT('USERENV','hostname') from dual;
    select SYS_CONTEXT('USERENV','hostname') from dual
    ERREUR à la ligne 1 :
    ORA-02003: invalid USERENV parameter

  • Is it possible to get control of the .SWF files in JSP files

    Hi All
    In my web application, I got 4 swf buttons which are created by flash and they are embedded in the jsp's. Each button perform the navigation to other page.
    this is the jsp file.
         <table width="100%" border="0">
                  <tr>
                    <td width="2%" height="26"> </td>
                    <td width="31%"> <object classid="clsid:...." codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="100" height="22">
                        <param name="BASE" value=".">
                        <param name="BGCOLOR" value="">
                        <param name="movie" value="button1.swf">
                        <param name="quality" value="high">
                        <embed src="button1.swf" width="100" height="22" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" base="." ></embed>
                      </object> <font size="-1" face="Arial, Helvetica, sans-serif"> </font></td>
                    <td width="67%" class="sitemapgy">*Add*  </td>
                  </tr>
                  <tr>
                    <td height="26"> </td>
                    <td><object classid="clsid:..." codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="100" height="22">
                        <param name="BASE" value=".">
                        <param name="BGCOLOR" value="">
                        <param name="movie" value="button2.swf">
                        <param name="quality" value="high">
                        <embed src="button2.swf" width="100" height="22" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" base="." ></embed>
                      </object> </td>
                    <td class="sitemapgy">*Edit* ;</td>
                  </tr>
                  <tr>
                    <td height="26"> </td>
                    <td><object classid="clsid:..." codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="100" height="22">
                        <param name="movie" value="button13.swf">
                        <param name="quality" value="high">
                        <param name="base" value=".">
                        <embed src="button7.swf" base="."  quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="100" height="22" ></embed>
                      </object></td>
                    <td class="sitemapgy">*Create*</td>
                  </tr>
                  <tr>
                    <td height="26"> </td>
                    <td><object classid="clsid:.." codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="100" height="22">
                        <param name="BGCOLOR" value="">
                        <param name="movie" value="main_print.swf">
                        <param name="quality" value="high">
                        <param name="base" value=".">
                        <embed src="main_print.swf" base="."  quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" width="100" height="22" ></embed>
                      </object></td>
                    <td class="sitemapgy"><font face="Arial, Helvetica, sans-serif">*Print*</font></td>
                  </tr>
                  <tr>
                    <td height="26"> </td>
                    <td><object classid="clsid:..." codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=5,0,0,0" width="100" height="22" >
                        <param name="BGCOLOR" value="">
                        <param name="BASE" value=".">
                        <param name="movie" value="button3.swf">
                        <param name="quality" value="high">
                        <embed src="button3.swf" width="100" height="22" quality="high" pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash" type="application/x-shockwave-flash" base="." ></embed>
                      </object></td>
                    <td class="sitemapgy"><font face="Arial, Helvetica, sans-serif">*_Admin_*</font></td>
                  </tr>
                  <tr>
                    <td height="24"> </td>
                    <td> </td>
                    <td> </td>
                  </tr>
                </table>When I click the button3.swf (Admin) button....it navigates to other page...Before that I need to get control of swf button and need to perform some login checks.
    Is it possible to get control?
    Thanks

    Thanks for your responses, I tried in the same way but when ever it looking at the path "/admin/admin_main.jsp",
    its navigating to error page if the username is admin too(abcd).
    Can you please help me regarding this.
    I am sending you my code and web.xml.
                     <filter>
              <filter-name>ExampleFilter</filter-name>
              <filter-class>com.pack.db.ExampleFilter</filter-class>
         </filter>
                   <filter-mapping>
              <filter-name>ExampleFilter</filter-name>
              <url-pattern>/admin/admin_main.jsp</url-pattern>
         </filter-mapping>
    import java.io.*;
    import javax.servlet.Filter;
    import javax.servlet.FilterChain;
    import javax.servlet.FilterConfig;
    import javax.servlet.ServletException;
    import javax.servlet.ServletRequest;
    import javax.servlet.ServletResponse;
    import javax.servlet.RequestDispatcher;
    import javax.servlet.http.*;
    public class ExampleFilter implements Filter {
         private FilterConfig filterConfig=null;
         public void init(FilterConfig config) throws ServletException {
              this.filterConfig = config;
         public void destroy() {
              filterConfig = null;
         public void doFilter(ServletRequest request, ServletResponse response,
                   FilterChain chain) throws IOException, ServletException {
              RequestDispatcher rd = null;
              String userInfo = "";
              String userName="";
              if (request instanceof HttpServletRequest) {
                   userInfo = ((HttpServletRequest) request).getUserPrincipal()
                                      .getName();
                             String[] pieces = userInfo.split("\\\\"); // Firefox sends DOMAIN\USERNAME as UserPrincipal
                                  userName = pieces[pieces.length -1]; // getting the username for which I need to perform check
                                  if(userName!="abcd"){
                                  System.out.println("userName IN ELSE PART:"+userName);
                                  System.out.println("INVALID USER NAME");
                                 rd = request.getRequestDispatcher("/admin/error.html");// i need to forward the response url to error page if the username is not equal to "abcd"
                                 rd.forward(request, response);
                             else{
                             chain.doFilter(request, response); // if username="abcd" I need to navigate to normal pages.
    Thanks

  • Is it possible to get the total value for column and assign to other field

    hi,
    Is it possible to get the total value of particular column and assign that value to another field?
    How to do this?
    Thanks in advance,
    SAN

    Afridi,
    My extended controller class code:
    package xxhr.oracle.apps.per.selfservice.appraisals.webui;
    import oracle.apps.fnd.framework.OAApplicationModule;
    import oracle.apps.fnd.framework.OAException;
    import oracle.apps.fnd.framework.OAViewObject;
    import oracle.apps.fnd.framework.webui.OAPageContext;
    import oracle.apps.fnd.framework.webui.beans.OAWebBean;
    import oracle.apps.fnd.framework.webui.beans.message.OAMessageStyledTextBean;
    import oracle.apps.per.selfservice.appraisals.webui.OverviewPageCO;
    import oracle.jbo.Row;
    public class XXOverviewPageCO extends OverviewPageCO {
    public XXOverviewPageCO() {
    public void processFormRequest(OAPageContext pageContext, OAWebBean webBean)
    super.processFormRequest(pageContext, webBean);
    if(pageContext.getParameter("XXCalcAvgButton")!=null){
    throw new OAException("welcome",OAException.INFORMATION);
    //getSum(pageContext, webBean);
    private String getSum(OAPageContext pageContext, OAWebBean webBean) {
    OAApplicationModule am = pageContext.getApplicationModule(webBean);
    OAViewObject ratvo = (OAViewObject)am.findViewObject("CompetenceElementsVO");
    OAViewObject valuevo = (OAViewObject)am.findViewObject("PerRatingLevelsVO");
    Integer Sum = new Integer("0");
    int numofRows = ratvo.getRowCount();
    for (int x = 0; x < numofRows; x++) {
    Object Rating =
    ratvo.getRowAtRangeIndex(x).getAttribute("ProficiencyLevelId");
    if(Rating!=null) {
    int numofRowsforvalue = valuevo.getRowCount();
    for(int i=0;i<numofRowsforvalue;i++){
    if(valuevo.getRowAtRangeIndex(i).getAttribute("RatingLevelId").equals(Rating)){
    Object StepValue=valuevo.getRowAtRangeIndex(i).getAttribute("StepValue");
    Sum = new Integer(StepValue.toString()) + Sum;
    OAMessageStyledTextBean displayCompAvg=(OAMessageStyledTextBean)webBean.findChildRecursive("XXCompAvgText");
    displayCompAvg.setValue(pageContext,Sum);
    return null;
    But it is not affecting in the page.
    Can you please tell me what is the problem.

  • Is it possible to get component associated with DefaultListSelectionEvent?

    Hallo,
    Is it possible to get component associated with DefaultListSelectionEvent, please?
    There are multiple tables in my window. All tables (must!) have same TableSelectionListener. Problem is that there's no information about component in default list selection model implementation. When fireing events DefaultListSelectionModel use self as event source (see DefaultListSelectionModel.fireValueChanged fragment below).
    e = new ListSelectionEvent(this, firstIndex, lastIndex, isAdjusting);Any ideas how to get component in ListSelectionListener.valueChanged, please? But don't forget that as a programer, i am the lazy. Thus implementing new selection model is not an acceptable solution, but class extension is :p
    One idea is to remember models component in constructor and override DefaultListSelectionModel.fireValueChanged like this:
    class MyGreatListSelectionModel extends DefaultListSelectionModel {
       protected JComponent boss;
        public MyGreatListSelectionModel(JComponent c) {
            boss = c;
        @Override protected void fireValueChanged(int firstIndex, int lastIndex, boolean isAdjusting)
            Object[] listeners = listenerList.getListenerList();
            ListSelectionEvent e = null;
            for (int i = listeners.length - 2; i >= 0; i -= 2) {
                if (listeners[i] == ListSelectionListener.class) {
                    if (e == null) {
                        // Only changed 'this' to 'boss'
                        e = new ListSelectionEvent(boss, firstIndex, lastIndex, isAdjusting);
                    ((ListSelectionListener)listeners[i+1]).valueChanged(e);
    }This should work, but if there already exists some mechanism, such extension is just slowing app down.

    Thanks for your help.
    However I could not get the result. I am using following code:
    public void myaction(ActionEvent event)
    FacesContext context = FacesContext.getCurrentInstance();
    UIViewRoot view = context.getViewRoot();
    UIComponent UI = view.findComponent("tab");
    if(UI == null)     
         System.out.println("UI Not Found ");
    else
         System.out.println("Get Current FecesContext");
    There is an Component having id "tab" is available on JSF page but I am getting "UI not Found" every time. Is there somthing wrong...Please suggest.

  • Possible to get variable name?

    Is it possible to get the name that you have used in your code of a variable?
    ie.
    procedure main_procedure
    is
       l_var varchar2(10) := 'Hello';
    begin
       dbms_output.put_line(get_var_name(l_var));
    end;
    function get_var_name(p_var in varchar2)
    return varchar2
    is
    begin
       -- insert magic here
    end;
    -- End code; Now call the procedure
    exec main_procedure;-- Needed output:
    "variable passed had name l_var and value Hello"

    Hi Sam,
    OK, this is definitely for fun only and NOT recommended for any production database!!
    With that out of the way, this has been adapted from Tom Kyte's who_called_me:
    SQL> create or replace procedure get_var_name (
      2     p_var in varchar2
      3  )
      4  as
      5     call_stack   varchar2(4096) default dbms_utility.format_call_stack;
      6     n            number;
      7     found_stack  boolean default false;
      8     l_line       varchar2(255);
      9     cnt          number := 0;
    10     l_owner      varchar2(255);
    11     l_name       varchar2(255);
    12     lineno       number;
    13     caller_t     varchar2(255);
    14     calling_line varchar2(4000);
    15     var_name     varchar2(1000);
    16  begin
    17     loop
    18        n := instr( call_stack, chr(10) );
    19        exit when ( cnt = 3 or n is null or n = 0 );
    20        l_line := substr( call_stack, 1, n-1 );
    21        call_stack := substr( call_stack, n+1 );
    22        if ( not found_stack ) then
    23           if ( l_line like '%handle%number%name%' ) then
    24              found_stack := true;
    25           end if;
    26        else
    27           cnt := cnt + 1;
    28           -- cnt = 1 is ME
    29           -- cnt = 2 is MY Caller
    30           -- cnt = 3 is Their Caller
    31           if ( cnt = 2 ) then
    32              lineno := to_number(substr( l_line, 13, 6 ));
    33              l_line   := substr( l_line, 21 );
    34              if ( l_line like 'pr%' ) then
    35                 n := length( 'procedure ' );
    36              elsif ( l_line like 'fun%' ) then
    37                 n := length( 'function ' );
    38              elsif ( l_line like 'package body%' ) then
    39                 n := length( 'package body ' );
    40              elsif ( l_line like 'pack%' ) then
    41                 n := length( 'package ' );
    42              elsif ( l_line like 'anonymous%' ) then
    43                 n := length( 'anonymous block ' );
    44              else
    45                 n := null;
    46              end if;
    47              if ( n is not null ) then
    48                 caller_t := ltrim(rtrim(upper(substr( l_line, 1, n-1 ))));
    49              else
    50                 caller_t := 'TRIGGER';
    51              end if;
    52 
    53              l_line := substr( l_line, nvl(n,1) );
    54              n := instr( l_line, '.' );
    55              l_owner := ltrim(rtrim(substr( l_line, 1, n-1 )));
    56              l_name  := ltrim(rtrim(substr( l_line, n+1 )));
    57           end if;
    58        end if;
    59     end loop;
    60     select text
    61     into calling_line
    62     from all_source
    63     where line = lineno
    64     and type = caller_t
    65     and name = l_name
    66     and owner = l_owner;
    67     var_name := trim ( substr (
    68        calling_line
    69        , instr(calling_line, '(') + 1
    70        , instr(calling_line, ')') - instr(calling_line, '(') - 1
    71     ));
    72     dbms_output.put_line('variable passed had name '||var_name||' and value '||p_var);
    73  end;
    74  /
    Procedure created.
    SQL> create or replace procedure main_procedure
      2  is
      3     l_var varchar2(10) := 'Hello';
      4  begin
      5     get_var_name(l_var);
      6  end;
      7  /
    Procedure created.
    SQL> exec main_procedure;
    variable passed had name l_var and value Hello
    PL/SQL procedure successfully completed.cheers,
    Anthony

  • Is it possible to get file encoding?

    I am working with windows netsh util
    /**filename = path to file*/
    private static BufferedReader readFileWithBufferedReader(String filename){
            FileInputStream fis = null;
            InputStreamReader sr= null;
            BufferedReader r    = null;
            try {
                fis = new FileInputStream(filename);
            } catch (FileNotFoundException ex) {
                ex.printStackTrace();
            }//fis catch
            try {
                /*creating InputStreamReader with encoding param*/
                sr = new InputStreamReader(fis, "Cp866" /*"Cp1251"*/);
                System.out.println("encoding ::: " +sr.getEncoding());
            } catch (UnsupportedEncodingException ex) {
                ex.printStackTrace();
            }//sr catch
                /*wrapping to BufferedReader*/
                br = new BufferedReader( sr);
            System.out.println("YES!!!");   
            return br;
        }I get InputStream from console. I set encoding as "cp866" (it's O.K.)
    Then, I save stream to file.
    Then user can open this file and get config from file.
    The problem is in open file procedure.
    I do not know file encoding: it can be "cp1251" (windows cyrillic) or it can be "cp866" (cmd output).
    So if user tries to open "cp1251" file with "cp866" encoding, he gets unreadable characters.
    Is it possible to get file encoding and then re-create InputStreamReader with proper encoding?

    Well, you can't get the file encoding. It's not saved with the file. Unless it's your file format, in which case you can save whatever you want.
    There are apps that can guess a file's encoding.
    Of course, if you have control over the files entirely, it shouldn't be a problem, and generally it'd make life a lot easier to just use UTF-8.
    So if user tries to open "cp1251" file with "cp866" encoding,
    he gets unreadable characters.what if you read a "cp866" with "cp1251" encoding?

  • OracleHomeInventory gets null oracleHomeInfo

    Dear all,
    Am getting the below error,when applying OPATCH
    -bash-3.2$ opatch apply
    Invoking OPatch 11.1.0.6.9
    Oracle Interim Patch Installer version 11.1.0.6.9
    Copyright (c) 2009, Oracle Corporation.  All rights reserved.
    Oracle Home       : /u01/oracle/PROD/db/tech_st/11.1.0
    Central Inventory : /u01/oracle/PROD/db/tech_st/11.1.0/admin/oui/PROD_oracle/oraInventory
       from           : /etc/oraInst.loc
    OPatch version    : 11.1.0.6.9
    OUI version       : 11.1.0.7.0
    OUI location      : /u01/oracle/PROD/db/tech_st/11.1.0/oui
    Log file location : /u01/oracle/PROD/db/tech_st/11.1.0/cfgtoollogs/opatch/opatch2010-06-03_02-47-54AM.log
    Patch history file: /u01/oracle/PROD/db/tech_st/11.1.0/cfgtoollogs/opatch/opatch_history.txt
    ApplySession applying interim patch '6266400' to OH '/u01/oracle/PROD/db/tech_st/11.1.0'
    List of Homes on this system:
    OPatchSession cannot load inventory for the given Oracle Home /u01/oracle/PROD/db/tech_st/11.1.0. Possible causes are:
       No read or write permission to ORACLE_HOME/.patch_storage
       Central Inventory is locked by another OUI instance
       No read permission to Central Inventory
       The lock file exists in ORACLE_HOME/.patch_storage
       The Oracle Home does not exist in Central Inventory
    ApplySession failed: ApplySession failed to prepare the system. OracleHomeInventory gets null oracleHomeInfo
    System intact, OPatch will not attempt to restore the system
    OPatch failed with error code 73I checked metalink notes . OPatch Fails With "LsInventorySession failed: OracleHomeInventory gets null oracleHomeInfo" [ID 728417.1] and
    Opatch error: "Inventory load failed... OPatch cannot load inventory for the given Oracle Home."
    -bash-3.2$ echo $ORACLE_HOME
    /u01/oracle/PROD/db/tech_st/11.1.0
    -bash-3.2$ cat /etc/oraInst.loc
    inst_group=dba
    inventory_loc=/u01/oracle/PROD/db/tech_st/11.1.0/admin/oui/PROD_oracle/oraInventory
    [root@oracle PROD_oracle]# cat /u01/oracle/PROD/db/tech_st/11.1.0/admin/oui/PROD_oracle/oraInst.loc
    inst_group=dba
    inventory_loc=/u01/oracle/PROD/db/tech_st/11.1.0/admin/oui/PROD_oracle/oraInventory
    -bash-3.2$ opatch lsinventory -all
    Invoking OPatch 11.1.0.6.9
    Oracle Interim Patch Installer version 11.1.0.6.9
    Copyright (c) 2009, Oracle Corporation.  All rights reserved.
    Oracle Home       : /u01/oracle/PROD/db/tech_st/11.1.0
    Central Inventory : /u01/oracle/PROD/db/tech_st/11.1.0/admin/oui/PROD_oracle/oraInventory
       from           : /etc/oraInst.loc
    OPatch version    : 11.1.0.6.9
    OUI version       : 11.1.0.7.0
    OUI location      : /u01/oracle/PROD/db/tech_st/11.1.0/oui
    Log file location : /u01/oracle/PROD/db/tech_st/11.1.0/cfgtoollogs/opatch/opatch2010-06-03_14-13-25PM.log
    Patch history file: /u01/oracle/PROD/db/tech_st/11.1.0/cfgtoollogs/opatch/opatch_history.txt
    List of Homes on this system:
    Inventory load failed... OPatch cannot load inventory for the given Oracle Home.
    Possible causes are:
       Oracle Home dir. path does not exist in Central Inventory
       Oracle Home is a symbolic link
       Oracle Home inventory is corrupted
    LsInventorySession failed: OracleHomeInventory gets null oracleHomeInfo
    OPatch failed with error code 73
    -bash-3.2$Any idea what could be wrong
    Kai

    From which OS user you are applying the patch? Is it the same user who installed the Oracle in first place? It looks like a permission problem.
    regards

  • While running a report through workspace getting "Null" error

    While running a report through workspace i am getting "Null" error.i have checekd the db connection and also access to hfm.
    Thanks

    Hi Raj,
    There are a few OSS Notes for your issue.
    If your Query has hierarchy in it then check 734184
    If your query is based on Infoset then check Note 784502 and 701941.
    Also check 668921.
    Bye
    Dinesh

  • How can I get null values for the later weeks

    Hi All,
    When I execute this code I get the records till current week.
    How can I display the output so that I get null values for the later weeks. (with the help of v_numOfWeeks variable in the code)
    Thanks,
    Vikram
    DECLARE
       v_query VARCHAR2(4000);
       TYPE ref_cursor IS REF CURSOR;
       v_refcur ref_cursor;
       v_sum NUMBER;
       v_id NUMBER;
       v_name VARCHAR2(1000);
       v_weeknum NUMBER;
       v_pernum NUMBER;
       v_numOfWeeks NUMBER := 5;
    BEGIN
    v_query := ' SELECT SUM(product_bkg), postn_id, postn_tbl.postn_name, b.week_num, b.period_num
                              FROM ops_cv_extract b, (SELECT row_id, desc_text postn_name
                          FROM s_postn) postn_tbl
                          WHERE lvl_6_id = 5767
                          AND fiscal_year = 2008
                          AND b.week_num < 4
                          AND b.period_num = 3
                          AND b.postn_id = TO_NUMBER(postn_tbl.row_id)
                          GROUP BY postn_id, postn_tbl.postn_name, b.week_num, b.period_num
                          ORDER BY  postn_tbl.postn_name, b.week_num';
    OPEN v_refcur FOR v_query;
    LOOP
       FETCH v_refcur INTO v_sum, v_id, v_name, v_weeknum, v_pernum;
       EXIT WHEN v_refcur%notfound;
       dbms_output.put_line('P'|| v_pernum||'W'|| v_weeknum||' '||v_name||' '||v_sum);
    END LOOP;
    END;
    This is the output when I execute this code.
    P3W1 COMM CNTRL ISAM 213 26961.61
    P3W2 COMM CNTRL ISAM 213 12870.4
    P3W3 COMM CNTRL ISAM 213 245.88
    P3W1 COMM CNTRL ISAM 273 72831.2
    P3W2 COMM CNTRL ISAM 273 8739.38
    P3W3 COMM CNTRL ISAM 273 3764.92
    P3W1 COMM CNTRL TAM 213 49844
    P3W2 COMM CNTRL TAM 213 20515.17
    P3W3 COMM CNTRL TAM 213 16167.46
    P3W2 COMM CNTRL TAM 216 12561.4
    P3W3 COMM CNTRL TAM 216 2027.1
    P3W1 COMM CNTRL TAM 273 -3336.71
    P3W2 COMM CNTRL TAM 273 -1376.68
    P3W3 COMM CNTRL TAM 273 19707.42
    P3W1 Damon Walters -609.07
    P3W2 Damon Walters 30030.24
    P3W3 Damon Walters 37475.1
    This is the output I'd like to get
    P3W1 COMM CNTRL ISAM 213 26961.61
    P3W2 COMM CNTRL ISAM 213 12870.4
    P3W3 COMM CNTRL ISAM 213 245.88
    P3W4 COMM CNTRL ISAM 213
    P3W5 COMM CNTRL ISAM 213
    P3W1 COMM CNTRL ISAM 273 72831.2
    P3W2 COMM CNTRL ISAM 273 8739.38
    P3W3 COMM CNTRL ISAM 273 3764.92
    P3W4 COMM CNTRL ISAM 273
    P3W5 COMM CNTRL ISAM 273
    P3W1 COMM CNTRL TAM 213 49844
    P3W2 COMM CNTRL TAM 213 20515.17
    P3W3 COMM CNTRL TAM 213 16167.46
    P3W4 COMM CNTRL TAM 213
    P3W5 COMM CNTRL TAM 213
    P3W1 COMM CNTRL TAM 273 -3336.71
    P3W2 COMM CNTRL TAM 273 -1376.68
    P3W3 COMM CNTRL TAM 273 19707.42
    P3W4 COMM CNTRL TAM 273
    P3W5 COMM CNTRL TAM 273
    P3W1 Damon Walters -609.07
    P3W2 Damon Walters 30030.24
    P3W3 Damon Walters 37475.1
    P3W4 Damon Walters
    P3W5 Damon Walters Edited by: polasa on Oct 28, 2008 6:42 PM

    Sure, in a Single SQL ->
    satyaki>
    satyaki>select * from v$version;
    BANNER
    Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Prod
    PL/SQL Release 10.2.0.3.0 - Production
    CORE    10.2.0.3.0      Production
    TNS for 32-bit Windows: Version 10.2.0.3.0 - Production
    NLSRTL Version 10.2.0.3.0 - Production
    Elapsed: 00:00:00.01
    satyaki>
    satyaki>
    satyaki>-- Start Of Test Data --
    satyaki>with week_tab
      2  as
      3    (
      4      select 1 period_num, 1 week_num, 10 bkg1 from dual
      5      union all
      6      select 1, 2, 40 from dual
      7      union all
      8      select 1, 3, 30 from dual
      9      union all
    10      select 1, 2, 20 from dual
    11      union all
    12      select 1, 1, 10 from dual
    13      union all
    14      select 1, 1, 20 from dual
    15      union all
    16      select 1, 3, 10 from dual
    17      union all
    18      select 2, 1, 15 from dual
    19      union all
    20      select 2, 2, 20 from dual
    21      union all
    22      select 2, 3, 10 from dual
    23      union all
    24      select 2, 1, 15 from dual
    25      union all
    26      select 2, 2, 30 from dual
    27      union all
    28      select 2, 3, 20 from dual
    29    )
    30  -- End Of Test Data --
    31  select period_num,
    32         week_num,
    33         (
    34            select sum(week_tab.bkg1)
    35            from week_tab
    36            where period_num = m.period_num
    37            and   week_num   = m.week_num
    38            group by week_num, period_num
    39         ) sum_bkg1
    40  from (
    41        select dum.week_num,
    42              wk.period_num
    43        from (
    44                select 1 week_num from dual
    45                union all
    46                select 2 from dual
    47                union all
    48                select 3 from dual
    49                union all
    50                select 4 from dual
    51                union all
    52                select 5 from dual
    53              ) dum ,
    54              (
    55                select distinct period_num
    56                from week_tab
    57          ) wk
    58      ) m;
    PERIOD_NUM   WEEK_NUM   SUM_BKG1
             1          1         40
             1          2         60
             1          3         40
             1          4
             1          5
             2          1         30
             2          2         50
             2          3         30
             2          4
             2          5
    10 rows selected.
    Elapsed: 00:00:00.48
    satyaki>Regards.
    Satyaki De.

  • Getting null values from nodes using DOMParser

    Hi
    I'm having problems retrieving the values from an XML doc.
    I'm using the DOMParser, but instead of retrieving the values
    from the nodes, I just get null.
    Code fragment :
    DOMParser parser = new DOMParser();
    parser.parse(url);
    XMLDocument doc = parser.getDocument();
    NodeList nl = doc.getElementsByTagName("*");
    Node n;
    iNode = nl.getLength();
    for (int i=0; i<iNode; i++)
    n = nl.item(i);
    String szNodeName = n.getNodeName();
    System.out.print(szNodeName+ " (" );
    System.out.print(n.getNodeValue()+")");
    System.out.println();
    The result is
    course (null)
    Name (null)
    All the node names are correct, but the node values are NOT
    displayed.
    Any idea ?
    Rodrigo
    null

    According to the DOM Level 1 spec, the "value" of an ELEMENT node
    is null and the getNodeValue() method will always return null for
    an ELEMENT type node. You have to get the TEXT children of an
    element and then use the getNodeValue() method in the text nodes.
    Oracle XML Team
    Rodrigo Loureiro (guest) wrote:
    : Hi
    : I'm having problems retrieving the values from an XML doc.
    : I'm using the DOMParser, but instead of retrieving the values
    : from the nodes, I just get null.
    : Code fragment :
    : DOMParser parser = new DOMParser();
    : parser.parse(url);
    : XMLDocument doc = parser.getDocument();
    : NodeList nl = doc.getElementsByTagName("*");
    : Node n;
    : iNode = nl.getLength();
    : for (int i=0; i<iNode; i++)
    : n = nl.item(i);
    : String szNodeName = n.getNodeName();
    : System.out.print(szNodeName+ " (" );
    : System.out.print(n.getNodeValue()+")");
    : System.out.println();
    : The result is
    : course (null)
    : Name (null)
    : All the node names are correct, but the node values are NOT
    : displayed.
    : Any idea ?
    : Rodrigo
    Oracle XML Team
    http://technet.oracle.com
    Oracle Technology Network
    null

  • I am facing problem while reading values from properties file ...i am getting null pointer exception earlier i was using jdeveloper10g now i am using 11g

    i am facing problem while reading values from properties file ...i am getting null pointer exception earlier i was using jdeveloper10g now i am using 11g

    hi TimoHahn,
    i am getting following exception in JDeveloper(11g release 2) Studio Edition Version 11.1.2.4.0 but it works perfectly fine in JDeveloper 10.1.2.1.0
    Root cause of ServletException.
    java.lang.NullPointerException
    at java.util.PropertyResourceBundle.handleGetObject(PropertyResourceBundle.java:136)
    at java.util.ResourceBundle.getObject(ResourceBundle.java:368)
    at java.util.ResourceBundle.getString(ResourceBundle.java:334)
    at org.rbi.cefa.master.actionclass.UserAction.execute(UserAction.java:163)
    at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
    at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
    at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
    at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
    at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:119)
    at java.security.AccessController.doPrivileged(Native Method)
    at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:315)
    at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:442)
    at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)
    at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)
    at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:139)
    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)
    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)
    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)
    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)
    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

  • I've recently been given a macbook pro from uni, with lots of adobe software on. I want to pair it with my iMac which has music etc and is it possible to get the software to the imac and the files to the macbook?Giving me the best of both :-)

    I've recently been given a macbook pro from uni, with lots of adobe software on. I want to pair it with my iMac which has music etc and is it possible to get the software to the imac and the files to the macbook?Giving me the best of both :-)

    You would need the original installation disks or files for the Adobe software to get it onto your iMac, and having it on two computers may not be allowed by your university's licensing. Talk to whoever issued the MacBook.
    As to the music, just copy it over to the MacBook, either via Home Sharing, file sharing, or an external storage medium (hard drive, USB flash drive, etc.).
    Regards.

  • Is it possible to get a refund for a case i bought at the store but its not an apple product?

    I bought a kate spade plastic case at the store 2 months ago and even the first day of having it on my iPhone I had multiple issues with it. However, I couldn't return it because I was away at school. I went into the Apple store and asked about the possibility of getting a refund for the case but they said it was a third party product and to contact the manufacturer. I called kate spade and since i wanted a refund and purchased at the apple store there was nothing they could do and to ask the apple store for my money back because thats where I purchased it. Am I ever going to get a refund and what should I do at this point?
    Thanks
    Sara

    http://support.apple.com/kb/HT1933
    Regards.

  • Fbl5n profit center is cracked   , itz possible to get profit center value

    fbl5n profit center is cracked u  , itz possible to get profit center value
    in ur zfbl5n report
    der r few changes in program to b made
    Message was edited by:
            Ronei Shedi

    Hello Ronei,
    No need to make a copy of the FBL5N to have the profit center in the list.
    You can have it in the ALV Layout.
    Select profit center in the Hidden fields column and pass it to left hand side column.
    Save as a Display Variant.
    Next time when you run the FBL5N, select your display variant in the last frame "List Output".
    Regards,
    Naimesh Patel

Maybe you are looking for