Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to use sql order by convert int in dataset( Foxpro D
Message
De
14/03/2012 01:39:50
 
 
À
13/03/2012 22:37:06
Information générale
Forum:
ASP.NET
Catégorie:
Code, syntaxe and commandes
Versions des environnements
Environment:
VB 9.0
OS:
Windows XP
Database:
Visual FoxPro
Application:
Desktop
Divers
Thread ID:
01538279
Message ID:
01538283
Vues:
26
>Hi all,
> i use vb.net dataset and visual foxpro to database. I want to use sql to order by convert int.
>If use sql server i can SELECT * FROM apos ORDER BY CONVERT(int, scode).
>if visual FoxPro i also can SELECT Cast(sCode as int) as s, bcode, bcode2, descript, unit, cdescript, uprice FROM apos order by s
>
>But in vb.net dataset selectCommand i use SELECT Cast(sCode as int) as s, bcode, bcode2, descript, unit, cdescript, uprice FROM apos order by s, it will error say Error in list of function arguments: 'AS' not recognized. Unable to parse query text.
>
>How can i do? Thank you ~~~

Similar syntax to the above works for me using VFPOLEDB. Are you sure you do not have a typo in the code?
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform