Revision 50aca900
Von Sven Schöling vor fast 12 Jahren hinzugefügt
SL/IC.pm | ||
---|---|---|
my ($self, $myconfig, $form) = @_;
|
||
|
||
# connect to db
|
||
my $dbh = $form->dbconnect($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
my $sth;
|
||
|
||
... | ... | |
|
||
$form->{"unit_changeable"} = $form->{orphaned};
|
||
|
||
$dbh->disconnect;
|
||
Common::webdav_folder($form) if $::lx_office_conf{features}{webdav};
|
||
|
||
$main::lxdebug->leave_sub();
|
||
}
|
||
... | ... | |
|
||
my ($self, $myconfig, $form) = @_;
|
||
|
||
my $dbh = $form->dbconnect($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
# get pricegroups
|
||
my $query = qq|SELECT id, pricegroup FROM pricegroup ORDER BY lower(pricegroup)|;
|
||
... | ... | |
#correct rows
|
||
$form->{price_rows} = $i - 1;
|
||
|
||
$dbh->disconnect;
|
||
|
||
$main::lxdebug->leave_sub();
|
||
|
||
return $pricegroups;
|
||
... | ... | |
|
||
my ($query, $sth);
|
||
|
||
my $dbh = $form->dbconnect($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
# get buchungsgruppen
|
||
$query = qq|SELECT id, description FROM buchungsgruppen ORDER BY sortkey|;
|
||
... | ... | |
my ($self, $myconfig, $form) = @_;
|
||
|
||
# connect to database
|
||
my $dbh = $form->dbconnect($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
my $where = qq|NOT p.obsolete|;
|
||
my @values;
|
||
... | ... | |
|
||
$form->{assembly_items} = selectall_hashref_query($form, $dbh, $query, @values);
|
||
|
||
$dbh->disconnect;
|
||
|
||
$main::lxdebug->leave_sub();
|
||
}
|
||
|
||
... | ... | |
my ($self, $myconfig, $form) = @_;
|
||
my @values = (conv_i($form->{id}));
|
||
# connect to database, turn off AutoCommit
|
||
my $dbh = $form->dbconnect_noauto($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
my %columns = ( "assembly" => "id", "parts" => "id" );
|
||
|
||
... | ... | |
|
||
# commit
|
||
my $rc = $dbh->commit;
|
||
$dbh->disconnect;
|
||
|
||
$main::lxdebug->leave_sub();
|
||
|
||
... | ... | |
}
|
||
|
||
# connect to database
|
||
my $dbh = $form->dbconnect($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
my $query =
|
||
qq|SELECT p.id, p.partnumber, p.description, p.sellprice,
|
||
... | ... | |
WHERE $where|;
|
||
$form->{item_list} = selectall_hashref_query($form, $dbh, $query, @values);
|
||
|
||
$dbh->disconnect;
|
||
|
||
$main::lxdebug->leave_sub();
|
||
}
|
||
|
||
... | ... | |
my $num_updated = 0;
|
||
|
||
# connect to database
|
||
my $dbh = $form->dbconnect_noauto($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
for my $column (qw(sellprice listprice)) {
|
||
next if ($form->{$column} eq "");
|
||
... | ... | |
$sth_multiply->finish();
|
||
|
||
my $rc= $dbh->commit;
|
||
$dbh->disconnect;
|
||
|
||
$main::lxdebug->leave_sub();
|
||
|
||
... | ... | |
my ($self, $module, $myconfig, $form) = @_;
|
||
|
||
# connect to database
|
||
my $dbh = $form->dbconnect($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
my @values = ('%' . $module . '%');
|
||
my $query;
|
||
... | ... | |
($form->{priceupdate}) = selectrow_query($form, $dbh, qq|SELECT current_date|);
|
||
}
|
||
|
||
$dbh->disconnect;
|
||
$main::lxdebug->leave_sub();
|
||
}
|
||
|
||
... | ... | |
$main::lxdebug->enter_sub();
|
||
|
||
my ($self, $myconfig, $form, $sortorder) = @_;
|
||
my $dbh = $form->dbconnect($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
my $order = qq| p.partnumber|;
|
||
my $where = qq|1 = 1|;
|
||
my @values;
|
||
... | ... | |
} #while
|
||
$form->{rows} = $j;
|
||
$sth->finish;
|
||
$dbh->disconnect;
|
||
|
||
$main::lxdebug->leave_sub();
|
||
|
||
... | ... | |
my ($self, $myconfig, $form) = @_;
|
||
|
||
# connect to database
|
||
my $dbh = $form->dbconnect($myconfig);
|
||
my $dbh = $form->get_standard_dbh;
|
||
|
||
my @values;
|
||
my $where;
|
||
... | ... | |
|
||
my $languages = selectall_hashref_query($form, $dbh, $query, @values);
|
||
|
||
$dbh->disconnect;
|
||
|
||
$main::lxdebug->leave_sub();
|
||
|
||
return $languages;
|
Auch abrufbar als: Unified diff
Datenbankhandles in IC nicht disconnecten