We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The example shows a one to many relationship between users and posts.
What happens if the relationship is one to one like user and work_address? where the latest instead of being an array should be a single object?
The text was updated successfully, but these errors were encountered:
The documentation shows an example of a one-to-one relationship between customers and addresses in the section "One To One". https://typesql.pages.dev/guides/nested-query-result/
In that case each user will have a single address object as shown below:
/* result type { id: number, full_name: string, address_id: number, address: { id: number, address: string, zip_code: string, city: string, state: string } }
Sorry, something went wrong.
No branches or pull requests
The example shows a one to many relationship between users and posts.
What happens if the relationship is one to one like user and work_address? where the latest instead of being an array should be a single object?
The text was updated successfully, but these errors were encountered: