|  Hi All
| 
|  I want something like 'SELECT * FROM employee WHERE department IS NOT NULL'
| 
|  I tried $schema->resultset('employee')->search({ department => {"IS" => "NOT 
|  NULL"}});
| 
|  But it is not working...
| 
|  Any help?
| 

$rs->search( { department => { '!=', undef } } );

or

my $sql = 'IS NOT NULL';
$rs->search( { department => \$sql } )

Read the docs for SQL::Abstract
http://search.cpan.org/~nwiger/SQL-Abstract-1.22/lib/SQL/Abstract.pm

Fernan

_______________________________________________
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/
Searchable Archive: http://www.mail-archive.com/[email protected]/

Reply via email to