(Solved) : Write Sql Query Market Symbol Date Priceondate Example Data Market Table Data Market Table Q42684024 . . .

WRITE A SQL QUERY

Market(symbol,date,price_on_date)

Example data from Market table : //DATA THAT WILL BE IN THEMARKET TABLE

(IBM,03-14-2016,203.23)
(IBM,03-13-2016,203.03)
(IBM,03-12-2016,202.63)
(IBM,03-11-2016,203.27)
(IBM,03-08-2016,203.13)
(IBM,03-07-2016,202.53)

Write a SQL statement to compute the return generating output inthe following format:

(IBM,03-14-2016,203.23,0.00098508)   RTN =(203.33-203.03)/203.03 //SQL QUERY THAT SHOULD OUTPUT THIS
(IBM,03-13-2016,203.03,0.00197404)        (203.03-202.63)/202.63
(IBM,03-12-2016,202.63,-0.00314852)       (202.63-203.27)/203.27
(IBM,03-11-2016,203.27,0.00068921)         (203.27-203.13)/203.13
(IBM,03-08-2016,203.13,0.00365378)         (203.13-202.53)/202.53
(IBM,03-07-2016,202.53,0.00000000)          there is no IBM price available prior to this date

When price for aprior date is not available, use 0.00000000 asthe return.
minimum 8 significant digits — but you can output more digits ifyou wish.

Expert Answer


Answer to WRITE A SQL QUERY Market(symbol,date,price_on_date) Example data from Market table : //DATA THAT WILL BE IN THE MARKET T…

Leave a Comment

About

We are the best freelance writing portal. Looking for online writing, editing or proofreading jobs? We have plenty of writing assignments to handle.

Quick Links

Browse Solutions

Place Order

About Us

× How can I help you?