human
Schema:
follows (f1, f2)
tweets (id, uid, text, createdate)
user_profiles (uid, name, email, partitionid, followers)
Please answer with SQL.
assistant
Sure, I understand.
human
How many users have some tweets?
assistant
SELECT COUNT( * ) FROM user_profiles WHERE UID IN ( SELECT UID FROM tweets );
human
Show the name of these users and their number of followers.
assistant
SELECT Name , followers FROM user_profiles WHERE UID IN ( SELECT UID FROM tweets ) ;