What worked well for me was getting a job in a small industrial business with a lot of IOT sensors. This brought a lot of SQL queries to optimize...
Using tools like MySQL WorkBench or dBeaver is essential to try queries in a friendly interface (tools that show time spent on queries & better tables than command line). Ideally, you should also search for database normalization.
If you don't have a database to practice with, you can analyze a small business need (ex.: managing employee salary, address & tasks), then create the schema. Then, you should generate tons of fake data to have a substantial time difference when optimizing queries. Try selecting all employees and their tasks, with different sorts. Try finding all employees with an address that starts with 4. Find all employees with a "i" in their name and where the task name is "plumber", etc.
Also, read about rails/laravel migrations, as they are the best methods I know to manage database versions.
Comments
What worked well for me was getting a job in a small industrial business with a lot of IOT sensors. This brought a lot of SQL queries to optimize...
Using tools like MySQL WorkBench or dBeaver is essential to try queries in a friendly interface (tools that show time spent on queries & better tables than command line). Ideally, you should also search for database normalization.
If you don't have a database to practice with, you can analyze a small business need (ex.: managing employee salary, address & tasks), then create the schema. Then, you should generate tons of fake data to have a substantial time difference when optimizing queries. Try selecting all employees and their tasks, with different sorts. Try finding all employees with an address that starts with 4. Find all employees with a "i" in their name and where the task name is "plumber", etc.
Also, read about rails/laravel migrations, as they are the best methods I know to manage database versions.