Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VFP6 Using strtran with wildcards
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00429940
Message ID:
00429974
Views:
23
>>Hi All,
>>
>>Is it possible to use wildcards with the strtran function.
>>
>>I'd like to remove all the text between two parenthesis along with the parenthesis from a field in a table.
>>
>>The horse_name field is populated with data like this:
>>
>> Best Hanover (Best Hanover's Mommy)
>>
>>I want to change the field to this:
>>
>> Best Hanover
>>
>>Here's a sample of what I've tried but doesn't work.
>>
>>replace horse_name with strtran(horse_name,"(*)","")
>>
>>
>
>replace horse_name with left(horse_name, at("(", horse_name)-1))

This gives me a error message "command contains unrecognized phrase/keyword"

Do you think that the strtran function can be used with wildcards?
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform