I created a point shapefile by converting a raster into points. The default fields generated were FID, Shape, POINT_ID, and GRID_CODE.

I added two new fields "X_location" and "Y_location". I generated the values for these two newly added fields by calculating geometry. Further, I extracted the corresponding NDVI and LST values for the points in the shapefile.

Now the problem is, when I apply the "Select by attributes" option, I can select values for the fields POINT_ID or GRID_CODE. But when the same is applied for the X_location, Y_location, NDVI or LST field, it doesn't work.

More specifically saying, I applied the following query.

Select by attributes--> Chose method as "Create new selection"--> "POINTID"--> Get Unique values--> "POINTID"= (Some value chosen from the retrieved value list)--> Apply. This query worked. But when the same was applied with a different field like "X_location", "Y_location", NDVI or LST, it selected nothing! Even after selecting a value from the list (after clicking "get unique values"), it showed, "0 out of 2799326 selected". I was only changing the field and getting the new unique values for the same field!

I made sure that the value I wanted to select, was present in the table. Also, in the ArcCatalog, in the file properties, I checked for index and there any index was not present. So I made new ones. Still it did not help.

Where exactly I am doing wrong?

closed as unclear what you're asking by Jochen Schwarze, ThingumaBob, Vince, whyzar, BERA Apr 25 at 13:03

Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.

  • 1
    What do you mean by "does not work", do you get an error? What is the sql expression you used? – BERA Apr 25 at 5:44
  • "Does not work"means it is not selecting anything, while from the fields POINT_ID and GRID_CODE it is selecting! The value I select is definitely present in the database and I select it by getting unique values from the select by attributes window. No error message is showing. – Swadhina Koley Apr 25 at 6:25
  • However, i solved the problem by exporting the shapefile to a feature dataset in a geodatabase. As I have a really large no. of entries (more than 27 lakh points), so I thought to convert it into a geodatabase. – Swadhina Koley Apr 25 at 6:26
  • 2.7m points isn't large for a shapefile. You didn't specify how you did the query, so there isn't any way to figure out what was wrong or why changing the format worked. – Vince Apr 25 at 10:20
  • To be able to select by coordinates you might have to round them, or even convert to integers – BERA Apr 26 at 5:07

I eventually found out a solution for the same problem while going through different trial and error methods. I have tried adding new fields and using the field calculator with the same existing values. But nothing worked. I don't know much about the indexing part (I found that solution only in this platform, but didn't work for me somehow!) However, as I have really a large no. of entries (more than 27 lakh points), I just thought give it a try by converting the shapefile into a feature class in a geodatabase and then apply the select by attribute option. And it worked!

Not the answer you're looking for? Browse other questions tagged or ask your own question.