Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Changes in Database


Timis

Recommended Posts

Posted

While I have tested my shop I added some test costomers and orders.Even if i delete them from the admin section, there ID are still present in my database.Is there a way to count the ID of the customers and the orders from zero?At this moment the next customer who'll join my shop will the the ID number 22 instead of 1.Any ideas?

Posted
there a way to count the ID of the customers and the orders from zero?

 

To reset the auto_increment counter for a column, perform the following sql query in phpmyadmin

 

ALTER TABLE customers AUTO_INCREMENT = 1

Mark Evans

osCommerce Monkey & Lead Guitarist for "Sparky + the Monkeys" (Album on sale in all good record shops)

 

---------------------------------------

Software is like sex: It's better when it's free. (Linus Torvalds)

  • 2 years later...
Posted
To reset the auto_increment counter for a column, perform the following sql query in phpmyadmin

ALTER TABLE customers AUTO_INCREMENT = 1

 

 

Will this same concept apply to increment the Orders number. For example if I want the next order number to be 1000, will it work?\

 

 

thanks for the help in advance

Posted
Will this same concept apply to increment the Orders number. For example if I want the next order number to be 1000, will it work?\

thanks for the help in advance

 

yes

Treasurer MFC

  • 4 weeks later...
Posted

just to be sure myself ...

 

ALTER TABLE orders AUTO_INCREMENT = 1

 

should reset Orders numbers to 1?

 

thanx

  • 2 weeks later...
  • 6 months later...
Posted
Yes you got it right  :thumbsup:

 

 

I tried this and now my site says

Parse error: parse error in C:\Domains\ryford.com\wwwroot\admin\orders.php on line 81

if I try to see an order

on line 81 it says

      case 'deleteconfirm':

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...