\g filename

Поиск
Список
Период
Сортировка
Искать

\g filename

От:
Rob Sargent <robjsargent@gmail.com>
Дата:
I just ran a query (select myfunction() \g bad/filename) which took almost an hour and a half then told me “no such file or directory” since I had scrogged the path.  Could this path not be checked prior to actual execution of the query?

ps sorry for the blank version of this same topic - or maybe zero content is rejected, hopefully.


Re: \g filename

От:
Adrian Klaver <adrian.klaver@aklaver.com>
Дата:
On 01/24/2018 12:30 PM, Rob Sargent wrote:
> I just ran a query (select myfunction() \g bad/filename) which took almost an hour and a half then told me “no such file or directory” since I had scrogged the path.  Could this path not be checked prior to actual execution of the query?

Maybe?:


test_(aklaver)> \o pg_test/some_file.txt
pg_test/some_file.txt: No such file or directory

> 
> ps sorry for the blank version of this same topic - or maybe zero content is rejected, hopefully.
> 
> 


-- 
Adrian Klaver
adrian.klaver@aklaver.com

Re: \g filename

От:
Rob Sargent <robjsargent@gmail.com>
Дата:

On 01/24/2018 01:38 PM, Adrian Klaver wrote:
> On 01/24/2018 12:30 PM, Rob Sargent wrote:
>> I just ran a query (select myfunction() \g bad/filename) which took 
>> almost an hour and a half then told me “no such file or directory” 
>> since I had scrogged the path. Could this path not be checked prior 
>> to actual execution of the query?
>
> Maybe?:
>
>
> test_(aklaver)> \o pg_test/some_file.txt
> pg_test/some_file.txt: No such file or directory

Ah yes, place the onus squarely on the user :)


FAQ