Thread: Server side lo-funcs name
Recently we got a complain about server side large object function names described in the doc: http://www.postgresql.org/message-id/51B2413F.8010305@gmail.com In the doc: http://www.postgresql.org/docs/9.3/static/lo-funcs.html "There are server-side functions callable from SQL that correspond to each of the client-side functions described above; indeed, for the most part the client-side functions are simply interfaces to the equivalent server-side functions" From the description it is hard for users to find out server side functions "loread" and "lowrite" becuase they are looking for "lo_read" and "lo_write". So I think his complain is fair. Included patches attempt to fix the problem. -- Tatsuo Ishii SRA OSS, Inc. Japan English: http://www.sraoss.co.jp/index_en.php Japanese: http://www.sraoss.co.jp diff --git a/doc/src/sgml/lobj.sgml b/doc/src/sgml/lobj.sgml index db5bc10..6dbc84c 100644 --- a/doc/src/sgml/lobj.sgml +++ b/doc/src/sgml/lobj.sgml @@ -527,10 +527,14 @@ int lo_unlink(PGconn *conn, Oid lobjId); <para> There are server-side functions callable from SQLthat correspond to - each of the client-side functions described above; indeed, for the - most part the client-side functions are simply interfaces to the - equivalent server-side functions. The ones that are actually useful - to call via SQL commands are + each of the client-side functions described above(please note + that the server side function + for <function>lo_read</function> is <function>loread</function> and + the server side function for <function>lo_write</function> + is <function>lowrite</function>); indeed, for the most part the + client-side functions are simply interfaces to the equivalent + server-side functions. The ones that are actually useful to call + via SQL commands are <function>lo_creat</function><indexterm><primary>lo_creat</></>, <function>lo_create</function><indexterm><primary>lo_create</></>, <function>lo_unlink</function><indexterm><primary>lo_unlink</></>,
On Sun, Jun 9, 2013 at 8:16 PM, Tatsuo Ishii <ishii@postgresql.org> wrote: > Recently we got a complain about server side large object function > names described in the doc: > http://www.postgresql.org/message-id/51B2413F.8010305@gmail.com > > In the doc: > http://www.postgresql.org/docs/9.3/static/lo-funcs.html > > "There are server-side functions callable from SQL that correspond to > each of the client-side functions described above; indeed, for the > most part the client-side functions are simply interfaces to the > equivalent server-side functions" > > From the description it is hard for users to find out server side > functions "loread" and "lowrite" becuase they are looking for > "lo_read" and "lo_write". So I think his complain is fair. Included > patches attempt to fix the problem. + each of the client-side functions described above(please note This line contains an obvious whitespace error, but more than that, I think the resulting paragraph doesn't read very well this way. I would suggest adding a new paragraph further down, maybe like this: --- a/doc/src/sgml/lobj.sgml +++ b/doc/src/sgml/lobj.sgml @@ -572,6 +572,14 @@ SELECT lo_export(image.raster, '/tmp/motd') FROM image The client-side functions do not require superuserprivilege. </para> + <para> + The functionality of <function>lo_read</function> and + <function>lo_write</function> is also available via server-side calls, + but the names of the server-side functions differ from the client side + interfaces in that they do not contain underscores. You must call + these functions as <function>loread</> and <function>lowrite</>. + </para> +</sect1> <sect1 id="lo-examplesect"> -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company
> Recently we got a complain about server side large object function > names described in the doc: > http://www.postgresql.org/message-id/51B2413F.8010305@gmail.com > > In the doc: > http://www.postgresql.org/docs/9.3/static/lo-funcs.html > > "There are server-side functions callable from SQL that correspond to > each of the client-side functions described above; indeed, for the > most part the client-side functions are simply interfaces to the > equivalent server-side functions" > >>From the description it is hard for users to find out server side > functions "loread" and "lowrite" becuase they are looking for > "lo_read" and "lo_write". So I think his complain is fair. Included > patches attempt to fix the problem. I have committed this. -- Tatsuo Ishii SRA OSS, Inc. Japan English: http://www.sraoss.co.jp/index_en.php Japanese: http://www.sraoss.co.jp
On Tue, Jun 11, 2013 at 1:32 AM, Tatsuo Ishii <ishii@postgresql.org> wrote: >> Recently we got a complain about server side large object function >> names described in the doc: >> http://www.postgresql.org/message-id/51B2413F.8010305@gmail.com >> >> In the doc: >> http://www.postgresql.org/docs/9.3/static/lo-funcs.html >> >> "There are server-side functions callable from SQL that correspond to >> each of the client-side functions described above; indeed, for the >> most part the client-side functions are simply interfaces to the >> equivalent server-side functions" >> >>>From the description it is hard for users to find out server side >> functions "loread" and "lowrite" becuase they are looking for >> "lo_read" and "lo_write". So I think his complain is fair. Included >> patches attempt to fix the problem. > > I have committed this. Did you see my email with proposed alternative text? You didn't even fix the whitespace error I pointed out. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company
> On Tue, Jun 11, 2013 at 1:32 AM, Tatsuo Ishii <ishii@postgresql.org> wrote: >>> Recently we got a complain about server side large object function >>> names described in the doc: >>> http://www.postgresql.org/message-id/51B2413F.8010305@gmail.com >>> >>> In the doc: >>> http://www.postgresql.org/docs/9.3/static/lo-funcs.html >>> >>> "There are server-side functions callable from SQL that correspond to >>> each of the client-side functions described above; indeed, for the >>> most part the client-side functions are simply interfaces to the >>> equivalent server-side functions" >>> >>>>From the description it is hard for users to find out server side >>> functions "loread" and "lowrite" becuase they are looking for >>> "lo_read" and "lo_write". So I think his complain is fair. Included >>> patches attempt to fix the problem. >> >> I have committed this. > > Did you see my email with proposed alternative text? You didn't even > fix the whitespace error I pointed out. I don't know why but I haven't received your email. I just found the email in the web archive and it looks better than what I proposed. Do you want to commit it yourself? -- Tatsuo Ishii SRA OSS, Inc. Japan English: http://www.sraoss.co.jp/index_en.php Japanese: http://www.sraoss.co.jp
On Tue, Jun 11, 2013 at 10:11 AM, Tatsuo Ishii <ishii@postgresql.org> wrote: >> Did you see my email with proposed alternative text? You didn't even >> fix the whitespace error I pointed out. > > I don't know why but I haven't received your email. I just found the > email in the web archive and it looks better than what I proposed. Do > you want to commit it yourself? Done. Thanks. -- Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company