SQLUpdate
This feature is not supported on the Wolfram Cloud.

SQLUpdate[conn,table,cols,data]
updates data in a table in an SQL connection.

DetailsDetails

  • To use SQLUpdate, you first need to load DatabaseLink using Needs["DatabaseLink`"].
  • Returns an integer specifying the number of rows affected by the query.
  • The following option can be given:
  • "Timeout"$SQLTimeoutthe timeout for the query

ExamplesExamplesopen allclose all

Basic Examples  (1)Basic Examples  (1)

In[1]:=
Click for copyable input

If you find that the examples in this section do not work as shown, you may need to install or restore the example database with the package, as described in Using the Example Databases.

In[2]:=
Click for copyable input

Create a table and insert some data:

In[3]:=
Click for copyable input
In[4]:=
Click for copyable input
In[5]:=
Click for copyable input
Out[5]=

Update all the data:

In[6]:=
Click for copyable input
Out[6]=
In[7]:=
Click for copyable input
Out[7]=

Insert more data:

In[8]:=
Click for copyable input
In[9]:=
Click for copyable input
Out[9]=

Update only data matching a condition:

In[10]:=
Click for copyable input
Out[10]=
In[11]:=
Click for copyable input
Out[11]=
In[12]:=
Click for copyable input
In[13]:=
Click for copyable input