Skip to content

[Feedback: FT.CREATE] Missing information about the order of the field index options #1275

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
amxfonseca opened this issue Mar 12, 2025 · 4 comments
Assignees
Labels

Comments

@amxfonseca
Copy link

Page https://redis.io/docs/latest/commands/ft.create/

The order on which the options are declared is relevant, but I can't seem to find such information in the current documentation page.

Example:

127.0.0.1:6379> FT.CREATE index-a ON JSON PREFIX 1 some:prefix SCHEMA $.field AS field TAG INDEXMISSING SORTABLE
OK
127.0.0.1:6379> FT.CREATE index-b ON JSON PREFIX 1 some:prefix SCHEMA $.field AS field TAG SORTABLE INDEXMISSING
(error) Field `INDEXMISSING` does not have a type
127.0.0.1:6379> 

In the example above the INDEXMISSING always needs to precede SORTABLE, otherwise Redis will throw an error.

@dwdougherty dwdougherty self-assigned this Mar 12, 2025
@dwdougherty
Copy link
Collaborator

Thank you, @amxfonseca. We'll take a look. I'm currently working on such a page for FT.AGGREGATE, so I'll add this request to my list.

@amxfonseca
Copy link
Author

@dwdougherty Thanks for the quick reply!

This seems more like a bug on the query parser and not something missing in the docs. But I am not sure what is the best place to open the issue.

@dwdougherty
Copy link
Collaborator

dwdougherty commented Mar 12, 2025

Perhaps. Feel free to open a ticket on the search repo. Otherwise, I still think it's a good idea to augment the FT.CREATE and FT.SEARCH page with parameter ordering information. I've added a ticket for this internally.

UPDATE: I found the following open ticket on the search repo: RediSearch/RediSearch#5177.

@dwdougherty
Copy link
Collaborator

Since I've opened a ticket to address FT.CREATE ordering, I'll go ahead and close this ticket. Thanks again, @amxfonseca.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants