I have an PostgreSQL geometric operator Query that returns a boolean of true if a point is within an area and false if the point does not when i enter it into my rails db.
select(circle ((0,0), 2)’ @> point ‘(1,1)’)’
I found this geometric operator from the documentation here https://www.postgresql.org/docs/8.2/functions-geometry.html.
However when I try to run the same query in rails console. It gives me an error of " ‘@>’ is not allowed as an instance variable name"
I was wondering how I would convert this query so that it returns a boolean of true or false in rails console. I tried looking at the documentation here but am unsure of how to change the query https://api.rubyonrails.org/classes/ActiveRecord/QueryMethods.html#method-i-select
Any thoughts on what the query would look like in the rails console? So that it returns a boolean of true or false instead of giving the error of
" ‘@>’ is not allowed as an instance variable name"