Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: trigger naming convention

Re: trigger naming convention

From: Marcus Claus <marcus.claus_at_brainpool.se>
Date: 1997/06/06
Message-ID: <339849D5.1D0D@brainpool.se>#1/1

Limin Guo wrote:
>
> Looks like a simple quesition. Would someone tell me what kind of
> naming convention for triggers, packages and procdures would be
> more meaningful and readable. Currently I am using trigger name's
> like:
>
> tablename_1_trg
>
> if I have more than one trigger on one table, I will use the number
> to replace 1 in the trigger name.
>
> Any reply would be highly appreciated.

Well, my team use the following form of trigger names:

tablename_tTO_trg_N

N=1,...n when multiple triggers

T = A)fter , B)efore
O = I)insert, U)update, D)elete

example

foobar_tbi_1   - trig before insert
foobar_tbd_1   - trig before delete
foobar_tau_1   - trig after update

and so on

When it comes to packages and proc/funcs, things are not so clear. Differenr programmers tend to have their own favorite format. I use the 'verb'+'object' format such as 'updateEmpolyee' or 'createEmpWebForm' and so on. Packages as we always use to hide procs/funcs in are most commonly refelecting a systems' different functional layers such as data manipulation layer, business logic layer, business object layer, web interface layer (creates web interfaces to the layers below as well as collect data from web clients, decodes it and so on, i.e. sits between the traditional core system shared between all client types, and the special thin clients such as web browsers. Packages tend to have names of the form

application_subsystem
or
application_layer

ex

foosystem_monthlybatches   (functional subsystem, dml only)
foosystem_employee	   (business object interface)
foosystem_webEmployee      (web interface for previous object layer)

and so on Received on Fri Jun 06 1997 - 00:00:00 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US