PDA

View Full Version : Can I use WHERE SOMETHING>0 on an SQL currency field (using VBA)?



Alex Wren
05-01-2007, 01:28 PM
Hello,

Having problems with two things.

I have a nice little bit of Excel VBA that queries a table within an Access db. Problem being is that the client has formatted the field as currency and the following code does not work.


sSQL = sSQL & " WHERE DNname.[LAST YEAR]>0 AND DNname.[THIS YEAR]=>0 AND ...

Also does anyone know if you can use less than on a text field?

i.e.


AND DNname.[CATEGORY]<'40' AND..

Thanks

omocaig
05-01-2007, 04:04 PM
http://www.mrexcel.com/board2/viewtopic.php?p=1302583#1302583

hth,
Giacomo