![]() |
Replace Product ID Number
Currenty X-Cart version 4.0.16 will start your product id numbers at #1. Is there an easy way to change that to a number of my choice?
Any help would be appreciated!!! |
If I understand your question, you probably want to change the productid #1 to a larger number, let's say productid #100
You can change the auto-increment values in your MySQL table with this command. Code:
ALTER TABLE xcart_products AUTO_INCREMENT = '<YOUR_NUMBER>' Replace <YOUR_NUMBER> with the actual integer value. For example: Code:
ALTER TABLE xcart_products AUTO_INCREMENT = '100' Doing this on a live X-Cart installation is very risky, as many of the tables refer to the productid. So, my advice, only do this if this is a completely fresh install with no products yet. MySQL docs: http://dev.mysql.com/doc/refman/4.1/en/example-auto-increment.html I hope this helps... |
I tried that command but it failed. Ireceived this response: SQL PATCH FAILED AT QUERY:
ALTER TABLE xcart_products AUTO_INCREMENT = '2500' I have some test products. Maybe this is why it failed? Any Ideas? |
Quote:
Hmmm... You might try it without the ticks. i.e. Code:
ALTER TABLE xcart_products AUTO_INCREMENT = 2500 Let me know if that works. |
Question - why are you worried about the product id number?
|
That worked!!! Thank you.
In reply to Question - why are you worried about the product id number? The product ID number shows in the product details page. For example it shows as Bike Helmet #1...if the productid is #1. I just think that it may be confusing to customers. Such a small number does not seem like a productid number. Bike Helmet #17566 is more obvious the number is a productid#. In my humble opinion. |
Actually I would suggest removing that number as it serves no purpose. Open up product.tpl and replace this:
Code:
{include file="dialog.tpl" title=$product.producttitle content=$smarty.capture.dialog extra="width=100%"} with this: Code:
{include file="dialog.tpl" title=$product.product content=$smarty.capture.dialog extra="width=100%"} |
I do think the number is useful, especially when you have many products that are similar. Many of our customers places phone orders and that number comes in very handy in identifying products quickly and eliminating mistakes.
|
Don't you have SKU numbers?
|
Yes, but SKU numbers are not visible until checkout. So most customers who are just browsing will never see that number and will usually refer to the productid number if they have questions regarding a paticular product.
|
All times are GMT -8. The time now is 12:57 AM. |
Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.