I was using the above fql query for getting the count of friends. It has been working for me for quite some time. [Javascript SDK ]

But now it gives the following error message,

{"error":{"message":"(#604) Your statement is not indexable. The WHERE
clause must contain an indexable column. Such columns are marked with
* in the tables linked from http://developers.facebook.com/docs/reference/fql ",
"type":"OAuthException"}}

I tried copying this query and pasting it in graph api explorer tool and it works perfectly fine.

I have checked the FQL reference for user and uid is still an indexable column.

I have checked the blogs for breaking changes, but there are none mentioned regarding fql.
Any idea why this is not working anymore ? And any other way to get this working ?

Thanks for the answer. Actually since I am using a javascript sdk I don't explicitly manage the access token. And doesn't the sdk automatically manage the access token ? anyways I'll look more into the authentication token.
–
BSTJan 28 '12 at 7:43

I have checked the authentication token, by using getLoginStatus() and the response gives a valid auth token and also the status saying connected. I also am not using the quotes either :-) Actually this piece of code was working just a couple of weeks ago. Surprisingly using the Graph API Explorer still works, wonder what is wrong with the Javascript SDK. Just to make sure I also tried enabling the https for the web server, but still nothing. Worst case I'll have to rewrite the code to just get the response from graph.facebook.com/fql..
–
BSTJan 28 '12 at 8:31

1

What browser are you using? (Chrome, IE, Safari have built in developer tools and Firefox has the FireBug plugin) You can monitor your network traffic to see the exact call the FB JS SDK is sending as well as the exact response from the API. Maybe your answer lies there. :)
–
DMCSJan 28 '12 at 8:34

Wow ! That was a good idea :-) And I think I see the problem now, when I saw the request that was being sent it is truncating the =XXX. graph.facebook.com/… friend_count FROM user WHERE uid&sdk=joey
–
BSTJan 28 '12 at 9:32

Wow I am jumping with joy !! :-) I replaced my query with fql?q=SELECT friend_count FROM user WHERE uid%3DXXXX and it works :-) I tried encoding the whole string but it was giving some other exception. So do you think the FB guys need to look into this ? Actually I have already raised a bug with them, now if it is their problem I'll just update it otherwise I shall have to close it.
–
BSTJan 28 '12 at 9:35