Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Blank DateTime field values and VFP OLE DB
Message
De
27/06/2007 11:21:29
Cetin Basoz
Engineerica Inc.
Izmir, Turquie
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Network:
Windows 2000 Server
Database:
MS SQL Server
Divers
Thread ID:
01235998
Message ID:
01236009
Vues:
17
>Hi everyone,
>
>Our company is writing a new application in .NET 2003 with the Mere Mortals framework, and we have to include a componenet that queries against VFP tables via OLE DB 6.0.
>
>Basically, the .NET component will query against a free VFP table to get any records that have a nonzero value in the Status field (integer) and a blank datetime value in the DTRANSMIT field. For whatever reason, the query returns 69 records via OLE DB, but if I run it in VFP against the same table, I get 2428 records.
>
>Here's the SQL statement we're trying to run through the OLE DB connection:
>
>select * from hcfahold where (status <> 0) and Cast(dtransmit as d) < {^'1900-01-01'}
>
>If anyone has any insight to get OLE DB to return the same number of records as VFP, I would sincerely appreciate it.
>
>Thanks,
>
>Ben Holton

select * from hcfahold where (status <> 0) and Cast(dtransmit as d) = {}

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
Répondre
Fil
Voir

Click here to load this message in the networking platform