oracle - Validate Column values while insert in PL/SQL -


i have following example

create table test (  c1 nvarchar(50) not null,  c2 number,  c3 date);  insert test(c1,c2,c3) select (v1,v2,v3)from emp ; 

i want add validations not insert null values c1, not insert string c2, insert dates only c3.

any idea in pl/sql?

thanks

there no need table definition, oracle throw error if try insert "wrong" data.

i have spotted should use select statement without parantheses:

insert test (ca, c2, c3) select v1, v2, v3 emp; 

maybe, want insert records fit table constraints. in case can use dbms_errlog along log errors into clause.

the records don't fit criterias inserted in table further review.

see this sql fiddle.


Comments

Popular posts from this blog

html - Sizing a high-res image (~8MB) to display entirely in a small div (circular, diameter 100px) -

java - IntelliJ - No such instance method -

identifier - Is it possible for an html5 document to have two ids? -