<?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: Raster Calculator &amp;quot;Merge&amp;quot; two Rasters - SyntaxError in Data Management Questions</title>
    <link>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490776#M27903</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hello Duncan,&lt;BR /&gt;&lt;BR /&gt;I tested your suggestion on my main computer but nothing changed i still had the same error messages...&lt;BR /&gt;&lt;BR /&gt;But than i also tested it on my second computer and it worked absolutly perfect, no errors *sigh*&lt;BR /&gt; &lt;BR /&gt;Right now i reinstall my ArcGIS version on this PC i have the feeling it's damaged.&lt;BR /&gt;&lt;BR /&gt;really thx for you help &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Hey! I'm having the same problem I'm not getting how to use the CON (Spatial ANALYST TOOL) to make the raster of both items, I guess you already figured it out! Please help me I need to know how to do this and Ive been stuck for days.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If you could explain me with detail I will really appreciated! Thanks&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;My mail is &lt;/SPAN&gt;&lt;A href="mailto:luismunozd@me.com"&gt;luismunozd@me.com&lt;/A&gt;&lt;SPAN&gt; THANKS A LOT!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 19 May 2014 01:45:53 GMT</pubDate>
    <dc:creator>luismunoz</dc:creator>
    <dc:date>2014-05-19T01:45:53Z</dc:date>
    <item>
      <title>Raster Calculator &amp;quot;Merge&amp;quot; two Rasters - SyntaxError</title>
      <link>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490771#M27898</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Greetings guys,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;first i must apologize for my english, i am no nativ speaker &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I have a problem with the Raster Calculator in ArcGis 10.2.1 (ArcInfo)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Situation description:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I have two different Rasters ("basic_raster" and "damm"). &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The "basic_raster" contains the normal Environment with z values &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]32841[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The "damm" raster contains a damm with z values&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]32843[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I would like to add the "Z" value from the Damm Raster to the Environment Raster.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;At the end it should looks like this picture but of course in one Raster&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]32842[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;In the Forum they said i had to create a "condition" raster. To do that i used the reclassify funktion from the spatial Analyst to create "Reclass_damm" (check the picture).&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]32840[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;87 = the infos i want to add to the other Raster (87meter is the height for the damm)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;0 = ignor this areas, i want to keep the infos from the basic_raster&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Next i started the Raster calculator and tried this command:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;New_Raster = Con(condition &amp;gt; 0, "Reclass_damm", "basic_raster")&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But something with the condition is wrong i get all the time this error: &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN style="font-style:italic;"&gt;Messages&lt;BR /&gt;Executing: RasterCalculator "New_Raster = con(condition &amp;gt; 0, "Reclass_damm" "basic_raster")" "E:\Master Thesis\Datenbank.mdb\New_Raster"&lt;BR /&gt;Start Time: Sun Apr 06 10:15:45 2014&lt;BR /&gt;New_Raster = con(condition &amp;gt; 0, Raster(r"Reclass_damm") Raster(r"basic_raster"))&lt;BR /&gt;ERROR 000539: Parsing error SyntaxError: invalid syntax (line 5)&lt;BR /&gt;Failed to execute (RasterCalculator).&lt;BR /&gt;Failed at Sun Apr 06 10:15:46 2014 (Elapsed Time: 0,55 seconds)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Maybe somebody out there who could help ?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 06 Apr 2014 08:17:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490771#M27898</guid>
      <dc:creator>Stefaningenfeld</dc:creator>
      <dc:date>2014-04-06T08:17:48Z</dc:date>
    </item>
    <item>
      <title>Re: Raster Calculator "Merge" two Rasters - SyntaxError</title>
      <link>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490772#M27899</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Original User: Hornbydd&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think your CON statement should be:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;New_Raster = Con(&lt;/STRONG&gt;&lt;STRONG&gt;"Reclass_damm"&lt;/STRONG&gt;&lt;STRONG&gt;, "Reclass_damm", "basic_raster", "VALUE &amp;gt; 0")&lt;/STRONG&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 06 Apr 2014 17:22:23 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490772#M27899</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2014-04-06T17:22:23Z</dc:date>
    </item>
    <item>
      <title>Re: Raster Calculator "Merge" two Rasters - SyntaxError</title>
      <link>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490773#M27900</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello Hornbydd,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;thx for your answer, your command worked fine with my little test setup.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;But when i tried it with a bigger Raster file i got this message:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN style="font-style:italic;"&gt;Messages&lt;BR /&gt;Executing: RasterCalculator "New_Raster = Con("reclass_damm", "reclass_damm", "basic_raster", "VALUE &amp;gt; 0")" C:\Users\stefan\Desktop\Versuchsdb.mdb\New_Raster&lt;BR /&gt;Start Time: Sun Apr 06 22:24:53 2014&lt;BR /&gt;New_Raster = Con(Raster(r"reclass_damm"), Raster(r"reclass_damm"), Raster(r"basic_raster"), "VALUE &amp;gt; 0")&lt;BR /&gt;ERROR 000539: Error running expression: rcexec() &lt;BR /&gt;Traceback (most recent call last):&lt;BR /&gt;&amp;nbsp; File "&amp;lt;expression&amp;gt;", line 1, in &amp;lt;module&amp;gt;&lt;BR /&gt;&amp;nbsp; File "&amp;lt;string&amp;gt;", line 5, in rcexec&lt;BR /&gt;&amp;nbsp; File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\sa\Functions.py", line 244, in Con&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; where_clause)&lt;BR /&gt;&amp;nbsp; File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\sa\Utils.py", line 47, in swapper&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; result = wrapper(*args, **kwargs)&lt;BR /&gt;&amp;nbsp; File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\sa\Functions.py", line 238, in Wrapper&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; where_clause)&lt;BR /&gt;&amp;nbsp; File "c:\program files (x86)\arcgis\desktop10.2\arcpy\arcpy\geoprocessing\_base.py", line 498, in &amp;lt;lambda&amp;gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; return lambda *args: val(*gp_fixargs(args, True))&lt;BR /&gt;ExecuteError: ERROR 999999: Error executing function.&lt;BR /&gt;FDO error: -2147024894 [GDB_Items]&lt;BR /&gt;No spatial reference exists.&lt;BR /&gt;ERROR 010302: Unable to create the output raster: C:\Users\stefan\Documents\ArcGIS\Default.gdb\Con_reclass_2&lt;BR /&gt;ERROR 010067: Error in executing grid expression.&lt;BR /&gt;Failed to execute (Con).&lt;BR /&gt;Failed to execute (RasterCalculator).&lt;BR /&gt;Failed at Sun Apr 06 22:24:54 2014 (Elapsed Time: 0,82 seconds)&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I did the same like before... This time the damm raster had a lot more Z values and the area was a lot bigger...&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;My Reclassify looked like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]32856[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;After it's done the file looked like this:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;[ATTACH=CONFIG]32857[/ATTACH]&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;looked fine to me the "noData" rasters got the 0...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;any clue what i made wrong ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;PS.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The original Damm Z values are in a polyline, is it possible to add them direct to the Raster, like the spatial analyst can do it with lines, points and polygones) ?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Right now i extract the position of the damm from the basic raster via "Extract by mask" &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The Damm Polyline is my mask.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Than i use "Raster to point" to create a point layer&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;After that i change the z values in a few areas and change it back to a raster (Raster to Point)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;This new Raster i reclassify and than i try to add the damm Z values to the basic raster.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;There must be a better way to to this... even when it would work...&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 06 Apr 2014 19:36:39 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490773#M27900</guid>
      <dc:creator>Stefaningenfeld</dc:creator>
      <dc:date>2014-04-06T19:36:39Z</dc:date>
    </item>
    <item>
      <title>Re: Raster Calculator "Merge" two Rasters - SyntaxError</title>
      <link>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490774#M27901</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Original User: Hornbydd&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Stefan,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Your syntax looks good but the error message is making a reference to no spatial reference. You need to ensure that both grids have the same coordinate system. You can use the Define Projection tool to set the raster that does not have a coordinate system defined.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;As a side note I see you are creating a raster in a &lt;/SPAN&gt;&lt;STRONG&gt;personal&lt;/STRONG&gt;&lt;SPAN&gt; geodatabase. Whilst that is possible I have found rasters in personal geodatabases to be problematic. I would strongly suggest you place the output raster in a &lt;/SPAN&gt;&lt;STRONG&gt;file&lt;/STRONG&gt;&lt;SPAN&gt; geodatabase or as an &lt;/SPAN&gt;&lt;STRONG&gt;ESRI grid&lt;/STRONG&gt;&lt;SPAN&gt; in a folder. ESRI grids seem to work best for raster processing but have a limited file name length.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Duncan&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Apr 2014 08:00:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490774#M27901</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2014-04-07T08:00:51Z</dc:date>
    </item>
    <item>
      <title>Re: Raster Calculator "Merge" two Rasters - SyntaxError</title>
      <link>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490775#M27902</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hello Duncan,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I tested your suggestion on my main computer but nothing changed i still had the same error messages...&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;But than i also tested it on my second computer and it worked absolutly perfect, no errors *sigh*&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Right now i reinstall my ArcGIS version on this PC i have the feeling it's damaged.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;really thx for you help &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 Apr 2014 12:53:14 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490775#M27902</guid>
      <dc:creator>Stefaningenfeld</dc:creator>
      <dc:date>2014-04-07T12:53:14Z</dc:date>
    </item>
    <item>
      <title>Re: Raster Calculator "Merge" two Rasters - SyntaxError</title>
      <link>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490776#M27903</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Hello Duncan,&lt;BR /&gt;&lt;BR /&gt;I tested your suggestion on my main computer but nothing changed i still had the same error messages...&lt;BR /&gt;&lt;BR /&gt;But than i also tested it on my second computer and it worked absolutly perfect, no errors *sigh*&lt;BR /&gt; &lt;BR /&gt;Right now i reinstall my ArcGIS version on this PC i have the feeling it's damaged.&lt;BR /&gt;&lt;BR /&gt;really thx for you help &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Hey! I'm having the same problem I'm not getting how to use the CON (Spatial ANALYST TOOL) to make the raster of both items, I guess you already figured it out! Please help me I need to know how to do this and Ive been stuck for days.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;If you could explain me with detail I will really appreciated! Thanks&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;My mail is &lt;/SPAN&gt;&lt;A href="mailto:luismunozd@me.com"&gt;luismunozd@me.com&lt;/A&gt;&lt;SPAN&gt; THANKS A LOT!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 May 2014 01:45:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/raster-calculator-amp-quot-merge-amp-quot-two/m-p/490776#M27903</guid>
      <dc:creator>luismunoz</dc:creator>
      <dc:date>2014-05-19T01:45:53Z</dc:date>
    </item>
  </channel>
</rss>

