<?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 import table from sql server to file geodatabsae in Data Management Questions</title>
    <link>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323162#M18466</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;ArcGIS 10.2.2.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm trying to import a table from a SQL Server database (not a geodatabase) to a file geodatabase.&amp;nbsp; In SQL Server, the table has a primary key that ArcGIS recognizes as an Object ID field.&amp;nbsp; When I import the table into the file geodatabase, ArcGIS ignores the primary key and creates a new Object ID field.&amp;nbsp; I need the primary key to stay with the table.&amp;nbsp; How can I import a table from a non geodatabase into a geodatabase and still keep the primary key?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 10 Jun 2014 22:22:53 GMT</pubDate>
    <dc:creator>StephanieSnider</dc:creator>
    <dc:date>2014-06-10T22:22:53Z</dc:date>
    <item>
      <title>import table from sql server to file geodatabsae</title>
      <link>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323162#M18466</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;ArcGIS 10.2.2.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I'm trying to import a table from a SQL Server database (not a geodatabase) to a file geodatabase.&amp;nbsp; In SQL Server, the table has a primary key that ArcGIS recognizes as an Object ID field.&amp;nbsp; When I import the table into the file geodatabase, ArcGIS ignores the primary key and creates a new Object ID field.&amp;nbsp; I need the primary key to stay with the table.&amp;nbsp; How can I import a table from a non geodatabase into a geodatabase and still keep the primary key?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jun 2014 22:22:53 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323162#M18466</guid>
      <dc:creator>StephanieSnider</dc:creator>
      <dc:date>2014-06-10T22:22:53Z</dc:date>
    </item>
    <item>
      <title>Re: import table from sql server to file geodatabsae</title>
      <link>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323163#M18467</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;What is the name of the primary key column?&amp;nbsp; ArcGIS tends to assume that columns&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;named "objectid" are available for reassignment.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;You don't say how you're going about the transition, or what language/interface you're&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;using, but one way to preserve your data is to recreate the table schema with an initial&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;objectid column and renaming the primary key into something obvious ("origid"), then&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;copying the contents, through a view or other query to include a row number in the&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;objectid spot, and renaming the original PK to the new name.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;- V&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jun 2014 01:58:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323163#M18467</guid>
      <dc:creator>VinceAngelo</dc:creator>
      <dc:date>2014-06-11T01:58:27Z</dc:date>
    </item>
    <item>
      <title>Re: import table from sql server to file geodatabsae</title>
      <link>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323164#M18468</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;The primary key field name is "Interest_ID".&amp;nbsp; I can't modify the fields of that table because of a .NET application that uses it.&amp;nbsp; This application is the life blood of our organization, and we don't have a test environment.&amp;nbsp;&amp;nbsp; For now away, modifying the fields even to add a new field is not a risk I'm willing to take as it would break our contract with the company that developed the app.&amp;nbsp; I've tried exporting the table from SQL Server to the file geodatabase using the geoprocessing tools but that removes the primary key.&amp;nbsp; I am able to do a join within the mxd and keep the primary key field, but I'd prefer a more permanent solution.&amp;nbsp; Ultimately, I'd like to set up this process in python to run each night so that the dataset is available to our staff....not just available through the map service.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jun 2014 14:19:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323164#M18468</guid>
      <dc:creator>StephanieSnider</dc:creator>
      <dc:date>2014-06-11T14:19:00Z</dc:date>
    </item>
    <item>
      <title>Re: import table from sql server to file geodatabsae</title>
      <link>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323165#M18469</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I found a solution.&amp;nbsp; I can create a view of the table in SQL Server.&amp;nbsp; Then I&amp;nbsp; export the view to the file geodatabase and it keeps the primary key field while adding an Object ID field.&amp;nbsp; Yeah!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jun 2014 14:50:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323165#M18469</guid>
      <dc:creator>StephanieSnider</dc:creator>
      <dc:date>2014-06-11T14:50:18Z</dc:date>
    </item>
    <item>
      <title>Re: import table from sql server to file geodatabsae</title>
      <link>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323166#M18470</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;File geodatabase isn't a full SQL implementation, and it doesn't honor a true primary key.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;It's a "feature" of file geodatabase that an objectid column will be promoted from the first&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;integer column it finds (or a "Miranda" objectid column will be created), and the contents&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;assigned sequentially from 1, so it is not possible to copy this table into a file geodatabase&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;without either losing the Interest_ID value or changing table organization to include an initial&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;ObjectID column.&amp;nbsp; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The ObjectID is not really a true column, so your legal staff might be able to argue that you &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;haven't "changed" the table (though I do wonder about their willingness to sign off on such a &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;data use constraint).&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;- V&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jun 2014 15:04:29 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323166#M18470</guid>
      <dc:creator>VinceAngelo</dc:creator>
      <dc:date>2014-06-11T15:04:29Z</dc:date>
    </item>
    <item>
      <title>Re: import table from sql server to file geodatabsae</title>
      <link>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323167#M18471</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Creating a view of the table will work for my needs.&amp;nbsp; We don't have ArcSDE....no license for it.&amp;nbsp; Thanks.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 11 Jun 2014 15:42:10 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/import-table-from-sql-server-to-file-geodatabsae/m-p/323167#M18471</guid>
      <dc:creator>StephanieSnider</dc:creator>
      <dc:date>2014-06-11T15:42:10Z</dc:date>
    </item>
  </channel>
</rss>

