Lets say I would like to make a database of cars and their owners in RDBMS e.g. Postgres. Each car has a unique serial code (maybe some other properties e.g. brand, color etc.) and an owner. The owner could be a person (name, last_name, address) or could be a company (registration_id, company_name)
If cars could be owned only by persons I would just add a column in the cars table with a foreign key to person_id. How would one handle it in this situation though - should I somehow use inheritance for this?