regarding merge fields in word document

Hello everybody,
I am merging some data fields into a word document. Data is present in MS Access database. There are few fields that merge "date" from the query in database. In a database query, this date is present in format 31-12-2010 and also in format 31-dec-2010.

But in my word document I want this date to be in a format "31 december 2010". I can not give this format in a query in database.

So, is it possible to formate this specific date fields in word document, whenever i execute my merge function through database???
Thanx a lot in advance
John_BASAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

als315Commented:
If you can see in the DB date in differnt format, it is stored as text. You can (and I stronly recommend you to do it) store date in Date|Time Field. You can add new field tou your table and use update query with function DateValue(YourDateField) to fill it.
Then you will be able to use in megre any date format.
John_BASAuthor Commented:
Thanx for your reply als315,
Your recommendation is absolutely right. In my databse date is already stored in Date/time field. It is not a text field.
Moreover I have attached a image of the properties in database query. In the properties of date field, there are no settings for "31 december 2010" format.

Is there a way that query generates a date in format 31-dec-2010, but it gets merge into my word document as 31 december 2010 ??
Any solution please?
Thanx a lot
Image.docx
als315Commented:
There is no difference in date format in query. Word is using own formatting in merge fields. In Word document change merge field output format (Change field view from Value to code and change it with designer or manually)
Your Guide to Achieving IT Business Success

The IT Service Excellence Tool Kit has best practices to keep your clients happy and business booming. Inside, you’ll find everything you need to increase client satisfaction and retention, become more competitive, and increase your overall success.

als315Commented:
But you can convert date to text in query with Format Function:
Format([YourDateField],"dd\ mmmm\ yyyy")
John_BASAuthor Commented:
Hello,
Thanx for reply.

Your comment: "(Change field view from Value to code and change it with designer or manually) "

Can you please guide the exact way to do it in MS Word?? The code of my merge field in MS Word looks like "MERGEFIELD  GeboorteDatum ". Can you please tell me the code to put in here to change its format to "d MMMM yyyy"???

"Geboortedatum" is the name of field which is coming from database.

Thank you
John_BASAuthor Commented:
Hello,
Can anybody please help me, regarding how to put the code to format merge field in MS Word?
Thanx
als315Commented:
Right mouse button on a field - select Toggle Field Code, field should be like this:
{MERGEFIELD  GeboorteDatum \@ "d MMMM yyyy" }
GrahamSkanRetiredCommented:
You need to see the field codes. Use the Alt+F9 toggle so that you see

{ MERGEFIELD GeboorteDatum}

Then insert a Date switch:

{ MERGEFIELD MyField  \@ "d MMMM yyyy"}

You can toggle back to the normal view with Alt+F9 again
als315Commented:
I've made an example. Correct will be:
{MERGEFIELD  "GeboorteDatum" \@ "d MMMM yyyy" }

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
GrahamSkanRetiredCommented:
Sorry. I didn't mean to change the field name. It should, of course be

{ MERGEFIELD GeboorteDatum \@ "d MMMM yyyy"}
John_BASAuthor Commented:
Thanx a lot,
It is working perfectly for me.
John_BASAuthor Commented:
The solution is perfect.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Word

From novice to tech pro — start learning today.