how can a change a column named 'population * 1.1' with oher name?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • danut34
    New Member
    • Feb 2012
    • 1

    how can a change a column named 'population * 1.1' with oher name?

    i cannot change column name "population * 1.1" with another name...
    i try with alter modify, alter change.. nothing
    i try puting the expression column in quotes..nothing ..
    i try all things..
  • saurav
    New Member
    • Feb 2012
    • 2

    #2
    ok bro you want to change the column name with help of query so your solution is
    here
    first you create the one table
    like
    create table thug
    (
    name varchar(10),
    address varchar(20),
    )
    now i want to change the column name like address from the table thug
    please see this query
    sp_rename 'thug.address', sammy
    'thug.address' in this first is [table name.column name(where you want to change)]
    sammy is new column name

    Comment

    Working...