Subject | RE: [firebird-support]1.5 bug and work around? |
---|---|
Author | Paul Hope |
Post date | 2008-06-03T08:35:25Z |
Hi Paul
There isnt any joining to do so your first suggestion wont work but I will
use a stored procedure ;-)
Thanks for replying
Regards
Paul
There isnt any joining to do so your first suggestion wont work but I will
use a stored procedure ;-)
Thanks for replying
Regards
Paul
> -----Original Message-----
> From: firebird-support@yahoogroups.com
> [mailto:firebird-support@yahoogroups.com] On Behalf Of Mercea Paul
> Sent: 03 June 2008 07:04
> To: firebird-support@yahoogroups.com
> Subject: RE: [firebird-support]1.5 bug and work around?
>
> Hi
>
>
>
> Maybe is possible to avoid union if you make something like:
>
>
>
> Select a.name, sum(b.qty),0,sum(b.bond)
>
> From otw_products b join product_name a on a.pid=b.pid
>
> Where b.whs=''
>
> Group by 1,2,4
>
>
>
> Or you can use a stored procedure !
>
>
>
> Best regards,
>
> Paul
>
>
>
> From: firebird-support@yahoogroups.com
> [mailto:firebird-support@yahoogroups.com] On Behalf Of Paul Hope
> Sent: 03 June 2008 00:32
> To: firebird-support@yahoogroups.com
> Subject: [firebird-support]1.5 bug and work around?
>
>
>
> Hi
> I have come accross what I assume is a known bug in 1.5
>
> select
> sum(qty),0,sum(bond),pid
> from otw_products where whs='' and pid=:pid group by 2,4
>
> goes crazy - returns infinite number of lines, where as
>
> select
> sum(qty),0,sum(bond)
> from otw_products where whs='' and pid=:pid group by 2
>
> works fine. Variations of putting constants and fields
> between and after the sum()s either work, crash the server or
> return infinite lines.
>
> I need this crazy patern in the select for a union clause to
> match the columns in the other part.
>
> Is there a way round?
>
> Regards
> Paul
>
> [Non-text portions of this message have been removed]
>
>
>
>
>
> [Non-text portions of this message have been removed]
>
>
> ------------------------------------
>
> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>
> Visit http://www.firebirdsql.org 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
>
>
>