Re: [HACKERS] pgbench tap tests & minor fixes
От
Fabien COELHO
Тема
Re: [HACKERS] pgbench tap tests & minor fixes
Дата
Msg-id
alpine.DEB.2.20.1706081952470.12833@lancre
Ответ на
Re: [HACKERS] pgbench tap tests & minor fixes (Nikolay Shaplov)
Список
Дерево обсуждения
[HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes. Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes. Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] pgbench tap tests & minor fixes. Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes. Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] pgbench tap tests & minor fixes. Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes. Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] pgbench tap tests & minor fixes. Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes. Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] pgbench tap tests & minor fixes. Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
Re: [HACKERS] pgbench tap tests & minor fixes. Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] pgbench tap tests & minor fixes. Andrew Dunstan <andrew.dunstan@2ndquadrant.com>
Re: [HACKERS] pgbench tap tests & minor fixes. Andres Freund <andres@anarazel.de>
Re: [HACKERS] pgbench tap tests & minor fixes. Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes. Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] pgbench tap tests & minor fixes. Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes. Tom Lane <tgl@sss.pgh.pa.us>
Re: [HACKERS] pgbench tap tests & minor fixes. Michael Paquier <michael.paquier@gmail.com>
Re: [HACKERS] pgbench tap tests & minor fixes. Alvaro Herrera <alvherre@alvh.no-ip.org>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Robert Haas <robertmhaas@gmail.com>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Alvaro Herrera <alvherre@2ndquadrant.com>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Re: [HACKERS] pgbench tap tests & minor fixes Fabien COELHO <coelho@cri.ensmp.fr>
Re: [HACKERS] pgbench tap tests & minor fixes Nikolay Shaplov <dhyan@nataraj.su>
Hello Nikolay, > I did some investigation: The code there really suppose that there is always > \n at the end of the line, and truncates the line. It is done in > > /* Get location of the ending newline */ > end_offset = expr_scanner_offset(sstate) - 1; > > just two lines above the code we are discussing. > > When you have one line code /sleep 2ms with no "end of line" symbol at the > end, it will cut off "s" instead of "\n" > > You've fix it, but now it will leave \n, in all sleeps in multiline scripts. > > So this should be fixed in both expr_scanner_get_substring cases, and keep last > symbol only if it is not "\n". Indeed, this is a mess. The code assumes all stuff is a line ending with '\n', but this is not always the case. >> Also, if someone could run a test on windows, it would be great. > I'll try to ask a friend of mine to run this on windows... That would be great! Here is a v7 which chomps the final newline only if there is one. Thanks again, -- Fabien. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers
В списке pgsql-hackers по дате отправления
От: Tom Lane
Дата:
От: Robert Haas
Дата: