Gossamer Forum
Home : Products : DBMan SQL : Discussion :

Re: [jai] Database Field Advice

Quote Reply
Re: [jai] Database Field Advice In reply to
You want a table structure perhaps like a country column and a date column and then the same country can have multiple dates, eg....

England 01/15
England 01/25
England 03/04

I think thats how best to do it. As you say multiple dates in one column is not what you want to be doing.

Depending how the dates are entered, as Jaspercram said, you can just split and insert...eg if commas:

Code:
my @dates = split ',', $IN->param('date_field');
for (@dates) {
$DB->table('Table_Name')->insert({ country_col => $country_name, date => $_ })'
}

Last edited by:

Paul: Jan 21, 2003, 8:45 AM
Subject Author Views Date
Thread Database Field Advice jai 3784 Jan 21, 2003, 3:33 AM
Post Re: [jai] Database Field Advice
jaspercram 3643 Jan 21, 2003, 7:27 AM
Thread Re: [jai] Database Field Advice
Paul 3643 Jan 21, 2003, 8:44 AM
Thread Re: [Paul] Database Field Advice
jai 3618 Jan 24, 2003, 4:09 PM
Thread Re: [jai] Database Field Advice
Paul 3615 Jan 24, 2003, 4:14 PM
Thread Re: [Paul] Database Field Advice
jai 3613 Jan 24, 2003, 5:35 PM
Thread Re: [jai] Database Field Advice
Paul 3628 Jan 24, 2003, 5:46 PM
Post Re: [Paul] Database Field Advice
jai 3585 Jan 26, 2003, 11:15 PM
Post Re: [Paul] Database Field Advice
jai 3576 Jan 28, 2003, 8:59 PM