<?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 cannot use VB expressions for services in Geoprocessing Questions</title>
    <link>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471772#M15787</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;10.1 geoprocessing tool.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm getting an error during the analysis phase in ArcCatalog while trying to publish my gp service. It says I can't use VB expressions in the Calculate Field Tool. The severity is High but i am still able to publish.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is the only line in my py script that uses the CalculateField tool:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;arcpy.CalculateField_management("in_memory/buffer", "GP_ID", "x", "PYTHON", "x = '" + uniqueid + "'")&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Am i missing something? Because I don't think there is any VB in there.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 06 Nov 2012 17:57:54 GMT</pubDate>
    <dc:creator>KevinGooss</dc:creator>
    <dc:date>2012-11-06T17:57:54Z</dc:date>
    <item>
      <title>cannot use VB expressions for services</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471772#M15787</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;10.1 geoprocessing tool.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm getting an error during the analysis phase in ArcCatalog while trying to publish my gp service. It says I can't use VB expressions in the Calculate Field Tool. The severity is High but i am still able to publish.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Here is the only line in my py script that uses the CalculateField tool:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="plain" name="code"&gt;arcpy.CalculateField_management("in_memory/buffer", "GP_ID", "x", "PYTHON", "x = '" + uniqueid + "'")&lt;/PRE&gt;&lt;DIV style="display:none;"&gt; &lt;/DIV&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Am i missing something? Because I don't think there is any VB in there.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Nov 2012 17:57:54 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471772#M15787</guid>
      <dc:creator>KevinGooss</dc:creator>
      <dc:date>2012-11-06T17:57:54Z</dc:date>
    </item>
    <item>
      <title>Re: cannot use VB expressions for services</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471773#M15788</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Kevin,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Using Server 9.3.1 you have to change the Expression Type parameter to 'PYTHON_9.3'. For the calculate field to work.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;A href="http://support.esri.com/en/knowledgebase/techarticles/detail/36571"&gt;http://support.esri.com/en/knowledgebase/techarticles/detail/36571&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Not sure if this is still the case with 10.1, but worth looking at&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Anthony&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Nov 2012 18:08:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471773#M15788</guid>
      <dc:creator>AnthonyGiles</dc:creator>
      <dc:date>2012-11-06T18:08:27Z</dc:date>
    </item>
    <item>
      <title>Re: cannot use VB expressions for services</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471774#M15789</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;no dice. but thank you for the suggestion.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Nov 2012 18:19:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471774#M15789</guid>
      <dc:creator>KevinGooss</dc:creator>
      <dc:date>2012-11-06T18:19:52Z</dc:date>
    </item>
    <item>
      <title>Re: cannot use VB expressions for services</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471775#M15790</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Its not an error, just a high-warning.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Check the help here:&lt;/SPAN&gt;&lt;BR /&gt;&lt;A href="http://resources.arcgis.com/en/help/main/10.1/index.html#//005700000093000000"&gt;http://resources.arcgis.com/en/help/main/10.1/index.html#//005700000093000000&lt;/A&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Specific to your case:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;Solution&lt;/STRONG&gt;&lt;BR /&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; If your tool is not using a VB expression, you can ignore this warning.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Per Anthony's response, the KB article still holds true...we now have the ability (in 10.1) to let you know about it and offer suggestions.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Nov 2012 18:25:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471775#M15790</guid>
      <dc:creator>KevinHibma</dc:creator>
      <dc:date>2012-11-06T18:25:49Z</dc:date>
    </item>
    <item>
      <title>Re: cannot use VB expressions for services</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471776#M15791</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Cool. Thank you.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Nov 2012 18:27:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471776#M15791</guid>
      <dc:creator>KevinGooss</dc:creator>
      <dc:date>2012-11-06T18:27:26Z</dc:date>
    </item>
    <item>
      <title>Re: cannot use VB expressions for services</title>
      <link>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471777#M15792</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Kevin,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Not that I am an expert in python but looking at the help file for Calculate Field the syntax is:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;CalculateField_management (in_table, field, expression, {expression_type}, {code_block})&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;so if uniqueid is a variable have you tried:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;arcpy.CalculateField_management("in_memory/buffer", "GP_ID",uniqueid,"PYTHON")&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;or if uniqueid is a field name&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;arcpy.CalculateField_management("in_memory/buffer", "GP_ID", "!uniqueid!","PYTHON")&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Regards&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Anthony&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 06 Nov 2012 18:37:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/geoprocessing-questions/cannot-use-vb-expressions-for-services/m-p/471777#M15792</guid>
      <dc:creator>AnthonyGiles</dc:creator>
      <dc:date>2012-11-06T18:37:59Z</dc:date>
    </item>
  </channel>
</rss>

