27, 2015 at 4:16 PM, Deven Phillips
wrote:
> OK, then I will look into perhaps implementing it as a pl-python or
> pl-java function. Thanks for the advice!!
>
> Deven
>
> On Fri, Mar 27, 2015 at 2:40 PM, Merlin Moncure
> wrote:
>
>> On Fri, Mar 27, 2015 at 1:36 PM, Ar
NVM, I guess that I just didn't wait long enough for the re-index operation
to complete... We're good now...
On Fri, Oct 14, 2016 at 6:45 AM, Deven Phillips
wrote:
> Here's hoping someone can help me... Overnight, our primary database
> server (part of a master/slave repl
in advance!
Deven Phillips
Thanks for the confirmation. Unfortunately, I will need to handle more
complex situations. I will look into creating a recursive subroutine to
handle things.
On Sep 23, 2016 5:12 PM, "Vitaly Burovoy" wrote:
On 9/23/16, Deven Phillips wrote:
> On Fri, Sep 23, 2016 at 10:14 AM, D
Actually, it looks like I have to create all of the parent objects first
before it would work... Is that correct?
Deven
On Fri, Sep 23, 2016 at 10:14 AM, Deven Phillips
wrote:
> Is there a way to set a nested element for which the parent paths do not
> yet exist?
>
> For example,
Is there a way to set a nested element for which the parent paths do not
yet exist?
For example, if I have a JSONB value called 'data':
{
"foo": "bar"
}
and run
jsonb_set(data, {'boo', 'baz'}, 'newvalue')
I would expect the output to be:
{
"foo": "bar",
"boo": {
"baz": "ne
NVM, a quick search through the output of `\dfS` showed me the
`pg_listening_channels()` function, which returns a TEXT[] of currently
subscribed channels.
Cheers,
Deven
On Sat, Sep 17, 2016 at 8:45 AM, Deven Phillips
wrote:
> From a connection which has previously executed a LIS
>From a connection which has previously executed a LISTEN
statement, is there a query which I can run which will tell me if it is
still listening on those channels?
Thanks in advance!!
Deven Phillips
l changes from
the temp table?
I've tried to use a simple case:
UPDATE target AS d SET data=jsonb_set(d.data, n.path, is_valid::JSONB, true)
> FROM temp_table n
> WHERE d.time_inserted=n.time_inserted AND d.data->>'id'=n.id
But this results in just the first update for a given PK being applied.
Any assistance would be appreciated!!!
Deven Phillips
lps others!!!
Deven
On Wed, Feb 17, 2016 at 10:47 AM, Deven Phillips
wrote:
> I have a "user" document with a key "tokens" and I would like to write a
> stored procedure for adding new token key-value pairs to the "tokens" part
> of the tree without remov
ted)
WHERE
email=$1
)
SELECT jsonb_pretty(token) FROM newtoken $$
LANGUAGE SQL;
Thanks in advance!!!
Deven Phillips
Thanks all!
On Feb 13, 2016 11:06 PM, "Tom Lane" wrote:
> Vitaly Burovoy writes:
> > On 2/13/16, Deven Phillips wrote:
> >> I'm trying to convert a series of ISO8601 strings into TIMESTAMPs for
> use
> >> with a function: ...
>
> > If you
I'm trying to convert a series of ISO8601 strings into TIMESTAMPs for use
with a function:
CREATE OR REPLACE FUNCTION v1_nexus_vlan_count(id TEXT, start_time
TIMESTAMP, end_time TIMESTAMP)
RETURNS TEXT AS $$
SELECT jsonb_pretty(jsonb_agg(row_to_json(datapoints))) AS data_array FROM (
SELECT
da
upposed to!!!
Deven
On Sat, Jan 9, 2016 at 12:06 AM, Deven Phillips
wrote:
> I think that I may have found the problem. It looks like the mysql_fdw
> uses the following query to gather information about the foreign schema:
>
> SELECT
> t.TABLE_NAME,
> c.COLUMN_NAME,
> CAS
= c.TABLE_NAME
WHERE
t.TABLE_SCHEMA = '%s'
When I poked around inside of MySQL that t.TABLE_CATALOG and
c.TABLE_CATALOG values are NULL. Trying to compare NULLs in MySQL using an
equals sign (=) results in a "FALSE" and thus the "JOIN" does not provide
an actual linkage.
Additional details. The MySQL server I am targeting is running
version 5.1.73. Perhaps it's too old of a version to support foreign schema
import?
Deven
On Fri, Jan 8, 2016 at 11:45 PM, Deven Phillips
wrote:
> I DID get a foreign table to work using the following:
>
> CREATE
as subsequently able to query that table from PostgreSQL..
I tried to add the "OPTIONS" to the IMPORT FOREIGN SCHEMA and got an error
that "dbname" is not a valid parameter.
Thanks,
Deven
On Fri, Jan 8, 2016 at 11:38 PM, Deven Phillips
wrote:
> Apparently not, though I hav
> On 01/08/2016 07:04 AM, Deven Phillips wrote:
>
>> Hi all,
>>
>> I installed the newly released PostgreSQL 9.5 this morning and
>> compiled the latest mysql_fdw extension from EnterpriseDB. I was able to
>> create the SERVER and USER MAPPING, but I ca
Hi all,
I installed the newly released PostgreSQL 9.5 this morning and compiled
the latest mysql_fdw extension from EnterpriseDB. I was able to create the
SERVER and USER MAPPING, but I cannot seem to get IMPORT FOREIGN SCHEMA to
do anything. The command executes without error, but none of the
For this purpose, I have seen it recommended to use a UUID instead of a
randomly generated integer. I do this myself for production applications
and over millions of records I have yet to log a conflict. Also, as stated
above, you could create a plpgsql function which would achieve exactly what
you
blem I am having
is that I cannot put the results of multiple tables into a single
array_add() call. How can I aggregate multiple joined tables into a single
array?
Thanks again for the help!!
Deven
On Mon, Mar 30, 2015 at 10:25 PM, Deven Phillips
wrote:
> I have already attempted a simi
51
Is there some way to make that value available to the inner select?
Thanks in advance!
Deven
On Mon, Mar 30, 2015 at 5:46 PM, Merlin Moncure wrote:
> On Mon, Mar 30, 2015 at 4:22 PM, Deven Phillips
> wrote:
> > I'm using PostgreSQL 9.4.1 on Ubuntu 14.10.
> >
&g
true)), true)
FROM (
SELECT DISTINCT * FROM virtual_interfaces WHERE vmid=vm_id) i
INTO res;
RETURN res;
END;
$$ LANGUAGE PLPGSQL;
Thanks for any help!
Deven
On Mon, Mar 30, 2015 at 3:25 PM, Merlin Moncure wrote:
> On Mon, Mar 30, 2015 at 6:27 AM, Deven Phillips
> w
res;
END;
$$ LANGUAGE PLPGSQL;
On Mon, Mar 30, 2015 at 5:22 PM, Deven Phillips
wrote:
> I'm using PostgreSQL 9.4.1 on Ubuntu 14.10.
>
> The function does the following:
>
> DROP FUNCTION get_vm_with_interfaces(vm_id BIGINT);
>
> CREATE OR REPLACE FUNCTION get_virtu
quot;template_name":"",
"self":"https://mysite.mydomain.tld
/v3/customer/3mcc/vdc/1241/vm/421ea391-b292-ca2e-9a3a-6da3037748c8",
"type":"cc.v3.vm",
"interfaces":[
{"vlan": null,
"vmid": 114778,
"order&
Hi all,
I have a query which selects several rows of data, and contained in one
of those rows is some aggregated JSON data. I am using row_to_json() to
make the whole output JSON and I am providing "true" for pretty formatting
of the JSON. The problem that I am seeing is that they nested JSON
Nevermind, it works exactly as I would have expected and it is the exact
speed improvement I needed!
Deven
On Mon, Mar 30, 2015 at 10:12 AM, Deven Phillips
wrote:
> To prevent multiple foreign table scans during queries, I would like to be
> able to create an FDW against a VIEW in a f
To prevent multiple foreign table scans during queries, I would like to be
able to create an FDW against a VIEW in a foreign MySQL database. Is this
possible?
Thanks in advance!
Deven
I have a multi-table join which will return 1 row per "interface" and I
would like to aggregate the interfaces as a nested section on the resulting
JSON output. Could someone help me to figure out how to accomplish that?
Example:
SELECT row_to_json(row) AS json
> FROM (
> SELECT
> c.s
OK, one of the devs on the GitHub page for that FDW helped me realize that
I had accidentally mapped the wrong table! Doh!
Deven
On Fri, Mar 27, 2015 at 5:31 PM, Adrian Klaver
wrote:
> On 03/27/2015 02:20 PM, Deven Phillips wrote:
>
>> Yes. Here's the MySQL schema:
&
72184 DEFAULT CHARSET=latin1
On Fri, Mar 27, 2015 at 5:19 PM, Adrian Klaver
wrote:
> On 03/27/2015 01:55 PM, Deven Phillips wrote:
>
>> Better example of the problem... My FDW table schema is:
>>
>> CREATE FOREIGN TABLE liquorstore_backendipaddress
s;
ERROR: failed to prepare the MySQL query:
Unknown column 'backend_network_id' in 'field list'
I still cannot figure out what the problem might be so any help would be
GREATLY appreciated.
Thanks,
Deven
On Fri, Mar 27, 2015 at 4:15 PM, Deven Phillips
wrote:
> I am trying
OK, then I will look into perhaps implementing it as a pl-python or pl-java
function. Thanks for the advice!!
Deven
On Fri, Mar 27, 2015 at 2:40 PM, Merlin Moncure wrote:
> On Fri, Mar 27, 2015 at 1:36 PM, Arthur Silva wrote:
> > On Fri, Mar 27, 2015 at 1:56 PM, Deven Phillips <
&
I am trying out some ideas using FDW, and I have added some FDW tables
which access a backend MySQL DB... Unfortunately, I am getting some errors
because of fields names with reserved words. I was wondering if there is a
way to "alias" a field name when creating the foreign table?
Thanks in advanc
Are there any plans or ideas about implement JSON Patch (
http://jsonpatch.com/) support for PostgreSQL? We deal with some relatively
large JSON documents for our in-house application and it is often better to
just send a json-patch update rather than the full document. It would be
very nice if we
35 matches
Mail list logo