{"id":236522,"date":"2018-07-03T12:00:52","date_gmt":"2018-07-03T19:00:52","guid":{"rendered":"http:\/\/www.esri.com\/arcgis-blog\/?post_type=blog&#038;p=236522"},"modified":"2018-07-03T15:43:58","modified_gmt":"2018-07-03T22:43:58","slug":"querying-feature-services-having-clause","status":"publish","type":"blog","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause","title":{"rendered":"Querying Feature Services: Having Clause"},"author":7421,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","format":"standard","meta":{"_acf_changed":false,"_searchwp_excluded":""},"categories":[23851],"tags":[25891,24501,104082,104222],"industry":[],"product":[36571,36861],"class_list":["post-236522","blog","type-blog","status-publish","format-standard","hentry","category-data-management","tag-arcgis","tag-feature-services","tag-query","tag-rest-api","product-arcgis-enterprise","product-api-rest"],"acf":{"short_description":"This article focuses on querying feature services using the having clause.","flexible_content":[{"acf_fc_layout":"content","content":"<p>Welcome to the first installation of the blog series &#8220;Querying Feature Services&#8221;. This series of articles will dive into the details and provide examples to describe what&#8217;s available for querying feature services. This article will focus on the having clause; a <a href=\"https:\/\/developers.arcgis.com\/rest\/services-reference\/query-feature-service-layer-.htm\">query<\/a> operation you can do on the layer resource through the <a href=\"https:\/\/developers.arcgis.com\/rest\/services-reference\/get-started-with-the-services-directory.htm\">REST API<\/a>\u00a0as of ArcGIS 10.6.1.<\/p>\n<p>The having clause partners with\u00a0<code>groupByForStatistics<\/code>\u00a0and <code>outStatistics<\/code>\u00a0query parameters to allow extra powerful queries using aggregate functions. The <code>where<\/code> clause, <code>geometry<\/code>, and <code>time<\/code> parameters can be used with having to further limit your query results. It&#8217;s supported on all feature services except those hosted in a spatiotemporal big data store. If you&#8217;re not sure whether your feature service or map service supports querying with the having clause, you&#8217;re in luck because there is a property in the service&#8217;s\u00a0<a href=\"https:\/\/developers.arcgis.com\/rest\/services-reference\/layer-feature-service-.htm\">layer<\/a>\u00a0resource called\u00a0<code>supportsHavingClause<\/code>\u00a0(I know, right?). Now, <code>supportsHavingClause<\/code>\u00a0is\u00a0<code>true<\/code> if the layer supports querying with the having clause. If you don&#8217;t see the property, or the property is <code>false<\/code>, you&#8217;re not able to use having. Wait a second, <em>how<\/em> do you use having?<\/p>\n<p>I mentioned previously that having is used with groupByForStatistics, outStatistics, and sometimes the where clause, geometry and time parameters, but I didn&#8217;t tell you how they might be used together. Let&#8217;s set up a scenario to help explain. You&#8217;re looking for a hotel in Los Angeles between August 16th and August 18th and you have data that contains information about the date, price per night, and the overall customer rating. You published your data as a feature service and you want to do some queries using the having clause to narrow down your choices (whoa, what a coincidence!). Suppose you want to find a hotel where the average price per nice is less than $200, but you only want hotels with a minimum customer rating greater than or equal to 4\/5 using the subset of data below.<\/p>\n"},{"acf_fc_layout":"image","image":{"ID":265682,"id":265682,"title":"Hotel Data Sample","filename":"hoteldata3.png","filesize":7544,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\/hoteldata3","alt":"Hotel Data Sample","author":"7421","description":"","caption":"","name":"hoteldata3","status":"inherit","uploaded_to":236522,"date":"2018-07-03 16:37:20","modified":"2018-07-03 16:37:40","menu_order":0,"mime_type":"image\/png","type":"image","subtype":"png","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":627,"height":462,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","thumbnail-width":213,"thumbnail-height":157,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","medium-width":354,"medium-height":261,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","medium_large-width":627,"medium_large-height":462,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","large-width":627,"large-height":462,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","1536x1536-width":627,"1536x1536-height":462,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","2048x2048-width":627,"2048x2048-height":462,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","card_image-width":627,"card_image-height":462,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldata3.png","wide_image-width":627,"wide_image-height":462}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<h3>Composing the Query<\/h3>\n<p>Let&#8217;s break that query down into its parts, starting with the where clause. The where clause will need to limit your query results to all hotels in Los Angeles between August 16th and August 18th, and may look like this: <code>city_name = 'Los Angeles' and date between '08\/16\/2018' and '08\/18\/2018'<\/code>.<\/p>\n<p>Alright, now that the search is limited to hotels in Los Angeles within your date range, you can enhance your results by calculating the average price per night by using the <code>outStatistics<\/code> parameter. Using <code>outStatistics<\/code> requires a specific syntax containing <code>statisticType<\/code>, <code>onStatisticField<\/code>, and <code>outStatisticFieldName<\/code>.\u00a0 Your input will look like this: <code>[{\"statisticType\": \"AVG\", \"onStatisticField\": \"price\", \"outStatisticFieldName\": \"AvgPrice\"}]<\/code>. It&#8217;s important to note that <code>outStatistics<\/code> can&#8217;t be used without <code>groupByFieldsForStatistics<\/code>. This means that you have to specify the field for which to calculate the average price per night. Since you&#8217;re looking for hotels, you&#8217;ll use\u00a0<code>hotel_name<\/code>.<\/p>\n<p>So, by now you have all the hotels in Los Angeles and their average price per night. To narrow it down further and make sure you only get hotels with an average price of less than $200 and a customer rating greater than or equal to 4, you have to use the having clause. Using the having clause also requires a specific syntax containing an aggregate function. Your having clause will look like this: <code>avg(price) &lt; 200 and min(customer_rating) &gt;= 4<\/code>.<\/p>\n<blockquote><p>It&#8217;s important to note that any supported aggregate function or comparison operator can be used in the having clause.<\/p><\/blockquote>\n<p>Now let&#8217;s see this in the layer query resource:<\/p>\n"},{"acf_fc_layout":"image","image":{"ID":265722,"id":265722,"title":"Query Parameters","filename":"hoteldataquery1-1.png","filesize":18670,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\/hoteldataquery1-2","alt":"Query Parameters","author":"7421","description":"","caption":"","name":"hoteldataquery1-2","status":"inherit","uploaded_to":236522,"date":"2018-07-03 16:48:29","modified":"2018-07-03 16:48:48","menu_order":0,"mime_type":"image\/png","type":"image","subtype":"png","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":613,"height":897,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","thumbnail-width":137,"thumbnail-height":200,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","medium-width":178,"medium-height":261,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","medium_large-width":613,"medium_large-height":897,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","large-width":613,"large-height":897,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","1536x1536-width":613,"1536x1536-height":897,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","2048x2048-width":613,"2048x2048-height":897,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","card_image-width":318,"card_image-height":465,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/hoteldataquery1-1.png","wide_image-width":613,"wide_image-height":897}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<blockquote><p>Note: This layout may be different depending on what feature service you&#8217;re working with.<\/p><\/blockquote>\n<p>The query returned three results:<\/p>\n"},{"acf_fc_layout":"image","image":{"ID":265732,"id":265732,"title":"Query Results","filename":"queryresult1.png","filesize":2439,"url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","link":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\/queryresult1","alt":"Query Results","author":"7421","description":"","caption":"","name":"queryresult1","status":"inherit","uploaded_to":236522,"date":"2018-07-03 16:50:05","modified":"2018-07-03 16:50:18","menu_order":0,"mime_type":"image\/png","type":"image","subtype":"png","icon":"https:\/\/www.esri.com\/arcgis-blog\/wp-includes\/images\/media\/default.png","width":270,"height":187,"sizes":{"thumbnail":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","thumbnail-width":213,"thumbnail-height":148,"medium":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","medium-width":270,"medium-height":187,"medium_large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","medium_large-width":270,"medium_large-height":187,"large":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","large-width":270,"large-height":187,"1536x1536":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","1536x1536-width":270,"1536x1536-height":187,"2048x2048":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","2048x2048-width":270,"2048x2048-height":187,"card_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","card_image-width":270,"card_image-height":187,"wide_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/09\/queryresult1.png","wide_image-width":270,"wide_image-height":187}},"image_position":"center","orientation":"horizontal","hyperlink":""},{"acf_fc_layout":"content","content":"<p>This example covered finding a hotel with an <em>average<\/em> price and <em>minimum<\/em> rating. These represent aggregate functions. You aren&#8217;t limited to average and minimum though; there are seven types of aggregate functions you can make use of in both the having clause and outStatistics parameters: <code>MIN<\/code>, <code>MAX<\/code>, <code>AVG<\/code>, <code>SUM<\/code>, <code>STDDEV<\/code>, <code>COUNT<\/code>, and <code>VAR<\/code>.<\/p>\n<p>The having clause is an important and powerful tool for getting the most out of your data. For more information on querying using the feature service layer resource, visit <a href=\"https:\/\/developers.arcgis.com\/rest\/services-reference\/query-feature-service-layer-.htm\">this page<\/a>. For more information on layer properties, visit <a href=\"https:\/\/developers.arcgis.com\/rest\/services-reference\/layer-feature-service-.htm\">here<\/a>.<\/p>\n"}],"authors":[{"ID":7421,"user_firstname":"Sarah","user_lastname":"Scott","nickname":"Sarah Scott","user_nicename":"sarahmegan200","display_name":"Sarah Scott","user_email":"SScott@esri.com","user_url":"","user_registered":"2018-03-21 18:21:18","user_description":"","user_avatar":"<img alt='' src='https:\/\/secure.gravatar.com\/avatar\/2db6e66925440e9dcae076e1b068a255d610bacbddb3b3207c12c2102de8e9d1?s=96&#038;d=blank&#038;r=g' srcset='https:\/\/secure.gravatar.com\/avatar\/2db6e66925440e9dcae076e1b068a255d610bacbddb3b3207c12c2102de8e9d1?s=192&#038;d=blank&#038;r=g 2x' class='avatar avatar-96 photo' height='96' width='96' loading='lazy' decoding='async'\/>"}],"related_articles":"","card_image":false,"wide_image":false},"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v25.9 (Yoast SEO v25.9) - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Querying Feature Services: Having Clause<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Querying Feature Services: Having Clause\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\" \/>\n<meta property=\"og:site_name\" content=\"ArcGIS Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/esrigis\/\" \/>\n<meta property=\"article:modified_time\" content=\"2018-07-03T22:43:58+00:00\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:title\" content=\"Querying Feature Services in ArcGIS 10.6.1 - The Having Clause\" \/>\n<meta name=\"twitter:description\" content=\"Learn how to utilize the having clause query parameter to get the most out of your data.\" \/>\n<meta name=\"twitter:site\" content=\"@ESRI\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":[\"Article\",\"BlogPosting\"],\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause#article\",\"isPartOf\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\"},\"author\":{\"name\":\"Sarah Scott\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/85e621935fd4d2c4efe4079dbb0173d4\"},\"headline\":\"Querying Feature Services: Having Clause\",\"datePublished\":\"2018-07-03T19:00:52+00:00\",\"dateModified\":\"2018-07-03T22:43:58+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\"},\"wordCount\":5,\"publisher\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#organization\"},\"keywords\":[\"ArcGIS\",\"feature services\",\"query\",\"REST API\"],\"articleSection\":[\"Data Management\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\",\"name\":\"Querying Feature Services: Having Clause\",\"isPartOf\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#website\"},\"datePublished\":\"2018-07-03T19:00:52+00:00\",\"dateModified\":\"2018-07-03T22:43:58+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/www.esri.com\/arcgis-blog\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Querying Feature Services: Having Clause\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#website\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/\",\"name\":\"ArcGIS Blog\",\"description\":\"Get insider info from Esri product teams\",\"publisher\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.esri.com\/arcgis-blog\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#organization\",\"name\":\"Esri\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/04\/Esri.png\",\"contentUrl\":\"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/04\/Esri.png\",\"width\":400,\"height\":400,\"caption\":\"Esri\"},\"image\":{\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/www.facebook.com\/esrigis\/\",\"https:\/\/x.com\/ESRI\",\"https:\/\/www.linkedin.com\/company\/5311\/\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/85e621935fd4d2c4efe4079dbb0173d4\",\"name\":\"Sarah Scott\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/2db6e66925440e9dcae076e1b068a255d610bacbddb3b3207c12c2102de8e9d1?s=96&d=blank&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/2db6e66925440e9dcae076e1b068a255d610bacbddb3b3207c12c2102de8e9d1?s=96&d=blank&r=g\",\"caption\":\"Sarah Scott\"},\"url\":\"\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"Querying Feature Services: Having Clause","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause","og_locale":"en_US","og_type":"article","og_title":"Querying Feature Services: Having Clause","og_url":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause","og_site_name":"ArcGIS Blog","article_publisher":"https:\/\/www.facebook.com\/esrigis\/","article_modified_time":"2018-07-03T22:43:58+00:00","twitter_card":"summary_large_image","twitter_title":"Querying Feature Services in ArcGIS 10.6.1 - The Having Clause","twitter_description":"Learn how to utilize the having clause query parameter to get the most out of your data.","twitter_site":"@ESRI","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":["Article","BlogPosting"],"@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause#article","isPartOf":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause"},"author":{"name":"Sarah Scott","@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/85e621935fd4d2c4efe4079dbb0173d4"},"headline":"Querying Feature Services: Having Clause","datePublished":"2018-07-03T19:00:52+00:00","dateModified":"2018-07-03T22:43:58+00:00","mainEntityOfPage":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause"},"wordCount":5,"publisher":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/#organization"},"keywords":["ArcGIS","feature services","query","REST API"],"articleSection":["Data Management"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause","url":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause","name":"Querying Feature Services: Having Clause","isPartOf":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/#website"},"datePublished":"2018-07-03T19:00:52+00:00","dateModified":"2018-07-03T22:43:58+00:00","breadcrumb":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.esri.com\/arcgis-blog\/products\/api-rest\/data-management\/querying-feature-services-having-clause#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.esri.com\/arcgis-blog\/"},{"@type":"ListItem","position":2,"name":"Querying Feature Services: Having Clause"}]},{"@type":"WebSite","@id":"https:\/\/www.esri.com\/arcgis-blog\/#website","url":"https:\/\/www.esri.com\/arcgis-blog\/","name":"ArcGIS Blog","description":"Get insider info from Esri product teams","publisher":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.esri.com\/arcgis-blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.esri.com\/arcgis-blog\/#organization","name":"Esri","url":"https:\/\/www.esri.com\/arcgis-blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/04\/Esri.png","contentUrl":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2018\/04\/Esri.png","width":400,"height":400,"caption":"Esri"},"image":{"@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/esrigis\/","https:\/\/x.com\/ESRI","https:\/\/www.linkedin.com\/company\/5311\/"]},{"@type":"Person","@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/85e621935fd4d2c4efe4079dbb0173d4","name":"Sarah Scott","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.esri.com\/arcgis-blog\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/2db6e66925440e9dcae076e1b068a255d610bacbddb3b3207c12c2102de8e9d1?s=96&d=blank&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/2db6e66925440e9dcae076e1b068a255d610bacbddb3b3207c12c2102de8e9d1?s=96&d=blank&r=g","caption":"Sarah Scott"},"url":""}]}},"text_date":"July 3, 2018","author_name":"Sarah Scott","author_page":false,"custom_image":"https:\/\/www.esri.com\/arcgis-blog\/app\/uploads\/2025\/08\/Newsroom-Keyart-Wide-1920-x-1080.jpg","primary_product":"ArcGIS REST API","tag_data":[{"term_id":25891,"name":"ArcGIS","slug":"arcgis","term_group":0,"term_taxonomy_id":25891,"taxonomy":"post_tag","description":"","parent":0,"count":209,"filter":"raw"},{"term_id":24501,"name":"feature services","slug":"feature-services","term_group":0,"term_taxonomy_id":24501,"taxonomy":"post_tag","description":"","parent":0,"count":19,"filter":"raw"},{"term_id":104082,"name":"query","slug":"query","term_group":0,"term_taxonomy_id":104082,"taxonomy":"post_tag","description":"","parent":0,"count":3,"filter":"raw"},{"term_id":104222,"name":"REST API","slug":"rest-api","term_group":0,"term_taxonomy_id":104222,"taxonomy":"post_tag","description":"","parent":0,"count":8,"filter":"raw"}],"category_data":[{"term_id":23851,"name":"Data Management","slug":"data-management","term_group":0,"term_taxonomy_id":23851,"taxonomy":"category","description":"","parent":0,"count":920,"filter":"raw"}],"product_data":[{"term_id":36571,"name":"ArcGIS Enterprise","slug":"arcgis-enterprise","term_group":0,"term_taxonomy_id":36571,"taxonomy":"product","description":"","parent":0,"count":976,"filter":"raw"},{"term_id":36861,"name":"ArcGIS REST API","slug":"api-rest","term_group":0,"term_taxonomy_id":36861,"taxonomy":"product","description":"","parent":36601,"count":75,"filter":"raw"}],"primary_product_link":"https:\/\/www.esri.com\/arcgis-blog\/?s=#&products=api-rest","_links":{"self":[{"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/blog\/236522","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/blog"}],"about":[{"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/types\/blog"}],"author":[{"embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/users\/7421"}],"replies":[{"embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/comments?post=236522"}],"version-history":[{"count":0,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/blog\/236522\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/media?parent=236522"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/categories?post=236522"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/tags?post=236522"},{"taxonomy":"industry","embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/industry?post=236522"},{"taxonomy":"product","embeddable":true,"href":"https:\/\/www.esri.com\/arcgis-blog\/wp-json\/wp\/v2\/product?post=236522"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}