Subject: bug#77088: closed (Re: bug#77088: 31.0.50: sql-mode: MariaDB and Mysql both handle escaped apostrophes in the same way.)

From: [email-masked] (GNU bug Tracking System)
Date: Thu, 20 Mar 2025 12:50:02 +0000

Your bug report

#77088: 31.0.50: sql-mode: MariaDB and Mysql both handle escaped apostrophes in the same way.

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
77088: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=77088
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#77088: 31.0.50: sql-mode: MariaDB and Mysql both handle escaped apostrophes in the same way.
From: Eli Zaretskii <[email-masked]>
To: Vincenzo Pupillo <[email-masked]>
Cc: [email-masked]
Date: Thu, 20 Mar 2025 14:48:29 +0200
List-Id: <debbugs-submit.debbugs.gnu.org>

> From: Vincenzo Pupillo <[email-masked]>
> Date: Mon, 17 Mar 2025 22:53:17 +0100
> 
> This patch fixes the way apostrophes are escaped in MariaDB product.
> Thanks.

Thanks, installed on the master branch, and closing the bug.

Subject: 31.0.50: sql-mode: MariaDB and Mysql both handle escaped apostrophes in the same way.
From: Vincenzo Pupillo <[email-masked]>
To: [email-masked]
Date: Mon, 17 Mar 2025 22:53:17 +0100
List-Id: <debbugs-submit.debbugs.gnu.org>

Ciao,
This patch fixes the way apostrophes are escaped in MariaDB product.
Thanks.

Vincenzo

>From d476df25bc5a75db984e714c2cc3477454d72368 Mon Sep 17 00:00:00 2001
From: Vincenzo Pupillo <[email-masked]>
Date: Mon, 17 Mar 2025 22:35:23 +0100
Subject: [PATCH] MariaDB and Mysql handle escaped aphostrophes in the same
 way.

* lisp/progmodes/sql.el (sql-mode): MariaDB and Mysql both handle
escaped apostrophes in the same way.
---
 lisp/progmodes/sql.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/progmodes/sql.el b/lisp/progmodes/sql.el
index a1c50a06990..58fbf3c51e7 100644
--- a/lisp/progmodes/sql.el
+++ b/lisp/progmodes/sql.el
@@ -4164,7 +4164,7 @@ sql-mode
               (eval
                '(syntax-propertize-rules
                  ;; Handle escaped apostrophes within strings.
-                 ((if (eq sql-product 'mysql)
+                 ((if (member sql-product '(mysql mariadb))
                       "\\\\'"
                     "''")
                   (0
-- 
2.48.1