Hi there.  Thanks for the reply.

That isn't explained at all on that page.  "You can also use the =~ 
operator:" has little explanation. I tried "==" and it worked as well.  
Because it was a negation, I thought using "=" would/should have worked.  
So this is working:

    exclude{(lat == 0.0) & (lon == 0.0)}.

Cheers

On Tuesday, January 5, 2021 at 6:40:03 AM UTC-5 Marcelo wrote:

> You should use the correct equality operator '=~', instead of just `=`, as 
> explained here:
>
> https://github.com/jeremyevans/sequel/blob/master/doc/dataset_filtering.rdoc#filtering-using-expressions-
>
> So it might just be
> DL[:yachts].exclude{(lat =~ 0.0) & (lon =~ 0.0)}.
>
> But check with .sql method to see if that produces the query you want. 
> Otherwise there are plenty of options for negative conditions:
>
> https://github.com/jeremyevans/sequel/blob/master/doc/dataset_filtering.rdoc#negating-conditions-
>
> Em ter., 5 de jan. de 2021 às 11:34, bee...@gmail.com <bee...@gmail.com> 
> escreveu:
>
>> I can't seem to get an exclusion working:
>>
>> DL[:yachts].exclude{(lat = 0.0) & (lon = 0.0)}
>>
>> Disregarding that [0.0,0.0] is possible for yacht, I'd like to exclude 
>> these floats from those associated fields, qualified with both filters.  
>>
>> I'm assuming this isn't a cast issue as 0.0 would be seen as a Float.  I 
>> know I could wiggle around this, but I want to get my head around this 
>> approach of having both inside a single exclude using that union operator.  
>>
>> Cheers
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "sequel-talk" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to sequel-talk...@googlegroups.com.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/sequel-talk/4889bde8-0698-4b1e-a87c-1f7faad09c40n%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/sequel-talk/4889bde8-0698-4b1e-a87c-1f7faad09c40n%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sequel-talk+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/sequel-talk/3dd68a20-bcb4-4d07-90e7-990ca8dd1042n%40googlegroups.com.

Reply via email to