Hi, Ian back once again at the SQL table!
This time its for a sub in one of my plugins (no prizes for guessing which one).
my $sth = $lt->select('Title', 'RC_Count', 'RC_IN', 'Hits'); ($title, $rc_count, $rc_in, $hits) = $sth->fetchall_list;
I am trying to get $rank, $title, $rc_count, $rc_in, $hits for each row returned in the decending order and use them as tags in my output as follows:
RC_Rank => $counter,
RC_Count => $rc_count,
RC_IN => $rc_in,
RC_Hits =>$hits
RC_Title => $title
} );
I am wondering if maybe I can do part of this with a hashref:
row: while ($review = $sth->fetchrow_hashref) {
my $title = $row->{Title}; then tie the rest in somehow... have not selected much with hashref before
http://www.iuni.com/...tware/web/index.html
Links Plugins
This time its for a sub in one of my plugins (no prizes for guessing which one).
Code:
$lt->select_options ('ORDER BY RC_Count DESC, RC_IN DESC, Hits DESC', "LIMIT $topx"); my $sth = $lt->select('Title', 'RC_Count', 'RC_IN', 'Hits'); ($title, $rc_count, $rc_in, $hits) = $sth->fetchall_list;
I am trying to get $rank, $title, $rc_count, $rc_in, $hits for each row returned in the decending order and use them as tags in my output as follows:
Code:
$output = Links::SiteHTML::display('rc_rank.html', { RC_Rank => $counter,
RC_Count => $rc_count,
RC_IN => $rc_in,
RC_Hits =>$hits
RC_Title => $title
} );
I am wondering if maybe I can do part of this with a hashref:
row: while ($review = $sth->fetchrow_hashref) {
my $title = $row->{Title}; then tie the rest in somehow... have not selected much with hashref before
http://www.iuni.com/...tware/web/index.html
Links Plugins