Default field in a table

New Contributor

In my database I a table with a field have a field called "Year" and at the moment this is set to a default for the current year i.e. 2019 and I have to change it each year.  Can this field be updated automatically so that next year this field will be amended to 2021 and so on through the years to come. 

5 Replies

@J0hn60rt0nmentions Instead of hard-coding a value, use the relevant Date function, which is Year(). Since you want to use the following year, not the current year, you'd use Year(Date())+1

@George Hepworth  Hi George,  many thanks for the message.  I have tried it it I get a error message say "Expression entered has a function containing the wrong number of arguments" I have tried it in most of the relevant formats  Number, Date/Time/and Short text. Any ideas please. What I thought would happen would be, as the database went over in to the next year the year will be auto updated which is what happens in the Date() function.

@J0hn60rt0nmentions Maybe I misunderstood the requirement. Here's what I thought you wanted:



Hi George,  Many thanks for the help and it works,  That's great ....... Super ...... 



@J0hn60rt0nmentions Congratulations on solving the problem. Continued success with your project.