Ra-chel
Ra-chel

Reputation: 9

Create a Custom ID in Access

I would like to create a Custom ID in format, "SACYear-Sequential Number", in an Access 2013 Table (Table Name = poledata) when records are appended into that Table.

eg. SAC18-1 (18 means 2018)

I have researched and found the code as below. As advised, I have to add 2 new fields in the Table, alternate_id_seq and alternate_id. However, errors show up for the following lines.

Expression = "SAC" & Year(Date()) Mod 100 & "-"

Look Up A Record In

Select pd.[alternate_id_seq] 
FROM poledata AS pd 
ORDER BY pd.[alternate_id_seq] DESC;

What's going wrong with them?

image description

Upvotes: 0

Views: 216

Answers (0)

Related Questions