I am doing a receipt system whereby it can auto generate a unique receipt
number for each receipt. It will be an increment of number eg.000001, 000002,
000003, and so on.....Wonder how should I go about doing this using PHP? Do need
some help here..technologies used are:PHP and MySQL...

Since you're using MySQL, create a table for your receipts with a receipt_number which is an auto_incremented, primary key, unsigned, not null, integer. When you add records to this, set this column's value to NULL or 0 and it will automatically use the next sequential number.


See the MySQL manual for more.
Larry

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Reply via email to