Indexes in Strapi

I have a number of relations in my tables stored in Strapi. I was wondering whether Strapi creates indexes over the foreign keys automatically, or will I need to do that? Also, say I want to create an index on createdAt field so that my sorts do take advantage of it. How can I do that? I’m using postgresql with strapi.

This topic has been created from a Discord post (1287751367066259500) to give it more visibility.
It will be on Read-Only mode here.
Join the conversation on Discord

How is it hard to find an answer for such a simple question?

Strapi (on v4) does indexing on id only automatically, there is no known way to add indexing to other attributes

^ exactly as ant said, we don’t have a way to add custom indexes

Also watch your tone, this is a community discord, people here are donating their time.

If you feel entitled to an answer you can go elsewhere

<@632956853122236457> thank you for answering the question. Never really expected that such a feature isn’t available already.

<@211722558385553408> I’m sorry if I came off as entitled. It was just a burning question I had. Sorry once again.