From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rares Vernica Subject: bug#23890: 25.0.94; Org-mode Table does not copy time interval correctly Date: Tue, 05 Jul 2016 21:44:56 -0700 Message-ID: <87zipvbcjb.fsf@gmail.com> References: <83inwlpifj.fsf@gnu.org> <8360slpdny.fsf@gnu.org> <87shvnhhmg.fsf@saiph.selenimh> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:44956) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bKekr-0001MW-MR for emacs-orgmode@gnu.org; Wed, 06 Jul 2016 00:48:10 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bKekk-0004Iz-Pa for emacs-orgmode@gnu.org; Wed, 06 Jul 2016 00:48:08 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:54686) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bKekk-0004Iu-MG for emacs-orgmode@gnu.org; Wed, 06 Jul 2016 00:48:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1bKekk-00024j-By for emacs-orgmode@gnu.org; Wed, 06 Jul 2016 00:48:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <87shvnhhmg.fsf@saiph.selenimh> (Nicolas Goaziou's message of "Tue, 05 Jul 2016 23:58:31 +0200") List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: Nicolas Goaziou Cc: 23890@debbugs.gnu.org Nicolas Goaziou writes: > It isn't a bug actually. > > Spreadsheet formulas are sent to Calc (unless it starts with "'(" in > which case it is treated as Elisp). Doing symbolic computations, Calc > parses "1d" as one time the symbolic variable "d". So "1d" is the same > as "d". > > Basically, the OP could use instead: > > #+TBLFM: $3='(identity $2) That did the trick, thanks! Just to clarify, how would you fix this: | [2016-07-05 Tue]--[2016-07-06 Wed] | 1d | vsum(d) | | [2016-07-06 Wed]--[2016-07-07 Thu] | 1d | 2 d | #+TBLFM: $3=vsum(@1$-1..@0$-1) Notice the "vsum(d)" instead of the expected "1 d". How would you add "identity" here? Thanks! Rares