You can clone with
HTTPS or Subversion.
Just a small feature request for the API. I'd like a clone method that would take an existing chain and return a functional duplicate of the working SQL command.
My use-case is like this: I have a lib that's generating a SELECT statement for single items by ID, as well as the list of all in a collection. Having to specify my fields/tables/etc is kinda cumbersome and creating a wrapper function is not very elegant either.
var select = squel.select()
var single = select.clone()
.where("id = ?")
var list = select.clone()
This is a trivial example, but after adding joins and other conditions, this becomes a much more friendly way to approach similar queries.
This is a good idea. In the interim have you tried using normal cloning methods? http://stackoverflow.com/a/5344074
I have not yet, I'll give it a spin and report back for other's reference.
All builders now have a clone() method.
Fixed test setup error whereby tests being run multiple times.
Simplified Makefile test file spec.
Latest version (1.0.5) now comes with a clone() method available to all query builders (but not Expression builders yet, unfortunately)
Stellar, I'll just be using that then :)