[med-svn] [Git][med-team/libbio-db-seqfeature-perl][master] * Fix "Column name offset is a reserved word in mysql"

Andreas Tille (@tille) gitlab at salsa.debian.org
Tue Nov 4 13:46:06 GMT 2025



Andreas Tille pushed to branch master at Debian Med / libbio-db-seqfeature-perl


Commits:
6bc2b7f5 by Andreas Tille at 2025-11-04T14:45:46+01:00
* Fix "Column name offset is a reserved word in mysql"
  Closes: #1120035

- - - - -


3 changed files:

- debian/changelog
- + debian/patches/c78ba356bbd015ba7e0ee119754b198037593821.patch
- + debian/patches/series


Changes:

=====================================
debian/changelog
=====================================
@@ -1,3 +1,13 @@
+libbio-db-seqfeature-perl (1.7.5-2) UNRELEASED; urgency=medium
+
+  * Team upload.
+
+  [ Moritz Schlarb ]
+  * Fix "Column name offset is a reserved word in mysql"
+    Closes: #1120035
+
+ -- Andreas Tille <tille at debian.org>  Tue, 04 Nov 2025 14:29:17 +0100
+
 libbio-db-seqfeature-perl (1.7.5-1) unstable; urgency=medium
 
   * New upstream version 1.7.5


=====================================
debian/patches/c78ba356bbd015ba7e0ee119754b198037593821.patch
=====================================
@@ -0,0 +1,88 @@
+From: Moritz Schlarb <schlarbm at uni-mainz.de>
+Origin: https://github.com/bioperl/Bio-DB-SeqFeature/pull/6/commits/c78ba356bbd015ba7e0ee119754b198037593821
+Last-Update: 2025-11-04
+Bug-Debian: https://bugs.debian.org/1120035
+Subject: [PATCH] Fix "Column name offset is a reserved word in mysql"
+
+Closes #5
+---
+ lib/Bio/DB/SeqFeature/Store/DBI/MariaDB.pm | 12 ++++++------
+ lib/Bio/DB/SeqFeature/Store/DBI/mysql.pm   | 12 ++++++------
+ 2 files changed, 12 insertions(+), 12 deletions(-)
+
+diff --git a/lib/Bio/DB/SeqFeature/Store/DBI/MariaDB.pm b/lib/Bio/DB/SeqFeature/Store/DBI/MariaDB.pm
+index 070c9c1..96ac1b7 100644
+--- a/lib/Bio/DB/SeqFeature/Store/DBI/MariaDB.pm
++++ b/lib/Bio/DB/SeqFeature/Store/DBI/MariaDB.pm
+@@ -315,9 +315,9 @@ END
+ 	  sequence => <<END,
+ (
+   id       int(10) not null,
+-  offset   int(10) unsigned not null,
++  `offset` int(10) unsigned not null,
+   sequence longblob,
+-  primary key(id,offset)
++  primary key(id,`offset`)
+ )
+ END
+ 	  interval_stats => <<END,
+@@ -684,7 +684,7 @@ sub _fetch_sequence {
+   my $sequence_table = $self->_sequence_table;
+ 
+   my $sql = <<END;
+-SELECT sequence,offset
++SELECT sequence,s.offset
+    FROM $sequence_table as s
+    WHERE s.id=?
+      AND s.offset >= ?
+@@ -718,9 +718,9 @@ sub _offset_boundary {
+   my $locationlist_table = $self->_locationlist_table;
+ 
+   my $sql;
+-  $sql =  $position eq 'left'  ? "SELECT min(offset) FROM $sequence_table as s WHERE s.id=?"
+-         :$position eq 'right' ? "SELECT max(offset) FROM $sequence_table as s WHERE s.id=?"
+-	 :"SELECT max(offset) FROM $sequence_table as s WHERE s.id=? AND offset<=?";
++  $sql =  $position eq 'left'  ? "SELECT min(s.offset) FROM $sequence_table as s WHERE s.id=?"
++         :$position eq 'right' ? "SELECT max(s.offset) FROM $sequence_table as s WHERE s.id=?"
++	 :"SELECT max(s.offset) FROM $sequence_table as s WHERE s.id=? AND s.offset<=?";
+   my $sth = $self->_prepare($sql);
+   my @args = $position =~ /^-?\d+$/ ? ($seqid,$position) : ($seqid);
+   $self->_print_query($sql, at args) if DEBUG || $self->debug;
+diff --git a/lib/Bio/DB/SeqFeature/Store/DBI/mysql.pm b/lib/Bio/DB/SeqFeature/Store/DBI/mysql.pm
+index a92aff0..8338f34 100644
+--- a/lib/Bio/DB/SeqFeature/Store/DBI/mysql.pm
++++ b/lib/Bio/DB/SeqFeature/Store/DBI/mysql.pm
+@@ -315,9 +315,9 @@ END
+ 	  sequence => <<END,
+ (
+   id       int(10) not null,
+-  offset   int(10) unsigned not null,
++  `offset` int(10) unsigned not null,
+   sequence longblob,
+-  primary key(id,offset)
++  primary key(id,`offset`)
+ )
+ END
+ 	  interval_stats => <<END,
+@@ -684,7 +684,7 @@ sub _fetch_sequence {
+   my $sequence_table = $self->_sequence_table;
+ 
+   my $sql = <<END;
+-SELECT sequence,offset
++SELECT sequence,s.offset
+    FROM $sequence_table as s
+    WHERE s.id=?
+      AND s.offset >= ?
+@@ -718,9 +718,9 @@ sub _offset_boundary {
+   my $locationlist_table = $self->_locationlist_table;
+ 
+   my $sql;
+-  $sql =  $position eq 'left'  ? "SELECT min(offset) FROM $sequence_table as s WHERE s.id=?"
+-         :$position eq 'right' ? "SELECT max(offset) FROM $sequence_table as s WHERE s.id=?"
+-	 :"SELECT max(offset) FROM $sequence_table as s WHERE s.id=? AND offset<=?";
++  $sql =  $position eq 'left'  ? "SELECT min(s.offset) FROM $sequence_table as s WHERE s.id=?"
++         :$position eq 'right' ? "SELECT max(s.offset) FROM $sequence_table as s WHERE s.id=?"
++	 :"SELECT max(s.offset) FROM $sequence_table as s WHERE s.id=? AND s.offset<=?";
+   my $sth = $self->_prepare($sql);
+   my @args = $position =~ /^-?\d+$/ ? ($seqid,$position) : ($seqid);
+   $self->_print_query($sql, at args) if DEBUG || $self->debug;


=====================================
debian/patches/series
=====================================
@@ -0,0 +1 @@
+c78ba356bbd015ba7e0ee119754b198037593821.patch



View it on GitLab: https://salsa.debian.org/med-team/libbio-db-seqfeature-perl/-/commit/6bc2b7f50c1773a7af7bcec263b667f68bcbb877

-- 
View it on GitLab: https://salsa.debian.org/med-team/libbio-db-seqfeature-perl/-/commit/6bc2b7f50c1773a7af7bcec263b667f68bcbb877
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20251104/dcf9308d/attachment-0001.htm>


More information about the debian-med-commit mailing list