[Dbix-class] strange SQL generated

Alan Humphrey alan.humphrey at comcast.net
Fri Feb 17 18:41:48 CET 2006


I've opened a couple of bugs against SQL::Abstract::Limit - the default SQL
generated doesn't handle table aliases.

http://rt.cpan.org/Public/Dist/Display.html?Status=Active&Name=SQL-Abstract-
Limit


-----Original Message-----
From: dbix-class-bounces at lists.rawmode.org
[mailto:dbix-class-bounces at lists.rawmode.org] On Behalf Of Matt S Trout
Sent: Wednesday, February 15, 2006 10:59 AM
To: dbix-class at lists.rawmode.org
Subject: Re: [Dbix-class] strange SQL generated

On Wed, Feb 15, 2006 at 10:34:35AM -0800, Alan Humphrey wrote:
> Looks like this line in ResultSet triggers the bug:
> 
>     $row = $self->search(\@unique_hashes, { rows => 1 })->first;
> 
> If the { rows => 1 } attribute is removed then there's no problem.
> 
> That attribute certainly *looks* superfluous...

For that query, yes. But that's indicative of a potentially larger problem
with limit/offset support on SQL Server. Can you give it a kick around and
see what does and doesn't work please?

-- 
     Matt S Trout       Offering custom development, consultancy and support
  Technical Director    contracts for Catalyst, DBIx::Class and BAST.
Contact
Shadowcat Systems Ltd.  mst (at) shadowcatsystems.co.uk for more information

 + Help us build a better perl ORM:
http://dbix-class.shadowcatsystems.co.uk/ +

_______________________________________________
List: http://lists.rawmode.org/cgi-bin/mailman/listinfo/dbix-class
Wiki: http://dbix-class.shadowcatsystems.co.uk/
IRC: irc.perl.org#dbix-class
SVN: http://dev.catalyst.perl.org/repos/bast/trunk/DBIx-Class/




More information about the Dbix-class mailing list