You must be doing SQLi as your question suggests, well SELECT DB_NAME() should give you the current database. OR you can use sqlmap to know the current database with --current-db command. Sqlmap also has another powerful command "--os-shell" that can take over the server. Hope this might help and Best of luck.
222 questions
227 answers
401 comments
711,579 users