Hi All,
I have a python script that generates an access mdb with tables. These tables need some serious reformatting. I used to import a module by hand and run some macro's to do the job.
Now I try to migrate this module to the software(Esri ArcGIS) from where the python script is run. Now I'm stuck on a couple of sql queries using InStrRev.
I get the 'Undefined function InStrRev in expression' error.
Here's the sql:
UPDATE lGelrail_ONDERHOUDER SET lGelrail_ONDERHOUDER.SORT = IIf(InStr([LAYER],"_")>1 And InStrRev([LAYER],"_") <> InStr([LAYER],"_"),Mid([LAYER],InStr([LAYER],"_")+1, InStrRev([LAYER],"_")-InStr([LAYER],"_") - 1),[FEATCL])
It took me quite some time to construct these sqls, which update a field using a substring between '_' in another field.
I saw some .Net solutions but Im on vb6.
Is there a way??
Thanks
I have a python script that generates an access mdb with tables. These tables need some serious reformatting. I used to import a module by hand and run some macro's to do the job.
Now I try to migrate this module to the software(Esri ArcGIS) from where the python script is run. Now I'm stuck on a couple of sql queries using InStrRev.
I get the 'Undefined function InStrRev in expression' error.
Here's the sql:
UPDATE lGelrail_ONDERHOUDER SET lGelrail_ONDERHOUDER.SORT = IIf(InStr([LAYER],"_")>1 And InStrRev([LAYER],"_") <> InStr([LAYER],"_"),Mid([LAYER],InStr([LAYER],"_")+1, InStrRev([LAYER],"_")-InStr([LAYER],"_") - 1),[FEATCL])
It took me quite some time to construct these sqls, which update a field using a substring between '_' in another field.
I saw some .Net solutions but Im on vb6.
Is there a way??
Thanks