Gossamer Forum
Home : Products : Gossamer Links : Version 1.x :

Re: Links v1.11 --> Problem with Multiple Databases

Quote Reply
Re: Links v1.11 --> Problem with Multiple Databases In reply to
Ok:

First, I'm running multiple databases. My postcards database is separate from the Links database (the sent-cards vs the cards-to-send) and on two sites, the postcards database is not even in the same "Database". I have 3 different databases running through DBSQL.pm on one site, and I've never had a confusion problem.

Two problems I've had, is that DBSQL.pm sometimes assumes that all fields are going to be there, and the log is filled with useless warnings about "uninitialized value used in Match" or "uninitialed value used in interator" etc. Doesn't seem to stop execution, but I was able to get rid of them by adding in some ugly hacks (initializing all fields in a passed hash) and/or first testing to see if the value exists.

my $id = $db->add_record (&cgi_to_hash($in), $in);

What seems to be happening, is something I hit way back in the first versions, where the ID field is not properly set.

Most likely, there is no field "ID" so that it can't be passed.

If you broke this down into:

$in = &cgi_to_hash($in);
$in->{'ID'} = '';

So that the field ID actually existed, but had a null value?

Or, delete $in->{'ID'}, so that it didn't exist at all.

I'm not sure which would work.

BTW.... this may be silly, but column Year.ID is autoincrement? and your Year.def file is up to date?



PUGDOGŪ
PUGDOGŪ Enterprises, Inc.
FAQ: http://postcards.com/FAQ


Subject Author Views Date
Thread Links v1.11 --> Problem with Multiple Databases Stealth 3448 Oct 27, 2000, 3:07 PM
Thread Re: Links v1.11 --> Problem with Multiple Databases
pugdog 3365 Oct 27, 2000, 6:20 PM
Thread Re: Links v1.11 --> Problem with Multiple Databases
Stealth 3362 Oct 27, 2000, 9:39 PM
Thread Re: Links v1.11 --> Problem with Multiple Databases
pugdog 3365 Oct 27, 2000, 9:51 PM
Post Re: Links v1.11 --> Problem with Multiple Databases
Stealth 3354 Oct 27, 2000, 9:54 PM
Thread Re: Links v1.11 --> Problem with Multiple Databases
Stealth 3330 Oct 28, 2000, 10:41 PM
Post Re: Links v1.11 --> Problem with Multiple Databases
pugdog 3338 Oct 28, 2000, 11:01 PM