不工作我試圖檢索使用YQL從雅虎財務數據的選項。非常奇怪的問題是,我可以下載所需的選項信息用於其他符號如AAPL(蘋果)和MSFT(微軟),而不是歌(谷歌)。選項符號「GOOG」在YQL
這裏是我的查詢和結果。很明顯,我可以檢索AAPL和MSFT的數據,但是GOOG缺失。這不僅發生在yahoo.finance.option_contracts中,而且與所有其他與選項相關的表(包括yahoo.finance.options)發生。我非常確定這不是與查詢限制相關的事情,因爲下面顯示的查詢預計只能檢索到不到10次的GOOG結果。
select * from yahoo.finance.option_contracts where symbol in ('GOOG', 'AAPL', 'MSFT')
{
"query": {
"count": 2,
"created": "2014-03-03T15:00:45Z",
"lang": "en-US",
"diagnostics": {
"url": [
{
"execution-start-time": "0",
"execution-stop-time": "1",
"execution-time": "1",
"content": "http://www.datatables.org/yahoo/finance/yahoo.finance.option_contracts.xml"
},
{
"execution-start-time": "4",
"execution-stop-time": "1057",
"execution-time": "1053",
"content": "http://finance.yahoo.com/q/op?s=MSFT"
},
{
"execution-start-time": "5",
"execution-stop-time": "3571",
"execution-time": "3566",
"content": "http://finance.yahoo.com/q/op?s=AAPL"
},
{
"error": "Connect Failure",
"execution-start-time": "5",
"execution-stop-time": "10017",
"execution-time": "10012",
"content": "http://finance.yahoo.com/q/op?s=GOOG"
},
{
"error": "Connect Failure",
"execution-start-time": "5",
"execution-stop-time": "10017",
"execution-time": "10012",
"content": "http://finance.yahoo.com/q/op?s=GOOG"
}
],
"publiclyCallable": "true",
"javascript": [
{
"execution-start-time": "3",
"execution-stop-time": "1074",
"execution-time": "1070",
"instructions-used": "18571",
"table-name": "yahoo.finance.option_contracts"
},
{
"execution-start-time": "3",
"execution-stop-time": "3616",
"execution-time": "3612",
"instructions-used": "31142",
"table-name": "yahoo.finance.option_contracts"
},
"Exception: Read timed out, url: http://finance.yahoo.com/q/op?s=GOOG",
{
"execution-start-time": "3",
"execution-stop-time": "10017",
"execution-time": "10013",
"instructions-used": "31142",
"table-name": "yahoo.finance.option_contracts"
}
],
"user-time": "10018",
"service-time": "19447",
"build-version": "0.2.2157"
},
"results": {
"option": [
{
"symbol": "AAPL",
"contract": [
"2014-03",
"2014-04",
"2014-05",
"2014-06",
"2014-07",
"2014-10",
"2015-01",
"2016-01"
]
},
{
"symbol": "MSFT",
"contract": [
"2014-03",
"2014-04",
"2014-05",
"2014-06",
"2014-07",
"2014-10",
"2015-01",
"2016-01"
]
}
]
}
}
}
總之,每次我試圖檢索GOOG選擇數據的時候,我只得到空的結果與「讀超時」的錯誤。對於其他選項符號,如AAPL和MSFT,我可以得到我想要的。
任何人都知道這是爲什麼?
當我嘗試直接訪問[finance.yahoo鏈接](http://finance.yahoo.com/q/op?s=GOOG) –
時,出現「服務器掛斷」消息(我認爲現在只是一個善變的服務) –
Nah,我還沒有得到符號'GOOG'的結果。現在它不會說'讀取超時',但'結果'中沒有檢索到數據。這是服務器端問題嗎? – Dongsan