Data dodania Pytanie
2017-03-17 16:03 PostgreSQL index search on JSONB type »
I have a postgres database with tables like this: CREATE TABLE state ( id SERIAL, keys JSONB NOT NULL ); CREATE INDEX keys_idx ON state (keys...
(0) odpowiedzi
2017-03-17 00:03 Ruby Sequel dirty status on json column not working using Postgresql »
Using sequel 4.29.0. I'm planning to use the before_save sequel hook to trigger an action, In this case I need to make sure if an specific column ch...
(1) odpowiedzi
2017-03-16 17:03 namedParameterJdbcTemplate batchUpdate vs INSERT INTO SELECT »
I'm performing an experiment where I want to see what approach to inserting multiple records into a PostgreSQL database is going to give me the best s...
(0) odpowiedzi
2017-03-16 12:03 Should I prefer ->> or @> »
In postgreSQL on a JSONB column I can run two queries with the same (?) result. Query 1: SELECT * FROM a WHERE b->>'c' = 'lorem'; Query 2: ...
(3) odpowiedzi
2017-03-15 09:03 Postgres jsonb, nested array querying to hide specific fields »
I have a jsonb data of following format, with nested arrays { "outerArray": [ { "price": { "amount": 108.95, "currencyCod...
(1) odpowiedzi
2017-03-14 23:03 postgresql convert jsonb to set of records »
Having issue with transforming jsonb to desired table type, any help would be appreciated. My jsonb is: {"left": ["ICMB", "IPERIOD", "IADDR", "KV"]}...
(1) odpowiedzi
2017-03-14 22:03 GROUP BY query slower when the data is in JSONB vs JSON »
In a Postgres 9.5 db I have 111K+ rows of data, and on the below group by query I noticed that there was a significant performance difference. SELEC...
(0) odpowiedzi
2017-03-14 18:03 Substring search on JSON data (ERROR: cannot extract element from a scalar) »
I've been looking at this tutorial and this example trying to find a performant way to query by substring with JSON (<9.5)/JSONB (*9.5) data. For ...
(1) odpowiedzi
2017-03-13 22:03 How to get value of a key inside an jsonb array in postgres and JOIN »
I have data that looks like inside a json table in postgres with a column called content has data similar to {schd:[{key1:val1, key2:val2}]} The w...
(1) odpowiedzi
2017-03-09 02:03 Using jsonb_accessor gem, how I can I receive the params in my controller from a form? »
I have the gem working with about 30 fields on a Form model. class Form < ApplicationRecord jsonb_accessor :fields, salutation:...
(0) odpowiedzi
2017-03-09 00:03 Injecting JSON parameter in nativeQuery - Spring JPA »
This works when @Query(value = "SELECT * FROM person WHERE school = :schoolId AND details @> '{\"id\":\"1234\",\"name\":\"John\"}'", nativeQuery ...
(1) odpowiedzi
2017-03-08 21:03 Postgres JSON array contains given array element »
I have been searching for this answer for long on stackoverflow, but did not find anything useful. I have data in my_tbl as: folder_id | links ...
(1) odpowiedzi
2017-03-05 23:03 Postgres JSONB support on zend/Db Zend Framework 3? »
how can i work with JSONB (postgresql) in zend framework 3?. for example i want make query's like this SELECT id, data->'title' AS title, data-&g...
(0) odpowiedzi
2017-03-03 22:03 Select matching element from jsonb in Postgres »
I have the the table orders which contains a column called stores with a jsonb with many elements like id status stores 1 in progress [...
(2) odpowiedzi
2017-03-01 23:03 string creating for jsonb query using psycopg2 »
I have following query with works in db SELECT count(*) as count FROM data WHERE name ='user' AND dt > date_trunc('month', current_timestamp...
(1) odpowiedzi
2017-03-01 00:03 Check that a jsonb object's keys are a subset of an allowed set »
I have a simple table with a jsonb column: CREATE TABLE products ( id serial NOT NULL PRIMARY KEY, type varchar(20) NOT NULL, details jso...
(0) odpowiedzi
2017-02-28 18:02 Rails PostgeSQL jsonb collections »
I have 2 models associated with a has many financial events belonging to a single order. In the financial events model there is a jsonb column named e...
(0) odpowiedzi
2017-02-28 17:02 jsonb aggegation in postgres select queries »
Given the following table: # create table thing (id serial, tags jsonb); # \d thing Table "public.thing" Column | Type |...
(0) odpowiedzi
2017-02-28 08:02 Optimizing Postgres JSONB query with not null constraint »
I've got a Postgres 9.4.4 database with 1.7 million records with the following information stored in a JSONB column called data in a table called acco...
(3) odpowiedzi
2017-02-25 20:02 PostgreSql Queries treats Int as string datatypes »
I store the following rows in my table ('DataScreen') under a JSONB column ('Results') {"Id":11,"Product":"Google Chrome","Handle":3091,"Description"...
(2) odpowiedzi
2017-02-24 20:02 Update data of array json »
MyTable id | data ___________ 1 |[{"Session1": "", "DeviceId1": ""}, {"Session2": "", "DeviceId2": ""}] I want update data and set Session1 equ...
(2) odpowiedzi
2017-02-24 17:02 Postgresql query dictionary of objects in JSONB field »
I have a table in a PostgreSQL 9.5 database with a JSONB field that contains a dictionary in the following form: {'1': {'id': 1, 'length': 24,...
(1) odpowiedzi
2017-02-24 09:02 multiply a value of each item of a json array with postgres 9.6 »
I tried many different things that I gathered here and there (official docs, blog posts, SO, …) but didn't succeed, so here's my question to you all...
(2) odpowiedzi
2017-02-23 14:02 Filter on values of json object »
I have a table with a jsonb column: CREATE TABLE test( id serial primary key, data jsonb ); insert into test (data) values( ({"a" : 1,"b" : 2,"r...
(2) odpowiedzi
2017-02-22 23:02 Flattening Postgres nested JSONB column »
I'm looking to see how to flatten data nested in a JSONB column. As an example, say we have the table users with user_id(int) and siblings(JSONB) Wit...
(1) odpowiedzi
2017-02-21 16:02 Extracting values from JSONB in Postgresql »
I have a table (users) in which I store different columns, one of them being a jsonb column named content. The other columns don't matter because they...
(1) odpowiedzi
2017-02-20 17:02 Dapper jsonb custom handler not accepting nulls »
I have a database field of type jsonb and I would like to handle it with Dapper. public class Customer { [Column(Name = "id")] public int id { g...
(0) odpowiedzi
2017-02-19 09:02 PostgreSql Querying Array Values »
I have the following JSON format stored as JSONB column in postgresql. {DisplayName":"Bob marley","FName":"Bob","Title":null,"LName":"Marley","State"...
(1) odpowiedzi
2017-02-18 00:02 Convert JSONB Array to Columns »
I have a query that returns a single column containing jsonb objects. Here is an example of some returned rows (jsonb::text for legibility here): [{...
(1) odpowiedzi
2017-02-17 19:02 Modify datatype of a field in JSONB in Postgres »
I have a JSONB column with JSON that looks like this: {"id" : "3", "username" : "abcdef"} Is there way to update the JSON to : {"id" : 3, "u...
(2) odpowiedzi
2017-02-17 14:02 Removing element from array within object JSONB »
I am attempting to remove an element from my database. The element I want to remove is within a JSON object called playerContainer which contains an a...
(1) odpowiedzi
2017-02-16 12:02 ActiveRecord & Postgresql: Query jsonb attribute »
I have a model Characteristic, with a equivalent attribute which is a jsonb value. ex: characteristic1: id:1 equivalent: {list: ['first', 'second'...
(1) odpowiedzi
2017-02-16 05:02 Flattening a nested json[b] array in Postgres »
I have jsonb column feeds with data in the form of this: [{ "id": 99999999, "lang": "pt", "entities": { "urls": [], "media": [{ "...
(2) odpowiedzi
2017-02-15 19:02 Use JSONB for postgres columns other than primary and foreign keys »
I just discovered JSONB for PostgreSQL and was wondering what could go wrong if I used it for all my tables' columns ? That is to say all my tables w...
(1) odpowiedzi
2017-02-14 19:02 Appending (pushing) and removing from a JSON array in PostgreSQL 9.5+ »
For versions less than 9.5 see this question I have created a table in PostgreSQL using this: CREATE TEMP TABLE jsontesting AS SELECT id, jsondata...
(1) odpowiedzi