Assume a standard server-side Web application. Database, backend, frontend. It's basic knowledge that one should check the licences of the libraries used before deciding on the license for the final product. For example, if there is a GPL library used in the backend, the whole thing has to be made GPL.
But my question is: if the application runs on a database management system with a copyleft license, does this make the whole application copyleft? On the other hand, if the application runs on a closed source DBMS like Microsoft SQL server, does this mean that making the whole application open source is impossible, because it would be required of the authors to also give the Microsoft SQL server along with the rest of the code?
If it depends on how exactly the connection to the database is made, or how the product is distributed (e.g. does it have an installation file which installs a DBMS automatically), then what condition is important for the final judgment?