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 7275 Apr 9, 2003, 8:41 AM
Thread Re: [bf] How to display unrelated files by date?
jai 7164 Apr 9, 2003, 4:18 PM
Thread Re: [jai] How to display unrelated files by date?
bf 7129 Apr 10, 2003, 2:51 PM
Thread Re: [bf] How to display unrelated files by date?
jai 7147 Apr 10, 2003, 4:28 PM
Thread Re: [jai] How to display unrelated files by date?
bf 7143 Apr 10, 2003, 4:46 PM
Thread Re: [bf] How to display unrelated files by date?
charly 7063 May 7, 2003, 4:56 AM
Thread Re: [charly] How to display unrelated files by date?
604 7053 May 7, 2003, 1:24 PM
Thread Re: [TheStone] How to display unrelated files by date?
charly 7051 May 7, 2003, 2:36 PM
Thread Re: [charly] How to display unrelated files by date?
604 7059 May 7, 2003, 2:42 PM
Thread Re: [TheStone] How to display unrelated files by date?
charly 7072 May 7, 2003, 2:55 PM
Thread Re: [charly] How to display unrelated files by date?
604 7043 May 7, 2003, 3:12 PM
Post Re: [TheStone] How to display unrelated files by date?
charly 6947 May 21, 2003, 7:09 AM