<?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: Using Python to print a &amp;quot;database view definition&amp;quot;?!  in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/using-python-to-print-a-quot-database-view/m-p/672308#M51998</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Short answer is you can't, unfortunately.&amp;nbsp; The&amp;nbsp;&lt;A class="link-titled" href="https://support.esri.com/en/other-resources/gis-dictionary/term/table%20view" title="https://support.esri.com/en/other-resources/gis-dictionary/term/table%20view"&gt;table view | Definition - Esri Support GIS Dictionary&lt;/A&gt; &amp;nbsp; isn't what you think it is, at least in terms of the Describe classes:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;SPAN style="color: #595959; font-family: 'Avenir Next W01', 'Avenir Next W00', 'Avenir Next', Avenir, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 15.9375px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 300; letter-spacing: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff; text-decoration-style: initial; text-decoration-color: initial; display: inline !important; float: none;"&gt;A representation of tabular data for viewing and editing purposes. The table view created when a table is added to ArcMap is a copy of the actual table data stored in memory.&lt;/SPAN&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;The TableView is an ArcGIS object, not a database object.&amp;nbsp; Exploring the &lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-functions/describe.htm" title="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-functions/describe.htm"&gt;Describe—Help | ArcGIS Desktop&lt;/A&gt; property groups, one sees there is no group of properties for either "Database View" or just "View," which is what we would need to extract the SQL behind a database view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now you might be thinking, why does &lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-data-access/walk.htm" title="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-data-access/walk.htm"&gt;Walk—Help | ArcGIS Desktop&lt;/A&gt; return the database views when I pass datatype of "Table"?&amp;nbsp; I can't answer that question, maybe someone from Esri can weigh in on that one.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 06 Apr 2018 13:50:26 GMT</pubDate>
    <dc:creator>JoshuaBixby</dc:creator>
    <dc:date>2018-04-06T13:50:26Z</dc:date>
    <item>
      <title>Using Python to print a "database view definition"?!</title>
      <link>https://community.esri.com/t5/python-questions/using-python-to-print-a-quot-database-view/m-p/672307#M51997</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am attempting to interrogate an SQL Server Enterprise Geodatabase using Python. I want to obtain information for all features, relationships, tables etc. within said database. (I have only been using python for about a week. So please be detailed.)&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am having an issue with the TableViews. When using the &lt;EM&gt;walk&lt;/EM&gt; function, with a datatype of "Table", I can print the File Name, but not the &lt;STRONG&gt;&lt;EM&gt;WhereClause&lt;/EM&gt;&lt;/STRONG&gt;. (I can see the definition in the View Properties dialog box.)&amp;nbsp;&lt;IMG class="image-1 jive-image" src="https://community.esri.com/legacyfs/online/400720_pastedImage_4.png" style="width: auto; height: auto;" /&gt;&lt;/P&gt;&lt;P&gt;I'm not sure how 'off' I am in my procedure and syntax. I have been trying the following statement |||&amp;nbsp;&lt;SPAN class="" style="color: #4d4d4d;"&gt;desc&lt;/SPAN&gt;&lt;SPAN style="color: #4d4d4d; background-color: #fafafa;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;=&lt;/SPAN&gt;&lt;SPAN style="color: #4d4d4d; background-color: #fafafa;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;arcpy&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;.&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;Describe(TableViewName)&amp;nbsp;&lt;/SPAN&gt;&lt;SPAN class="" style="color: blue;"&gt;print&lt;/SPAN&gt;&lt;SPAN style="color: #4d4d4d; background-color: #fafafa;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #a31515;"&gt;"Where Clause: "&lt;/SPAN&gt;&lt;SPAN style="color: #4d4d4d; background-color: #fafafa;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;+&lt;/SPAN&gt;&lt;SPAN style="color: #4d4d4d; background-color: #fafafa;"&gt; &lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;desc&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;.&lt;/SPAN&gt;&lt;SPAN class="" style="color: #4d4d4d;"&gt;whereClause&lt;/SPAN&gt;&lt;SPAN style="color: #4d4d4d; background-color: #fafafa;"&gt;&amp;nbsp;|||&amp;nbsp; &lt;/SPAN&gt;(I pulled this from the TableView properties example on the ArcPy Help on ArcGIS.com.)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;Any ideas?! Thanks!&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 05 Apr 2018 21:30:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/using-python-to-print-a-quot-database-view/m-p/672307#M51997</guid>
      <dc:creator>Rachel_R_Marquez</dc:creator>
      <dc:date>2018-04-05T21:30:40Z</dc:date>
    </item>
    <item>
      <title>Re: Using Python to print a "database view definition"?!</title>
      <link>https://community.esri.com/t5/python-questions/using-python-to-print-a-quot-database-view/m-p/672308#M51998</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Short answer is you can't, unfortunately.&amp;nbsp; The&amp;nbsp;&lt;A class="link-titled" href="https://support.esri.com/en/other-resources/gis-dictionary/term/table%20view" title="https://support.esri.com/en/other-resources/gis-dictionary/term/table%20view"&gt;table view | Definition - Esri Support GIS Dictionary&lt;/A&gt; &amp;nbsp; isn't what you think it is, at least in terms of the Describe classes:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;SPAN style="color: #595959; font-family: 'Avenir Next W01', 'Avenir Next W00', 'Avenir Next', Avenir, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 15.9375px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: 300; letter-spacing: normal; orphans: 2; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff; text-decoration-style: initial; text-decoration-color: initial; display: inline !important; float: none;"&gt;A representation of tabular data for viewing and editing purposes. The table view created when a table is added to ArcMap is a copy of the actual table data stored in memory.&lt;/SPAN&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;The TableView is an ArcGIS object, not a database object.&amp;nbsp; Exploring the &lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-functions/describe.htm" title="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-functions/describe.htm"&gt;Describe—Help | ArcGIS Desktop&lt;/A&gt; property groups, one sees there is no group of properties for either "Database View" or just "View," which is what we would need to extract the SQL behind a database view.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now you might be thinking, why does &lt;A class="link-titled" href="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-data-access/walk.htm" title="http://desktop.arcgis.com/en/arcmap/latest/analyze/arcpy-data-access/walk.htm"&gt;Walk—Help | ArcGIS Desktop&lt;/A&gt; return the database views when I pass datatype of "Table"?&amp;nbsp; I can't answer that question, maybe someone from Esri can weigh in on that one.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 06 Apr 2018 13:50:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/using-python-to-print-a-quot-database-view/m-p/672308#M51998</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2018-04-06T13:50:26Z</dc:date>
    </item>
  </channel>
</rss>

