<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Query ArcGIS Services where &amp;quot;Lock Database Schema&amp;quot; is True in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199392#M15317</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've got another question for you. How can i actually modify the property to set the flags to false if they are enabled? I tried several different ways of setting the json property in the "&lt;SPAN class="keyword" style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: #006699;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: #000000;"&gt; properties[&lt;/SPAN&gt;&lt;SPAN class="string" style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: blue;"&gt;'schemaLockingEnabled'] == 'false'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: #000000;"&gt;:&lt;/SPAN&gt;" section, but couldn't get one to stick so I thought I'd ask for your approach.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 08 Jun 2015 15:08:50 GMT</pubDate>
    <dc:creator>JoshLehn</dc:creator>
    <dc:date>2015-06-08T15:08:50Z</dc:date>
    <item>
      <title>Query ArcGIS Services where "Lock Database Schema" is True</title>
      <link>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199388#M15313</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Does anyone know how we can search our services for this parameter, or set the default to false?? These are really hard to find without clicking into each individual service!&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE:&amp;nbsp; Jake showed us how to find them with python, but we are now finding that the Services do not seem to be respecting/modifying the information in the configuration store (even after stop/starting). Has anyone experienced this or know how we might resolve this?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="https://community.esri.com/legacyfs/online/62897_Lock.jpg"&gt;&lt;IMG alt="Lock.jpg" class="image-1 jive-image" height="517" src="https://community.esri.com/legacyfs/online/62897_Lock.jpg" style="width: 620px; height: 337px;" width="950" /&gt;&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 17 Feb 2015 21:06:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199388#M15313</guid>
      <dc:creator>JoshLehn</dc:creator>
      <dc:date>2015-02-17T21:06:18Z</dc:date>
    </item>
    <item>
      <title>Re: Query ArcGIS Services where "Lock Database Schema" is True</title>
      <link>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199389#M15314</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Josh,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One way you could search this is by using Python.&amp;nbsp; Ex:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;import os, json

for root, dirs, files in os.walk(r"C:\arcgisserver\directories\arcgissystem\arcgisinput"):
&amp;nbsp;&amp;nbsp;&amp;nbsp; for name in files:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if 'serviceconfiguration.json' in name:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; json_data = open(os.path.join(root, name))
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; data = json.load(json_data)
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; values = data['service']
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; try:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; properties = values['properties']&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if properties['schemaLockingEnabled'] == 'false':
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print values['serviceName']
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; except:
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; pass&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 09:56:30 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199389#M15314</guid>
      <dc:creator>JakeSkinner</dc:creator>
      <dc:date>2021-12-11T09:56:30Z</dc:date>
    </item>
    <item>
      <title>Re: Query ArcGIS Services where "Lock Database Schema" is True</title>
      <link>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199390#M15315</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Awesome code, thank you! &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here is the next puzzler, we're finding that the configuration store does not seem to be updating the "schemaLockingEnabled" property when we toggle it in server manager, even after restarting the service. Have you experienced this before??&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 17 Feb 2015 22:06:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199390#M15315</guid>
      <dc:creator>JoshLehn</dc:creator>
      <dc:date>2015-02-17T22:06:42Z</dc:date>
    </item>
    <item>
      <title>Re: Query ArcGIS Services where "Lock Database Schema" is True</title>
      <link>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199391#M15316</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have used the Catalog window for that purpose and that seems to work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the Catalog window (or using ArcCatalog) Connect to your ArcGIS Server with admin rights, go to the parameters tab and click on the button Advanced. At the bottom, you will see the property and you can change the value to "false" (just write it).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 17 Feb 2015 23:04:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199391#M15316</guid>
      <dc:creator>XanderBakker</dc:creator>
      <dc:date>2015-02-17T23:04:33Z</dc:date>
    </item>
    <item>
      <title>Re: Query ArcGIS Services where "Lock Database Schema" is True</title>
      <link>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199392#M15317</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I've got another question for you. How can i actually modify the property to set the flags to false if they are enabled? I tried several different ways of setting the json property in the "&lt;SPAN class="keyword" style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: #006699;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: #000000;"&gt; properties[&lt;/SPAN&gt;&lt;SPAN class="string" style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: blue;"&gt;'schemaLockingEnabled'] == 'false'&lt;/SPAN&gt;&lt;SPAN style="font-size: 12px; font-family: Consolas, 'Courier New', Courier, mono, serif; color: #000000;"&gt;:&lt;/SPAN&gt;" section, but couldn't get one to stick so I thought I'd ask for your approach.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 08 Jun 2015 15:08:50 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199392#M15317</guid>
      <dc:creator>JoshLehn</dc:creator>
      <dc:date>2015-06-08T15:08:50Z</dc:date>
    </item>
    <item>
      <title>Re: Query ArcGIS Services where "Lock Database Schema" is True</title>
      <link>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199393#M15318</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think that the "serviceconfiguration.json" files located in /arcgisinput are static and written to only once upon creation of the service. The configuration files that are updated whenever changes are made are the ones located in the configuration store directory. (C:\arcgisserver\config-store\services\&amp;lt;servicename&amp;gt;.MapServer.json). &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 26 Aug 2015 20:47:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199393#M15318</guid>
      <dc:creator>JamesVogl</dc:creator>
      <dc:date>2015-08-26T20:47:17Z</dc:date>
    </item>
    <item>
      <title>Re: Query ArcGIS Services where "Lock Database Schema" is True</title>
      <link>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199394#M15319</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;My DBA helped me alter the above code so it would work on the non-static json files for the services:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;import os, json&lt;/P&gt;&lt;P&gt;for root, dirs, files in os.walk(r"C:\arcgisserver\config-store\services"):&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; for name in files:&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if name.endswith('.json') and name != 'FolderInfo.json':&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; filename = os.path.join(root, name)&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; json_data = open(os.path.join(root, name))&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; data = json.load(json_data)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; try:&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; properties = data['properties']&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if properties['schemaLockingEnabled'] == 'true':&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; print data['serviceName']&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; except:&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; pass&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This helped me check that I had fixed all the 'false' to 'true'&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 Aug 2017 19:08:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/query-arcgis-services-where-quot-lock-database/m-p/199394#M15319</guid>
      <dc:creator>BeccaBlackman1</dc:creator>
      <dc:date>2017-08-14T19:08:59Z</dc:date>
    </item>
  </channel>
</rss>

