-
Notifications
You must be signed in to change notification settings - Fork 232
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add improvements to the petdesk sample application
- Loading branch information
1 parent
c4507f3
commit 54cbea8
Showing
5 changed files
with
71 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
32 changes: 32 additions & 0 deletions
32
petcare-sample/b2c/web-app/petdesk/dbscripts/pet-management.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
CREATE TABLE Pet ( | ||
id VARCHAR(255) PRIMARY KEY, | ||
name VARCHAR(255) NOT NULL, | ||
breed VARCHAR(255) NOT NULL, | ||
dateOfBirth VARCHAR(255) NOT NULL, | ||
owner VARCHAR(255) NOT NULL | ||
); | ||
|
||
CREATE TABLE Vaccination ( | ||
id INT AUTO_INCREMENT PRIMARY KEY, | ||
petId VARCHAR(255) NOT NULL, | ||
name VARCHAR(255) NOT NULL, | ||
lastVaccinationDate VARCHAR(255) NOT NULL, | ||
nextVaccinationDate VARCHAR(255), | ||
enableAlerts BOOLEAN NOT NULL DEFAULT 0, | ||
FOREIGN KEY (petId) REFERENCES Pet(id) ON DELETE CASCADE | ||
); | ||
|
||
CREATE TABLE Thumbnail ( | ||
id INT AUTO_INCREMENT PRIMARY KEY, | ||
fileName VARCHAR(255) NOT NULL, | ||
content MEDIUMBLOB NOT NULL, | ||
petId VARCHAR(255) NOT NULL, | ||
FOREIGN KEY (petId) REFERENCES Pet(id) ON DELETE CASCADE | ||
); | ||
|
||
CREATE TABLE Settings ( | ||
owner VARCHAR(255) NOT NULL, | ||
notifications_enabled BOOLEAN NOT NULL, | ||
notifications_emailAddress VARCHAR(255), | ||
PRIMARY KEY (owner) | ||
); |