Please note that the contents of this offline web site may be out of date. To access the most recent documentation visit the online version .
Note that links that point to online resources are green in color and will open in a new window.
We would love it if you could give us feedback about this material by filling this form (You have to be online to fill it)



The cloudsql package

import "appengine/cloudsql"

Introduction

Package cloudsql exposes access to Google Cloud SQL databases.

This package is intended for MySQL drivers to make App Engine-specific connections.

Applications should use this package through database/sql: Select a pure Go MySQL driver that supports this package, and use sql.Open with protocol "cloudsql" and an address of the CloudSQL instance. The exact format of the second argument to sql.Open is driver-dependent; consult the driver's documentation for details.

Example:

import "database/sql"
import _ "<some mysql package>"

db, err := sql.Open("mysql", "cloudsql:my-instance*dbname/user/passwd")

Index

func Dial(instance string) (net.Conn, error)

func Dial

func Dial(instance string) (net.Conn, error)

Dial connects to the named Cloud SQL instance.

Authentication required

You need to be signed in with Google+ to do that.

Signing you in...

Google Developers needs your permission to do that.