Kassem Shehady
Kassem Shehady

Reputation: 760

Connect to CloudSql from Google Dataflow

When Connecting to CloudSql from Google Dataflow job

public String cnstr = "jdbc:google:mysql://xxx:zzz:yyy/dbname?user=root&password=****";
Connection conn = DriverManager.getConnection(cnstr);
                PreparedStatement st = conn.prepareStatement(selectSql))

I got this error:

No suitable driver found for jdbc:google:mysql://

Any Help?

Upvotes: 3

Views: 1212

Answers (1)

Kassem Shehady
Kassem Shehady

Reputation: 760

I change the connection string to

jdbc:mysql://0.0.0.0:3306/dbname?user=root&password=****

And now it is working perfectly;

Upvotes: 3

Related Questions