Gossamer Forum
Home : General : Databases and SQL :

Help with Perl SQL Statement

Quote Reply
Help with Perl SQL Statement
Hi could someone help out a non-perl programmer with this statement:

I want to set $num_cats = SELECT COUNT(Depth) FROM lsql_Category WHERE Depth=$count;

$count is from my for loop.

Here is what I have so far:

Code:


my ($num_cats) = $DB->table('Category')->select(['COUNT(Depth)'])->fetchrow_array;




Thanks!
Subject Author Views Date
Thread Help with Perl SQL Statement Ian 11898 May 12, 2002, 9:22 PM
Thread Re: [sooke] Help with Perl SQL Statement
Ian 11506 May 12, 2002, 9:50 PM
Thread Re: [sooke] Help with Perl SQL Statement
Paul 11470 May 13, 2002, 1:50 AM
Thread Re: [Paul] Help with Perl SQL Statement
Ian 11485 May 13, 2002, 7:54 AM
Post Re: [sooke] Help with Perl SQL Statement
Stealth 11454 May 13, 2002, 9:09 AM
Thread Re: [sooke] Help with Perl SQL Statement
Alex 11460 May 13, 2002, 9:10 AM
Thread Re: [Alex] Help with Perl SQL Statement
Ian 11560 May 13, 2002, 9:14 AM
Thread Re: [sooke] Help with Perl SQL Statement
Alex 11479 May 13, 2002, 9:23 AM
Post Re: [Alex] Help with Perl SQL Statement
Ian 11431 May 13, 2002, 9:41 AM