You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
const photo: Photo = {
ID: photoID, // Photo ID is the same as the S3 object name
DatePosted: DateTime.now(),
LinkID: review.ID, // LinkID references the review
};
await createPhoto(photo);
Retrieving a review and its photo
Get the Review
SELECT * FROM Review WHERE ID=?
Get the Photos associated with the review. Review and photo is a one-to-many relationship
SELECT * FROM Photo WHERE ReviewID=?
Get the image file associated with the photo, using the photo ID