0

When I try to write Format([my_date_element], "yyyy/mm/dd") I get an error because of bad syntax.

2
  • 1
    What is the exact error message? What date type is my_date_element? What is the full SQL statement? Commented Feb 21, 2018 at 15:32
  • Ok, I solved a problem, but thank you Andy, because when I changed the SQL statement everything worked just fine. Then I noticed that in a project view the above expression changed to Format([my_date_element], "rrrr/mm/dd"). It's because in my language (Polish) "year" means "rok" and it appears that I have to use Polish symbols in project view next time when I have MS Access set to Polish. Commented Feb 21, 2018 at 15:50

1 Answer 1

2

In the project view of a query you have different symbols depending on the language you use. So e. g. "year" means "rok" in Polish and thus I have to use "r" instead of "y" in Format function.

Sign up to request clarification or add additional context in comments.

1 Comment

Add a note about where the language is set; is this an Access setting or an OS setting?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.