It depends on what you want to store.
Concerning the gamestate
For action games (as opposed to turn by turn games) you will need to run the gamestate at a decent speed (for performance) and more importantly for the player's experience you will have to update the clients regularly (multiple times per second).
Therefore a solution based on a C/C++ server would be preferable. But in the end any language able to provide good performance and proper network socket communication is fine.
The data should be stored in memory during the game session with eventual saves to the server's disks during the session or when players disconnect if you want persistent or semi-persistent game worlds.
You can use SQL to store data if most of it is relational. But if you want to store the gamestate and things that are better stored/retrieved in binary form then you will be better off storing the "save games" in files as you would on the clients.
Non action games and other data
If you have a lot of relational data, data about players, about game sessions, results, etc, then you can use an SQL database.
When it comes to turn based games, leaderboards and non gamestate related features any scripting language and database will do. But this is a separate subject.