implicit pass-through of all relations in the relpipe-in-sql mode (if called with no arguments) v_0
authorFrantišek Kučera <franta-hg@frantovo.cz>
Tue, 29 Oct 2019 00:23:56 +0100
branchv_0
changeset 19 44db9e1e7c7f
parent 18 76cbba3f7041
child 20 b295f8985f13
implicit pass-through of all relations in the relpipe-in-sql mode (if called with no arguments)
src/relpipe-tr-sql.cpp
--- a/src/relpipe-tr-sql.cpp	Sat Oct 26 22:32:36 2019 +0200
+++ b/src/relpipe-tr-sql.cpp	Tue Oct 29 00:23:56 2019 +0100
@@ -54,6 +54,7 @@
 
 		if (std::regex_match(cli.programName(), std::wregex(L"^(.*/)?relpipe-in-sql$"))) {
 			// relpipe-in-sql:
+			if (cli.arguments().size() == 0) configuration.copyRelations.push_back({L".*", L"", false});
 			std::shared_ptr<writer::RelationalWriter> writer(writer::Factory::create(std::cout));
 			configuration.sqlBeforeRelational = isatty(fileno(stdin)) ? nullptr : &std::wcin;
 			configuration.sqlAfterRelational = nullptr;