By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
428,787 Members | 2,251 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 428,787 IT Pros & Developers. It's quick & easy.

Help with MS Query Date prompt format

P: 1
I'm just beginning to use SQL for MS Queries in Excel and am having difficulty with how to imput the date into a prompt.

I've used prompts for other fields and they seem to work fine, however, when I input the date in the query below in the following format YYYY-MM-DD, I get the following error:

"String length exceeds column length parameter #1.data truncated."

Expand|Select|Wrap|Line Numbers
  1. SELECT 
  2.     ARInvoice.ShipTO_State, 
  3.     ARInvoice.ShipTO_City, 
  4.     ARInvoice.InvoiceNo, 
  5.     ARInvoice.InvoiceDate, 
  6.     ARInvoice.SalesAmt1, 
  7.     ARInvoice.CreditAmount, 
  8.     ARInvoice.DebitAmount, 
  9.     ARInvoice.DiscAmount, 
  10.     ARInvoice.SalesTax1Amt
  11. FROM 
  12.     ARInvoice ARInvoice
  13. WHERE 
  14.     (ARInvoice.InvoiceDate>?)
  15. ORDER BY 
  16.     ARInvoice.ShipTO_State
I've tried the following formats with the same error:

MM/DD/YYYY
MM/DD/YY
MM-DD-YYYY
MM-DD-YY
M/D/YYYY
M-D-YYYY
M/D/YY
M-D-YY

I'm querying a Sage BusinessWorks data base.

Can anyone help?

Thank you,

John
Aug 15 '07 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.