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

Access 97 Dlookup field formating

P: 2
I have created a P & L Statement which I'm very pleased with after downloading historical data from excel spreadsheets. I've created a successful DLookup function called LYMTD in a select query to callup certain data into a report. The Dlookup function in my query works well but when I try to total the 17 LYMTD amounts in my P & L report using =Sum([LYMTD]) I get a message which says "The microsoft Jet engine can not execute the SQL statement because it contains a field that has an invalid data type". I have done everything to ensure this is not the case. Can anyone make any suggestions as to how I can sort this out?
May 21 '07 #1
Share this Question
Share on Google+
2 Replies


JConsulting
Expert 100+
P: 603
I have created a P & L Statement which I'm very pleased with after downloading historical data from excel spreadsheets. I've created a successful DLookup function called LYMTD in a select query to callup certain data into a report. The Dlookup function in my query works well but when I try to total the 17 LYMTD amounts in my P & L report using =Sum([LYMTD]) I get a message which says "The microsoft Jet engine can not execute the SQL statement because it contains a field that has an invalid data type". I have done everything to ensure this is not the case. Can anyone make any suggestions as to how I can sort this out?
try
=Sum(val([LYMTD]))
May 21 '07 #2

P: 2
KTB
try
=Sum(val([LYMTD]))
Thanks for that.
However I found that the following solution works using "CCur":
LYYTD: CCur(DLookUp("[YTD]","[PLTable]","[YTD] =" & [YTD])).
May 21 '07 #3

Post your reply

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