1.

List the different types of relationships in SQL.

Answer»
  • One-to-One - This can be defined as the RELATIONSHIP between two tables where each record in one table is ASSOCIATED with the MAXIMUM of one record in the other table.
  • One-to-Many & Many-to-One - This is the most commonly used relationship where a record in a table is associated with multiple records in the other table.
  • Many-to-Many - This is used in cases when multiple instances on both sides are needed for defining a relationship.
  • Self-Referencing Relationships - This is used when a table NEEDS to define a relationship with itself.


Discussion

No Comment Found