Gossamer Forum
Home : Products : DBMan SQL : Discussion :

How to display unrelated files by date?

Quote Reply
How to display unrelated files by date?
Awhile ago TheStone supplied this Global to allow data from unrelated files to be used in templates

sub {
my ($table, $field, $value) = @_;
my $sth = $DB->table($table)->select({ $field => $value });
my @output;
while (my $rs = $sth->fetchrow_hashref ) {
push @output, $rs;
}
return { loop_hash => \@output };
}

It works very well but another requirement has raised it's ugly face and I need to do the same thing but display the items by date, most often the files are not entered in order and this global will just display the output as it finds them in the files.

Or is there another way?

Thanks.....
Subject Author Views Date
Thread How to display unrelated files by date? bf 5553 Apr 9, 2003, 8:41 AM
Thread Re: [bf] How to display unrelated files by date?
jai 5462 Apr 9, 2003, 4:18 PM
Thread Re: [jai] How to display unrelated files by date?
bf 5433 Apr 10, 2003, 2:51 PM
Thread Re: [bf] How to display unrelated files by date?
jai 5449 Apr 10, 2003, 4:28 PM
Thread Re: [jai] How to display unrelated files by date?
bf 5447 Apr 10, 2003, 4:46 PM
Thread Re: [bf] How to display unrelated files by date?
charly 5374 May 7, 2003, 4:56 AM
Thread Re: [charly] How to display unrelated files by date?
604 5364 May 7, 2003, 1:24 PM
Thread Re: [TheStone] How to display unrelated files by date?
charly 5363 May 7, 2003, 2:36 PM
Thread Re: [charly] How to display unrelated files by date?
604 5369 May 7, 2003, 2:42 PM
Thread Re: [TheStone] How to display unrelated files by date?
charly 5383 May 7, 2003, 2:55 PM
Thread Re: [charly] How to display unrelated files by date?
604 5353 May 7, 2003, 3:12 PM
Post Re: [TheStone] How to display unrelated files by date?
charly 5258 May 21, 2003, 7:09 AM