From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Yuan Fu Newsgroups: gmane.emacs.bugs Subject: bug#54591: 29.0.50; sqlite-select returns blob result as multibyte string Date: Thu, 28 Apr 2022 21:59:21 -0700 Message-ID: <9B7077C1-8164-4DE3-BEEC-BF68A235F61C@gmail.com> References: <83h77jaof6.fsf@gnu.org> <87lewsakng.fsf@gnus.org> <83o81o93ak.fsf@gnu.org> <87a6d672xr.fsf@gnus.org> Mime-Version: 1.0 (Mac OS X Mail 16.0 \(3696.80.82.1.1\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="4537"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 54591@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Fri Apr 29 07:02:37 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nkIm3-0000uE-9T for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 29 Apr 2022 07:02:35 +0200 Original-Received: from localhost ([::1]:58516 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nkIm2-0003Ze-54 for geb-bug-gnu-emacs@m.gmane-mx.org; Fri, 29 Apr 2022 01:02:34 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57706) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nkIja-0002aG-Ts for bug-gnu-emacs@gnu.org; Fri, 29 Apr 2022 01:00:02 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:56600) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nkIja-0006JX-HW for bug-gnu-emacs@gnu.org; Fri, 29 Apr 2022 01:00:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1nkIja-0006Ty-9m for bug-gnu-emacs@gnu.org; Fri, 29 Apr 2022 01:00:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Yuan Fu Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Fri, 29 Apr 2022 05:00:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 54591 X-GNU-PR-Package: emacs Original-Received: via spool by 54591-submit@debbugs.gnu.org id=B54591.165120838124866 (code B ref 54591); Fri, 29 Apr 2022 05:00:02 +0000 Original-Received: (at 54591) by debbugs.gnu.org; 29 Apr 2022 04:59:41 +0000 Original-Received: from localhost ([127.0.0.1]:50497 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nkIjF-0006T0-9w for submit@debbugs.gnu.org; Fri, 29 Apr 2022 00:59:41 -0400 Original-Received: from mail-pj1-f41.google.com ([209.85.216.41]:37790) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nkIjD-0006Sl-CL for 54591@debbugs.gnu.org; Fri, 29 Apr 2022 00:59:39 -0400 Original-Received: by mail-pj1-f41.google.com with SMTP id t11-20020a17090ad50b00b001d95bf21996so9552054pju.2 for <54591@debbugs.gnu.org>; Thu, 28 Apr 2022 21:59:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=zFqmAnAlDjdsrVJCshqIjPjQdb+BPrCgWfCpLMURttE=; b=MQpm9GZIcLCjErFS+68Tpr8dH+qaAFE4ywVO+iyWTv0jTbwriNaaC0uyvKGe/mtTxy F2xRRlREMkWBSeYyaeAlKJLsmgP/Bd+iGr5z7+kqKc+5MfK6PML+uWNXH41Dn1B5rpqA hZrjLz67ePhctSasQZcsZEfIK4PZfmaQV5xlJf2LCZRuRomI4wr08PnnJYXLnbEJd3lJ Yo+EUDnfH3qhYo/p68H4xFzWCiXDULvUYF9aQ4WaNMae0l3d/lmho9EaacZKzV9q3rP/ NrMMhtjrtDvayNf8116hlLrQbIKw34OK51L7q1rdStTsD1TZqwRZCZqngLbkZ6YIpT7Q nM+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:subject:from:in-reply-to:date:cc :content-transfer-encoding:message-id:references:to; bh=zFqmAnAlDjdsrVJCshqIjPjQdb+BPrCgWfCpLMURttE=; b=YgO0YJKTLep+ma9z/aP5ay7rirqjO6vHRnXV6J+/KlbeSrSFHnwy10u/95s9S/0b4t s60Caer0fyKnAgD3q4eaiXX14ImpOt5/i7NDJzcA1YspfrKJmYCD7jAUhvfBMzhs72p5 K3fPhgBT3AKpa629d04+6iUPW5v7z7ggTaBM9S2RwU4/Pqdh0Ir0CQMCpUEz6vAGkgX/ teEwxSSfIIrCAqdXNLtPeKo5FLSnyvIwB/ZE1tCseGBnQ9Iv1kPuxVp0b/coc0sOiiIJ n+S2JpOmgTmrid9eHtMeTSEStQG1EA9UWZnLlcF4t1HcoGwVWnuqD4ZNRcTFVVKtysMi J2qQ== X-Gm-Message-State: AOAM530QCLbG6eniKd8iLcd2+NYp/HEBiZ0w8KgG1Qt6M1dsL+9tMi9/ twhyWk+Vf4R3QM7NNaV8KWk= X-Google-Smtp-Source: ABdhPJzgmZdOom1kwzJtYnGWOdHG8Bh3tkTQS9FT/9B2N7rcCdotP8S1qzkflX11H/9JUikZOuVptw== X-Received: by 2002:a17:90a:d083:b0:1c9:94bb:732d with SMTP id k3-20020a17090ad08300b001c994bb732dmr1969058pju.106.1651208373328; Thu, 28 Apr 2022 21:59:33 -0700 (PDT) Original-Received: from smtpclient.apple ([104.180.75.250]) by smtp.gmail.com with ESMTPSA id p125-20020a62d083000000b0050d475ed4d2sm1434305pfg.197.2022.04.28.21.59.32 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 28 Apr 2022 21:59:32 -0700 (PDT) In-Reply-To: <87a6d672xr.fsf@gnus.org> X-Mailer: Apple Mail (2.3696.80.82.1.1) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:230926 Archived-At: > On Mar 31, 2022, at 4:54 AM, Lars Ingebrigtsen wrote: >=20 > Eli Zaretskii writes: >=20 >> Can we place the burden of knowing the type of the column on the >> caller? I mean, if they know it's a binary blob, they should tell = us, >> and then we don't decode it? >=20 > We could -- that was my last example: >=20 >>> "insert into test7 values (?, ?)" ["foo" (:binary binary)] >=20 > Or some syntax like that. (And then never decode when we select from = a > BLOB column.) But... >=20 >> (Of course, if there's a way of knowing the type, we could DTRT >> automatically for each type.) >=20 > Yes, I'm hoping somebody else could have a look at the sqlite > documentation and tell me I'm missing some obvious way to get that > information. :-) I had a quick look at the log and didn=E2=80=99t see anything related to = sql. So what do we end up doing? I think at least a notice could be = added to the manual? Something like =E2=80=9CUse (encode-coding-string = xxx 'raw-text)) if you want to get out a binary blob=E2=80=9D. Yuan=