|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Bad substitution error :chomp:
Hello all,
I'm using Korn shell and can execute this line with no problem at the command line. newtest=${gorseve_file//.csv/_log.txt } gorseve_file = gorseve_8762.csv ( what the var. was) echo $newtest gorseve_8762_log.txt In my script however, I receive a bad substitution error? |
|
#2
|
|||
|
|||
|
This is driving me crazy, been searching around for solution,
Is there another way to set a variable = to a substring or I think its some error with the brackets and korn shell?? thx in advance |
|
#3
|
|||
|
|||
|
Two things:
If you show the code that fails it is much easier to spot problems. What you show has errors Code:
gorseve_file = gorseve_8762.csv There is a space before the = and after it, for example. But I can't tell if that is in the script. |
![]() |
| Viewing: Dev Shed Forums > Operating Systems > UNIX Help > Bad substitution error :chomp: |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|