Database connection
Hey I have a mysql database, I can connect to it and run CRUD actions.
But I feel like the setup is wrong.
I have this function:
and I call the db for running queries.
But that means I create a connection on any query, what would be the correct way to connection the bot on startup and have a live connection?
But I feel like the setup is wrong.
I have this function:
and I call the db for running queries.
But that means I create a connection on any query, what would be the correct way to connection the bot on startup and have a live connection?
