From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id KKfABpM60WNB6wAAbAwnHQ (envelope-from ) for ; Wed, 25 Jan 2023 15:20:03 +0100 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id iAhGBpM60WMNtwAAauVa8A (envelope-from ) for ; Wed, 25 Jan 2023 15:20:03 +0100 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id B5B0B2EE88 for ; Wed, 25 Jan 2023 15:20:02 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pKgc4-0008KN-Ek; Wed, 25 Jan 2023 09:18:56 -0500 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 1pKgbz-0008J6-JS for emacs-orgmode@gnu.org; Wed, 25 Jan 2023 09:18:51 -0500 Received: from mail-pj1-x1036.google.com ([2607:f8b0:4864:20::1036]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pKgbx-0005M7-R9; Wed, 25 Jan 2023 09:18:51 -0500 Received: by mail-pj1-x1036.google.com with SMTP id m7-20020a17090a71c700b0022c0c070f2eso1490627pjs.4; Wed, 25 Jan 2023 06:18:49 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:in-reply-to:date:subject:cc:to:from:user-agent :references:message-id:from:to:cc:subject:date:message-id:reply-to; bh=vgNGPUoJ2WiFgO9OClwLo2NEw6c7+GhcuAyk4aXTK7Q=; b=JGdVQPp38m6SvbgNML3SMTS1KvQ8uyTJq4jfiYifLrfV3kTajY39/qE5qv7LKIgwuf IzbCJZkdj0ytgLlLQnKsjNZb+/4+m/05H2uWduM6yd8n6lL8LqbqDVgTg55CDeX1o6x8 bjK6kVDPL+9zuQzL0j6iY9vkH1mnYBpPuKzv8S8G1YucYQQridyGrhPz762/+tAl/r8U 3FN80wHcxmywaq5A8xuRYbk2CgphKwFtOJalq9/AU02UHw50Ttc1Xn3V1wGJFLsot+0P eidZxNStwNBUqj1LjLcqiIcOGPivwHuGzStS2aFOmFAKmCtExnJc4/MfjDsRzmopMTGV AuWg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:in-reply-to:date:subject:cc:to:from:user-agent :references:message-id:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=vgNGPUoJ2WiFgO9OClwLo2NEw6c7+GhcuAyk4aXTK7Q=; b=RXzpwNKWkPyhdpdu+Sy5bGewzwX8jeLjFEw6pg+jRub6sdK4IR07fPccHBYcjrC82k neYUmOjGGyT5TpITTfxNHdqc4U1h5bx7HB+J4v+e1u/RO148B/30zKMyYhkbWcatNbB0 24Td/hrjdGIsPIBX2PMbGCGucaGmYnPfPbIds2deHDmbo9KTGijOF5zgybyjKzS9uOk8 vIbNohDQx6Jh1YSjqt9FNpLKNJjLw2rczKh4KOrXmJtzy3+Bxqe9a7pjiVXRFaejFnN2 d87FjJEOYsJ5xC89W2Nmwuno79bx8dh5SqE/bVXg1H1Ax7lzpYBXU+B6BUKKIMxRPppE cunA== X-Gm-Message-State: AO0yUKWvIU0d8nqVtY5XNYRT4+D3adf0BJJBpRNc8qkw+2uHGiJhv/o/ /ycBkD5l5NicwaeyA3ikL5NdZePrVpUtKA== X-Google-Smtp-Source: AK7set9SqEHF1ceiq3xgt7er+Zn/HCk9Z04zN6OkpchwRXjlxDELU+1N2BQfxrlkXtrHeqA8cOzB2g== X-Received: by 2002:a17:902:c78a:b0:196:35cf:3afe with SMTP id w10-20020a170902c78a00b0019635cf3afemr520816pla.38.1674656327557; Wed, 25 Jan 2023 06:18:47 -0800 (PST) Received: from dingbat (220-235-140-148.dyn.iinet.net.au. [220.235.140.148]) by smtp.gmail.com with ESMTPSA id i3-20020a1709026ac300b0019462aa090bsm3647010plt.284.2023.01.25.06.18.45 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 25 Jan 2023 06:18:47 -0800 (PST) Message-ID: <63d13a47.170a0220.e629f.6974@mx.google.com> X-Google-Original-Message-ID: --text follows this line-- References: <874jsqbvfq.fsf@kraus.my> <87358an35i.fsf@localhost> <63c5b8db.170a0220.e466f.2573@mx.google.com> <87o7qxmr6y.fsf@kraus.my> <87fsc9iifs.fsf@localhost> <63d0e433.170a0220.54a51.4c8f@mx.google.com> <87a626n64x.fsf@localhost> User-agent: mu4e 1.9.16; emacs 29.0.60 From: Tim Cross To: Ihor Radchenko Cc: rms@gnu.org, Jean Louis , emacs-orgmode@gnu.org Subject: Re: Supporting non-free SQL clients in ob-sql (was: [PATCH] ob-sql: Add support for Athena) Date: Thu, 26 Jan 2023 01:05:58 +1100 In-reply-to: <87a626n64x.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::1036; envelope-from=theophilusx@gmail.com; helo=mail-pj1-x1036.google.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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1674656402; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=vgNGPUoJ2WiFgO9OClwLo2NEw6c7+GhcuAyk4aXTK7Q=; b=tXyf+hLa3GyFHzll7reqTD29tLfF4SRqxUuAY1vdo0MXSCKgCPf8xWcnglAFoB0lyw5Oml UCL7v0wHNz39jVYYfjKXWaWC/of9Wif30IhuETgNgurw3Tv+0+0zbyE7MQf0qlN1V6t7wd hbz99RA7aYHMqLqdJHtcFEIgQuwLOeGX9UHWZ0qJrdZBvafHrlgk0biUTP2v4sv6TNo2iP +sZ2uZ9pIL3Q34tz1cOmyY7Ds2OxMyIhSunAhIHhQtAGL6BpqRFwURfwuNamtYEb3cKLoq xH26e0J7BEGb+2yJXftSP9+/yYUIK0bF6qCEyHV/ptLkBPlZJddd/e4UBE/W6A== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=JGdVQPp3; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com ARC-Seal: i=1; s=key1; d=yhetil.org; t=1674656402; a=rsa-sha256; cv=none; b=ftEXLciB5DAKSnMZxMxkQlvCBdQmrsNrULxgnBXoM15KQAosqFG4GETKx9CjPcLhA0vp9L OuaHKeeWWdexE3y321nJghQZc83YQoLpbVv62l29iUwaZkysYfgFa2MJKhmmfH4JJu9zYT 8lwfp26nawS5C/w56qboy5RH8rJ9ZszjPn/6V9rPj7fi3w79k0nbQCu6Di8Uw+TeIQ66lw 3S3vvC+0+WFFfQ7MMAMUD7R9OhYSU8dyGMWdOydVlrPIYSpTfKGdRAvjK3eeS5/WpeZOGh yUwslR9xe5YMFSahZ9T7UXWGiPnNbgx/2te8AWGTk5ouAAptqhLcXRAU1S7EmQ== X-Migadu-Scanner: scn1.migadu.com Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=JGdVQPp3; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=pass (policy=none) header.from=gmail.com X-Migadu-Spam-Score: -6.25 X-Spam-Score: -6.25 X-Migadu-Queue-Id: B5B0B2EE88 X-TUID: H3WEkwTkNL5d Ihor Radchenko writes: > Tim Cross writes: > >> to be very clear, ob-sql is not adding any NEW interface to any external >> program. It is just using the Emacs built-in SQL library (Elisp), which >> has been part of Emacs for a long time (I was using it in late 90s to >> work with Oracle RDMS). It is this library that provides the 'support' >> for things like Oracle's RDMS. If you want more specific information, >> ask on emacs-devel. Org mode is just using this built-in library. > > This is wrong. > `org-babel-execute:sql' directly calls the CLI executable via `process-file'. > > That said, the discussion about sql.el is also relevant wrt non-free SQL > client support. It will be helpful to clarify what is morally acceptable > for all the scenarios, not just for Org's use-case. > >> The Oracle database is simply a relational database management system in >> the same way as Postgres, MySQL, Ingris, MS-Sql server etc. All of these >> have a CLI client and support connections via JDBC. The sql.el library >> provides specialised comint based interfaces which run the CLI to >> communicate with the RDMS. The closest of your 3 choices is b, as the >> build-in Emacs sql library executes the RDMS CLI in a sub-process comint >> buffer. > > Org does not use this comint interface yet. We may in future though, for > sessions: > > (defun org-babel-prep-session:sql (_session _params) > "Raise an error because Sql sessions aren't implemented." > (error "SQL sessions not yet implemented")) OK, thanks the for correction. I was confused because the set of supported RDBMS is the same as those supported by sql.el and the connection credentials uses the same variable name i.e. sql-connection-alist. However, I gues the point remains, sql.el and ob-sql.el support a number of non-free RDMS and I think this is fine given that 1. There is no encouragement, implicit or explicit, to use a non-free database 2. Provided support provides a way to interact with these non-free RDMS using free software. 3. There is no requirement to install non-free software to use ob-sql.el. The software is fully functional using a free RDMS like postgres. For maintenance reasons and to add session support, I would suggest that using sql.el instead of re-inventing this wheel would be a better outcome. I've used sql.el for years and it works extremely well and I don't htink it would be too hard to integrate into ob-sql.