Below code can be used in controller:
const knex = strapi.connections.default;
const result = await knex('articles_tags__tags_articles as atta')
.where('tag_id', 2)
.join('articles', 'atta.article_id', 'articles.id')
.select('articles.*')
https://docs-v3.strapi.io/developer-docs/latest/development/backend-customization.html#queries
Top comments (0)