Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
VARTYPE in ASP
Message
General information
Forum:
Visual FoxPro
Category:
Internet applications
Title:
Miscellaneous
Thread ID:
00265554
Message ID:
00265655
Views:
18
>Thank's Hugo!
>
>This is good tip.
>
>I am here all day trying to find out what type my recordset("filed") has.
>Lets say I have VFP table with a structure:
>F1 C(10)
>F2 N(10,2)
>F3 I
>F4 Y
>So I ran a simple select
>SET rs=conn.execute("select * from table")
>My rs("F1").Value - should be C(10)
> rs("F2").Value - should be N(10,2)
> rs("F3").Value - should be I
> rs("F4").Value - should be ??? I don't know what type shuold be here ???
>
>If this truth why when I am doing subtotals like this
>
>DO WHILE NOT RS.EOF
> tF1=0
> cF1 = RS('F1').Value
> DO WHILE cF1 = RS('F1').Value
> tF1=tF1+RS('F2').Value (*)
> LOOP
>LOOP
>
>It's a simple model but it gives me an error in (*) string, saing that I have data type mismatch.
>
>What I am doing wrong ?
>How ignorant I am ?

The fields collection of a recordset has a type property.
Tim Westmoreland
Software Engineer
Skyline Technologies, Inc.

"Upper classes are a nation's past; the middle class is its future." - Ayn Rand, Russian-born author (1905-1982).
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform