17 lines
373 B
Plaintext
17 lines
373 B
Plaintext
``++UPDATE dbtab SET ...++`` without a ``++WHERE++`` condition changes all the entries of the table. Check whether dataset to be changed can be limited by a suitable ``++WHERE++`` condition.
|
|
|
|
|
|
== Noncompliant Code Example
|
|
|
|
----
|
|
UPDATE COUNTRIES SET NAME=country_name.
|
|
----
|
|
|
|
|
|
== Compliant Solution
|
|
|
|
----
|
|
UPDATE COUNTRIES SET NAME=country_name WHERE CODE=country_code.
|
|
----
|
|
|