![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
How would I read a unix file with parentheses in the filename For Example: ct /tmp filename(date).txt It likes to think anything after ( is options |
#3
| |||
| |||
|
|
On 19 Aug, 19:48, Specific <domp... (AT) gmail (DOT) com> wrote: How would I read a unix file with parentheses in the filename For Example: ct /tmp filename(date).txt It likes to think anything after ( is options Try preceding both ( and ) with \ A backslash means "the following character is to be taken literally" in Unix convention. The CHANGE() function of Databasic is useful to do that automatically. |
#4
| |||
| |||
|
|
How would I read a unix file with parentheses in the filename For Example: ct /tmp filename(date).txt It likes to think anything after ( is options |
#5
| |||
| |||
|
|
I'd try ct /tmp "filename(date).txt" -- frosty "Specific" <domp... (AT) gmail (DOT) com> wrote in message news:3f6c9169-2d89-4d35-a94c-e21a8e311d50 (AT) b4g2000pra (DOT) googlegroups.com... How would I read a unix file with parentheses in the filename For Example: ct /tmp filename(date).txt It likes to think anything after ( is options |
#6
| |||
| |||
|
|
On Aug 19, 3:47*pm, "frosty" <fros... (AT) bogus (DOT) invalid> wrote: I'd try ct /tmp "filename(date).txt" -- frosty "Specific" <domp... (AT) gmail (DOT) com> wrote in message news:3f6c9169-2d89-4d35-a94c-e21a8e311d50 (AT) b4g2000pra (DOT) googlegroups.com... How would I read a unix file with parentheses in the filename For Example: ct /tmp filename(date).txt It likes to think anything after ( is options I think ct checks deliminates by ( *so I'll have to try the list-item method output of \( and in quotes is filename(T not on file. |
#7
| |||
| |||
|
|
How would I read a unix file with parentheses in the filename For Example: ct /tmp filename(date).txt It likes to think anything after ( is options |
#8
| |||
| |||
|
|
list-item worked great, however, what if I want to delete an item with (? I think delete would have the same problem as CT |
#9
| |||
| |||
|
|
On 19/08/2010 22:58, Specific wrote: list-item worked great, however, what if I want to delete an item with (? I think delete would have the same problem as CT Try something like: SELECT /tmp WITH *A0 = "[(]" DELETE /tmp Note you may want to refine that selection a little - that will (should) select any item with an open parenthesis anywhere in the item-id. I'm also going on memory for the dictionary item to use (*A0). In Information flavours, I would now use @ID but I don't think the pure PICK flavours have that. Cheers, Brian |
#10
| |||
| |||
|
|
Top-post follow-up to Brian's note. *It seems you're using D3 so: SELECT /tmp = "[whatever]" We don't need *A0 for a simple query like that. *And it's correct that D3 doesn't support @ID by default, however, given a couple minutes to play with it I believe it's easily doable. You can also simply do the rm operation from TCL to shell out and execute the host OS command: !rm /tmp/filename_with_(funky?)_characters If this is a one-shot then make use of the transparency between D3 and the OS using "!", or with OSFI /tmp references as you're doing. If you're doing a lot of these (for anyone reading this) then it's inefficient to shell out for a lot of operations, and better to ! to a single command that uses grep, pipe, and rm, all in a single command. HTH Brian Speirs wrote: On 19/08/2010 22:58, Specific wrote: list-item worked great, however, what if I want to delete an item with (? I think delete would have the same problem as CT Try something like: * *SELECT /tmp WITH *A0 = "[(]" * *DELETE /tmp Note you may want to refine that selection a little - that will (should) select any item with an open parenthesis anywhere in the item-id. I'm also going on memory for the dictionary item to use (*A0). In Information flavours, I would now use @ID but I don't think the pure PICK flavours have that. Cheers, Brian |
![]() |
| Thread Tools | |
| Display Modes | |
| |