-1

In the google spring cloud documentation, it is mentioned that

While one-to-one and many-to-many relationships can be implemented in Cloud Spanner and Spring Data Cloud Spanner using constructs of interleaved parent-child tables, only the parent-child relationship is natively supported.

Does anyone have a view about what this means? Does this mean google spring cloud advises us to use One To Many interleaved relationship even though data model always expects only one entry on the child side of the relationship? I noticed google cloud spring module has an open issue to support one to one relationship, but that is open for a while now.

TylerH
  • 20,799
  • 66
  • 75
  • 101
Rocky
  • 391
  • 7
  • 20

1 Answers1

1

This means that even while it is possible to construct a one-to-one relationship using interleaved tables, it is not advised because Cloud Spanner does not natively support it. It is advised to use a one-to-many connection instead, with the understanding that there will be just one entry on the kid side of the relationship.

You can visit the official documentation for best practices supplied by Cloud Spanner for more comprehensive information and recommended techniques for using it.

Chanpols
  • 1,184
  • 1
  • 3
  • 13