Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFPOLEDB Bug or ?
Message
De
20/02/2010 09:35:59
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
 
À
20/02/2010 06:50:45
Information générale
Forum:
Visual FoxPro
Catégorie:
Problèmes
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Database:
Visual FoxPro
Divers
Thread ID:
01449715
Message ID:
01450049
Vues:
59
>>Yes Gregory,
>>That is the problem. It works as if it is a date only value.
>>Cetin
>>
>
>
>Cetin,
>
>To exclude foxpro anomalies, I have tried it with vbs and I can confirm that vbs also loses the time part.
>
>
>
>We cannot blame it on foxpro. VBS is also wrong
>Now, if .net works it cannot be VFPOLEDB
>
>So, I'm intrigued where it goes wrong. I believe both vfp and vbs pass a VT_DATE
>
>
>WScript.Echo Now()
>
>
>
>Set loCon = Createobject("AdoDb.Connection")
>Set loCmd = Createobject("Adodb.Command")
>
>loCon.ConnectionString="Provider=VFPOLEDB;Data Source=D:\Project9\Parse\Data\tmp.dbc"
>
>loCon.CursorLocation= 3    'adUseClient
>loCon.Open()
>loCmd.ActiveConnection=loCon
>loCmd.CommandText="insert into Test (f1, f2) values (123,?)"
>
>Set loParm = loCmd.CreateParameter("f2")
>
>loParm.Type = 135 
>
>loParm.Value = Now()
>
>loCmd.Parameters.Append( loParm )
>
>loCmd.Execute()
>
>loCon.Close
>
Thanks for trying in VB. I still blame on foxpro because if I do it against SQL server using SQLOLEDB, SQLNCLI driver the time part is included. It is not how VFP passes it, it is not VFPOLEDB then who is guilyty? Me for sure trying to use it from VFP:)
Cetin
Çetin Basöz

The way to Go
Flutter - For mobile, web and desktop.
World's most advanced open source relational database.
.Net for foxheads - Blog (main)
FoxSharp - Blog (mirror)
Welcome to FoxyClasses

LinqPad - C#,VB,F#,SQL,eSQL ... scratchpad
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform