Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Mline not returning all text
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 8 SP1
OS:
Windows 2000 SP4
Network:
Windows 2000 Pro
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01003652
Message ID:
01003754
Views:
23
Mark,

>i should have put in the complete original query!

That usually helps get to the answer quicker. *g*

>
>select mline(memo1,1) as "description"
>
>by changing this to
>
>select padr(mline(memo1,1),100) as "description"
>
>it works just fine. it didn't work with set memowidth to 50 and set _mline = 50 though!

This is caused by VFP running a prequery to determine how big to make the result column.. for the row it chose, the result of mline(memo1,1) was a single character, so it made that column c(1). Which is not big enough for most of the rows.

Anytime you use a variable width calculation in a SQL SELECT statement you should always use a function like padr() to give the column a finite desired width for the result.
df (was a 10 time MVP)

df FoxPro website
FoxPro Wiki site online, editable knowledgebase
Previous
Reply
Map
View

Click here to load this message in the networking platform