Connect relation in sql

Is it possible to connect relations via raw SQL statement e.g. jsstrapi.db.connection.raw() ?
The strapi system is too slow for what I want to do.

Thanks.

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

I found a way by debugging the db for tables, there are auto generated tables for relations.

If you query those, you can basically look at the foreigns key and then you just insert a entry with the ids of collection A and collection B

I will show a more sophisticated example later, but that’s the gist bascially.

I think this should be mentioned in the doc in case people need to do faster db operations in bulk