Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Force Calculated Field to Type Integer in View?
Message
From
29/11/2002 03:10:21
 
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Miscellaneous
Thread ID:
00727704
Message ID:
00728113
Views:
13
Hello again ..

i've tested a bit more now .. in VFP 8 this limitation seems to be taken away ..

i was able to do a DBSETPROP('view.field','field','datatype','I')
on a local view and it kept the parameter .., but the conversion with INT() on the calculation was needed so the view really don't displays the decimal places .. (but it didn't crash when the INT() was not used, it just displayed the decimal places .. and at the same time DBGETPROP returned 'I' for the Datatype) ..

a cursoradapter with a INT() around the calculation and without any CursorSchema set seems to know that it's gonna be an integer and directly maps it correct

a cursoradapter without a INT() but with the cursorschema set to 'I' for the calced column didn't work at all when trying to fill it with CursorFill(.t.,.f.) (aerror -> Result is incompatible with cursor schema) - this one made me wonder since it wouldn't be a problem to do a implicit conversion to Int wouldn't it? and what is even more strange that the same thing on remote data works just nice ..


ok ... enough inconsistency for now :)

but hey, better inconsistent feature richness than consistent limitation ..
wouldn't you agree

Regards

Christian
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform