Expert academic support · 100% original work · 24/7 help 24/7 support: support@treatisely.com
Uncategorized

Week 11 SQL LAB : Randomize re_HouseSale DATES Wednesday, January 4, 2023, 10:07

  • Posted
  • AuthoradminX
  • Length102 words
  • Reading time1 min

Week 11 SQL LAB : Randomize re_HouseSale DATES
Wednesday, January 4, 2023, 10:07 AMNumber of replies: 0
1. Check your re_HouseSale table : ( week 10 Homework )
SaleDate must be Date
Price must be a number
2. Randomize SaleDate in re_HouseSale table in your database :
200 records 60 Month forward,
150 records 75 Month forward,
170 records 8 years back,
300 records 5 years back.
HINT : use date_add() and date_sub() functions, use “limit 200” to specify number of records,
update records with year (sales_date) = 2008 only
example:update re_HouseSale set SaleDate = date_add( SaleDate, interval 5 year)
where year(SaleDate) = 2008 limit 200;
3. Display the number distinct ( unique) years in your re_HouseSale table.
Post your SQL for feedback

adminX

Subject expert at Treatisely.

Make your next academic task easier to manage

Tell us what you are working on and take the next step with Treatisely.

Submit your assignment free