Hello,
I'm trying to filter my layer to create a featureSet with a right but dashboard sends me a error .
My goal is to keep the features who have the same date as the actual year. I use the field DEVIATION and I hoped with a right do the query.
Here's my code
I've seen on esri documentation https://doc.arcgis.com/fr/drone2map/2023.1/help/sql-reference-for-elements-used-in-query-expressions... and my code seems good but it's doesn't work.
Thank you for your help!
Solved! Go to Solution.
The SQL functions in that page are not comprehensive. A lot depends on the underlying RDBMS, and there are many functions not on that list you can use, others on that list that don't always seem to work.
If you're trying to filter by year, and the year is always at the end of the string, try this:
var sizeFilter = `DEVIATION LIKE '%${Year(Now())}'`
The SQL functions in that page are not comprehensive. A lot depends on the underlying RDBMS, and there are many functions not on that list you can use, others on that list that don't always seem to work.
If you're trying to filter by year, and the year is always at the end of the string, try this:
var sizeFilter = `DEVIATION LIKE '%${Year(Now())}'`
Thank you it works!!!