Q

Question

C#, VFP, ERROR [22018] [Microsoft][ODBC Visual FoxPro Driver]Operator/operand type mismatch.

I am trying to pass a DateTime value to my FoxPro database in C# and getting the following exception
 ERROR [22018] [Microsoft][ODBC Visual FoxPro Driver]Operator/operand type mismatch.

I have tried passing value in many  different ways such via query string, or inline with query but failed.

I am only getting this exception while passing the  DateTime, I can pass any other data type in the query.

Your help is much appreciated.

201409-LO-Qu-014

Find Your Answer,
Ask the Experts.

Start your free trial

Free 30 day trial of a Premium Membership. Cancel anytime.

What's a Premium Membership?

Download the Experts Exchange Guide

Consulting & Contracting:
How to Go Out On Your Own

Can you become an independent contractor with your own business?

We will never share this with anyone.

Skill Training Video TutorialsExpand your tech skills quickly with five-minute, instructional videos.

See More Programming Videos

What does a Premium Membership get you?

  • Unlimited Access to over 4 million verified technology solutions

  • Unlimited Access to thousands of interactive articles and videos

  • Unlimited technical writing assistance

  • Submit your projects for Expert Testing

  • Expand your professional network with our messaging and hire me features

  • Ad free and mobile optimized experience

Join the Network Today!

See Plans and Pricing