Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFPOLEDB Bug or ?
Message
De
20/02/2010 06:50:45
 
 
À
18/02/2010 10:48:26
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
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:
01450026
Vues:
73
>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
Gregory
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform