troubleshooting Question

Problems with date in SQL INSERT...???

Avatar of Andrew Angell
Andrew AngellFlag for United States of America asked on
6 Comments1 Solution1519 ViewsLast Modified:
I'm having some troubles trying to insert a date into a FileMaker database via SQL.  The following is something I'm trying:

INSERT INTO Invoices (CreationDate) VALUES (2/20/2007)

I don't get any parsing errors with this and the data inserts, however, it's doing the math and inserting 2 divided by 20 divided by 2007.  Winds up with a crazy decimal like .0002343023403030.  

If I try and put single quotes around the date value FM returns a "query failed" error, and nothing more.

Any information on how I can get the SQL query to treat 2/20/2007 as a date value instead of doing the math would be greatly appreciated.  Thanks!

Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 6 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 6 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros