Re: Indexing on JSONB field not working - Mailing list pgsql-bugs

From Zhihong Zhang
Subject Re: Indexing on JSONB field not working
Date
Msg-id E0F0CF2B-46DB-425C-9338-0FA59561B6B6@gmail.com
Whole thread Raw
In response to Re: Indexing on JSONB field not working  (Jeff Janes <jeff.janes@gmail.com>)
Responses Re: Indexing on JSONB field not working
List pgsql-bugs
That command yields nothing. If I use the tablename ‘assets’, it only returns stats on columns, nothing about indexes. The indexed field is in JSONB field ‘_doc’. This is the stats on the column,

select * from pg_stats where tablename='assets' and attname='_doc';
schemaname | tablename | attname | inherited | null_frac | avg_width | n_distinct | most_common_vals | most_common_freqs | histogram_bounds | correlation | most_common_elems | most_
common_elem_freqs | elem_count_histogram
------------+-----------+---------+-----------+-----------+-----------+------------+------------------+-------------------+------------------+-------------+-------------------+------
------------------+----------------------
public | assets | _doc | f | 0 | 18 | -1 | | | | | |
|
(1 row)

Let me know if you want any other information.

Zhihong


On Dec 21, 2019, at 10:17 AM, Jeff Janes <jeff.janes@gmail.com> wrote:

Can you show the output of:

select * from pg_stats where tablename ='float_number_index_path2'

For readability, use the output format which shows the columns down the screen, not across.  In psql, that would toggled on with \x.


pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: Indexing on JSONB field not working
Next
From: Jeff Janes
Date:
Subject: Re: Indexing on JSONB field not working