Update a content type field via db not working D8
To update the value of a field for a node, you need to.


Load it
Modify it
Save it


In code it looks like this:

$node = \Drupal\node\Entity\Node::load($nid);
if ($node) {
  $node-&gt;field_p_frontip = '192.168.1.100';
  $node-&gt;save();
}


How you set the value of the field, depends on the field itself. Most fields are simple, and can be set with a scalar value. If field has multiple values or stores more complex data (like the address field), you need to account for this complexity. Usually this is done with arrays.