Skip to content
This repository has been archived by the owner on Aug 4, 2020. It is now read-only.

Commit

Permalink
remove #todo, issue was due to running with older version of cassandra
Browse files Browse the repository at this point in the history
  • Loading branch information
lyubent committed Apr 15, 2014
1 parent 2a1919a commit 5d45acd
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions cass.py
Expand Up @@ -122,7 +122,6 @@ def get_friend_usernames(username, count=5000):
""" """
global get_friends_query global get_friends_query
if get_friends_query is None: if get_friends_query is None:
# view get_follower_usernames' issue with LIMIT below.
get_friends_query = session.prepare(""" get_friends_query = session.prepare("""
SELECT friend FROM friends WHERE username=? LIMIT ? SELECT friend FROM friends WHERE username=? LIMIT ?
""") """)
Expand All @@ -141,11 +140,6 @@ def get_follower_usernames(username, count=5000):
SELECT follower FROM followers WHERE username=? LIMIT ? SELECT follower FROM followers WHERE username=? LIMIT ?
""") """)


# todo, currently the above limit clause param isn't binded and causes :
# Exception Type: SyntaxException at /
# Exception Value: <ErrorMessage code=2000
# [Syntax error in CQL query]
# line 2:66 mismatched input '?' expecting INTEGER"
rows = session.execute(get_followers_query, (username, count)) rows = session.execute(get_followers_query, (username, count))
return [row.follower for row in rows] return [row.follower for row in rows]


Expand Down

0 comments on commit 5d45acd

Please sign in to comment.