original_string: public function insert($table, array $data = null)
      {
          $insert = $this->build()->insert($table);
          if ($data) {
              return $insert->values($data)->execute();
          }
  
          return $insert;
      }
code: public function insert($table, array $data = null)
      {
          $insert = $this->build()->insert($table);
          if ($data) {
              return $insert->values($data)->execute();
          }
  
          return $insert;
      }
code_tokens: public function insert ( $ table , array $ data = null ) { $ insert = $ this -> build ( ) -> insert ( $ table ) ; if ( $ data ) { return $ insert -> values ( $ data ) -> execute ( ) ; } return $ insert ; }
docstring: Insert data into a table
  
  When all parameters are specified, the insert query is immediately
  executed and the number of rows affected will be returned. Otherwise
  the query builder is returned so you can extend the query further.
  
  @param string $table
  @param array  $data (optional)
  @return Query|int
  @throws QueryException
docstring_tokens: Insert data into a table