View | Details | Raw Unified | Return to bug 26328
Collapse All | Expand All

(-)a/C4/Barcodes/ValueBuilder.pm (-2 / +1 lines)
Lines 26-32 sub get_barcode { Link Here
26
    my ($args) = @_;
26
    my ($args) = @_;
27
    my $nextnum;
27
    my $nextnum;
28
    # not the best, two catalogers could add the same barcode easily this way :/
28
    # not the best, two catalogers could add the same barcode easily this way :/
29
    my $query = "select max(abs(barcode)) from items";
29
    my $query = "select max(cast(barcode as unsigned)) from items";
30
    my $sth = C4::Context->dbh->prepare($query);
30
    my $sth = C4::Context->dbh->prepare($query);
31
    $sth->execute();
31
    $sth->execute();
32
    while (my ($count)= $sth->fetchrow_array) {
32
    while (my ($count)= $sth->fetchrow_array) {
33
- 

Return to bug 26328