select isnull(max(right(id,4)),0)+1 as MaxID from tb_rjz where left(ID,8)='+ FormatDateTime('yyyyMMdd',now) select iif(isnull(max(right(id,4))),1,max(right(id,4))+1) as maxid from tb_rjz where datedof;left(id,8)='+ )
select isnull(max(right(id,4)),0)+1 as MaxID from tb_rjz where left(ID,8)='+ FormatDateTime('yyyyMMdd',now)--- parameters yyyymmdd text(255); select iif(isnull(max(right(id,4))),1,max(right(id,4))+1) as maxid from tb_rjz where left(id,8)=yyyymmdd
select iif(isnull(max(right(id,4))),1,max(right(id,4))+1) as maxid
from tb_rjz where datedof;left(id,8)='+ )
parameters yyyymmdd text(255);
select iif(isnull(max(right(id,4))),1,max(right(id,4))+1) as maxid
from tb_rjz where left(id,8)=yyyymmdd