i created this test table db and added 3 columns col,col2 and cal3 . I want the cal 3 value to be derived from col + col2 . Doesn't let be to insert data using insert satament. what is the sql statement to insert values.
The table created statement is as follows :-
create table db
(
col number(10),col2 number(20), cal3 number(10) generated always as (col+col2)
);
Since you have a computed column you have to specify the columns you insert into:
a
select * from db
after the insert above would give you: