druid4net icon indicating copy to clipboard operation
druid4net copied to clipboard

BoundFilter with strings

Open monodop opened this issue 4 years ago • 0 comments

I'm trying to create a new BoundFilter to compare strings. Because there's a struct constraint, it's not letting me pass the string type:

new BoundFilter<string>("srcip", lower: "127", lowerStrict: false, ordering: SortingOrder.alphanumeric)
// Error: CS0453 The type 'string' must be a non-nullable value type in order to use it as parameter 'T' in the generic type or method 'BoundFilter<T>'

Am I doing something wrong? According to the docs, it should be able to work: https://druid.apache.org/docs/latest/querying/filters.html#bound-filter

{
    "type": "bound",
    "dimension": "name",
    "lower": "foo",
    "upper": "hoo"
}

monodop avatar Jun 02 '20 21:06 monodop