From c9a055df44587b656b89a591d03d4bef6eb15cf5 Mon Sep 17 00:00:00 2001 From: Vadim Voitenko Date: Sat, 24 Aug 2024 16:49:20 +0300 Subject: [PATCH] fix: fixed COPY restoration statement string (added semicolon and new line) Closes #179 --- internal/db/postgres/entries/table.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/db/postgres/entries/table.go b/internal/db/postgres/entries/table.go index bc389a40..4eef88ad 100644 --- a/internal/db/postgres/entries/table.go +++ b/internal/db/postgres/entries/table.go @@ -84,7 +84,7 @@ func (t *Table) Entry() (*toc.Entry, error) { } } - var query = `COPY "%s"."%s" (%s) FROM stdin` + var query = "COPY \"%s\".\"%s\" (%s) FROM stdin;\n" var schemaName, tableName string if t.LoadViaPartitionRoot && t.RootPtSchema != "" && t.RootPtName != "" { schemaName = t.RootPtSchema