diff --git a/database/spanner/spanner.go b/database/spanner/spanner.go index f59046a77..84ff25224 100644 --- a/database/spanner/spanner.go +++ b/database/spanner/spanner.go @@ -55,6 +55,13 @@ type DB struct { data *spanner.Client } +func NewDB(admin sdb.DatabaseAdminClient, data spanner.Client) *DB { + return &DB{ + admin: &admin, + data: &data, + } +} + // WithInstance implements database.Driver func WithInstance(instance *DB, config *Config) (database.Driver, error) { if config == nil {