Re: [GENERAL] ORDER BY for jsonb

2015-04-18 Thread Jim Nasby
On 4/18/15 1:30 AM, Pai-Hung Chen wrote: Thanks for the help. So in this case, the performance of ORDER BY will not be affected at all by whether an index is created on the jsonb setting field? No. The optimizer is going to first try and satisfy the WHERE clause with that relevant index.

Re: [GENERAL] Cast SRF returning record to a table type?

2015-04-18 Thread Jim Nasby
On 4/18/15 12:47 AM, David G. Johnston wrote: If you could find a way to pass a value of type some_table into the function - instead of the name/text 'some_table‘ - you could possibly use polymorphic pseudotypes...just imagining here... Oh, I didn't think about that. Maybe I'll try it. What

Re: [GENERAL] [SQL] function to send email with query results

2015-04-18 Thread Jim Nasby
On 4/18/15 12:52 AM, David G. Johnston wrote: On Friday, April 17, 2015, Suresh Raja suresh.raja...@gmail.com mailto:suresh.raja...@gmail.com wrote: Hi all: I'm looking to write a function to send email with result of a query.Is it possible to send email with in a function.

Re: [GENERAL] ORDER BY for jsonb

2015-04-18 Thread Pai-Hung Chen
Thanks for the help. So in this case, the performance of ORDER BY will not be affected at all by whether an index is created on the jsonb setting field? Pai-Hung -Original Message- From: Jim Nasby jim.na...@bluetreble.com Sent: ‎4/‎17/‎2015 8:59 PM To: Pai-Hung Chen

Re: [GENERAL] function to send email with query results

2015-04-18 Thread John R Pierce
On 4/17/2015 10:30 PM, Suresh Raja wrote: I'm looking to write a function to send email with result of a query. Is it possible to send email with in a function. Any help is appreciated. I would do that in an application, not a pl sql function. make a query, fetch the results,