Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3693270
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T04:21:29+00:00 2026-05-19T04:21:29+00:00

I want to drop a column called id which is an auto incrementing PK.

  • 0

I want to drop a column called id which is an auto incrementing PK.

The SQL:

alter table "CO88GT"."XGLCTL" drop column id cascade;

And I get:

Error: [SQL0952] Processing of the SQL statement ended.  Reason code 10.

SQLState:  57014

ErrorCode: -952

I could be wrong but I think it has something to do with preventing the table from losing data. To get around this issue I need to create a new table without the column and copy the data from the old table into the new table and then replace the old table with the new table.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T04:21:29+00:00Added an answer on May 19, 2026 at 4:21 am

    Info

    AS400 is giving you a warning (inquiry message) because of possible data loss, asking you to Cancel or Ignore the requested operation. So, beacuse of this being a interactive request, over JDBC/ODBC you cannot type ‘I’ to ignore, and AS throws you an ErrorCode: -952 with SQLState: 57014 and Reason code 10.

    In the documentation of SQL0952 says:

    Message Text:   Processing of the SQL statement ended. Reason code &1.
    Cause Text:     The SQL operation was ended before normal completion. The reason code is &1. Reason codes and their meanings are:
    
    * 1 - An SQLCancel API request has been processed, for example from ODBC.
    * 2 - SQL processing was ended by sending an exception.
    * 3 - Abnormal termination.
    * 4 - Activation group termination.
    * 5 - Reclaim activation group or reclaim resources.
    * 6 - Process termination.
    * 7 - An EXIT function was called.
    * 8 - Unhandled exception.
    * 9 - A Long Jump was processed.
    * 10 - A cancel reply to an inquiry message was received.
    * 11 - Open Database File Exit Program (QIBM_QDB_OPEN).
    * 0 - Unknown cause.
    

    If you are using JDBC and the SQL error isn’t self-explanatory, you can make a JDBC connection with parameter ‘errors=full‘, which will give much more info on the error. For other connection parameters see this.

    example connection string:

    jdbc:as400://serverName;libraries=*libl;naming=system;errors=full;

    With that connection the resulting error would be like this:

    Error: [SQL0952] Processing of the SQL statement ended.  Reason code 10.
    Cause . . . . . :   The SQL operation was ended before normal completion.
    The reason code is 10.
    Reason codes and their meanings are:
    1 -- An SQLCancel API request has been processed, for example from ODBC.
    2 -- SQL processing was ended by sending an exception.
    3 -- Abnormal termination.
    4 -- Activation group termination.
    5 -- Reclaim activation group or reclaim resources.
    6 -- Process termination.
    7 -- An EXIT function was called.
    8 -- Unhandled exception.
    9 -- A Long Jump was processed.
    10 -- A cancel reply to an inquiry message was received.
    11 -- Open Database File Exit Program (QIBM_QDB_OPEN).
    0 -- Unknown cause.
    Recovery  . . . :   If the reason code is 1, a client request was made to cancel SQL processing.  For all other reason codes, see previous messages to determine why SQL processing was ended.
    
    SQLState:  57014
    ErrorCode: -952
    

    The solution

    So finally, if you cannot use STRSQL, another solution is to use iSeries Navigator, to be exact its “Run SQL scripts” (it is usually here –> “%Program Files%\IBM\Client Access\Shared\cwbundbs.exe”).

    But first of all you have to add a system reply parameter (only once per machine)

    ADDRPYLE SEQNBR(1500) MSGID(CPA32B2) RPY(‘I’)

    This is done in “green screen”. This sets a deafult answer (‘I’) on CPA32B2 inquiry message. The CPA32B2 is an internal massage id, which is tied to an drop column operation.

    (It actually doesn’t have to be done in “green screen”, use it like CHGJOB command. Example :

    cl: ADDRPYLE SEQNBR(1500) MSGID(CPA32B2) RPY(‘I’);

    )

    Now you can start “Run SQL scripts”, the first command to run is:

    cl: CHGJOB INQMSGRPY(*SYSRPYL);

    this changes the current job parameter INQMSGRPY, to *SYSRPYL. *SYSRPYL causes to look if exists a system reply parameter when an inquiry message should be displayed.

    Now you can run your alter which drops the column.


    Unfortunately, I don’t know how to drop a column, just using JDBC. If someone knows please let me know.

    References:

    • Understanding What Controls the Automatic Reply Function
    • Replying to Run-Time Inquiry Messages
    • Error in dropping column (forum post)
    • How can I avoid SQL0952 on ALTER TABLE?
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Why does SQL 2008 all of a sudden want to drop my tables when
I'm using SQL Server 2008. I have a NVARCHAR(MAX) column called Title and i
I want to be notified when column drag-n-drop operation is ended to update column
I want to add a new column CreatedBy to a table PerformanceData. I want
I want create a drop shadow around the canvas component in flex. Technically speaking
I want to find a way to produce drop caps (large initial letters several
I want to add a Select One option to a drop down list bound
So I have this SQL table that I need to update. Now we use
I have a table called ProjectRegion. It has two columns, an id and a
I am trying to drop the default value on a bit column, I have

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.