Gossamer Forum
Home : Products : DBMan : Customization :

Re: [Helpdesk] Append to 2nd DB using info from add form [update]

Quote Reply
Re: [Helpdesk] Append to 2nd DB using info from add form [update] In reply to
I'll give you an example of something I use and perhaps this will provide a solution. This is from a classifieds system which has 7 databases. When I view a User from the user databasewant I use the following to display all the ads within the other 6 databases. This is just an example of one.

print qq|
<table width=450><TR><TD><$font><B>Current Classifieds:</B></font></TD></TR>|;

&switch_to_announce;
undef %in;
$in{'UserID'} = $rec{'UserID'};
$in{'mh'} = 50;

my ($status2,@hits2) = &query("view");
if ($status2 eq "ok") {
my ($numhits2) = ($#hits2+1) / ($#db_cols+1);

for (0 .. $numhits2 - 1) {
%rec2 = &array_to_hash($_, @hits2);
print qq| <TR><TD><$font><A HREF="$db_script_url?db=announce&uid=$db_uid&ItemID=$rec2{'ItemID'}&view_records=1">$rec2{'ItemID'}</A> - $rec2{'Category'} - $rec2{'Title'}</font>&nbsp;</td></tr> |;
}
}

print qq|</table></CENTER><P>|;

Something like this would provide the display you are looking for without having to store the ID numbers and then make links. The above provides links automatically.

Hope this helps

Unoffical DBMan FAQ

http://creativecomputingweb.com/dbman/index.shtml/
Subject Author Views Date
Thread Append to 2nd DB using info from add form Helpdesk 3218 Jun 29, 2002, 10:54 PM
Thread Append to 2nd DB using info from add form [update]
Helpdesk 3097 Jul 4, 2002, 12:56 PM
Thread Re: [Helpdesk] Append to 2nd DB using info from add form [update]
LoisC 3104 Jul 4, 2002, 1:06 PM
Thread Re: [LoisC] Append to 2nd DB using info from add form [update]
Helpdesk 3091 Jul 4, 2002, 1:15 PM
Thread Re: [Helpdesk] Append to 2nd DB using info from add form [update]
LoisC 3100 Jul 4, 2002, 7:08 PM
Thread Re: [LoisC] Append to 2nd DB using info from add form [update]
Helpdesk 3101 Jul 4, 2002, 7:45 PM
Thread Re: Append to 2nd DB using info from add form [update]
Helpdesk 3073 Jul 8, 2002, 7:47 AM
Post Append to 2nd DB using info from add form [update]
Helpdesk 3048 Jul 22, 2002, 6:10 PM