Hi, any idea to my following problem
I have an orderid, ordernumber and date
ordernumber is unique, starting manually from 1 to infinity , until the date is 31/12/2012, after that ordernumber is resetting to 1 again
Is it possible?
Thanks
Hi, any idea to my following problem
I have an orderid, ordernumber and date
ordernumber is unique, starting manually from 1 to infinity , until the date is 31/12/2012, after that ordernumber is resetting to 1 again
Is it possible?
Thanks
How are you incrementing this number? Please show the code involved.
Hi again.. what im trying to do is i cannot have the same id within the same date
Id=1, 2/5/2012
id=2, 2/5/2012
id-2, 2/5/2012 ----> error id exists.
Id=2, 3/5/2012 ----> no problem here, since the date is different
You are probably looking for something along the lines of
dmax("[ID]", "[Tbl_table_name]","[date]=#" & date() & "#")+1
As a side note, date is a bad choice for a field as it is used elsewhere.
ID should be something useful like orderID otherwise it will just get confused with every other ID in your database and 30 ID fields, tends to get confusing.