Reference no: EM132250982
Assignment -
Using the Colonial database, create the following Stored Procedure - CreateDynamicTripAd.
This procedure will take in a Trip Id as a parameter and perform the following:
It will return a result set with the following info
- Trip Id
- Trip Name
- Season
- Average Reservation Price
- Number of Reservations
- Most positive review note
Reviews are stored in a table called Trip reviews. The table contains the columns
Trip Id, rating from 1 to 5 , date of review and a review Note.
Assuming all columns are filled with data.
The procedure will also update a new table named TripAds which keeps track of the ad count generate for this trip, the trip Id and last time it was updated.
Note: For this exercise, create the following tables:
TripReviews
- TripId
- rating
- reviewNote
- dateofreview
TripAds
- TripID
- ad count
- dateof generation
Complete the assignment Using Microsoft Server SQL Server Management Studio 17 And MySQL (php my Admin).
Attachment:- Assignment Files.rar