[symfony-users] Re: edit id in admin

2010-05-24 Thread Tom Ptacnik
So the problem is, that symfony always write the autoincrement id or it doesn't insert id at all? On 21 kvÄ›, 19:51, Mihai Rusoaie mi...@rusoaie.com wrote: Hello! When I insert an new object in the database, I want the id to be assigned automatically (autoincrement). In the edit form,

Re: [symfony-users] Re: edit id in admin

2010-05-24 Thread Eno
On Mon, 24 May 2010, Oleg Sverdlov wrote: I do not expect problems with partial restore/merge, since the tag name is always operator-assigned and unique. In my experience, numeric ID often is a problem when doing partial restore. That's why they need to be assigned by the database and managed

Re: [symfony-users] Re: edit id in admin

2010-05-24 Thread Oleg Sverdlov
On Mon, May 24, 2010 at 3:57 PM, Eno symb...@gmail.com wrote: I do not agree. It may be simply of indicator of people relying too much on belowed MySQL AUTO_INCREMENT feature. Beloved? AUTO_INCREMENT was designed to be used this way. If humans assigned IDs, how do you guarantee uniqueness

[symfony-users] Re: edit id in admin

2010-05-24 Thread Richtermeister
Hey Oleg, the tag to product argument makes no sense to me... What are you attaching tags to if not the product's ID's? In your version, you want to edit product ids.. so what happens to the references in the product_to_tags table? You have to update them accordingly? If you just went with

Re: [symfony-users] Re: edit id in admin

2010-05-24 Thread Oleg Sverdlov
On Mon, May 24, 2010 at 7:30 PM, Richtermeister nex...@gmail.com wrote: the tag to product argument makes no sense to me... What are you attaching tags to if not the product's ID's? to product IDs which are not auto-generated but indeed user-generated codes entered from a catalog. In your

Re: [symfony-users] Re: edit id in admin

2010-05-24 Thread Eno
On Mon, 24 May 2010, Oleg Sverdlov wrote: primary key has unique value. The database server is supposed to raise an error when someone tries to enter duplicate value. It's up to software to process this type of errors. So, after you have thousands of rows in the table, will you users keep

[symfony-users] Re: edit id in admin

2010-05-23 Thread pghoratiu
I think that you are going the wrong way to solve this. I would leave the id as is in the database and create a separate field contract_id that you change the way you want. This number should be set only when the contract is finalized. I think that messing with the id directly will give you a

[symfony-users] Re: edit id in admin

2010-05-23 Thread Richtermeister
Hey Oleg, gabriel is right. Using database ids with outside systems (your accounting system) is a bad idea and a database design no-no for all sorts of reasons.. One issue is that you're coding only for your current situation, but what happens when your accounting system changes? Or when you need

Re: [symfony-users] Re: edit id in admin

2010-05-23 Thread Oleg Sverdlov
Hi Daniel, On Sun, May 23, 2010 at 10:20 PM, Richtermeister nex...@gmail.com wrote: Using database ids with outside systems (your accounting system) is a bad idea and a database design no-no for all sorts of reasons.. My example was from different area. To put it simply, we have the

[symfony-users] Re: edit id in admin

2010-05-22 Thread pghoratiu
I did not try it but you should be able to make this change by overriding the save() method for the form and/or the object. gabriel -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are