Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Coding Conventions
Try at http://anzus-technology.com
there are some standards you can try at this site. You might not like all of
their suggestions but they are a good starting point.
Regards
--
Kevin A Lewis (BOCM PAULS LTD) - Animal Feed Manufacturer - Ipswich United
Kingdom)
<Kevin_A_Lewis_at_Hotmail.com>
The views expressed herein by the author of this document
are not necessarily those of BOCM PAULS Ltd.
<markp7832_at_my-deja.com> wrote in message news:86nst9$1vt$1_at_nnrp1.deja.com...
> In article <86nga3$nv8$1_at_nnrp1.deja.com>,
> mshabrawi_at_excite.com wrote:
> > Hello,
> > Is there a white paper that describes PL/SQL coding conventions ?
> > Thanks
> > Mohamed EL-Shabrawi
> >
> I do not know about a white paper but may I recommend:
>
> start every scalar variable with a v_
> start every cursor with c_
> define rowtype as r_
> define pl/sql tables as t_
>
> Whenever a scalar variable will hold data that originates in, or will
> be inserted or updated into a table define it using the table.column%
> type format or as references to a previously created scalar variable
> defined as table.column%type.
>
> For counters use the pls_integer type for speed.
>
> Code only in lowercase. There is no need to capitalize language
> statements. (I find it easier to concentrate on the logic when the
> statements keywords are not jumping out at me)
>
> Use procedures/functions in anonymous blocks to modularize the code
>
> Use line comments, -- to isolate sections of code that you want to draw
> attention to such as end of large if's, end of loops, end of procedures
> and functions etc...
>
> Do not over-indent.
> --
> Mark D. Powell -- The only advice that counts is the advice that
> you follow so follow your own advice --
>
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
Received on Thu Jan 27 2000 - 04:17:34 CST
![]() |
![]() |