See how to execute a Python script to connect to your Spanner instance and to load data into two tables using the Cloud Spanner API.
- [Instructor] So now we're going to use the API…to write some data into our database.…We've got the familiar pattern…in the first few lines of code, here.…We're using the spanner library.…We're setting out instance and database variables…and then we're having a main method…to call our working method.…You can see on the insert data method,…again, similar pattern to what we saw in the previous movie.…We basically create the connection string…or the equivalent of it by the spanner dot client…and the spanner client dot instance,…passing in the instance id and the instance dot database,…passing the database id.…
Depending on how you set up your session,…you might find that you need to alter line 10…where it's saying spanner client equals spanner dot client…passing in no parameters.…As we did with the previous movie,…you might need to pass in a parameter called project…and set that equal to the string value…of your particular project id.…That's because there appears to be a bug,…in the beta version of this product,…
- What is Cloud Spanner?
- Creating an instance and database using the console
- Making hot schema updates
- Cloud Spanner queries
- Loading data into Cloud Spanner
- Understanding transactions
- Cloud Spanner DevOps tools
- Auditing logs with Stackdriver
- Cost optimization
Skill Level Intermediate
Google Cloud Storage and Data Essential Trainingwith Joseph Lowery2h 54m Intermediate
Google Cloud Platform Essential Trainingwith Lynn Langit3h 56m Intermediate
1. Why Cloud Spanner?
2. Cloud Spanner Basics
3. Cloud Spanner Queries
4. Cloud Spanner DevOps
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.