From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id 2EDoHEYK3l6oDQAA0tVLHw (envelope-from ) for ; Mon, 08 Jun 2020 09:52:06 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id wH24GEYK3l4dewAA1q6Kng (envelope-from ) for ; Mon, 08 Jun 2020 09:52:06 +0000 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 AC1D19403E9 for ; Mon, 8 Jun 2020 09:52:05 +0000 (UTC) Received: from localhost ([::1]:50246 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jiERn-0005W1-Kg for larch@yhetil.org; Mon, 08 Jun 2020 05:52:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50220) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jiEHo-0007Zn-9b for emacs-orgmode@gnu.org; Mon, 08 Jun 2020 05:41:44 -0400 Received: from mailbackend.panix.com ([166.84.1.89]:20006) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jiEHj-0002Nc-W0 for emacs-orgmode@gnu.org; Mon, 08 Jun 2020 05:41:43 -0400 Received: from panix1.panix.com (panix1.panix.com [166.84.1.1]) by mailbackend.panix.com (Postfix) with ESMTP id 49gSv66PQTz1T0f; Mon, 8 Jun 2020 05:41:38 -0400 (EDT) Received: by panix1.panix.com (Postfix, from userid 20712) id 49gSv65JTRzcbc; Mon, 8 Jun 2020 05:41:38 -0400 (EDT) Received: from localhost (localhost [127.0.0.1]) by panix1.panix.com (Postfix) with ESMTP id 49gSv64v3jzcbW; Mon, 8 Jun 2020 05:41:38 -0400 (EDT) Date: Mon, 8 Jun 2020 05:41:38 -0400 From: Jude DaShiell To: tbanelwebmin , emacs-orgmode@gnu.org Subject: Re: [join rows] (was: join tables from different files) In-Reply-To: Message-ID: References: <878sh0q66c.fsf@mat.ucm.es> <87lfkync8o.fsf_-_@mat.ucm.es> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Received-SPF: pass client-ip=166.84.1.89; envelope-from=jdashiel@panix.com; helo=mailbackend.panix.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/06/08 05:41:38 X-ACL-Warn: Detected OS = FreeBSD 9.x or newer [fuzzy] X-Spam_score_int: -41 X-Spam_score: -4.2 X-Spam_bar: ---- X-Spam_report: (-4.2 / 5.0 requ) BAYES_00=-1.9, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 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" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=none; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Spam-Score: -1.01 X-TUID: aPRwwE7nN6wC If what's wanted here is a horizontal join of tables paste(1) might be used to start the process however the #TBLFMT: line for the new table would need new formulas and column headers may need adjusting. Something like this was possible in dBase III+ using modify structure if memory serves. On Mon, 8 Jun 2020, tbanelwebmin wrote: > Date: Mon, 8 Jun 2020 02:18:45 > From: tbanelwebmin > To: emacs-orgmode@gnu.org > Subject: Re: [join rows] (was: join tables from different files) > > Le 07/06/2020 ? 17:09, Uwe Brauer a ?crit?: > > > "t" == tbanelwebmin writes: > > > > Yes you can. > > Use an org-id > > > > Thanks! Nice! > > > > > > I have a another question in this context: > > can I join, say 4 tables, but row wise? > > Say I have > > > > #+TBLNAME: RK > > #+ATTR_HTML: :border 2 :rules all :frame border > > | met | Q1 | Q2 | Q3 | total | > > |-----+----+----+-----+-------| > > | RK | 1 | 1 | 0.5 | 2.5 | > > #+TBLFM: $5=$2+$3+$4 > > > > #+TBLNAME: SVD > > #+ATTR_HTML: :border 2 :rules all :frame border > > | met | Q1: | Q2 | Q3 | total | > > |-----+-----+----+----+-------| > > | SVD | 0.5 | 1 | 1 | 2.5 | > > #+TBLFM: $5=$2+$3+$4;f1 > > > > #+TBLNAME: MIN > > #+ATTR_HTML: :border 2 :rules all :frame border > > | met | Q1 | Q2 | total | > > |-----+----+-----+-------| > > | MIN | 2 | 0.5 | 2.5 | > > #+TBLFM: $4=$2+$3 > > > > #+TBLNAME: BDF > > #+ATTR_HTML: :border 2 :rules all :frame border > > | met | Q1 | Q2 | total | > > |-----+------+------+-------| > > | MIN | 0.75 | 1.75 | 2.5 | > > #+TBLFM: $4=$2+$3 > > > > Since they don't have the same amount of columns, I'd like to join the 4 tables like this > > #+TBLNAME: Total1 > > #+ATTR_HTML: :border 2 :rules all :frame border > > | met | Q1 | Q2 | Q3 | total | > > |-----+-----+----+-----+-------| > > | RK | 1 | 1 | 0.5 | 2.5 | > > |-----+-----+----+-----+-------| > > | SVD | 0.5 | 1 | 1 | 2.5 | > > #+TBLFM: $5=$2+$3+$4;f1 > > > > #+TBLNAME: Total2 > > #+ATTR_HTML: :border 2 :rules all :frame border > > | met | Q1 | Q2 | total | > > |-----+------+------+-------| > > | MIN | 2 | 0.5 | 2.5 | > > |-----+------+------+-------| > > | MIN | 0.75 | 1.75 | 2.5 | > > #+TBLFM: $4=$2+$3 > > > > Is this possible? > > > > regards > > Uwe Brauer > > I'm not aware of anything specific for this purpose. A starting point could be the `append' lisp function: > > #+begin_src elisp :var table1=RK :var table2=SVD :colnames t > (append table1 table2) > #+end_src > > #+RESULTS: > | met | Q1: | Q2 | Q3 | total | > |-----+-----+----+-----+-------| > | RK | 1 | 1 | 0.5 | 2.5 | > | SVD | 0.5 | 1 | 1 | 2.5 | > > > > --