[Dbix-class] Select from subselect

Allan Cochrane allan.cochrane at gmail.com
Fri Dec 16 04:32:42 GMT 2011


On Thu, Dec 15, 2011 at 5:22 PM, Drew Taylor <drew at drewtaylor.com> wrote:


> I think
> https://metacpan.org/module/DBIx::Class::Manual::Cookbook#Subqueries
> will be helpful to you.
>
> Drew
>
>
Hi,

thanks, the link you gave me doesn't show the generated SQL so it's hard to
tell if it does what I want! :-) I find no examples in the documentation of
using a subquery in the 'from' attribute. There is an example of that usage
in the tests, which is what I ended up referring to and I managed to get
the SQL to look something like SELECT ... FROM (SELECT ..) JOIN ... ON xxx
but I still cannot see how to make more than one join condition for xxx.
The package test code assumes a relationship between two tables, which is
not the case here ...

Thanks

Allan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/dbix-class/attachments/20111215/a7f=
54557/attachment.htm


More information about the DBIx-Class mailing list