Skip to content
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

Indexed Properties of type int[] not added to index. #509

Open
Jay1980 opened this issue Dec 19, 2024 · 1 comment
Open

Indexed Properties of type int[] not added to index. #509

Jay1980 opened this issue Dec 19, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@Jay1980
Copy link

Jay1980 commented Dec 19, 2024

a property that is of type int[] is not added to the index at all. e.g.

    [Indexed]
    public int[] Ids { get; set; } = Array.Empty<int>();

whereas string[] is. e.g.

    [Indexed]
    public string[] Ids { get; set; } = Array.Empty<string>();

I think the issue arises around this code:

private static bool IsTypeIndexableArray(Type t) => t == typeof(string[]) || t == typeof(bool[]) || t == typeof(Guid[]) || t == typeof(List<string>) || t == typeof(List<bool>) || t == typeof(List<Guid>);

Should I be decorating int[] fields differently?

@slorello89 slorello89 added the enhancement New feature or request label Dec 19, 2024
@slorello89
Copy link
Member

Hi @Jay1980 - for some background, indexing and searching arrays of non-scalar strings is a (relatively) new thing in RediSearch, and Redis OM .NET has not been updated to support that feature yet.

It is possible to do though so I will leave this issue open as an enhancement.

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

No branches or pull requests

2 participants