0

Timestamp conversion

The Yahoo! Finance CSV API has a strange timezone offset and timestamp format:

CODE
select * from csv where url='http://download.finance.yahoo.com/d/quotes.csv?s=YHOO,GOOG,AAPL&f=sl1d1t1c1ohgv&e=.csv' and columns='symbol,price,date,time,change,col1,high,low,col2'

{
"symbol": "\"YHOO\"",
"price": "14.02",
"date": "\"4/29/2009\"",
"time": "\"4:00pm\"",
"change": "+0.38",
"col1": "13.74",
"high": "14.35",
"low": "13.70",
"col2": "15937403"
},


Is it possible to convert the date/time fields into UTC timestamps, using the format: YYYY-MM-DD HH:MM:SS ?

by
1 Reply
  • Please try the new "execute" functionality in our open data tables - this is exactly one of the things its designed to help you do.

    You can call the csv table using y.query and then make use of the Javascript date object to parse and reformat it as you'd like.

    Jonathan
    0

Recent Posts

in YQL