[ic] not using autonumber when creating a new item in admin ui

John Allman allmanj at houseofireland.com
Thu Jan 15 09:30:24 EST 2004

Stefan Hornburg wrote:

>On Thu, 15 Jan 2004 13:30:58 +0000
>John Allman <allmanj at houseofireland.com> wrote:
>>Hi - i'm writing an admin page to manage a table that is not part of the 
>>core interchange but is essential in our site. I'm using interchange 
>>4.8.3.  I'm manually selecting numbers for primary keys in this table 
>>based on the current values in there. I have based this as much as 
>>possible on the item_edit page and have simply changed the block of code 
>>in the [if cgi ui_new_item] tag to set item_id to the particular value i 
>>want (i have made sure that ui_new_item is set when this page is 
>>accessed by modifying the values in icmenu to be like those for 
>>item_edit, i.e. the form value set to ui_new_item=1). I have removed all 
>>of the AUTO_SEQUENCE and AUTO_NUMBER code.
>>Unfortunately, although everything looks good on the editing page and 
>>the number i want is appearing there, when i submit it, it chooses a 
>>completely different value which it appears to be getting from an 
>>autonumber file in the products directory of my catalog.
>>How can i get it to use my number instead? Or will i just have to adapt 
>>my plan to take this autonumbering into account?
>Why did you remove AUTO_SEQUENCE ? That tells IC to rely on the
>auto_increment feature of MySQL.
>	Racke
This table doesn't have auto_increment set...


More information about the interchange-users mailing list