Syntax problem with COPY function

Hey there, i am stuck with a problem for a few days.
I want to upload .txt files (50+ rows) in supabase.
Everythings worked fine until i tried to get the files from my front end.
I am using this code :
begin
EXECUTE format(E'
COPY (tablename)
FROM PROGRAM curl %L
DELIMITER %L
encoding %L'
,input_url, '\t', 'windows-1251');
end;

When i just use write the url it work without the EXECUTE FORMAT (it's plpgsql)

Any clues ?
Was this page helpful?