POST
|
Once again Thank You. Yes it's true, that it is working also. I thinking about one thing more. If I have file: almukantarat_B.csv and use script: >>> for file in arcpy.ListFiles("*.csv"): ... rootname = file.split("_")[1] ... rootname2 = rootname.split(".")[0] then probably I have 3 parts: - almukantarat (rootname[1]) - B (rootname2[0]) - csv (rootname2[1]) So How Can I join those parts to get name: "almukantarat_B.csv" . I think I can use those 3 parts and command join, but could You explain how script should look like? I'm asking about it because then I will more possibility and the script will be more universal in case which I describe in my first post. So then I will can compare files between two folders without caring about file from folder2. The structure of file could be: *_*.csv. By the way: I'm very positive surprised of this forum and presence very helpful persons.:o
... View more
09-25-2013
10:27 PM
|
0
|
0
|
1601
|
POST
|
I tried to use this script and it seems that everything is working. Thank You. I have one question more why in this script "fileName = file.split(".")[0]" exist "[0]. What is changing by this? Maybe it is not smart question, but as I mentioned I just started in python.
... View more
09-25-2013
03:41 AM
|
0
|
0
|
1601
|
POST
|
I think that in this example every each file from folder1 is comparing with all files from folder2. My intention is comparing first file from folder1 with first file from folder2, than second file from folder1 with second folder from folder2.
... View more
09-24-2013
02:01 AM
|
0
|
0
|
1601
|
POST
|
Hi, Thank You so much, I will try to implement Your suggestion, and of course I will let You know if it is working. Thanks.
... View more
09-24-2013
01:25 AM
|
0
|
0
|
1601
|
POST
|
I'm pretty new user of ArcGIS. My intention is compare contents of the files (csv) from one folder with files in another folders . In those folders exist files with the same name but in second folder files have different endings. First Folder: almukantarat.csv almukantarat1.csv Second Folder: almukantarat_A.csv almukantarat1_A.csv I don't know, maybe it can be done in Python or only in ModelBuilder (using Compare files?). Please, could You help me how script or model should look like? I have ArcGIS Desktop 10.0. In one file could be thousands objects, in each folder could be hundred files, so from my site it isn't possible to compare it manually.Thanks a lot
... View more
09-22-2013
11:29 PM
|
0
|
7
|
5238
|
Online Status |
Offline
|
Date Last Visited |
11-11-2020
02:23 AM
|