0

I want to use Doctrine's DBAL Query Builder to insert record into database.

I've found that this in fact is possible in the latest documentation via insert method: http://docs.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/query-builder.html#building-a-query

However, I have the latest version of DBAL installed via Composer and it has no such methods.

Why is that?

What are my alternatives?

tom
  • 8,189
  • 12
  • 51
  • 70
Slava Fomin II
  • 26,865
  • 29
  • 124
  • 202
  • 1
    possible duplicate of [Missing insert() method on Doctrine DBAL Query Builder](http://stackoverflow.com/questions/25437816/missing-insert-method-on-doctrine-dbal-query-builder) – tom Oct 15 '14 at 07:43
  • What exact version are you using? Also see the question linked above. – Maerlyn Oct 15 '14 at 08:14

1 Answers1

1

I guess you installed the latest stable (2.4.2) and this version contains no insert method in the QueryBuilder.

If you check the same file on the master branch this contains the insert method

I think there is something wrong with the documentation as I can't find anywhere how to view the documentation of the latest stable ...

tom
  • 8,189
  • 12
  • 51
  • 70