Adding only one value to the table in sql

前端 未结 6 1137
别跟我提以往
别跟我提以往 2020-12-31 05:26

I have a table named student which consists of (rollno, name, sem, branch)

If I want to INSERT only one value (i.e only name h

6条回答
  •  我在风中等你
    2020-12-31 05:57

    First, if the table is all empty, just wanna make the column 'name' with values, it is easy to use INSERT INTO. https://www.w3schools.com/sql/sql_insert.asp.

    `INSERT INTO TABLE_NAME (COLUMN_NAME) VALUES ("the values")` 
    

    Second, if the table is already with some values inside, and only wanna insert some values for one column, use UPDATE. https://www.w3schools.com/sql/sql_update.asp

      UPDATE table_name SET column1 = value1 WHERE condition;
    

提交回复
热议问题