Results 1 to 3 of 3
  1. #1
    Join Date
    Jan 2004

    Unanswered: Oracle Naming Conventions

    We currently have DB2 Naming Convention, but we're looking for the Oracle Naming Conventions. Can someone suggest a list of conventions?

    Thank you.

  2. #2
    Join Date
    Aug 2003
    Where the Surf Meets the Turf @Del Mar, CA
    Provided Answers: 1
    There are none.
    Use the same as you use for DB2.
    It will be less confusing .

  3. #3
    Join Date
    Sep 2003
    Milan, Italy
    Avoid putting the "$" symbol in the table, columns, views, procedure etc names; dollars are "reserved" by convention to Oracle provided objects (since Oracle is expensive, i believe ;-) )

    There is just a loose convention for pl/sql objects, which i've noticed it's quite followed but not everywhere. The convention is to have parameters prefixed by p_, local variables by l_, such as

    create or replace procedure p (p_customer_type in number)
    l_cus_count number;
    select count(*)
    into l_cus_count
    from customer
    where customer_type = p_customer_type;
    end p;

    the main aim of this "convention" is to avoid clashing table names with parameters/local variables ones - and to distinguish at first sight which is a column/table name and which is a parameter/local variable, quite useful in long sql statements especially involving joins.

    Anyway, most important thing is to have a convention, followed across the company/application; which one is not very important, as anacedent pointed out.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts