Re: Custom Insert function
От | Jan Wieck |
---|---|
Тема | Re: Custom Insert function |
Дата | |
Msg-id | 200109210608.f8L68Ca01506@saturn.jw.home обсуждение исходный текст |
Ответ на | Custom Insert function ("Brian C. Doyle" <bcdoyle@mindspring.com>) |
Список | pgsql-general |
Brian C. Doyle wrote: > Hello all, > > Is it possible to create a function that would look like > this_function('file.csv'); > > and make it run > COPY this_table FROM '/this/location/file.csv' USING DELIMITERS ','; > > Thus eliminating alot of repeated work each time??? > > if so what would I put on the returns Looks like a job for PL/TclU. It could read an external file, do all the necessary conversions with Tcl's enhanced regular expressions and execute inserts unsing a prepared INSERT plan. Jan -- #======================================================================# # It's easier to get forgiveness for being wrong than for being right. # # Let's break this rule - forgive me. # #================================================== JanWieck@Yahoo.com # _________________________________________________________ Do You Yahoo!? Get your free @yahoo.com address at http://mail.yahoo.com
В списке pgsql-general по дате отправления: