Posted on 2005-05-06
Last Modified: 2009-01-09
I'm working with DB2 8.0 and I want to modify a nullable column to not nullable column. But, I don't know how to do it.
It's very very easy this question, suppose this table

create table table_1
   te1_id INTEGER,
   te1_description VARCHAR(50)

I want modify column te1_id to not nullable column.


Question by:mjuri
    LVL 25

    Accepted Solution

    alter table table_1 add check (te1_id is not null)
    LVL 57

    Expert Comment

    by:Raja Jegan R
    You can do
    alter table alter column column_name set not null

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    IT, Stop Being Called Into Every Meeting

    Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

    This article explains all about SQL Server Piecemeal Restore with examples in step by step manner.
    Read about achieving the basic levels of HRIS security in the workplace.
    Video by: Steve
    Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    737 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    20 Experts available now in Live!

    Get 1:1 Help Now