I created a batch# field using the following command in SQL. Iím trying now to access it in my program. It looks like it was created as a data area, but itís defined at char(2000), even though the actual sequence number is dec(8,0). I tried putting it in my pgm as a data area with a size of dec(8,0) and when I ran it it said the field size is wrong.†Maybe I need to have an SQL statement retrieve the value and increment it? Not sureÖ. Any ideas? Just an FYI, I create the counter this way because it's also being used by other SQL stored procedures.
create sequence mm610dvl/batch_seq as decimal(8,0) start with 100†increment by 1 no order cycle no minvalue no maxvalue cache 20††††