hi, i have a table created like this: CREATE TABLE "NJIPD "."APVEN"
(
"DTAARADATA" VARCHAR(2000) ,
"ID" INTEGER NOT NULL GENERATED ALWAYS AS IDENTITY ( START WITH +1
, INCREMENT BY +1 , NO CACHE ) )
IN "USERSPACE1" ;
i have insert into njipd.apven values('12737',default) once only, so
there is only one record in the table, and the id column is 1, when i
try to insert one more time, i get the sql error 359, can someone help
me what to do? thanks 9 6683
Shouldn't be. Which platform and version?
The default MAXVALUE should be the max of the datatype.
Is this the only identity that is failing?
You can check in SYSIBM.SYSSEQUENCES for the entries,
or you can use db2look to echo back the table definition.
db2look should spell out what it thought were the defaults used.
Cheers
Serge
--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
the platform is on windows and udb version 8.1 with fp3, i have
several other tables use the same way to create, but this one gives me
error. here is the ddl extraction with db2look
------------------------------------------------
-- DDL Statements for table "NJIPD "."APVEN"
------------------------------------------------
CREATE TABLE "NJIPD "."APVEN" (
"DTAARADATA" VARCHAR(2000) ,
"ID" INTEGER NOT NULL GENERATED ALWAYS AS IDENTITY ( START WITH +1
, INCREMENT BY +1 , NO CACHE ) )
IN "USERSPACE1" ;
-- DDL Statements for indexes on Table "NJIPD "."APVEN"
CREATE INDEX "NJIPD "."APVEN" ON "NJIPD "."APVEN"
("ID" ASC);
when i look at table SYSIBM.SYSSEQUENCES , how am i able to relate the
seqid, seqname to the table name? thanks
the platform is on windows and udb version 8.1 with fp3, i have
several other tables use the same way to create, but this one gives me
error. here is the ddl extraction with db2look
------------------------------------------------
-- DDL Statements for table "NJIPD "."APVEN"
------------------------------------------------
CREATE TABLE "NJIPD "."APVEN" (
"DTAARADATA" VARCHAR(2000) ,
"ID" INTEGER NOT NULL GENERATED ALWAYS AS IDENTITY ( START WITH +1
, INCREMENT BY +1 , NO CACHE ) )
IN "USERSPACE1" ;
-- DDL Statements for indexes on Table "NJIPD "."APVEN"
CREATE INDEX "NJIPD "."APVEN" ON "NJIPD "."APVEN"
("ID" ASC);
when i look at table SYSIBM.SYSSEQUENCES , how am i able to relate the
seqid, seqname to the table name? thanks
Try SYSCAT.TABDEP. This looks a bit spooky.
--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
Try SYSCAT.TABDEP. This looks a bit spooky.
--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
the syscat.tabdep is the relationship between table and view, but it
still not tell me how to relate to the syscat.sequences on the seqname
and seqid.
the syscat.tabdep is the relationship between table and view, but it
still not tell me how to relate to the syscat.sequences on the seqname
and seqid.
Last but not least here it is:
syscat.colidentattributes
Sorry for sending you of to TABDEP.
Cheers
Serge
--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab
Last but not least here it is:
syscat.colidentattributes
Sorry for sending you of to TABDEP.
Cheers
Serge
--
Serge Rielau
DB2 SQL Compiler Development
IBM Toronto Lab This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics
by: Tim Gaunt |
last post by:
Hi,
I'm hoping that someone will be able to help me with this one, I'm
developing an application which basically inserts a load of data into the
database ready for validation at a later date, I...
|
by: grzes |
last post by:
MS SQL Server 2000.
My case is: I have the table T with primary key calling __recid int
without identity property. This table includes a lot of records (about
1000000). I need to convert __recid's...
|
by: Mark |
last post by:
BEGINNER QUESTION
I have a table which has a compound primary key consisting of two columns.
One of these columns is a foreign key which is generated in another table by
an identity.
I want...
|
by: Who.Really.Really.Cares |
last post by:
Hi!
In dynamic SQL I'm inserting a row to a table with an IDENTITY column.
How can I retrieve the generated identity value?
The statement "VALUES IDENTITY_VAL_LOCAL()" returns the following...
|
by: WhiteEagl |
last post by:
Hello,
I would need some help with this identity column problem in
SQLServer.
I have a database with two tables. The Parent table has an Identity
column.
Parent (ParentID IDENTITY, Name)...
|
by: .Net Newbie |
last post by:
Hello,
I am somewhat new to .Net and currently working on an intranet site using C#
going against SQL Server 2k. I am accepting personal information on a
single webform and trying to insert the...
|
by: sameer_deshpande |
last post by:
Hi,
I need to create a partition table but the column on which I need to
create a partition may not have any logical ranges. So while creating
or defining partition function I can not use any...
|
by: sajithamol |
last post by:
How we can make identity column to have a value next to the value of previous identity column row?This sequence breaks when we delete some rows.how we can maintain this sequence?
|
by: hellboss |
last post by:
Hi Everyone ! im using SQL SERVER 2005,
My problem is, i am inserting a set of values into a table using a subquery, the problem occurs when i tried to get the auto generated column in the table...
|
by: Charles Arthur |
last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
|
by: emmanuelkatto |
last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud.
Please let me know.
Thanks!
Emmanuel
|
by: Sonnysonu |
last post by:
This is the data of csv file
1 2 3
1 2 3
1 2 3
1 2 3
2 3
2 3
3
the lengths should be different i have to store the data by column-wise with in the specific length.
suppose the i have to...
|
by: Hystou |
last post by:
There are some requirements for setting up RAID:
1. The motherboard and BIOS support RAID configuration.
2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers,...
|
by: jinu1996 |
last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new...
| |