[ic] Table access problem
Jerry
jerry@digitalfm.com
Thu, 14 Dec 2000 17:45:01 -0500
Maybe someone a little more familiar with the
IC internals could help here? Taking the inventory
thing a bit farther with:
[calc tables="inventory" arg="carts"]
my $item;
foreach my $item ( @{$Safe{'carts'}->{'main'}} )
{
my $in_stock = tag_data('inventory', 'quantity', $item->{code});
next if $in_instock >= $item->{quantity};
$item->{changed_it} = $item->{quantity};
$item->{quantity} = $in_stock;
return;
}
[/calc]
Generates an error:
Safe: Can't locate object method "open_table" via package
"Vend::Table::DBI" at /d01/inter/lib/Vend/Data.pm line 872.
This IC 4.6 with CVS updates from a couple of days ago, linux
and the IC:Bundle installed to perl, using MySql.
Perhaps this needs to be a SQL call of some sort?
replacing: my $in_stock = tag_data('inventory', 'quantity', $item->{code});
with: my $in_stock = 5;
for instance and the rest of it works as it should.
Any help appreciated A LOT
Jerry Uphoff