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 8176793
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 6, 20262026-06-06T23:19:45+00:00 2026-06-06T23:19:45+00:00

I am using Oracle 11g for my web application. I want to add a

  • 0

I am using Oracle 11g for my web application. I want to add a column and a comment to an existing table. I can do that easily with the below commands

ALTER TABLE product ADD product_description VARCHAR2(20)

and

COMMENT ON COLUMN product.product_description 
     IS 'This is comment for the column';

But I want to do above task in single command. I searched on internet for a command to add a column and comment in a single command but I couldn’t find. I wonder if this is possible. Any suggestions would be highly appreciated.

  • 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-06-06T23:19:48+00:00Added an answer on June 6, 2026 at 11:19 pm

    No, you can’t.

    There’s no reason why you would need to. This is a one-time operation and so takes only an additional second or two to actually type and execute.

    If you’re adding columns in your web application this is more indicative of a flaw in your data-model as you shouldn’t need to be doing it.


    In response to your comment that a comment is a column attribute; it may seem so but behind the scenes Oracle stores this as an attribute of an object.

    SQL> desc sys.com$
     Name                                      Null?    Type
     ----------------------------------------- -------- ----------------------------
     OBJ#                                      NOT NULL NUMBER
     COL#                                               NUMBER
     COMMENT$                                           VARCHAR2(4000)
    
    SQL>
    

    The column is optional and sys.col$ does not contain comment information.

    I assume, I have no knowledge, that this was done in order to only have one system of dealing with comments rather than multiple.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We are using Oracle 11g as backend in our asp.net Web application. In signup
Using Oracle 11g I want a single exception to an otherwise sorted table select
I am developing an application using oracle 11g, Java(struts2) and Hibernate. I have table
I am using Oracle 11g r2 . I have a table that stores images
I'm using Oracle 11g Schema I want to select the month and day from
I'm using oracle 11g sql developer I have a varchar2 column with dates as
I am using Oracle 11g client, with ODP.NET. I am trying to add conditional
I'm developing a web service using NHibernate, WCF and Oracle 11g R1. The web
I am using oracle 11g and have a table with an XMLType. There are
I'm using oracle 11g. I'm inserting date and time using function SYSDATE into column

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.