Pergunta de entrevista da empresa Indus Valley Partners

Write a SQL query to join two tables. Can these two tables be joined? Example of three classes in an inheritance chain; Had a var be of type first class and set it equal to be an instance of the second class, and asked which method would be used when called (from the first class, or the second class).