cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

The PTC Community email address has changed to community-mailer@ptc.com. Learn more.

Search Thing by identifier

seanccc
17-Peridot

Search Thing by identifier

Hi,

Everything can be searched by its identifier. I used to think that this field is indexed. But recently noticed that this field does not have any index in the table thing_model. Is this correct ?

 

Regards,

Sean

1 ACCEPTED SOLUTION

Accepted Solutions
yhan
17-Peridot
(To:seanccc)

Hi @seanccc,

 

After checking twx postgresql database instance, the thing_model table has two below indexes, I think the identifier column value of the thing_model table can be the same in multiple rows and also can be null, so twx doesn't create an index for it OOTB.

  •  CREATE UNIQUE INDEX thing_model_pkey ON twx_schema.thing_model USING btree (entity_id)
  • CREATE UNIQUE INDEX thing_model_name_ukey ON twx_schema.thing_model USING btree (name)

 

 

Thanks,

/Yoyo

View solution in original post

2 REPLIES 2
yhan
17-Peridot
(To:seanccc)

Hi @seanccc,

 

After checking twx postgresql database instance, the thing_model table has two below indexes, I think the identifier column value of the thing_model table can be the same in multiple rows and also can be null, so twx doesn't create an index for it OOTB.

  •  CREATE UNIQUE INDEX thing_model_pkey ON twx_schema.thing_model USING btree (entity_id)
  • CREATE UNIQUE INDEX thing_model_name_ukey ON twx_schema.thing_model USING btree (name)

 

 

Thanks,

/Yoyo

slangley
23-Emerald II
(To:seanccc)

Hi @seanccc.

 

If you are satisfied with the response you received, please mark the previous post as the Accepted Solution for the benefit of others with the same question.

 

Regards.

 

--Sharon

Top Tags