Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Char vs Varchar in Index
Message
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00843921
Message ID:
00844054
Views:
33
>Larry,
>
>I'm not Andy, but I'll take a SWAG. A VARCHAR can contain 1 to n characters where n equals the maximum field size. A CHAR is fixed. I would think that resolving a variable length expression would be slower than a fixed length expression.

Hi George,
I would normally agree but this is an index we're talking about. Character expressions are compared one character at a time (at least they were in SQL Server of old). If index keys are stored in the same way field data is tired (e.g variable length) then I would think VARCHAR would be faster. However, I would think the difference would be neglible.

Regards.
Larry Miller
MCSD
LWMiller3@verizon.net

Accumulate learning by study, understand what you learn by questioning. -- Mingjiao
Previous
Reply
Map
View

Click here to load this message in the networking platform