<?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: Creating unique logical IDS in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327369#M25420</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;it won't be related to any other databases.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;That's what they always say. :cool:&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 10 Jul 2012 17:00:08 GMT</pubDate>
    <dc:creator>curtvprice</dc:creator>
    <dc:date>2012-07-10T17:00:08Z</dc:date>
    <item>
      <title>Creating unique logical IDS</title>
      <link>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327366#M25417</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Hi there,&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've been tasked with creating unique IDs for a street light layer for a municipality, the client wants the unique IDs to be logical and sequential. &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;I've found scripts on how to make IDs with python based on FIDs, but this won't work in my case.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;For example, I'd like to have sequential IDs for street lights that are on the same street (close to eachother) rather than having streetlight #1 be in the East corner of the map and streetlight # 2 being at an opposite corner.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;So far I've created X and Y fields, but it still isn't AS logical as I'd like.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Does anyone know of a script I can use in Field Calculator that would work for something like this, or does more geoprocessing have to be done?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jul 2012 12:59:38 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327366#M25417</guid>
      <dc:creator>LaurenYee</dc:creator>
      <dc:date>2012-07-10T12:59:38Z</dc:date>
    </item>
    <item>
      <title>Re: Creating unique logical IDS</title>
      <link>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327367#M25418</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;I've been tasked with creating unique IDs for a street light layer for a municipality, the client wants the unique IDs to be logical and sequential. &lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;"Smart" unique unique feature ids are generally frowned upon in a database design. They seem like a good idea at the time, but the more used a database is, the more pain they can create. Imagine you have the streetlight sequential going down the street and then a streetlight is added&amp;nbsp; in between 003 and 004 -- there you are, your nice setup is immediately broken. It's far better to have unique IDs and have other fields carry that kind of information like labels that sequence the lights going down the street.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;This is your client, though!&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;There are many ways to approach this issue of sorting them going down the street. For example, you may be able to order ids along a set of streets going in the same direction by doing a NEAR to a point at one end and sorting by distance. You also may want to look into dynamic segmentation to address the points to locations along routes.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jul 2012 15:11:31 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327367#M25418</guid>
      <dc:creator>curtvprice</dc:creator>
      <dc:date>2012-07-10T15:11:31Z</dc:date>
    </item>
    <item>
      <title>Re: Creating unique logical IDS</title>
      <link>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327368#M25419</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;"Smart" unique unique feature ids are generally frowned upon in a database design. They seem like a good idea at the time, but the more used a database is, the more pain they can create. Imagine you have the streetlight sequential going down the street and then a streetlight is added&amp;nbsp; in between 003 and 004 -- there you are, your nice setup is immediately broken. It's far better to have unique IDs and have other fields carry that kind of information like labels that sequence the lights going down the street.&lt;BR /&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;SPAN&gt; &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Yeah, the idea for adding new streetlights would be to then start attaching letters to end of the number, which is simple enough I suppose.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;The only reason they want unique IDs is to organize and keep track of fixes, it won't be related to any other databases.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I already have address fields established to the poles, but this is what the client wants. I'm surprised ESRI hasn't made this process easier?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jul 2012 16:52:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327368#M25419</guid>
      <dc:creator>LaurenYee</dc:creator>
      <dc:date>2012-07-10T16:52:11Z</dc:date>
    </item>
    <item>
      <title>Re: Creating unique logical IDS</title>
      <link>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327369#M25420</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;it won't be related to any other databases.&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;That's what they always say. :cool:&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 10 Jul 2012 17:00:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/creating-unique-logical-ids/m-p/327369#M25420</guid>
      <dc:creator>curtvprice</dc:creator>
      <dc:date>2012-07-10T17:00:08Z</dc:date>
    </item>
  </channel>
</rss>

