I have a simple question. I am tackling bug #131 - so you can tell it is a very old bug. The bug was raised by Timo and it reads as follows.
0000131: Allow deleting special Types from the demo database
The next version should set all special types to deletable, in the demo database and also in the update script.
We need to add a function to the setup of Special types so that special types can be deleted if they have not been used anywhere yet.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Q1. I suppose I should ask (as the bug is so old) - do we still need this? If so then.....
I will modify db/basedata/p_type.csv so that all the false are true and that will fix the issue of getting what we want for new databases.
Now regarding upgrading existing databases I will add the following SQL to the upgrade script.....
UPDATE p_type SET p_type_deletable_l=TRUE WHERE p_type_code_c IN ('A/C', 'ACF', 'AFDF', 'AFO', ........ );
where this query has all 62 of the initial items we add inside the IN(). This one SQL statement will do what we want. But my next question is...
Q2. Which file does this go in for the next release, and do we just do these things for PostgreSQL? So in the past we seem to have created, for example, a patch_0.2.22_0.2.23.pg.sql. Do I just create a new one of these? The latest file in trunk seems to be: patch_0.2.24_0.2.25.sql. Is this the latest that I should modify or do I create a patch_0.2.25_0.2.26.pg.sql and commit that to trunk?
Q3. Are you happy with my plan? It will only be a 5 minute job.