Re: Re: proposal: ignore null fields in not relation type composite type based constructors

Поиск
Список
Период
Сортировка
От Jeevan Chalke
Тема Re: Re: proposal: ignore null fields in not relation type composite type based constructors
Дата
Msg-id CAM2+6=VYnCNicuKTvkQp+TFEDe2JMOk9KjtrXcFjQePYm6J8pQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Re: proposal: ignore null fields in not relation type composite type based constructors  (Pavel Stehule <pavel.stehule@gmail.com>)
Ответы Re: Re: proposal: ignore null fields in not relation type composite type based constructors  (Pavel Stehule <pavel.stehule@gmail.com>)
Список pgsql-hackers
<div dir="ltr">Hi Pavel,<br /><br />Here are few more comments on new implementation.<br /><br />1.<br /> <span
style="font-family:couriernew,monospace">/*<br />- * SQL function row_to_json(row)<br />+ * SQL function
row_to_json(rowrecord, pretty bool, ignore_nulls bool)<br />   */<br /></span><br />In above comments, parameter name
"row"should changed to "rowval".<br /><br />2.<br /><span style="font-family:courier new,monospace">-DATA(insert OID =
3155(  row_to_json       PGNSP PGUID 12 1 0 0 0 f f f f t f s 1 0 114 "2249" _null_ _null_ _null_ _null_ row_to_json
_null__null_ _null_ ));<br /> +DATA(insert OID = 3155 (  row_to_json       PGNSP PGUID 12 1 0 0 0 f f f f t f s 1 0 114
"224916 16" _null_ _null_ "{rowval,pretty,ignore_nulls}" _null_ row_to_json _null_ _null_ _null_ ));<br /></span><br />
Numberof arguments (pronargs) should be 3 now. However, when we create it<br />again with default values it gets
updated.But still here we should not have<br />inconsistency.<br /><br />3.<br /><span style="font-family:courier
new,monospace"> externDatum row_to_json(PG_FUNCTION_ARGS);<br />  extern Datum row_to_json_pretty(PG_FUNCTION_ARGS);<br
/>+externDatum row_to_json_pretty_choosy(PG_FUNCTION_ARGS);<br /> extern Datum to_json(PG_FUNCTION_ARGS);<br
/></span><br/>With this new implementation, we have NOT added row_to_json_pretty_choosy()<br /> function. So need to
removethat added line. Also we have only one function<br />with default arguments and thus removed row_to_json_pretty()
functionas<br />well. Thus need to remove extern for that too.<br /><br />4.<br />Can we have couple of test cases with
namedargument along with skipped<br /> pretty parameter test?<br /><br /><br />Thanks<br /><br /><div
class="gmail_extra">--<br /><div dir="ltr">Jeevan B Chalke<br />Principal Software Engineer, Product Development<br
/>EnterpriseDBCorporation<br />The Enterprise PostgreSQL Company<br /><br /></div></div></div> 

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Joel Jacobson
Дата:
Сообщение: Re: PL/pgSQL 2
Следующее
От: Pavel Stehule
Дата:
Сообщение: Re: [Fwd: Re: proposal: new long psql parameter --on-error-stop]