From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 975B92C7CA for ; Thu, 25 Apr 2019 06:49:59 -0400 (EDT) Received: from turing.freelists.org ([127.0.0.1]) by localhost (turing.freelists.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id nE6HQk8m3fZT for ; Thu, 25 Apr 2019 06:49:59 -0400 (EDT) Received: from mail-lf1-f66.google.com (mail-lf1-f66.google.com [209.85.167.66]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTPS id 45CA22C5AC for ; Thu, 25 Apr 2019 06:49:59 -0400 (EDT) Received: by mail-lf1-f66.google.com with SMTP id j11so17152382lfm.0 for ; Thu, 25 Apr 2019 03:49:59 -0700 (PDT) Date: Thu, 25 Apr 2019 13:49:56 +0300 From: Konstantin Osipov Subject: [tarantool-patches] Re: [PATCH v1 1/1] sql: invalid integer type in arithmetic operations Message-ID: <20190425104956.GI29257@atlas> References: <72941eba60647c98f4559cbd0c862bade990d761.1556120090.git.kshcherbatov@tarantool.org> <0929e575-2d28-7cd0-36bc-0a1bf1af76fe@tarantool.org> <04E0C86F-84E5-400F-ACE0-80FD6799E4E3@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <04E0C86F-84E5-400F-ACE0-80FD6799E4E3@tarantool.org> Sender: tarantool-patches-bounce@freelists.org Errors-to: tarantool-patches-bounce@freelists.org Reply-To: tarantool-patches@freelists.org List-Help: List-Unsubscribe: List-software: Ecartis version 1.0.0 List-Id: tarantool-patches List-Subscribe: List-Owner: List-post: List-Archive: To: tarantool-patches@freelists.org Cc: Vladislav Shpilevoy , Kirill Shcherbatov * n.pettik [19/04/25 09:18]: > Surely, we still can create space and set format with unsigned types > from Lua, so strictly speaking UNSIGNED is allowed even now. > But we can’t set UNSIGNED as a type of column in SQL, and we don’t > set this type in meta. So in some sense it is not allowed. > Mb it is worth fixing comment. Or return _UNSIGNED instead > of _NUMBER in this case. I guess there will be no severe consequences. SQL *is* server. Please begin by having a comment containing a table for integer type arithmetics, something like this: Plus operation: -------------- integer float integer integer float float float float It's best to implement such table in the source code too, and not have complicated branching. -- Konstantin Osipov, Moscow, Russia, +7 903 626 22 32 http://tarantool.io - www.twitter.com/kostja_osipov