php-sql-query-builder icon indicating copy to clipboard operation
php-sql-query-builder copied to clipboard

Write and WriteFormatted should be merged into the same method.

Open nilportugues opened this issue 10 years ago • 0 comments

The new write method should have:

public function write($query, $formatted = false);

Under the hood, it should call writeRaw (v1 write function) or writeFormatted (same as v1).

public function writeRaw(QueryInterface $query, $resetPlaceholders = true);
public function writeFormatted(QueryInterface $query);

An example of a function behaving like this is json_decode($value, JSON_PRETTY_PRINT);

nilportugues avatar Apr 11 '15 09:04 nilportugues