Variable naming method

What is the good way to name the variable name? my method is first 3characters is datatype :
int intNumber;
String strName;
JButton btnGo;Any comment for my naming conversion? I think all expert java programmers not like this right? why?

This looks very MS standard.
If you use an IDE, the type is displayed as you type the variable, so finding the type is much simpler than it used to be.
If you change the type of a variable you would have to rename it as well.
I would suggest just naming the variable based on what it does and why it is there.

Similar Messages

  • Very odd behavior regarding variable naming with DataService.fill()

    I'm experiencing this odd behavior in LCDS 2.5, wich pertains
    to variable naming for the objects returned by a DataService.fill()
    call. I ceated a simple destination with a Java adapter. the Server
    side Java data object is defined as follows)
    package test;
    public class RepositoryObject
    private String m_strObjectId;
    private boolean m_bIsValid;
    private long m_lSize;
    [public setters and getters here]
    On Flex side, the ActionScript value object is defined as
    follows:
    package test
    [Bindable]
    [RemoteClass(alias="test.RepositoryObject")]
    public class RepositoryObject
    public var m_strObjectId:String;
    public var m_bIsValid:Boolean;
    public var m_lSize:Number;
    public function RepositoryObject()
    The FDS destination definition (in
    data-management-config.xml):
    <destination id="testDs">
    <adapter ref="java-dao" />
    <properties>
    <source>test.TestDS</source>
    <scope>application</scope>
    <metadata>
    <identity property="m_strObjectId"/>
    </metadata>
    <network>
    <session-timeout>20</session-timeout>
    <paging enabled="false" pageSize="10" />
    <throttle-inbound policy="ERROR" max-frequency="500"/>
    <throttle-outbound policy="REPLACE"
    max-frequency="500"/>
    </network>
    <server>
    <fill-method>
    <name>getObjects</name>
    </fill-method>
    </server>
    </properties>
    </destination>
    What I figured while debugging into the client was is the
    data returned by the service (I'm using the mx:DataService call)
    returns objects whose variable names
    do not match my definition:
    m_strObjectId becomes objectId
    m_lSize becomes size
    m_bIsValid becomes isValid
    I wonder why that renaming??? Basically "m_str" prefix was
    stripped and capital "O" became lower case "o" for my first
    variable etc.
    For instance, in a datagrid cell renderer I could not
    reference the returned value as {data.m_strObjectId}, but if I use
    {data.objectId}, it works.
    Any ideas why this behavior (which I found confusing and odd)
    would be greately appreciated.
    Robert

    The latter, as "getM_strObjectId " is an ugly name... don't
    tell me that causes issue...ok kidding, I got you. The
    setter/getter names are important in this context.
    Thanks a lot.
    Robert

  • Oci_connect using easy connect naming method needs listener??

    Hi,
    I was thinking that using the easy connect naming method in oci_connect does not require a running local tnslsnr!? Am I wrong?
    I tried:
    $db = '(DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = my-ora-host.example.com)(PORT = 1521)) (CONNECT_DATA = (SERVER = DEDICATED) (SERVICE_NAME = my-service.example.com)))';
    // $db = '//my-ora-host.example.com:1521/my-service.example.com';
    $ora_conn = oci_connect('test', 'test', $db);
    Using both versions of the 'db' I receive the error:
    mod_fcgid: stderr: PHP Warning: oci_connect(): ORA-12541: TNS:no listener in ....
    I am using a self compiled PHP 5.3.8 using Oracles instantclient 11.2.0.3.0 (on Linux, 32bit).
    There are NO special environment variables ( like ORACLE_HOME or TNS_ADMIN), because I was thinking that I don't need them...
    Am I wrong? Is a running tnslsnr always required? Or am I doing wrong in specifying the connection string?
    Any help is appreciated!
    chuan

    The connection strings are fine. They only control how PHP attempts to connect to the DB. The DB will need a listener started so that those incoming requests are handled. Use: 'lsnrctl start' on the DB machine.

  • Sending variables to methods

    i want to send some variables a method in another file, but my coding isn't working
    TextToFile.main(variablea,variableb,variablec)any suggestions?

    sorry, should have defined that, will next time
    what i meant was that the code (posted above) is supposed to be sending the variables to the file named TextToFile, however my error reads
    unreported exception java.lang.Exception;must be caught or declared to be thrown
    is there any other way to send multiple string variables to a file?

  • FileName using Variable Substitution Method

    Hi SAP experts,
    I need some advise regarding this.
    I have here sample structure of message,
    DT_Root  --> root node
      Tree  --> occurence is 1 to unbounded
        SubTree1
        SubTree2
        SubTree3
    What will be my File Content Conversion parameters to be set in Variable Substitution Method in order for me to get the value of SubTree3 and make it as my filename?
    Also, the value of SubTree3 must not be present on my actual payload..
    var1:payload,1,SLI,1   ---?? what if it is unbounded?
    Kindly advise.
    Thank you very much.

    Hi Raj,
    I cannot open the link.
    Anyway, is it ok if you will advise me regarding my question a while ago?
    I have here sample message structure,
    CSV --> Message Type
    SLI  --> 1 .. unbounded (occurence)
      subSLI1
      subSLI2
      subSLI3
    FileNode --> 1..1 (occurence)
      FileName --> 1..1
    Here's my parameters in Variable Substituion method,
    FileName Scheme: %var1%.csv
    var1   --  payload:CSV,1,FileNode,1,FileName,1
    File Content Conversion Parameters:
    Recordset Structure: SLI,FileNode
    SLI.addHeaderLine: 3
    SLI.headerLine: PERIO;EAN;ILN,....
    SLI.fieldFixedLengths: 8;10;13;...
    SLI.fixedLengthTooShortHandling: Cut
    SLI.fieldSeparator: ;
    SLI.endSeparator: 'nl'
    FileNode.fieldFixedLengths: 0
    FileNode.fixedLengthTooShortHandling: Cut
    I must the output flatfile with a value of the filename in the FileName field.
    And the content of the flatfile must look like this,'
    PERIO;EAN;ILN;SALES;TURNO;PERFL;SUBSFL;SALUN;%CURRENCY%;STOCK;STOUN;ARTNR;ARKTX
    20071020;737052020198 ;4333342000008;         1;        9.95;W;X;ST ;EUR;0000000000;ST ;                                  
    20071020;737052056852 ;4333342000008;         1;       14.50;W;X;ST ;EUR;0000000000;ST ;                                  
    20071020;737052073552 ;4333342000008;         1;       12.95;W;X;ST ;EUR;0000000000;ST ;                                  
    *each field has a fixed field length.
    Kindly advise if my set parameters are correct.
    Thank you very much!

  • Variable Substitution Method

    Hi,
    When Im going through the variable substitution method with respect to the target directory:
    with the help of the blog
    An interesting usage of Variable Substitution in XI
    I dint understand what is the SID here. SID of different systems like DEV system, PRD system and etc. What exactly is an SID?
    If we take SID as a variable in the variable substitution method, then the value to VAR will be getting from the header i.e, Receiver_Service.
    From where does the Receiver_Service gets the SID? whenever the system is changed from DEV to PRD or to someother.
    Kindly let me know if i can get any such other blogs on this scenario.
    Thanks in Advance,
    Divya

    Hi ,
    As said above Message header contains the following informations
    sender_party
    sender_service
    receiver_party
    receiver_service
    interface_name
    interface_namespace
    message_id
    message_id_hex
    SID stands for System ID and is a three character unique name for a SAP system. It will be different for different systems like for Dev system it may be XXX and for quality system say YYY and similarly for production system say ZZZ. Message header values are accessed dynamically.
    Thanks!

  • Transportaion probled for Variable Substitutiom Method

    hi all,.
    we have done variable substitution method in DEV, but it not reflecting in QA.
    also tell me wht r the things we need to change manually after importing the object into INT and QA?
    regards
    sreeni

    Hi Chirag,
    Tank you very much.
    we are using CMS for this transportations in XI.
    I have created one CC as RCVR and we have used Message all as FCC.
    Now exported in DEV then it ready to import in CMS. If we import this in CONSODITION TAB of CMS, then it is imported into my QA.
    Now, I open the that Scenario in ID of QA.
    Here My doubt is:
    In CC channel we have give some values manually for  EXAMPLE, Target DIR.
    What abt file name scheme?
    If we use FCC and to get File Name as dynamic form PayLoad Values.
    For that we can use Variable Substitution Method using percenatge simbles.
    And we have to check the check box for Variable Substitution Method Enable.
    After checking the check box, we have to give variable names and values from PayLoad data.
    Ok,
    now my doubt is,
    Whethere we have to change the following manually or not.
    1) Taget Directory
    2) File name scheme
    3) FTP Server Name
    4) User ID (FTP)
    5) Pasword
    6)Check Box (for Variable Substitution Method Enable)
    7)For this Variable Substitution Method, variable names which we used for  FIle Name Scheme and its values   right.
    plz
    revert
    regards
    sreeni

  • Variable naming conventions

    Hi all,
    I come from a mostly JAVA background. Big emphasis in that arena on encapsulation and modularization of code to help facilitate ease of maintenance and reuse...in theory I sometimes struggle with variable naming conventions within my ABAP code because I'm not all together certain there are any. In C or C++ I might use a derivation of Hungarian notation to name varaibles...and in JAVA I might observe certain object oriented rules regarding varaible naming...I find myself using a combination of those two protocols in my ABAP code. Does anyone have any suggestions for how I might name global and lcoal variables within my code?
    regards,
    Mat

    Hi,
    Please check this links perhaps they may help.
    http://help.sap.com/saphelp_nw04/helpdata/en/92/c2b084bc1d11d2958700a0c94260a5/content.htm
    https://websmp101.sap-ag.de/~sapdownload/011000358700004455192006E/NameConventions.pdf
    http://help.sap.com/saphelp_nw04/helpdata/en/2a/6b0b1f547a11d189600000e829fbbd/content.htm
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/011ccf90-0201-0010-92a7-b319adf89b73
    http://web.mit.edu/sapr3/dev/newdevstand.html
    Regards,
    Ferry Lianto

  • Where do you stand on variable naming in your application code?

    Just out of curisoity really, I've worked in a number of places over the years and encountered multiple coding styles.
    Just thought I'd throw it out there and see what your personal preferences are for variable naming??
    I've seen a lot just use v_ for any variable..
    v_name
    v_dateofbirth
    v_ageSome prefix with the scope instead of just v..
    l_localname
    g_globaldateThen some add the datatype..
    lv_localvarchar
    ln_localnumber
    gb_globalbooelanAnd some even use c/java stylee..
    vMyName
    dDateOfBirthp for parameters..
    p_param1or i/o
    i_in_param
    o_out_paramAnd so on...
    Me, I generally just fit in with the 'house style', unless I think it's that bad that it's unusable, but that's been pretty rare.
    You?
    Edited by: smon on Mar 17, 2011 2:21 AM

    smon wrote:
    Just out of curisoity really, I've worked in a number of places over the years and encountered multiple coding styles.
    Just thought I'd throw it out there and see what your personal preferences are for variable naming??
    I've seen a lot just use v_ for any variable..
    v_name
    v_dateofbirth
    v_ageSome prefix with the scope instead of just v..
    l_localname
    g_globaldateThen some add the datatype..
    lv_localvarchar
    ln_localnumber
    gb_globalbooelan
    Yes, I just tend to use "v_" for variables, "p_" for parameters, "c_" for constants, "cur_" for cursors, "pkg_" for packages etc.
    The problem with using e.g. "lv_" for varchars and "ln_" for numbers etc. is that at some point you'll get a requirement change such that something that was stored as a number now needs to be a varchar because the business has changed the "codes" being used and you would end up having to change the variable name throughout the code, or worse still leave the variable name but just change it's datatype and have something that looks inconsistent.
    And some even use c/java stylee..
    vMyName
    dDateOfBirth
    Yuk!
    p for parameters..
    p_param1or i/o
    i_in_param
    o_out_param
    just "p_". Keep it simple.

  • TIP 02: Easy Connect Naming Method in 10g by Joel Pèrez

    Hi OTN Readers!
    Everyday I get connection on Internet and one of the first issues that
    I do is to open the OTN main page to look for any new article or any
    new news about the Oracle Technology. After I open the main page of
    OTN Forums and I check what answers I can write to help some people
    to work with the Oracle Technology and I decided to begin to write some
    threads to help DBAs and Developers to learn the new features of 10g.
    I hope you can take advantage of them which will be published here in
    this forum. For any comment you can write to me directly to : [email protected]
    Please do not replay this thread, if you have any question related to
    this I recommend you to open a new post. Thanks!
    The tip of this thread is: Easy Connect Naming Method
    Joel Pérez
    http://otn.oracle.com/experts

    Let's go to test it removing the BASE1 service of the listener.ora file
    # listener.ora Network Configuration File: C:\oracle\product\10.1.0\db_1\NETWORK\ADMIN\listener.ora
    # Generated by Oracle configuration tools.
    SID_LIST_LISTENER =
      (SID_LIST =
        (SID_DESC =
          (GLOBAL_DBNAME = BASE2)
          (ORACLE_HOME = C:\oracle\product\10.1.0\db_1)
          (SID_NAME = BASE2)
    LISTENER =
      (DESCRIPTION =
        (ADDRESS = (PROTOCOL = TCP)(HOST = oracle10g)(PORT = 1521))
      )and Now, I am going to reload the listener service in order to
    apply the change to the enviroment.
    Microsoft Windows 2000 [Version 5.00.2195]
    (C) Copyright 1985-2000 Microsoft Corp.
    C:\>
    C:\>lsnrctl stop
    LSNRCTL for 32-bit Windows: Version 10.1.0.2.0 - Production on 20-APR-2004 13:20
    :35
    Copyright (c) 1991, 2004, Oracle.  All rights reserved.
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=oracle10g)(PORT=1521)))
    The command completed successfully
    C:\>lsnrctl start
    LSNRCTL for 32-bit Windows: Version 10.1.0.2.0 - Production on 20-APR-2004 13:20
    :39
    Copyright (c) 1991, 2004, Oracle.  All rights reserved.
    Starting tnslsnr: please wait...
    TNSLSNR for 32-bit Windows: Version 10.1.0.2.0 - Production
    System parameter file is C:\oracle\product\10.1.0\db_1\network\admin\listener.or
    a
    Log messages written to C:\oracle\product\10.1.0\db_1\network\log\listener.log
    Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1521)))
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=oracle10g)(PORT=1521)))
    STATUS of the LISTENER
    Alias                     LISTENER
    Version                   TNSLSNR for 32-bit Windows: Version 10.1.0.2.0 - Produ
    ction
    Start Date                20-APR-2004 13:20:41
    Uptime                    0 days 0 hr. 0 min. 2 sec
    Trace Level               off
    Security                  ON: Local OS Authentication
    SNMP                      OFF
    Listener Parameter File   C:\oracle\product\10.1.0\db_1\network\admin\listener.o
    ra
    Listener Log File         C:\oracle\product\10.1.0\db_1\network\log\listener.log
    Listening Endpoints Summary...
      (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1521)))
    Services Summary...
    Service "BASE2" has 1 instance(s).
      Instance "BASE2", status UNKNOWN, has 1 handler(s) for this service...
    The command completed successfully
    C:\>Joel Pérez
    http://otn.oracle.com/experts

  • Order of execution of named method user properties and server script

    Dear All,
    If for a Custom method on an applet, we have scripts in WebApplet_preinvokemethod and WebApplet_invokemethod and also for the same Custom method we have applet Named Method user properties and BC Named Method user properties, what will be the order of execution of these scripts and Named Method user properties??

    The Private Event Submission sample portlet shows how to achieve this. It is part of the PDK download.
    Peter

  • How to call a variable named "PI"

    I have a typedef that contains a variable named "PI" like the constant 3.1416... but it's an acronym for "Program Information".... I can't rename it since it's a corporate typedef...
    If I need to call it from an expression, TestStand takes it as the constant, but returns a syntax error due to variable notation... example "Step.Result.PI"
    Is there a way to call it?
    Thanks
    Jim
    Solved!
    Go to Solution.

    Hi,
    This type def called PI, you dont say what is made of, lets say its just a string containing information about your program. To use it you would insert it as a Local, FileGlobal, Parameter or StationGlobal in your Sequence/SequenceFile/Station Globals.
    eg Insert into Locals of MainSequence, Locals.my_pi (this is avariable of type PI) and you would enter some inital value.
    How this helps
    Regards
    Ray Farmer
    Regards
    Ray Farmer

  • Multiple Data Source (for FAILOVER) in Easy Connect Naming method

    Hi All,
    I was wondering if there is a way to specify multiple addresses as part of data source property in the connection string when trying to connect to Oracle with Easy Connect Naming method? this is basically for failover scenario.
    I know its straight forward, if i use Connect Descriptor. But not sure how to do it with EZConnect
    For ex. this is what I want to achieve with EZConnect
    sales.us.example.com=
    (DESCRIPTION=
    (ADDRESS_LIST=
    (LOAD_BALANCE=off)
    (FAILOVER=ON)
    *(ADDRESS=(PROTOCOL=tcp)(HOST=sales1-server)(PORT=1521))*
    *(ADDRESS=(PROTOCOL=tcp)(HOST=sales2-server)(PORT=1521)))*
    (CONNECT_DATA=(SERVICE_NAME=sales.us.example.com)))
    I appreciate your suggestions...
    Thanks

    You might get better answers in one of the DB forums from a generic fail-over perspective as EZconnect isn't specific to ODP.NET.
    I don't know if there's a way to do it or not with EZConnect version of the connect string, but you can certainly provide the fully qualified connect string without using tnsnames.ora..
    constring = "data source=(DESCRIPTION=(ADDRESS_LIST=(LOAD_BALANCE=off)(FAILOVER=ON)(ADDRESS=(PROTOCOL=tcp)(HOST=sales1-server)(PORT=1521))(ADDRESS=(PROTOCOL=tcp)(HOST=sales2-server)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=sales.us.example.com))); user id=scott;password=tiger"
    Hope it helps,
    Gres

  • NET8의 LOCAL NAMING METHODS 이용관련 CHECK POINTS & TROUBLESHOOTING

    제품 : SQL*NET
    작성날짜 : 2000-12-15
    ===================================================================
    Net8의 Local Naming Methods 이용관련 Check Points & Troubleshooting
    ====================================================================
    Net8 관련 내용중 Local Naming Methods(sqlnet.ora와 tnsnames.ora
    를 이용해서 DB에 Connect하는 방법)에 관한 일반적인 Check Points 및
    Troubleshooing 사항을 정리해보도록 하겠다.
    [Client Connection : Local Naming Methods]
    1. Local Naming method resolves service names by using the local configuration files tnsnames.ora and sqlnet.ora.
    2. One of the benefits of the Local Naming method is that it provides a simple method for resolving service name addresses. It is easy to configure local naming by using a GUI called the Net8 Assistant. When you configure a client machine for local naming by using the Net8 Assistant, a tnsnames.ora file is generated. To configure all the other client machines on the network that need to use the same database services, you can simply copy this file to the client machines.
    3. Another benefit of using the local-naming method is that it resolves service name across networks running different protocols.
    [Local Naming : Configuration]
    1. The local-naming method resolves service names by using the information configured and stored on each individual client. Local naming is most appropriate for simple distributed networks with a small number of services that change infrequently.
    2. Local naming requires the configuration of two local files, tnsnames.ora and sqlnet.ora. The tnsnames.ora file contains the address needed to direct a connection request to the specified listener on the specified node by using the specified database. The sqlnet.ora file stores information about the selected naming method.
    3. Local naming is easy to configure by using the Net8 Assistant. The Net8 Assistant is implemented in Java and is packed with the Java Runtime Environment. You can run the Net8 Assistant on any platform on which Net8 is installed.
    4. When you configure an Oracle8 server to use the local-naming method for service names resolution, the client-side configuration files tnsnames.ora and sqlnet.ora are automatically generated. After the configuration is complete, you copy these two files from the server to the client machines.
    [Client Files : Parameters]
    1. The tnsnames.ora and sqlnet.ora files are generated at the default location ORACLE_HOME\net80\admin.
    2. The first parameter in the tnsnames.ora file specifies the service name and the domain name for the client.
    3. The tnsnames.ora file contains a parameter called DESCRIPTION. This parameter contains information about the connect descriptor for the client.
    4. The ADDRESS parameter in the tnsnames.ora file specifies the network address of the host to which the client is connected. If multiple addresses are specified, use the keyword ADDRESS_LIST before the ADDRESS parameter.
    5. Another parameter in the tnsnames.ora file is the CONNECT_DATA parameter. This parameter specifies the SID of the database to which the client is connected.
    6. The DEFAULT_DOMAIN parameter of the sqlnet.ora file specifies the domain from which the client most often requests names. When this parameter is set, the domain name is automatically appended to the service name in a connect string.
    7. The DIRECTORY_PATH parameter is another key parameter of the sqlnet.ora file. This parameter specifies the names resolution method to be used for the client-server connection.
    8. The sqlnet.ora file also contains a parameter called DEFAULT_ZONE.
    This parameter specifies the region to which the client belongs.
    [Troubleshooting the Client Side]
    These are common client-side problems and the error messages associated with
    each error code.
    ORA-12154: "TNS: could not resolve service name"
    ORA-12198: "TNS: could not find path to destination"
    ORA-12203: "TNS: unable to connect to destination"
    ORA-12533: "TNS: illegal ADDRESS parameters"
    1. The ORA-12154 error occurs when Net8 cannot locate the connect descriptor specified in the tnsnames.ora configuration file. To solve this problem, first verify that a tnsnames.ora file exists and is accessible. Next, verify that multiple copies of the tnsnames.ora file are not present. After checking the existence of the tnsnames.ora file, verify that the service name specified in the connect string is mapped to a connect descriptor in the tnsnames.ora file. Verify also that the file does not contain any syntaz errors. The ORA-12154 error also occur if there is more than one copy of the sqlnet.ora file. Verify that duplicate copies of the sqlnet.ora file are not present.
    2. The ORA-12198 and ORA-12203 errors occur when the client is unable to find the required database. To solve this problem, first verify that you have correctly entered the service name that you want to use. Next verify that the service name parameters in the ADDRESS section of the connect descriptor in the tnsnames.ora file are correctly defined. Then, verify that the tnsnames.ora file is stored in the correct directory. The ORA-12198 and ORA-12203 errors can also occur if the listener on the remote node is not running. Verify that the listener on the remote node has started and is running. If the listener is not running, start the listener by using the Listener Control(LSNRCTL) utility.
    3. The ORA-12533 error occurs if the protocol-specific parameters in the ADDRESS section of the designated connect descriptor in the tnsnames.ora file are incorrect. To solve this problem, use the correct protocol-specific parameters in the ADDRESS section of the connect descriptor.
    4. The ORA-12545 error occurs when the listener on the remote node cannot be contacted. This may happen if the values of the ADDRESS parameter in the tnsnames.ora file and the listener.ora file are incorrect. In this case replace the incorrect values with the correct values in both the files. The ORA-12545 error can also occur if the listener on the remote node is not
    started. To verify whether or not the listener is started, determine its status with the STATUS command of the LSNRCTL utility. If necessary, start the listener on the remote node with the START command.

    제품 : SQL*NET
    작성날짜 : 2000-12-15
    ===================================================================
    Net8의 Local Naming Methods 이용관련 Check Points & Troubleshooting
    ====================================================================
    Net8 관련 내용중 Local Naming Methods(sqlnet.ora와 tnsnames.ora
    를 이용해서 DB에 Connect하는 방법)에 관한 일반적인 Check Points 및
    Troubleshooing 사항을 정리해보도록 하겠다.
    [Client Connection : Local Naming Methods]
    1. Local Naming method resolves service names by using the local configuration files tnsnames.ora and sqlnet.ora.
    2. One of the benefits of the Local Naming method is that it provides a simple method for resolving service name addresses. It is easy to configure local naming by using a GUI called the Net8 Assistant. When you configure a client machine for local naming by using the Net8 Assistant, a tnsnames.ora file is generated. To configure all the other client machines on the network that need to use the same database services, you can simply copy this file to the client machines.
    3. Another benefit of using the local-naming method is that it resolves service name across networks running different protocols.
    [Local Naming : Configuration]
    1. The local-naming method resolves service names by using the information configured and stored on each individual client. Local naming is most appropriate for simple distributed networks with a small number of services that change infrequently.
    2. Local naming requires the configuration of two local files, tnsnames.ora and sqlnet.ora. The tnsnames.ora file contains the address needed to direct a connection request to the specified listener on the specified node by using the specified database. The sqlnet.ora file stores information about the selected naming method.
    3. Local naming is easy to configure by using the Net8 Assistant. The Net8 Assistant is implemented in Java and is packed with the Java Runtime Environment. You can run the Net8 Assistant on any platform on which Net8 is installed.
    4. When you configure an Oracle8 server to use the local-naming method for service names resolution, the client-side configuration files tnsnames.ora and sqlnet.ora are automatically generated. After the configuration is complete, you copy these two files from the server to the client machines.
    [Client Files : Parameters]
    1. The tnsnames.ora and sqlnet.ora files are generated at the default location ORACLE_HOME\net80\admin.
    2. The first parameter in the tnsnames.ora file specifies the service name and the domain name for the client.
    3. The tnsnames.ora file contains a parameter called DESCRIPTION. This parameter contains information about the connect descriptor for the client.
    4. The ADDRESS parameter in the tnsnames.ora file specifies the network address of the host to which the client is connected. If multiple addresses are specified, use the keyword ADDRESS_LIST before the ADDRESS parameter.
    5. Another parameter in the tnsnames.ora file is the CONNECT_DATA parameter. This parameter specifies the SID of the database to which the client is connected.
    6. The DEFAULT_DOMAIN parameter of the sqlnet.ora file specifies the domain from which the client most often requests names. When this parameter is set, the domain name is automatically appended to the service name in a connect string.
    7. The DIRECTORY_PATH parameter is another key parameter of the sqlnet.ora file. This parameter specifies the names resolution method to be used for the client-server connection.
    8. The sqlnet.ora file also contains a parameter called DEFAULT_ZONE.
    This parameter specifies the region to which the client belongs.
    [Troubleshooting the Client Side]
    These are common client-side problems and the error messages associated with
    each error code.
    ORA-12154: "TNS: could not resolve service name"
    ORA-12198: "TNS: could not find path to destination"
    ORA-12203: "TNS: unable to connect to destination"
    ORA-12533: "TNS: illegal ADDRESS parameters"
    1. The ORA-12154 error occurs when Net8 cannot locate the connect descriptor specified in the tnsnames.ora configuration file. To solve this problem, first verify that a tnsnames.ora file exists and is accessible. Next, verify that multiple copies of the tnsnames.ora file are not present. After checking the existence of the tnsnames.ora file, verify that the service name specified in the connect string is mapped to a connect descriptor in the tnsnames.ora file. Verify also that the file does not contain any syntaz errors. The ORA-12154 error also occur if there is more than one copy of the sqlnet.ora file. Verify that duplicate copies of the sqlnet.ora file are not present.
    2. The ORA-12198 and ORA-12203 errors occur when the client is unable to find the required database. To solve this problem, first verify that you have correctly entered the service name that you want to use. Next verify that the service name parameters in the ADDRESS section of the connect descriptor in the tnsnames.ora file are correctly defined. Then, verify that the tnsnames.ora file is stored in the correct directory. The ORA-12198 and ORA-12203 errors can also occur if the listener on the remote node is not running. Verify that the listener on the remote node has started and is running. If the listener is not running, start the listener by using the Listener Control(LSNRCTL) utility.
    3. The ORA-12533 error occurs if the protocol-specific parameters in the ADDRESS section of the designated connect descriptor in the tnsnames.ora file are incorrect. To solve this problem, use the correct protocol-specific parameters in the ADDRESS section of the connect descriptor.
    4. The ORA-12545 error occurs when the listener on the remote node cannot be contacted. This may happen if the values of the ADDRESS parameter in the tnsnames.ora file and the listener.ora file are incorrect. In this case replace the incorrect values with the correct values in both the files. The ORA-12545 error can also occur if the listener on the remote node is not
    started. To verify whether or not the listener is started, determine its status with the STATUS command of the LSNRCTL utility. If necessary, start the listener on the remote node with the START command.

  • Reflective invoke of variable-argument method?

    I'm having trouble reflectively invoking a variable-argument method. Can anyone provide a code snippet that does it? Here's my test, with the output below:
    package comet.pod;
    import java.lang.reflect.Method;
    public class Test
       public void doSomething (Object... args)
          System.out.println ("hello world");
       public void test()
          Method method = null;
          try
             Class<?> c = Test.class;
             Class[] argTypes = new Class[] { Object[].class };
             method = c.getMethod ("doSomething", argTypes);
             System.out.println ("is VarArgs? " + method.isVarArgs());
          catch (Exception x) { System.err.println (x); }
          try
             method.invoke (this, (Object[]) null);
          catch (Exception x) { System.err.println (x); }
          try
             method.invoke (this, new Object());
          catch (Exception x) { System.err.println (x); }
          try
             method.invoke (this, new Object[] { "arg" });
          catch (Exception x) { System.err.println (x); }
       public static void main (final String[] args)
          new Test().test();
    }is VarArgs? true
    java.lang.IllegalArgumentException: wrong number of arguments
    java.lang.IllegalArgumentException: argument type mismatch
    java.lang.IllegalArgumentException: argument type mismatch

    You need something like:
    method.invoke(this, new Object[] { new Object[] { "arg1", "arg2" } });To see why, consider what you would do if your method was:
    public void doSomething (Object a1, Object a2, Object... aVar)Alex

Maybe you are looking for

  • VOICE MEMOS R GONE HELPPP

    Hi, i recently restarted my ipod by mistake and everything got deleted however i had alreaedy saved all the pics before this. problem is that all my voice memos r gone and i never made a backup file earlier. what do i do???????????i need 2 recover th

  • I don't want to write too much code is there a different way of doing this

    I am writing a precedure to check on the max test scores for different codes ('S01','S02'.S03') --there are more then I need to insert the table if the record with the best score does not exists for example for b.sortest_tesc_code = 'BSV', I am writi

  • How do I edit a converted pdf into word document?

    i just converted a pdf to word and would like to edit it. How?

  • Sharing Violation in DreamWeaver CS6

    Hi there, I am experiencing a 'sharing violation' message in Dreamweaver CS6 when using a web development tool - Mixture. http://www.mixture.io Basically, when i try to save files in dreamweaver, whilst mixture is running, I get a message saying: I c

  • Activation server problem after installing IOS5

    I have a very specific problem: Last year in July 2010 my brother died, I got from his legacy his Iphone which was sold by T-Mobile. I requested T mobile to unlock (SIM) as I had a subscription of of KPN. Untill then everything worked okey. In Septem