Could somebody post a better solution?

What if you get a db that did not tell you the version number? What are you gonna do?