0
使用fql從java代碼返回的start_time值不同於從圖形瀏覽器返回的值。facebook事件start_time沒有返回正確的值
FQL:
fql?q={"events":"SELECT eid, name,description, start_time, end_time, pic_small,pic_big, eid,venue,location from event WHERE eid in (SELECT eid FROM event_member WHERE uid = me() and start_time > 1347482366)" ,"locations":"select page_id,location from page where page_id IN (select venue.id from #events)" ,"rsvpStatus":"select eid, rsvp_status from event_member where eid IN (select eid from #events) AND uid = me()"}
Java代碼的結果:
{
"data": [
{
"name": "events",
"fql_result_set": [
{
"eid": 495493753795633,
"name": "Yo yo party",
"description": "",
"start_time": **1347656400**,
"end_time": **1347670800**,
"pic_small": "http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v2\/yy\/r\/XcB-JGXohjk.png",
"pic_big": "http:\/\/profile.ak.fbcdn.net\/static-ak\/rsrc.php\/v2\/yn\/r\/5uwzdFmIMKQ.png",
"venue": {
"id": 154409375600
},
"location": "PIKE PLACE FISH MARKET"
}
]
},
{
"name": "locations",
"fql_result_set": [
{
"page_id": 154409375600,
"location": {
"street": "86 Pike Place",
"city": "Seattle",
"state": "WA",
"country": "United States",
"zip": "98101",
"latitude": 47.608639747653,
"longitude": -122.3405485174
}
}
]
},
{
"name": "rsvpStatus",
"fql_result_set": [
{
"eid": 495493753795633,
"rsvp_status": "attending"
}
]
}
]
}
圖探險結果:
{
"data": [
{
"name": "events",
"fql_result_set": [
{
"eid": 495493753795633,
"name": "Yo yo party",
"description": "",
"start_time": "**2012-09-14T14:00:00-0700**",
"end_time": "**2012-09-14T18:00:00-0700**",
"pic_small": "http://profile.ak.fbcdn.net/static-ak/rsrc.php/v2/yy/r/XcB-JGXohjk.png",
"pic_big": "http://profile.ak.fbcdn.net/static-ak/rsrc.php/v2/yn/r/5uwzdFmIMKQ.png",
"venue": {
"id": 154409375600
},
"location": "PIKE PLACE FISH MARKET"
}
]
},
{
"name": "locations",
"fql_result_set": [
{
"page_id": 154409375600,
"location": {
"street": "86 Pike Place",
"city": "Seattle",
"state": "WA",
"country": "United States",
"zip": "98101",
"latitude": 47.608639747653,
"longitude": -122.3405485174
}
}
]
},
{
"name": "rsvpStatus",
"fql_result_set": [
{
"eid": 495493753795633,
"rsvp_status": "attending"
}
]
}
]
}
這裏有問題:
- 時間格式差異
- 返回到java代碼的start_time和end_time不正確。當我轉換unix時間戳時,事實上比實際事件開始和結束時間少了一個小時。
這是一個已知的問題嗎?任何信息將非常感激。