Home    Back    Forward    Refresh    txtSQL Homepage

UPDATE Syntax
txtSQL >= 3.0.0 Beta

UPDATE [ db.table | table ]
          WHERE WhereClause
          SET ( column1 = value, column2 = value... ) |
                    ([column1, column2...]) VALUES (column1_value, column2_value...)
          [ LIMIT LimitClause ]

This statement will allow for a user to update [a] row[s] of information in the table/database combination provided that fit a certain criteria (the WHERE clause).

If a $limit is defined, then txtSQL will stop updating rows and return the number of rows updated at the $limit. NOTE- This limit only needs one value (i.e. array(20) stops at 21 rows) unlike a regular limit clause.

If a column is of type enum and the value being updated does not exist as one of the enum values, the last value from the enum list is inserted.

NOTE- To have a complete look at the UPDATE function, and any changes to its functionality, see the update() function


User Comments - UPDATE Syntax
No comments posted yet;
Last Page Next Page

'Language Reference'

User Functions

Database Functions

Data Manipulation Functions

Table Functions

Error Handling Functions

SQL Syntax
  • SELECT Syntax
  • INSERT Syntax
  • DELETE syntax
  • UPDATE Syntax
  • CREATE DATABASE Syntax
  • DROP DATABASE Syntax
  • SHOW DATABASES Syntax
  • USE Syntax
  • LOCK Syntax
  • UNLOCK Syntax
  • IS LOCKED Syntax
  • CREATE TABLE Syntax
  • DROP TABLE Syntax
  • SHOW TABLES Syntax
  • DESCRIBE Syntax
  • SHOW USERS Syntax
  • GRANT PERMISSIONS Syntax
  • Column Properties
  • Column Types
  • LIMIT Syntax
  • ORDERBY Syntax
  • WHERE Syntax

  • [ txtSQL Documentation powered by txtSQL | 6 SQL Queries ]