From unknown Wed Jun 18 00:24:22 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#64964 <64964@debbugs.gnu.org> To: bug#64964 <64964@debbugs.gnu.org> Subject: Status: [PATCH] Handle tabs in the SQL shown in the column listing Reply-To: bug#64964 <64964@debbugs.gnu.org> Date: Wed, 18 Jun 2025 07:24:22 +0000 retitle 64964 [PATCH] Handle tabs in the SQL shown in the column listing reassign 64964 emacs submitter 64964 john muhl severity 64964 normal tag 64964 patch thanks From debbugs-submit-bounces@debbugs.gnu.org Sun Jul 30 15:19:45 2023 Received: (at submit) by debbugs.gnu.org; 30 Jul 2023 19:19:45 +0000 Received: from localhost ([127.0.0.1]:51262 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qQBxA-0006fl-G4 for submit@debbugs.gnu.org; Sun, 30 Jul 2023 15:19:45 -0400 Received: from lists.gnu.org ([2001:470:142::17]:60888) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qQBfQ-0006GP-GT for submit@debbugs.gnu.org; Sun, 30 Jul 2023 15:01:25 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qQBfK-0003V6-K9 for bug-gnu-emacs@gnu.org; Sun, 30 Jul 2023 15:01:18 -0400 Received: from out-123.mta1.migadu.com ([2001:41d0:203:375::7b]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qQBfH-00076a-UZ for bug-gnu-emacs@gnu.org; Sun, 30 Jul 2023 15:01:18 -0400 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=pub.pink; s=key1; t=1690743671; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=6YLRwhzVsMb2CvcshMLLo0o0JeiTQvcyIhdCGSQXCek=; b=v9I2KhtMz656945+keeTFgHNBZT+kLZXSMh83W8YpA4hoUWHjpFC19w+jMYttQ2nRc/Ms9 TVFj9EL2Qi4taPsCyYvZhTX82BRsft8EQlBZJYbnRZud7M8aLfB5yBgTsVMMSSONQSFFXv PlXQQpW+p6Kt3EZp2F3OUbdnzYXMLlY= From: john muhl To: bug-gnu-emacs@gnu.org Subject: [PATCH] Handle tabs in the SQL shown in the column listing Date: Sun, 30 Jul 2023 13:48:20 -0500 Message-ID: <873515i5qj.fsf@pub.pink> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Migadu-Flow: FLOW_OUT Received-SPF: pass client-ip=2001:41d0:203:375::7b; envelope-from=jm@pub.pink; helo=out-123.mta1.migadu.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: 0.9 (/) X-Debbugs-Envelope-To: submit X-Mailman-Approved-At: Sun, 30 Jul 2023 15:19:41 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.1 (/) --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Tags: patch In sqlite-mode if the SQL used to create a column used tabs then the hide part of list columns would not remove anything after the first tab. M-x sqlite-mode-open-file my.db Table Name Number of Rows=20=20 images 0=20 users 0 With point on =E2=80=98images=E2=80=99 execute sqlite-mode-list-columns (or= press c) Table Name Number of Rows=20=20 images 0=20 id INTEGER PRIMARY KEY AUTOINCREMENT user_id INTEGER FOREIGN KEY (user_id) REFERENCES users (id) ON DELETE CASCADE users 0 There are two tab characters before =E2=80=98ON DELETE=E2=80=99. Press c ag= ain and it collapses to: Table Name Number of Rows=20=20 images 0=20 ON DELETE CASCADE users 0 In GNU Emacs 30.0.50 (build 1, x86_64-pc-linux-gnu, GTK+ Version 3.24.38, cairo version 1.17.8) of 2023-07-28 built on localhost Repository revision: febf4889d196895b07b3278cfac3f8ccb6a34235 Repository branch: jm/lua-ts-mode System Description: Fedora Linux 38 (Workstation Edition) Configured using: 'configure --with-native-compilation=3Daot --with-pgtk' --=-=-= Content-Type: text/patch Content-Disposition: attachment; filename=0001-Handle-tabs-in-the-SQL-shown-in-the-column-listing.patch >From 07920c70d7180cf969c264120ef267e960f779ae Mon Sep 17 00:00:00 2001 From: john muhl Date: Sun, 30 Jul 2023 13:43:10 -0500 Subject: [PATCH] Handle tabs in the SQL shown in the column listing * lisp/sqlite-mode.el (sqlite-mode-list-columns): Handle tabs. --- lisp/sqlite-mode.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/sqlite-mode.el b/lisp/sqlite-mode.el index c3047c786f7..8cb94485369 100644 --- a/lisp/sqlite-mode.el +++ b/lisp/sqlite-mode.el @@ -126,7 +126,7 @@ sqlite-mode-list-columns (forward-line 1) (if (looking-at " ") ;; Delete the info. - (delete-region (point) (if (re-search-forward "^[^ ]" nil t) + (delete-region (point) (if (re-search-forward "^[^ \t]" nil t) (match-beginning 0) (point-max))) ;; Insert the info. -- 2.41.0 --=-=-= Content-Type: multipart/signed; boundary="==-=-="; micalg=pgp-sha256; protocol="application/pgp-signature" --==-=-= Content-Type: text/plain --==-=-= Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQFABAEBCAAqFiEEK5CvUQq7L5O2pQef9D+KfcKUo10FAmTGs3QMHGptQHB1Yi5w aW5rAAoJEPQ/in3ClKNdocEH/0lZqILE8CK/5YM8Dqw7U5tNAKUElvAwxKL/9/zb /+Ixoe3SIbmy9WdFPyBMfDVGSy+IUMjfaWnKCddwLhpe4DFXLLcuTS33eeHKgSHG KbLmBINTlX4es82+LrQTUCTbySyw4BnueAwjfYS+kpC80iKVVMarPQO21AN3cY51 sS6hr3byBeERBxGBQ/O08B3lv6pKdgCWITg2xvpQnGtArBb1WaPqA/gGDUmdaZQw lfB1XXq1xuzvsoqb6tKt4Dn8pkh1XlmeqJqi3S+nD48A1hINzWTK1jqNk0hk24V8 G/59lCDD1JvGdCq07Dsc4mkY/zE+9Mbi+g/gUwMWgz9MDec= =MMV/ -----END PGP SIGNATURE----- --==-=-=-- --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Aug 03 04:49:05 2023 Received: (at 64964-done) by debbugs.gnu.org; 3 Aug 2023 08:49:05 +0000 Received: from localhost ([127.0.0.1]:50841 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qRU12-00039C-Qu for submit@debbugs.gnu.org; Thu, 03 Aug 2023 04:49:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:58186) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qRU11-00038P-PG for 64964-done@debbugs.gnu.org; Thu, 03 Aug 2023 04:49:04 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qRU0w-00044F-39; Thu, 03 Aug 2023 04:48:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=N8612reOupGmYFb2QA/D4qZ2PgezvY/WPl7SzZPRbzQ=; b=RX5RtIGxvGQn9/XY6Ik4 fK1L8oysYY6yjV1y7rug0PNvkpnOo8sWB4XqR9VOialK8O+eH4Ra3hToeJzJqO1lqNCpnaT1gxKMH gMgDzL7X/eLmf3OqoirDlRnZ9pOYtuUY1hJVrVHwnOkM+RJ/73ZLgyCJRIiV8pdxHCAMALuE16+3m /31TjsgQ4FUtiMiLKvSU2S2fr9uiJz9qv0QMBTHJQIkRQdSJCo+E0NoEJLwl0jkA/6p97HF24OsvP H8nfLQOMQHjFesIXyzSwxmU15NqausUBar/UvURBfzK+0Cv3RJt4uSmgoZcle/GS+ofLZAHMxlj3Q 8ofEF7DMmT10Hw==; Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qRU0v-0001Xp-Ix; Thu, 03 Aug 2023 04:48:57 -0400 Date: Thu, 03 Aug 2023 11:49:06 +0300 Message-Id: <83h6pgy0hp.fsf@gnu.org> From: Eli Zaretskii To: john muhl In-Reply-To: <873515i5qj.fsf@pub.pink> (bug-gnu-emacs@gnu.org) Subject: Re: bug#64964: [PATCH] Handle tabs in the SQL shown in the column listing References: <873515i5qj.fsf@pub.pink> MIME-version: 1.0 Content-type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 64964-done Cc: 64964-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > Date: Sun, 30 Jul 2023 13:48:20 -0500 > From: john muhl via "Bug reports for GNU Emacs, > the Swiss army knife of text editors" > > In sqlite-mode if the SQL used to create a column used tabs then the > hide part of list columns would not remove anything after the first tab. > > M-x sqlite-mode-open-file my.db > > Table Name Number of Rows > images 0 > users 0 > > With point on ‘images’ execute sqlite-mode-list-columns (or press c) > > Table Name Number of Rows > images 0 > id INTEGER PRIMARY KEY AUTOINCREMENT > user_id INTEGER > FOREIGN KEY (user_id) REFERENCES users (id) > ON DELETE CASCADE > users 0 > > There are two tab characters before ‘ON DELETE’. Press c again and it > collapses to: > > Table Name Number of Rows > images 0 > ON DELETE CASCADE > users 0 Thanks, I installed your patch on the emacs-29 branch, and I'm therefore closing this bug. From unknown Wed Jun 18 00:24:22 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Thu, 31 Aug 2023 11:24:09 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator