Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Select, substr(), and MEMO.... HELP!!!
Message
From
22/11/2000 22:26:50
Dragan Nedeljkovich (Online)
Now officially retired
Zrenjanin, Serbia
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00444398
Message ID:
00444883
Views:
14
>>I am trying to use SQL select to get the first 60 chars of a memo field that represents the description of some work to be done. I need it to result in a 60 char text field that I can display in a browse window.
>>
>>...
>>Select item, substr(desc,1,60), price from WorkTable into table Items
>>Browse

My best shot would be

Select item, PADR(desc,60), price from WorkTable into table Items

So it will invariably create a c(60) field, regardless of the length of the memo. Padx() functions are just great, they work with any sort of parameter - logical, date, all sorts of numbers, and (surprised?) strings and memos.

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform