The varchar mapping in queries is controlled by SET VARCHARMAPPING command which is set to OFF by default for backward compability. Are you using RTM or beta version of VFP9?
>I just upgraded an app and found that the new Varchar is causing some rather surprising issues.
>
>I have some SELECT statements which have the traditional: PADR([expr],xx) as FieldName to create fields of the appropriate length in the cursor. Well, VFP9 is now casting these by default as Varchar. Ok. Fine. Well, I also then copy this cursor out to a Fox2x DBF. Pretty common export scenario. Well, the varchars of any length are all converted to memo fields.
>
>Am I doing something wrong? I can't find anything in the documenation about this. I'm a tad surprised that the default casting for a character expression is varchar. I'm also surprised that a varchar(10) gets turned into a memo field instead of a char(10) with COPY TO.
>
>Do I need to go back and check/fix every SELECT in my code?
--sb--