News:

Support the VirtueMart project and become a member

Main Menu

To manually choose the category id

Started by elgiga, May 17, 2012, 20:26:02 PM

Previous topic - Next topic

elgiga

Hi my name is Zak
I'd like to know if there's a way to change the number of the
"Category ID" under the task "General Information" after creating a
new category ?
I would like to fill it in with my own numbers.
Thank you

jenkinhill

I guess you can write the ID into the database with phpMyAdmin - but I don't know if this will cause other issues.
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

elgiga

hi thanks for you answer

this is what i am doing every time i create a new category on the administrator, i manually log in on my phpMyAdmin and change the the category id on `jo_virtuemart_categories`
virtuemart_category_id
and `jo_virtuemart_categories_da_dk`
virtuemart_category_id
and `jo_virtuemart_category_categories`
there is 2 tables i changes
id and category_child_id
and to not lose the images i all so change on `jo_virtuemart_category_medias`
virtuemart_category_id
..

so i was thinking if there is a why on the administrator where creating a new category that there when writing the name of it all so manually choosing the category ID

jenkinhill

What you want to do is probably unique to your store, not something anyone else would want so would not be part of the core. It could possibly be programmed in by someone, but we do not support core code hacks.
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

PRO

elgiga, this can be done as long as it is a # only.

BUT, do remember, products are also mapped to the categories etc.

WHY do you want to do this?

Explain your scenario, I could understand order #s , but not categories, unless its a conversion.
I could not imagine having to do it manually every time


elgiga

thanks jenkinhill

Yes BanquetTables.pro
the ID NR, i want to change is only NR, but i want to choose them.
Why?
Be cores my vendor gave me a file with all product and thy have allready a category id, so if i create a new category and give it the category id nr.  then automatically the product Will be viewed

and i have added this code on  the edit_categoryform file, sow i can see and change the category id, but its not accepting my nr.'s only the automaticly added one :(, i can show u it liv if u have team view

[attachment cleanup by admin]

baqpad

Quote from: PRO on May 19, 2012, 01:19:54 AM
Explain your scenario, I could understand order #s , but not categories, unless its a conversion.
I could not imagine having to do it manually every time

I'm ending up with a very similar problema. Vendor has its own local software with more than 120 categories and generating its own category IDs. It would be very easy if there's a chance to create categories with any given ID number.
I guess this scenario could happen often when a local store software generate categories in this way.
Has anyone a work around for this problem?

- Virtuemart 2.0.20b
- Joomla 2.5.9
- PHP 5.3.21

angusmcr

I have this same issue I have a database from a till system that has categories numbers already set.

We need to match both the category and product number so that we can easily update prices in-future is there any way to do this.