with reference to the fql stream table (https://developers.facebook.com/docs/reference/fql/stream/) i'm trying to get the created_time timestamp from the graph api explorer and it returns nothing when i use the 'type' table.
SELECT created_time FROM stream WHERE source_id={MY_GROUP_ID} AND type=11
is this a facebook bug or anything i missed? because when i use type=308 it successfully returns the created_time.
Thanks
Related
We have run a PowerBI subscription to generate visualisations report in PDF format we have get many errors like this
There is no data for the field at position x
The problem is we searched many times about it we found that it may occurred due to missing data in dataset.
But we have about 30 datasets with a query to oracle database we cannot figure out which is the missing data and the log does not mention which report causes the error.
Is there a way to figure out which field is missing?
Or is there a way to enrich the reports error log to give us which report failed?
A sample of exact error is repeated with different positions :
processing!ReportServer_0-8!1e18!02/07/2022-09:56:36:: e
ERROR: Throwing Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: , Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: There is no data for the field at position 29.;
Dears
I found a solution help me. I will share it.
The error is due to missing data, not missing values, which means the column name defined in the data set field has been changed in the database.
note:
When make the value equals null it will not give the same error; even if it is used in the report it will give a different error.
about how to detect ?
Simply install report builder in machine has connection to this database and open this report with report builder and make verify fields, it will give detailed error with the name of dataset fields not found so we tracked it in database we found it has been changed so fix it in either dataset or column name in database it fix the issue.
New challenge we are going to handle it either column name exist or changed to e, never get error and give empty report better as there is some database the report will connect may not have the same column names so it should give empty part of report instead of error.
thanks BR,
Get data for a specified date.
https://graph.facebook.com/v5.0/campaigns_id?fields=id,name,delivery_status,effective_status,status,spent,daily_budget,frequency,result,insights.time_range({'since':'2020-02-20','until':'2020-02-20'}){impressions,inline_link_clicks,cost_per_inline_link_click,cpm,inline_link_click_ctr}&access_token=XXXXX&time_range({'since':'2020-02-20','until':'2020-02-20'})
I get data for all the time.
How can I get data for a specified date ?
Time ranges can only be applied to "insights" edge here
You can achieve this with this call:
https://graph.facebook.com/v5.0/{your-campaign-id}?fields=id,name,effective_status,status,daily_budget,insights.time_range({'since':'2020-02-20','until':'2020-02-20'}){impressions,inline_link_clicks,cost_per_inline_link_click,cpm,inline_link_click_ctr}&access_token=XXXXX
You only need your first "time_range" in your query
I've created a function from a query that fetches the weather forecast from darksy.net API.
Basically, I pass the latitude and longitude as a single parameter to the query and I get a weather forecat.
The parameter is entered as text in the form of "lat,long". Eg: Lisbon is 38.736946,-9.142685
Everything works fine, the data is loaded into Power Query. However, when hitting "Close and Apply" button I get the error:
It seems the URL is adding E2%80%8E before the parameter.
I tried 2 differente APIs (darksy.net and http://api.openweathermap.org) and the problem happens in both.
Why is this? Can anyone help?
I am trying to integrate Facebook API to my web app. I want to check approximately when the user joined Facebook by querying earliest comment like following:
SELECT text, time FROM comment WHERE fromid= me() ORDER BY time ASC LIMIT 1
However, I got error saying:
"message": "Your statement is not indexable. The WHERE clause must contain an indexable column.
How can I fix this issue?
Thank you.
The comment table is for fb:comments, so you need to use the proper table first. This would be the status table. http://developers.facebook.com/docs/reference/fql/status.
SELECT status_id, message, time FROM status WHERE uid=me() ORDER BY time ASC LIMIT 1
But
What if the first post is from another user?
Then we should use the stream table. The first item in the news feed, should theoretically be after the date of joining (why show items before?) This is assuming the API holds all the data for the news feed.
So this will involve playing with streams, filter_keys and created_time
http://developers.facebook.com/docs/reference/fql/stream_filter
http://developers.facebook.com/docs/reference/fql/stream
A FQL query with a WHERE clause must include an indexable column, as shown in the docs for the table (they're now marked with a star, & shown in the Supported Base Where Clauses section).
fromid is not an indexable column so your WHERE clause can't be just a condition on this column.
I don't think it's possible to discover when a user joined Facebook via the Graph API or FQL; there's no property of the FQL User table that gives this, & the Graph API User schema is pretty close to the User table.
I'm looking to find old facebook posts using FQL. I tried this:
SELECT actor_id, message, created_time FROM stream
WHERE source_id = me() and (created_time>date1 and created_time<date2)
but even if the interval between date1 and date2 is only one day, it only returns a fraction of the posts. So, I tried chunking them, but even at 1 hour intervals it still doesn't quite get everything, and I quickly approach the 600 query limit for stream requests.
Is there a better way?
Have you tried using Graph API? Something like this should help you out with pages:
https://graph.facebook.com/PAGE_ID/feed?value=1&base_amount=1&limit=25&until=1332873234
To query your own posts the url is a bit different:
https://graph.facebook.com/USER_ID/home?value=1&base_amount=1&limit=25&since=1344348794",
You can test Graph API queries here:
https://developers.facebook.com/tools/explorer/?method=GET&path=40796308305%2Ffeed