Skip to content

Commit

Permalink
fix #1722
Browse files Browse the repository at this point in the history
  • Loading branch information
afghanistanyn authored Aug 18, 2022
1 parent 6bb36f7 commit fa263a4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion sql/engines/mongo.py
Original file line number Diff line number Diff line change
Expand Up @@ -949,7 +949,10 @@ def query(self, db_name=None, sql="", limit_num=0, close_conn=True, **kwargs):
if "limit" in query_dict and query_dict["limit"]:
query_limit = int(query_dict["limit"])
limit = min(limit_num, query_limit) if query_limit else limit_num
find_cmd += ".limit(limit)"
find_cmd += f".limit({limit})"
if "skip" in query_dict and query_dict["skip"]:
query_skip = int(query_dict["skip"])
find_cmd += f".skip({query_skip})"
if "count" in query_dict:
find_cmd += ".count()"
if "explain" in query_dict:
Expand Down

0 comments on commit fa263a4

Please sign in to comment.