Doctrine\OrientDB\Query\Query::update PHP Method

update() public method

Changes the internal command to an UPDATE, setting the class to update.
public update ( string $class ) : Command
$class string
return Command
    public function update($class)
    {
        $commandClass = $this->getCommandClass('update');
        $this->command = new $commandClass($class);
        return $this->command;
    }

Usage Example

Ejemplo n.º 1
0
 public function testHydrationOfALongProperty()
 {
     $manager = $this->createManager();
     $query = new Query();
     $query->update('Profile')->set(array('hash' => 2937480))->where('@rid = ?', '#' . $this->getClassId('Profile') . ':0');
     $manager->execute($query);
     $neoProfile = $manager->find("#" . $this->getClassId('Profile') . ":0");
     $this->assertInternalType('integer', $neoProfile->hash);
 }
All Usage Examples Of Doctrine\OrientDB\Query\Query::update