Added open/close connection capabilities

Now it's possible to call open and get a connection handler, then use it for subsequent call.
It's necessary  if you want to manage a transaction.