Db2 Sql Error Sqlcode=-551 Sqlstate=42501 Create Table
Contents |
a group -551; db2 sql error sqlcode 204 sqlstate 42704 SQL0551N Technote (troubleshooting) Problem(Abstract) You try to create a
Db2 Sql Error Sqlcode 302 Sqlstate 22001
view, materialized query tables (MQTs), SQL routine, trigger, or package that contains static db2 sql error sqlcode 803 sqlstate 23505 SQL, and get error SQLCODE: -551 or SQL0551N. Symptom SQL0551N "
Db2 Sql Error Sqlcode 104 Sqlstate 42601
object "
is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select
Db2 Sql Error Sqlcode 668 Sqlstate 57016
the forum that you want to visit from the selection below. Results 1 to 6
Sql0551n Sqlstate 42501
of 6 Thread: ERROR SQLCODE "-551", SQLSTATE "42501" when doing inserts. Tweet Thread Tools Show Printable Version Subscribe to this Thread… Search db2 sql error sqlcode=-551 sqlstate=42501 sqlerrmc Thread Advanced Search Display Linear Mode Switch to Hybrid Mode Switch to Threaded Mode 04-28-09,16:14 #1 db2pro View Profile View Forum Posts Banned Join Date Mar 2009 Posts 36 Unanswered: ERROR SQLCODE "-551", SQLSTATE "42501" http://www-01.ibm.com/support/docview.wss?uid=swg21381783 when doing inserts. Hi All, When I am running the following insert command. I am getting the following error. COMMAND: INSERT INTO WCCADM12.CDEVENTDEFTP ( LANG_TP_CD , EVENTDEF_TP_CD , EVENT_CAT_CD , EVENT_NAME , ENABLE_NOTIFY , EXPIRY_DT , DESCRIPTION , LAST_UPDATE_USER , LAST_UPDATE_DT ) VALUES ( 100, 15, 6, 'PartyComplianceNextVerify', 'Y', null, 'Party Compliance Next Verify Date', null, CURRENT_TIMESTAMP ) ERROR:: DB21034E The command was processed as an SQL statement because it was not http://www.dbforums.com/showthread.php?1641803-ERROR-SQLCODE-quot-551-quot-SQLSTATE-quot-42501-quot-when-doing-inserts a valid Command Line Processor command. During SQL processing it returned: SQL0727N An error occurred during implicit system action type "7". Information returned for the error includes SQLCODE "-551", SQLSTATE "42501" and message tokens "WCCADM12|ALTER TABLE|WCCADM12.CDEVENTDEFTP". LINE NUMBER=0. SQLSTATE=56098 When I tried for solutions on google. Many replied that the solution is to 1. drop the triggers related to this table 2. then run the insert commands 3. create the triggers again. The above steps are absolutely working. But as this is in DEV. I am ok to do this and get rid of the issues. But I am worried about doing this in PROD. I just want to know that does anyone has encountered the same issue and could be fixed without dropping and recreating the Triggers. Actually my triggers on this table are for only Updates and Deletes but not on the INSERTS. I am not able to understand why the inserrts are failing. Anyone please help me in finding a solution for this issue without dropping and recreating the triggers. DB2 Version : DB2 v 9.5 OS Level : AIX 5.3 Reply With Quote 04-28-09,16:19 #2 Marcus_A View Profile View Forum Posts Registered User Join Date May 2003 Location USA Posts 5,737 Did you try and grant update and delete to the us
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company http://stackoverflow.com/questions/1588687/db2-connection-problem-with-java Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Db2 connection problem with java up vote 7 down vote favorite 3 I am having problem with DB2. I just installed db2 sql the db2 as a db2admin and with a password. When i try to connect to database it is success full and while running any simple select query it give me following error:- DB2 SQL Error: SQLCODE=-204, SQLSTATE=42704, SQLERRMC=DB2ADMIN.LOGIN, DRIVER=3.57.82 I have a database named onp and a table in it called 'login' in which there is one table called 'login' with two fields username and password. Query that i am running Select * from db2 sql error login; gives me error DB2 SQL Error: SQLCODE=-204, SQLSTATE=42704, SQLERRMC=DB2ADMIN.LOGIN, DRIVER=3.57.82 Select * from system.login; gives me error:- (//system is schema name) DB2 SQL Error: SQLCODE=-551, SQLSTATE=42501, SQLERRMC=DB2ADMIN;SELECT;SYSTEM.LOGIN, DRIVER=3.57.82 I have tried all the resources on the net and exhausted completely. Please help me java jdbc db2 db2-luw share|improve this question edited Jul 21 at 19:47 mustaccio 10.7k41933 asked Oct 19 '09 at 13:33 RishiPatel 801211 add a comment| 4 Answers 4 active oldest votes up vote 8 down vote accepted I don't know a lot about DB2, but looking up the error codes... The first error is because you didn't specify a schema, so it couldn't find the login table. SQLCODE -204 Object not defined to DB2 DB2 apparently requires you to specify the schema name or it looks in the schema with the same name as your login user. You must use SET SCHEMA or fully qualify the table name. The second error is because you don't have the privileges to perform that select: SQLCODE -551, Error: DOES NOT HAVE THE PRIVILEGE TO PERFORM OPERATION ON OBJECT I'm not sure why the db2admin user wouldn't be able to select from this table... Resources: List of DB2 SQLCODEs share|improve this answer answered Oct 19 '09 at 13:44 Powerlord 60.1k1093146 Thanks I got it solved with your help