|
Hello.
I have two tables.
USER user_id password
FRIEND_LIST user_id friend_id
If user 1 is friend of user 2 then in friend_list there will be 2 records:
1 2 2 1
Thats how I'm controlling friend list.
My question is how can I create an efficient query ...
Started by Enrique on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
The query you already wrote is along the right lines, I think you need one less join to the friend-list table:
select distinct fl1.user_id, fl2.friend_id from friend_list fl1 inner join friend_list you have two complementary entries....
|
|
Hi
I have this problem. Given a users table that consists of users' username in a social network and friends table that contain a user's name and a user's friendname like below...
username friendname John Thomas Chris James
... I'm trying to write an ...
Started by core_pro on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
SELECT * FROM ( SELECT username FROM friends START WITH username = 'myname' CONNECT BY friendname = PRIOR username AND level <= 3 ) WHERE username = 'friendname' AND rownum = 1
Update the level as necessary: you may search for the third layer....
|
|
Currently I am in need to find the friends of friends in my application using PHP and MYSQL
For example : Database structure is like this. Table Name : tbl_friendlist
Ident mem_id friend_id 1 2 1 2 1 2 3 1 3 1 4 1 5 1 8
How can i achieve this
I am able...
Started by Fero on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
If you need to find a way without.
Your friends
SELECT friend_id FROM tbl_friendlist WHERE f.mem_id = 1
And so then you just wrap mem_id in (SELECT friend_id FROM tbl_friendlist WHERE mem_id = 1).
|
Ask your Facebook Friends
|
Ok I have searched before asking, all I found was several questions asking what I am but 0 answers so maybe someone who knows will see this or I will make it a more clear question.
I have a social network similar to myspace/facebook. In my code you are...
Started by jasondavis on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
You do a subquery:
SELECT DISTINCT user_id FROM friends WHERE friend_id IN (SELECT user_id FROM friends WHERE friend_id = 1)
Test both of these for performance:
SELECT DISTINCT user_id FROM friends FROM friends....
|
|
Hi,
I've recently stared looking into the Facebook API and am trying to workout how to retrieve the list of friends of another user (in this case the user is someone I'm friends with).
So far I've only worked out how to find out the friends of a person...
Answer Snippets (Read the full thread at stackoverflow):
It looks like Friends.get is what you want..
Http://wiki.developers.facebook.com/index.php/Friends.get
See the uid optional parameter.
|
|
In C++, I have a class A which is friend with a class B.
I looks like inherited classes of B are not friend of class A.
I this a limitation of C++ or my mistake ?
Here is an example. When compiling, I get an error on line "return new Memento":
Memento...
Started by Jérôme on
, 6 posts
by 6 people.
Answer Snippets (Read the full thread at stackoverflow):
(See also " friendship isn't inherited, transitive, or reciprocal ")
The friend directive was originally intended as some "loophole" to bypass the encapsulation....
Friendship is not inherited, you have to explicitly declare every friend relationship.
|
|
I wrote a script to export twitter friends as foaf rdf description. Now I'm looking for a tool to visualize the friend networks. I tried http://foafscape.berlios.de/ but for 300+ Nodes it is really slow and does a bad job on auto formatting.
Any hints...
Started by Peter Hoffmann on
, 9 posts
by 9 people.
Answer Snippets (Read the full thread at stackoverflow):
In one of the talks at dConstruct08 last week there was a social graph showing the friend for some flare examples, there is a friend of a friend graph around there..
Social Graph.
|
|
Started by Andrroid on
, 64 posts
by 38 people.
Answer Snippets (Read the full thread at reddit):
Http://i.imgur.com/YXv6c.jpg Is it okay to say Droid Incredible *2....
Also looking at it again I think 5 is the motorola photon .
I am fairly sure the one marked 3 is an HTC phone .
Ok, I got as many as I could.
Awesome! Now time to play name that phone...
|
|
For example, I have class Article with methods getTitle () and getContent () .
I also have ArticlesService with method getAllArticles () . How to create a list of links with meaningful names (formed with #{article.title} )? Like:
http://mysiteaddress....
Started by Roman on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
If this is intended as an improvement of an existing application, then you basically need a PhaseListener and/or a Filter which detects "dirty" URL's and redirect the request to a "friendly" URL and when it detects "friendly" URL, it should....
|
|
Hi folks,
I'm not so into this social media stuff, so I'll describe the task here.
I plan an application, that needs the social graph between two indiviuals in order to work. The first one is the user of the application, which provides us with access ...
Started by Steve|munich on
, 8 posts
by 8 people.
Answer Snippets (Read the full thread at wickedfire):
MyBrainIsFullOfFuck.jpg
srs, why would you even want to do definitely will need their friend....
|