 |
 |
Archives of the TeradataForum
Message Posted: Wed, 15 Jul 2009 @ 20:59:45 GMT
Subj: | | Re: Generate always identity question |
|
From: | | Anderson, Dirk |
Try defining NO_TRY as BYTEINT, and specify a value (NULL) in the select list for the insert.
The below works...
CREATE SET TABLE user_work.LOAD_SIMUL
(NO_SEQ INTEGER GENERATED ALWAYS AS IDENTITY (START WITH 1 INCREMENT BY 1 NO
CYCLE), NO_TRY BYTEINT,
REQUESTtxt VARCHAR(7), DTS TIMESTAMP(2), DTE TIMESTAMP(2) );
INSERT INTO user_work.LOAD_SIMUL
SELECT NULL
,1
, SUBSTRING(QueryText,9,7)
,StartTime
,LastRespTime
from DBC.QryLog
where Username = 'dummy'
and StartTime between '2009-07-13 14:54:00.00' and '2009-07-13 15:32:00.00'
Thanks.
Dirk Anderson
Architect
Enterprise Information Management
| |