Re: Hi all

From: Palooka <nobody_at_nowhere.com>
Date: Fri, 21 Aug 2009 20:27:40 +0100
Message-ID: <NyCjm.29274$D91.22850_at_newsfe01.ams2>



On 21/08/09 18:26, pal wrote:
> On Aug 18, 12:17 pm, Tim X<t..._at_nospam.dev.null> wrote:
>> pal<jayadevpal..._at_gmail.com> writes:
>>> Can any one tell me how to declare a temporary table in a trigger(like
>>> in SQL Server)?
>>
>> OMG! Do NOT do it!
>>
>> 1. Avoid triggers unless there is a very good reason and no other
>> solution will work. Triggers can easily get unmanageable and are
>> effectively side effects that can make maintenance and debugging a
>> nightmare (especially if different teams end up doing the maintenance).
>>
>> 2. Creating tables is a DDL (Data Definition Language) statement and
>> therefore causes an implicit commit. This would cause unexpected
>> behavior with transaction management etc (actually, I don't think you
>> can have DDL in triggers for this reason).
>>
>> 3. Maybe consider a temporary global table which is created already and
>> take advantage of its support for transaction independence etc. While
>> its not clear why you want to create a table in a trigger, it is likely
>> that the features of a temporary global table would provide what you are
>> after - though I'm totally guessing of course as we have no details on
>> what your trying to do).
>>
>> Tim
>>
>> --
>> tcross (at) rapttech dot com dot au
>
>
> Thanks for the comments. I am quiet happy to see these comments. I am
> getting some orders for my project which i have developed using SQL
> Server.But some clients need Oracle version. So I am just trying to
> spend some time on Oracle, which is new to me. Once again thanks for
> the advice.
>
>

Copy the business requirements.
Copy the logical design.
Avoid copying or attempting to translate either the physical design or the application coding.

Palooka Received on Fri Aug 21 2009 - 14:27:40 CDT

Original text of this message