The Archn00b
Registered User.
- Local time
- Yesterday, 16:37
- Joined
- Jun 26, 2013
- Messages
- 76
Hello everyone,
I think this is a vba question at heart so I've posted this here.
I'm trying to use this in a query:
SELECT
.
Does anyone have any ideas?
Thanks!
I think this is a vba question at heart so I've posted this here.
I'm trying to use this in a query:
SELECT
Code:
, SUM(CDbl([Table].[Field])) AS [New Field]
FROM Table
GROUP BY [Table].[Code][/B]
The CDbl() is used because the original value for [Table].[Field] is of the data type TEXT in Access (I'm connecting to an ODBC database). Of course it has to be a number so I've used CDbl() to convert the value.
However I get an error message:
[B]"Data type mismatch in the criteria expression" [/B]
Which I think is something to do with the
[CODE][B]SUM(CDbl([Table].[Field]))[/B]
Does anyone have any ideas?
Thanks!