On Feb 14, 2007, at 12:21 PM, A. Pagaltzis wrote:
Hi Ian,
* Ian Docherty <[EMAIL PROTECTED]> [2007-02-14 16:40]:
A. Pagaltzis wrote:
* Will Smith <[EMAIL PROTECTED]> [2007-02-12 21:25]:
my $column = $c->model("myDB::Author")->get_column('last_name');
while(my $name = $column->next){
$lname[$i] = $name;
$i = $i + 1;
}
Ugh. Use `push`; this isn’t C.
Or 'map'
That won’t work here, since there’s no list to process, just an
iterator. (I always thought List::Util should supply `unfold`…)
Of course map, push, and everything else is kind of pointless anyway...
my @name = $c->model( 'myDB::Author' )->get_column( 'last_name' )->all;
--
Jason Kohles
[EMAIL PROTECTED]
http://www.jasonkohles.com/
"A witty saying proves nothing." -- Voltaire
_______________________________________________
List: [email protected]
Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/[email protected]/
Dev site: http://dev.catalyst.perl.org/