Distance Between Tow layers Based on Unique field with network analysis

1118
10
04-05-2011 06:25 AM
Highlighted
New Contributor
Hi
I'm Trying to Calculate the Shortest Distance Between Tow points within tow layers using unique code, based on network analyst.
The number of records in each table is similar.
Closest Facility does not match with my goal, because the output is a matrix from each point in the Base layer to each point in the Target Layer.
I can't do this manually, because the layers has more then one million records

My request  is, for example - to count the distance from field to filed that has the same unique number :
the distance field result should be: from unique 1 in layer A to Unique 1 in layer B
The number of records should be equal to the number of records in each table
I attached excel file for demo

Is their a Script, a Patch or Manual that preform this kind of function?

Thank you Very Much!
Locking foreword to your Answer
Tags (2)
Reply
0 Kudos
10 Replies
Highlighted
Esri Regular Contributor
This is easy to do with the Route solver using the ROUTENAME property. This has been described in the forums many times. Search on the ROUTENAME and you will find previous posts. For example:
http://forums.arcgis.com/threads/12128-add-origin-amp-destination-locations-from-the-same-row-to-a-r...

Jay Sandhu
Reply
0 Kudos
Highlighted
New Contributor
This is easy to do with the Route solver using the ROUTENAME property. This has been described in the forums many times. Search on the ROUTENAME and you will find previous posts. For example:
http://forums.arcgis.com/threads/12128-add-origin-amp-destination-locations-from-the-same-row-to-a-r...

Jay Sandhu





Hi Jay
First Of all Thank you
I have tried it with small try layers and it worked.
when i loaded the full layer (about 2 million records) the window below indicates that loading completed, but the bar shows the "stops" has only a number of 71200
1. Is it Possible?
2. Are their limitations of records?
I'm working with arcgis 10, and windows 7, 32 bit
Thank you
Reply
0 Kudos
Highlighted
Esri Regular Contributor
There are no limitations on the record numbers. Though loading and working with 2 million may take a while. Have you opened the Stops sub layer's attribute table and verified their are only 71,200 records? The NA Window does not allow you to "expand" the stops there as it will take a long time to refresh that window if their are hundred's of things in it. But will show a accurate number of records that were loaded.

You could also run the GP tool Add Locations to first compute the network location fields on your input data (both sets) and look at the status field to make sure they are getting "located" on the network. Once you have verified that the data is correct then you can load this data into a route layer's Stops feature class using the network fields (not geometry) and the load will go very fast.

Jay Sandhu
Reply
0 Kudos
Highlighted
New Contributor
There are no limitations on the record numbers. Though loading and working with 2 million may take a while. Have you opened the Stops sub layer's attribute table and verified their are only 71,200 records? The NA Window does not allow you to "expand" the stops there as it will take a long time to refresh that window if their are hundred's of things in it. But will show a accurate number of records that were loaded.

You could also run the GP tool Add Locations to first compute the network location fields on your input data (both sets) and look at the status field to make sure they are getting "located" on the network. Once you have verified that the data is correct then you can load this data into a route layer's Stops feature class using the network fields (not geometry) and the load will go very fast.

Jay Sandhu


Hi Jay
Thanks!
The main problem that I'm having at the moment is after loading completed successfully:
I'm Trying to save, or to load the second layer, but the arcgis collapse, giving me no chance to save or load.
I have attached the error massage.

At the first time, i maneged to Press the save button, and when I'm trying to open the mxd the following appears:
"Could not Open Template: c:\....\ArcMap\Templates\Normal.mxt"

My be i need to split the records? (1 million or less?)

Thanks
Yonatan
Reply
0 Kudos
Highlighted
Esri Regular Contributor
Do try by splitting the data. Can you tell me what version of the ArcGIS software you are using and how much RAM is on that machine? It could be running out of memory.

Jay Sandhu
Reply
0 Kudos
Highlighted
New Contributor
Do try by splitting the data. Can you tell me what version of the ArcGIS software you are using and how much RAM is on that machine? It could be running out of memory.

Jay Sandhu


HI
I have Arcgis10 and windows 7 32 bit
I tried to split the records for 650K, but the arcmap crashed.
WHich number should i choose?
Thanks
Reply
0 Kudos
Highlighted
New Contributor
HI
I have Arcgis10 and windows 7 32 bit
I tried to split the records for 650K, but the arcmap crashed.
WHich number should i choose?
Thanks


8 GB RAM (HP Z600 WORKSTATION)
Reply
0 Kudos
Highlighted
New Contributor
8 GB RAM (HP Z600 WORKSTATION)


Hi Jay
I Upgraded my system to 64 bit, and even sow, after the first successfull load, I'm unable to save or to load another layer.
(with 650k)
Do you have a possible solution to me? maybe the form of the layers? now they are in GDB format
I want to mark, that once i manged loading the same layers, 2m records, twice to "closest facility" function.
Thank you
Reply
0 Kudos
Highlighted
Esri Regular Contributor
It is hard to say what number will work, but how about processing 100k at a time.
That way if it works you can repeate it 20 times and get the work done.

Jay Sandhu
Reply
0 Kudos