Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Saving space with Varchar
Message
From
05/09/2008 14:21:03
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Environment versions
Visual FoxPro:
VFP 9 SP2
OS:
Vista
Network:
Windows XP
Database:
Visual FoxPro
Miscellaneous
Thread ID:
01345228
Message ID:
01345233
Views:
17
>I thought the varchar field type would save space in the file size of my table?
>
>I have a table that has thousands of records and many character fields, I thought by changing the character fields to varchar the table size would be reduced?
>
>Have I got this all wrong?

The table size is not reduced. As I understand it, VFP VarChar is there mainly to improve interoperability with SQL Server. IIRC another effect is different handling of trailing spaces/column padding. See the help: "HELP FIELD TYPES" for VarChar, including the code sample.
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform