Gossamer Forum
Home : Products : Gossamer Forum : Discussion :

How to update User table with an external global?

Quote Reply
How to update User table with an external global?
Hi,

I try to update the GForum User table throw a global in Links SQL. Here the global I try to use in Links SQL:

Code:

sub {
my $vars = shift;
my $user_id = $vars->{user_id};
use lib '/path/to/GForum/admin';
my $tu = GT::SQL->new ("/path/to/GForum/admin/defs");
$tu->table('User')->update( { user_something => '1' }, { user_id => $user_id } );
}


When I try the global, I receive this error:

Code:

Can't call method "table" on an undefined value at /path/to/GForum/admin/GForum/Table/User.pm line 360.


The global works with the Post or Forum table, but not with the User table. It's probably a permission problem, but I don't know how to solve it.

Thank you very much for your help!

François

Last edited by:

Franco: May 19, 2004, 7:48 AM
Subject Author Views Date
Thread How to update User table with an external global? Franco 4619 May 19, 2004, 7:40 AM
Thread Re: [Franco] How to update User table with an external global?
Jagerman 4449 May 19, 2004, 12:45 PM
Thread Re: [Jagerman] How to update User table with an external global?
carfac 4408 May 21, 2004, 11:40 AM
Post Re: [carfac] How to update User table with an external global?
carfac 4403 May 21, 2004, 12:22 PM
Post Re: [carfac] How to update User table with an external global?
carfac 4398 May 21, 2004, 12:35 PM
Post Re: [Jagerman] How to update User table with an external global?
Franco 4412 May 21, 2004, 12:56 PM