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 006872A4CA for ; Wed, 20 Mar 2019 06:14:48 -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 Pakgk0SU7GQl for ; Wed, 20 Mar 2019 06:14:47 -0400 (EDT) Received: from smtp29.i.mail.ru (smtp29.i.mail.ru [94.100.177.89]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTPS id A82122A44B for ; Wed, 20 Mar 2019 06:14:47 -0400 (EDT) Date: Wed, 20 Mar 2019 13:14:44 +0300 From: Kirill Yukhin Subject: [tarantool-patches] Re: [PATCH] sql: make spaces without PK illegal in queries Message-ID: <20190320101444.qkfyzq4mghjcggdo@tarantool.org> References: <20190319202552.93360-1-korablev@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20190319202552.93360-1-korablev@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: v.shpilevoy@tarantool.org, Nikita Pettik Hello, On 19 Mar 23:25, Nikita Pettik wrote: > Our SQL codebase was inherited from SQLite, where each table must have > at least one index - primary (if no explicit PK declared, one based on > rowid is implicitly created). In Tarantool spaces can exists without > indexes. The only existing restriction is that they can't contain any > data. Hence, even very basic queries fail with assertion/seagfault if > they are applied to spaces with no indexes. Situation when space turns > out to remain without PK is quite common due to the absence of > transactional DDL: for instance, space drop procedure consists of > several steps including dropping all indexes; space itself is dropped at > the very end. Thus, if a sequence of queries is interrupted by drop > space procedure and one is not finished, the rest of queries will > operate on space with no indexes. > > As a solution to this problem (at least temporary) now we disallow > query processing involving spaces without PK except for views. > > Closes #3780 > --- > Branch: https://github.com/tarantool/tarantool/tree/np/gh-3780-dissalow-spaces-without-pk > Issue: https://github.com/tarantool/tarantool/issues/3780 Your patch is OK. I've checked it into 2.1 branch. -- Regards, Kirill Yukhin