CDbCommand failed to execute the SQL statement: SQLSTATE[HY000]: General error: 1 OCIStmtExecute: ORA-00001: unique constraint (ORA02.DOCENTE_PK) violated
(ext\pdo_oci\oci_statement.c:146)INSERT INTO docente (LABORATORIO, MATRICOLA, FACOLTA_FACOLTA_ID, DIPART_DIPART_ID, ANAGRA_ANAGRA_ID) VALUES (:yp0, :yp1, :yp2, :yp3, :yp4) RETURNING MATRICOLA INTO :RETURN_ID
Can you help me??
Page 1 of 1
Problem with DB
#2
Posted 26 April 2010 - 03:07 AM
as it says "unique constraint"
You have to check your existing data and the data you want to insert
You have to check your existing data and the data you want to insert
Find more about me.... btw. Do you know your WAN IP?
#4
Posted 26 April 2010 - 05:47 AM
Can't help you without seeing your table and index structure and what data you have and want to insert
but
for example... if you create a primary key on a field LABORATORIO you CANNOT insert two rows with the same value for that field
but
for example... if you create a primary key on a field LABORATORIO you CANNOT insert two rows with the same value for that field
Find more about me.... btw. Do you know your WAN IP?
#5
Posted 26 April 2010 - 06:09 AM
mdomba, on 26 April 2010 - 05:47 AM, said:
Can't help you without seeing your table and index structure and what data you have and want to insert
but
for example... if you create a primary key on a field LABORATORIO you CANNOT insert two rows with the same value for that field
but
for example... if you create a primary key on a field LABORATORIO you CANNOT insert two rows with the same value for that field
My primary key is MATRICOLA...
i have this problem when I use a form for the research....not when I insert a new docente
#6
Posted 26 April 2010 - 06:19 AM
kitty10, on 26 April 2010 - 06:09 AM, said:
i have this problem when I use a form for the research....not when I insert a new docente
I don't understand what you mean by research?
in the error says:
(ext\pdo_oci\oci_statement.c:146)INSERT INTO docente (LABORATORIO,
so it's trying to add new data to the table
Find more about me.... btw. Do you know your WAN IP?
#7
Posted 26 April 2010 - 08:07 AM
mdomba, on 26 April 2010 - 06:19 AM, said:
I don't understand what you mean by research?
in the error says:
(ext\pdo_oci\oci_statement.c:146)INSERT INTO docente (LABORATORIO,
so it's trying to add new data to the table
in the error says:
(ext\pdo_oci\oci_statement.c:146)INSERT INTO docente (LABORATORIO,
so it's trying to add new data to the table
I have a form search docente with 4 textbox
Matricola
Facolta
Dipartimento
Anagra Anagra
and I have this error
CDbCommand failed to execute the SQL statement: SQLSTATE[HY000]: General error: 1 OCIStmtExecute: ORA-00001: unique constraint (ORA02.DOCENTE_PK) violated
(ext\pdo_oci\oci_statement.c:146)INSERT INTO docente (LABORATORIO, MATRICOLA, FACOLTA_FACOLTA_ID, DIPART_DIPART_ID, ANAGRA_ANAGRA_ID) VALUES (:yp0, :yp1, :yp2, :yp3, :yp4) RETURNING MATRICOLA INTO :RETURN_ID
Share this topic:
Page 1 of 1

Help












