Hello:
I have a data file where one of the columns contains full path names. Is there a trick to getting a basename from that field? Any builtins for other transformations on that field?
Appreciate any pointers.
Thanks,
Sarat.
Am 21.11.2020 um 01:18 schrieb Sarat Sreepathi:
Hello:
I have a data file where one of the columns contains full path names.
Is there a trick to getting a basename from that field? Any builtins
for other transformations on that field?
Appreciate any pointers.
Thanks,
Sarat.
Recursion: ;)
basen(fullp) = (a = strstrt(fullp,'\'), a == 0 ? fullp : basen( substr(fullp,a+1,strlen(fullp) ) ) )
pr basen('helo')
pr basen('helo\halo')
pr basen('helo\halo\holo')
In the same way you can delete (possibly multiple) .extensions from the filename.
Sysop: | Keyop |
---|---|
Location: | Huddersfield, West Yorkshire, UK |
Users: | 185 |
Nodes: | 16 (1 / 15) |
Uptime: | 08:27:52 |
Calls: | 3,649 |
Calls today: | 5 |
Files: | 11,145 |
Messages: | 3,445,099 |