Their software is commercial but the database schema is completely viewable once installed
This is exactly the same case of a commercial product where the code source is viewable. Which is by the way the case of most applications: you can decompile them and have an idea of the source code they use.
In the exactly same way, the data used by some applications add value to those apps, but can be easily extracted. For example, textures in a video game add value and are often very expensive to create, but are mostly stored as a set of JPEGs in an archive.
You have to understand that in the three cases, the fact that you can view something does not authorize you to use it.
Some companies will try to invent some techniques to prevent the users with less technical background from accessing database schema, source code or data by using encryption or obfuscation. Other companies will just say that it is forbidden, and sue people who annoy them the most.
In a case of game textures, for example, I don't risk too much if I use some just for me, even if it's prohibited. If, on the other case, I am a large company and will use those textures in my own game with lots of sales, chances are the case will end in a court.
So to answer your question:
What's the legality of basing my product of the same database schema and just potentially renaming columns and tables and maybe removing one or two things?
This is probably illegal, depending on the license of the product you want to copy the schema from.