Subject Re: [firebird-support] Stored Procedures Left Outer Join
Author Diego Rodriguez
I still think I can not use triggers, because the stored procedures (and the
reports) use parameters (date and segment) and I had to make a lot of
partial counts, because the report can have a lot of different parameters,
and it will not be very easy to maintain if the reports change (and I think
they will change)

I suppose I can run every SP alone and then join the results outside
firebird, but I would prefer to do it inside firebird. Any suggestions?

Diego

----- Original Message -----
From: "Alan McDonald" <alan@...>
To: <firebird-support@yahoogroups.com>
Sent: Friday, September 30, 2005 1:44 PM
Subject: RE: [firebird-support] Stored Procedures Left Outer Join


>> The complete process of my app is a weekly huge insert from a file, using
>> external files, and inmediatly after generate a report for the data
>> reciently inserted (the table has a date field). Not intermediate
>> deletes or
>> updates. Also weekly, I delete records older than 90 days, preventing the
>> table from growing indefinitely. The counts are also grouped on data that
>> has been reciently inserted, so I don't think the auxiliar table is a
>> solution.
>>
>> You say "definitely not using joined SPs anyway"
>>
>> why?
>
> because they will often need to be fully evaluated for each record on the
> left side of the join - very heavy - check the plan to see if this is the
> case.
>
>>
>> I tried to use also views, but I needed to pass parameters to the
>> query, and
>> I read in this list selectable stored procedures are like views
>> and you can
>> pass parameters to the query
>>
>> Diego
>
> true, but the processing is too costly. Your bulk inserts can still use
> the
> triggered approach but it depends which processing you can tolerate the
> most. The triggered approach will cause lengthy insert times, but the
> group
> retrieval will be ligthning fast.
> Alan
>
>
>
>
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> Visit http://firebird.sourceforge.net and click the Resources item
> on the main (top) menu. Try Knowledgebase and FAQ links !
>
> Also search the knowledgebases at http://www.ibphoenix.com
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> Yahoo! Groups Links
>
>
>
>
>
>
>
>
>
>