Sign In | Register Now About Bytes | Help | Site Map
Connecting Tech Pros Worldwide

Finding Tables without any Primary key

Question posted by: amir (Guest) on July 19th, 2008 11:15 AM
My Problem:
------------------
1- When I was trying to run some queries like below, I got the error
like this:
------------------------------ Command Entered
------------------------------
select * from bank1.abrnparams ;
-----------------------------------------------------------------------------
SQL0540N The definition of table "BANK1.ABRNPARAMS" is incomplete
because it
lacks a primary index or a required unique index. SQLSTATE=57001
2- Also, when I tried to show some Tables in C#, I got same.

What I have done:
-------------------------
I tried to check the problem through checking the
SYSIBM.SYSCOLUMNS.KEYSEQ by:

SELECT DISTINCT KEYSEQ, COUNT(*)
FROM SYSIBM.SYSCOLUMNS
GROUP BY KEYSEQ;

All tables in my schema, has one key column at least.

What I need:
------------------
I need a solution for facing to error I got above.
Any help will appreciated, before.
Serge Rielau's Avatar
Serge Rielau
Guest
n/a Posts
July 19th, 2008
02:15 PM
#2

Re: Finding Tables without any Primary key
Which platform and version of DB2 are you on?
Which client interface and version are you using?

(This smells like the client wants to keep bookmarks fro editing....)
Cheers
Serge

--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab

amir's Avatar
amir
Guest
n/a Posts
September 14th, 2008
06:45 AM
#3

Re: Finding Tables without any Primary key
On 19 ÌæáÜ, 17:08, Serge Rielau <srie...@ca.ibm.comwrote:
Quote:
Which platform and version of DB2 are you on?
Which client interface and version are you using?
>
(This smells like the client wants to keep bookmarks fro editing....)
Cheers
Serge
>
--
Serge Rielau
DB2 Solutions Development
IBM Toronto Lab


Dear Friend,
I think the table has some BLOB and not defined good.
Our Database version is UDB v7.1 also.

I AM LOOKING FOR
how to define BLOB fields in the DB2 way (different tables) in my DB2
version?
Thanks

 
Not the answer you were looking for? Post your question . . .
189,847 Experts ready to help you find a solution.
Sign up for a free account, or Login (if you're already a member).

Latest Articles: Read & Comment
  • Didn't find the answer you were looking for?
    Post Your Question
  • Top Community Contributors