Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I need to get a count of how many databases are living on my server. Should be a simple query, right?

share|improve this question

2 Answers 2

If you actually just want the count, and not a list you can also use a query like this.

SELECT count(*) FROM information_schema.SCHEMATA;
share|improve this answer
    
Thanks, y'all. For some reason google was not able to find anything useful. –  Matt Herzog Sep 3 '10 at 18:27

In mysql:


  show schemas;

Quick & simple.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.