When i am trying to insert values into a table i am getting
integrity constraint violated error
kindly suggest me where i am doing wrong
SQL> insert into customers_products values(&tid,&cno,&pno,'&date',&qty);
Enter value for tid: 8200
Enter value for cno: 3001
Enter value for pno: 6000
Enter value for date: 11-feb-2010
Enter value for qty: 10
old 1: insert into customers_products values(&tid,&cno,&pno,'&date',&qty)
new 1: insert into customers_products values(8200,3001,6000,'11-feb-2010',10)
insert into customers_products values(8200,3001,6000,'11-feb-2010',10)
*
ERROR at line 1:
ORA-02291: integrity constraint (SCOTT.FK_CUSTOMERS) violated - parent key not found
here is the
customers table
SQL> select * from customers;
CUSTNO FIRST_NAME LAST_NAME C CREDIT_LIMIT CREDIT_CARD_NO CREDIT_C
------ ------------------------------ ------------------------------ - ------------ -------------- --------
3001 Jean Livingston E #### #### Standard
3002 Kimberely Grant A #### #### Premium
3003 Charles Johnson I #### #### Charge
3004 Winston Taylor R #### #### Limited
3005 Jean Paul B #### #### I
3006 Martha Sullivan E #### #### Prepaid
6 rows selected.