Can you index elements of an array in Postgres?
I'm wondering if I can do something like
CREATE INDEX firstelement ON mytable (myarray[1]);
this part开发者_如何转开发icular syntax creates a syntax error.
Try this one, with extra parentesis:
CREATE INDEX firstelement ON mytable ((myarray[1]));
精彩评论