Access Database Query to Microsoft Word Mail Merge

C

CRBI

I have an access database in which I've written a query to pull certain data.
I am now performing a mail merge in Microsoft Word for that data. Everything
works perfectly except this one thing -- in the table (and therefore the
query itself) I have a field for contribution amount. In the table design I
have the data type as Currency and the properties as 2 decimal places. When
I view this info in datasheet view, it shows correctly, as $140.50. However,
once I run the mail merge and use that field, it only shows $140.5. I have
wracked my brains and cannot figure out why it doesn't show the full number.
Does anybody have any ideas here? And please, not too complicated for a
entry level user.
 
K

Ken Sheridan

The underlying number value is 14.5, you see the 50 cents in full purely as a
result of formatting. In the query return the formatted value. The Format
function returns a String expression, so will retain the trailing zero. In
query design view put something like this in the 'field' row of a blank
column:

MyMoneyFieldFormatted:Format([MyMoneyField],"$#,##0.00")

By specifically formatting it as USD rather than as "Currency" it will
ensure that it appears as such on a system whose currency is set to something
else. If I opened your file for instance I'd otherwise see the money as GBP.

Ken Sheridan
Stafford, England
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top