Is the stream table from the REST API incomplete? - facebook-graph-api

I'm trying to get all my wall information (status, photo tags, friends' posts, etc.) with the stream table.
But when I try to do that, a lot of information which is on my wall doesn't appear in the stream response.
For example, I can't get my December status.
Can someone help me?

From my experience, the stream table is incomplete. Using FQL to query the full table results in missing entries. A workaround is to query to original tables of the entries, e.g. the status table:
SELECT uid, status_id, time, source, message FROM status WHERE uid = me()
This is more complete. Obviously, you would have to query the photo table and others in parallel. In order to not loose too much time, you can batch the queries.
The stream table, however, seems to be fine for posts originating from friends.
A downside - apart from the multiple queries - is that the other tables don't have additional meta information about likes or comments, so these need to be retrieved in a second step then.

Related

Retrieving iCloud Note Tables Through Web Service But Table Cells Are Out Of Order In The Response

I've gone through some forensic analysis and implemented iCloud Account access programmatically (with authentication).
The problem I'm facing is that, when getting responses for Notes Table attachment, the table cells are out of order. E.g. sometimes the cells from the 2nd row appears first, and cells from the 1st row comes next. I couldn't find any meta data from which I can know the ordering of these cells.
FYI, I have decoded the attachment responses with Versioned-Document and Crframework protocall-buffer objects. If someone has worked with this technology or followed similar forensic analysis, can you help me getting order of the table cell data?
Thanks in advance.

Conditional Relationships between Two Tables in Django?

The following image shows a rough draft of my proposed database structure that I will develop for Django. Briefly, I have a list of ocean Buoys which have children tables of their forecast conditions and observed conditions. I'd like Users to be able to make a log of their surf sessions (surfLogs table) in which they input their location, time of surf session, and their own rating.
I'd like the program to then look in the buoysConditions table for the buoy nearest the user's logged location and time and append to the surfLog table the relevant buoyConditions. This will allow the user to keep track of what conditions work best for them (and also eventually create notifications for the user automatically).
I don't know what the name for this process of joining the tables is, so I'm having some trouble finding documentation on it. I think in SQL it's termed a join or update. How is this accomplished with Django?
Thanks!

Unable to update a Power BI table schema through the API with or without ApiaryIO

I am using Power BI API.
I've got a dataset with some tables and rows.
From Power BI API Console I don't have any issue when retrieving datasets or tables.
However the PUT verb on a table resource to update its schema always returns a 504 - Proxy request timed out
It's the first time I use Apiary IO so it might be its problem and not Power BI update, but that leads me to some questions:
Is there any workaround to test Power BI with, for example, Fiddler? I can type the url and body but I will need an Authorization header with the OAuth2 token if I'm not mistaken. How can I get that? ApiaryIO seems to hide it.
As per Update Schema Documentation the URL with the resource is https://api.powerbi.com/v1.0/myorg/datasets/{myDatasetId}/tables/{myTableName}
and the verb is a PUT. What is then the meaning of the "name": "???" parameter that goes in the JSON body? Is it the table's name or something else? I am assuming it's the table name but it seems redundant as I am already accessing the resource {myTableName} as per the given URL.
And my last related question is how to rename a specific table's column without modifying its data? This is what I'm trying to achieve by updating the schema but I don't understand how does Power BI know what column I am trying to rename.
Thank you!
Sorry that you're having trouble. You can get a token in two ways -the right way is to create an app in AAD (here's how). The wrong way ;) is to open the Power BI.com service, in a browser then open fiddler, then press F5 to reload. You should be able to see the Access Token in various requests. If you register an app, you can plug in your App's information in one of the samples we have https://powerbi.microsoft.com/developers, see client app or web app.
The name you provide in the table is the friendly human readable name that appears in the UI when you're building a report. Without it the system is unusable by humans :).
Let me get back to you on #3.
Calling PUT table will attempt to save upgrade the table without loosing any data (unless you removed columns). If it can't, it will return a conflict error. If you still want to update the table schema, you would have to delete the rows and call PUT table again. There is currently no direct way to rename a column. PUT table would treat it like a delete and add for that column. You would loose the data in that column but not the whole table.

FQL: group results that have a field in common

I'm developing an application based on the facebook checkins.
I'm searching a way to group the results, that I receive asking for an user's checkins, by the page_id with a single FQL query.
Generally I would try with the GROUP clause of the SQL language but i read that this clause isn't supported by FQL.
Thanks in advance,
Luca
Since there is no GROUP BY available, as you said, this is not possible via a single FQL query.
Your options are to either do that yourself while processing the data you received by looping over it and transfering it into the desired data structure, or if you know what pages are involved beforehand, by doing a multi query including one single query for every page_id.

How to access my user activity on other users' pages or fan pages using the Graph API?

I would like to find any of my own activity (post, comment, share, etc.) on another user's page or a fan page. That is, obtain a list of all the comments, posts and whatnot that I have made on user XYZ's page, or on SOMETVSHOW's page.
Is that possible at all? I've looked at the different relations that are accessible using the Graph API, but there seems to be no direct way to get this data.
One way to do this is to collect ALL of my own activity and then run this data through a filter that would extract just the comments, post, etc. that I left on a certain user's page or fan page. But that is not really efficient, especially if you have (like me) a very large amount of data to capture in the first place.
Also, I could go the other way and grab ALL of that user's or fan page's activity and the filter out my own posts and comments, but likewise, this would take an eternity and produce huge amounts of data that need to be processed.
Any ideas? Thank you!
You should be able to do this pretty easily via FQL:
SELECT post_id, type, message, created_time, attachment FROM stream
WHERE source_id = PAGE_ID AND actor_id = me() LIMIT 200
You will have the normal limitations of the stream table to deal with, so you may have to page back through these results to get everything you are looking for.