Query on Performance Impact Between String Array and String
TLDR Aljosa asked about performance differences between using a string array and a string. Kishore Nallan confirmed no significant impact, only minor memory overhead.
Powered by Struct AI
1
3
25mo
Solved
Oct 26, 2021 (25 months ago)
Aljosa
Aljosa
09:52 PMIs there any significant performance hit to worry about if i were to set my facetable fields as a string array
The reason is that in my dataset between different groups of items, field names are shared (with a good reason) but in some cases they are arrays of string rather than string. It seems easier to just set everything to be an array, unless there is a huge performance hit
string[]
instead of just a regular string
?The reason is that in my dataset between different groups of items, field names are shared (with a good reason) but in some cases they are arrays of string rather than string. It seems easier to just set everything to be an array, unless there is a huge performance hit
Oct 27, 2021 (25 months ago)
Kishore Nallan
Kishore Nallan
01:52 AMNo, there shouldn't be any difference between string array and string, except for some additional book keeping memory overhead, which will also not be significant.
1
Aljosa
Aljosa
04:03 PMThank you 🙂
Typesense
Lightning-fast, open source search engine for everyone | Knowledge Base powered by Struct.AI
Indexed 2786 threads (79% resolved)
Similar Threads
String vs Integer Indexing Performance
TJ inquired about performance differences between string and integer indexing. Jason explained it depends on the intended use of the field.
3
6mo
Solved
Comparing Two String Arrays
Andrew asked about comparing two string arrays. Jason replied that it's not possible.
2
11mo
Efficiency of Searching: String vs. String[]
Alan asked about the efficiency of using a string vs. string[] in a search query. Jason explained that it depends on the usage, but in their case, both should be nearly the same.
7
13mo
Solved