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 a0a0a87 commit c51fe8e
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions jamesql/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -763,11 +763,7 @@ 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 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:
elif query_type in QUERY_TYPE_COMPARISON_METHODS and gsi_type in {GSI_INDEX_STRATEGIES.DATE, GSI_INDEX_STRATEGIES.NUMERIC}:
result = QUERY_TYPE_COMPARISON_METHODS[query_type](query_term, gsi)
if isinstance(result[0], list):
for item in result:
Expand Down

0 comments on commit c51fe8e

Please sign in to comment.