Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Query

Posted on 2000-02-18
3
Medium Priority
?
173 Views
Last Modified: 2010-04-04
Hi

please tel me whats wrong with this
Query1.Sql.Add ('select * from Invoice');
Query1.Sql.Add ('Where Date >= "1/1/2000" and Date <= "31/1/2000"');
When i run the program give me type mismatch expression

0
Comment
Question by:sivatagiherceg
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 8

Accepted Solution

by:
ZifNab earned 10 total points
ID: 2534396
hi,

A / is interpreted as M/D/Y. A . is interpreted as D.M.Y.

Thus :

11/1/99 is November 1, 1999.

11.1.99 is January 11, 1999.

here is an example with the orders.db from dbdemo

select *
from orders
where (SaleDate >= '04/12/1988') AND (SaleDate <= '08/12/1988')


Regards, Zif.
 
0
 
LVL 5

Expert Comment

by:TheNeil
ID: 2534402
Make sure that your dates are formatted correctly. I find that it expects them to be in the format

YYYY-MM-DD HH:MM:SS

You could also try getting rid of the "s

Have you tried your queries out in database desktop or somtehing similar?

The Neil

0
 
LVL 8

Expert Comment

by:ZifNab
ID: 2534432
argh, sivatagiherceg,

sorry I didn't noticed the comment on your previous question. I don't get notified when a comment is given. Only when an answer is rejected or graded. Sorry!

Well, I think it should work now. Not?

Zif.
0

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
This tutorial will teach you the special effect of super speed similar to the fictional character Wally West aka "The Flash" After Shake : http://www.videocopilot.net/presets/after_shake/ All lightning effects with instructions : http://www.mediaf…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses

715 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question