Stored Procedure: COPY table FROM (where path is a text variable) - Mailing list pgsql-general

From Charles Pare
Subject Stored Procedure: COPY table FROM (where path is a text variable)
Date
Msg-id BAY124-W452C5D9DCC7C7E68E1227CEF0D0@phx.gbl
Whole thread Raw
List pgsql-general
Hi, in a stored procedure, if I do
COPY table FROM 'mypath' DELIMITERS '\t'; it works but if my path is a text variable, i.e.
COPY table FROM mytextvar DELIMITERS '\t'; it doesn't work, I get

ERROR: syntax error at or near "$1"
SQL state: 42601
Context: SQL statement in PL/PgSQL function "parseinsert" near line 15

Thank's
Charles


Get news, entertainment and everything you care about at Live.com. Check it out!

pgsql-general by date:

Previous
From: "Bauhaus"
Date:
Subject: Re: SQL problem..
Next
From: "Dimitrius Weddington"
Date:
Subject: how to covert a column?