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 709D121E45 for ; Mon, 4 Feb 2019 08:08:21 -0500 (EST) 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 pJ9KlzIGExMG for ; Mon, 4 Feb 2019 08:08:21 -0500 (EST) Received: from smtpng2.m.smailru.net (smtpng2.m.smailru.net [94.100.179.3]) (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 2C68B1FA13 for ; Mon, 4 Feb 2019 08:08:20 -0500 (EST) Subject: [tarantool-patches] Re: [PATCH v5 5/6] sql: get results of PRAGMA statement in YAML format References: <1a7fd53719a4790845c68f815a4f1a9f4f84b97a.1548771900.git.imeevma@gmail.com> <64adcf21-d8dc-6069-8382-79fc1a467e15@tarantool.org> <9c3b19c5-a1ba-5816-d525-9f6dacc04144@tarantool.org> From: Vladislav Shpilevoy Message-ID: <2591c7d9-4d3e-308c-39e5-3da864ef000e@tarantool.org> Date: Mon, 4 Feb 2019 16:08:18 +0300 MIME-Version: 1.0 In-Reply-To: <9c3b19c5-a1ba-5816-d525-9f6dacc04144@tarantool.org> Content-Type: text/plain; charset="utf-8"; format="flowed" Content-Language: en-US Content-Transfer-Encoding: 8bit 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: Imeev Mergen , tarantool-patches@freelists.org Cc: korablev@tarantool.org Thanks for the fixes! > commit 3c930d8c81aed9ff25f2d582e8bd7743ff57d861 > Author: Mergen Imeev > Date:   Thu Dec 13 21:07:31 2018 +0300 > >     sql: get results of PRAGMA statement as result set > >     Currently box.sql.execute ('PRAGMA') returns nothing, but prints >     list of pragmas and their statuses to stdout. Such strategy is >     considered to be wrong since output of this command would be >     unavailable for users who redirect stdout, use net box connection >     etc. This patch makes the command to return result as the rest of >     SQL commands. The result contains only FLAG-type pragmas and their >     statuses. > > diff --git a/test/sql/sql-debug.test.lua b/test/sql/sql-debug.test.lua > index 721ef19..e429c38 100644 > --- a/test/sql/sql-debug.test.lua > +++ b/test/sql/sql-debug.test.lua > @@ -10,3 +10,8 @@ result = box.sql.execute('PRAGMA parser_trace') >  box.sql.execute('PRAGMA parser_trace = 1') >  box.sql.execute('PRAGMA parser_trace') >  box.sql.execute('PRAGMA parser_trace = '.. result[1][1]) > + > +-- > +-- Make PRAGMA command return the result as a result set. > +-- > +box.sql.execute('PRAGMA') > Why is this test in sql-debug.test.lua instead of pragma.test.lua?