Skip to content

Commit

Permalink
add DATE index type
Browse files Browse the repository at this point in the history
  • Loading branch information
capjamesg committed Aug 24, 2024
1 parent 0bc00ee commit 0fa62ab
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion jamesql/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -763,7 +763,11 @@ def _run(self, query: dict, query_field: str) -> List[str]:
for doc_uuid in gsi.values(min=lower_bound, max=upper_bound)
]
)
elif query_type in QUERY_TYPE_COMPARISON_METHODS:
elif query_type in QUERY_TYPE_COMPARISON_METHODS and gsi_type == GSI_INDEX_STRATEGIES.NUMERIC:
matching_documents.extend(
QUERY_TYPE_COMPARISON_METHODS[query_type](query_term, gsi)
)
elif query_type in QUERY_TYPE_COMPARISON_METHODS and gsi_type == GSI_INDEX_STRATEGIES.DATE:
matching_documents.extend(
*QUERY_TYPE_COMPARISON_METHODS[query_type](query_term, gsi)
)
Expand Down

0 comments on commit 0fa62ab

Please sign in to comment.