Oracle database sequences generated by Django

70 views
Skip to first unread message

Harold A

unread,
Apr 23, 2021, 10:49:15 PM4/23/21
to Django users
Hello everyone.

I have a web application built in Django == 1.11.6, when the migrations were generated in oracle the sequences are created and they can be modified and even deleted. 

When I update to django 3 and I generate the migrations again, it creates the sequences with a name similar to this (ISEQ $$ _ 76200) but it does not allow me to edit them and or delete them, it shows me the following message (ORA-32794: cannot delete a sequence generated by the system). The downside is that I have a stored procedure that drops a stream and recreates it to load with data from other tables each time it is run. 
(BEGIN / * DELETE RPT DATA ------------------------------------------- --- * / / * INITIALIZE THE SEQUENCE --------------------------------------------- - * / DELETE FROM SISREPORTS_RPT02; EXECUTE IMMEDIATE 'DROP SEQUENCE SISREPORTS_RPT02_SQ'; EXECUTE IMMEDIATE 'CREATE SEQUENCE SISREPORTS_RPT02_SQ INCREMENT BY 1 START WITH 1 MAXVALUE 9999999999999999999999999999 MINVALUE 1 CACHE 20 '; /*FINISH ----------------------------------------------- -------------------- * /) 

 My question is that if the new versions of django can do some configuration before generating them migrations and can have the option to modify the oracle sequences.
Reply all
Reply to author
Forward
0 new messages