|
我想insert into使用Oracle SQL将2行插入一个句子的表中。4 J7 s$ Y) } E5 A5 L! v9 p/ w" N
该代码有效:
0 l+ ?# f- T* Ginsert into a_glw select tt.*,work_id_seq.nextval from (select 11111,'one text',12345,'new text',NULL, 'some text','nice text','test','text','great text from dual union all select 11111,'one text',12345,'new text',NULL, 'some text','nice text','test','text','great text from dual) tt;当我改变的值test到text代码错误00918. 00000 - "column ambiguously defined":
$ p- S1 s7 m q4 v9 E, |insert into a_glw select tt.*,work_id_seq.nextval from (select 11111,'one text',12345,'new text',NULL, 'some text','nice text','text','text','great text from dual union all select 11111,'one text',12345,'new text',NULL, 'some text','nice text','test','text','great text from dual) tt;在一个select在句子中插入相同的值似乎是个问题。我怎样才能解决这个问题?
# ~9 ~& h2 f P1 r+ y% I( A C" H) O- W8 r# }
解决方案: |
|