I have a python program that stores values in a database. I'd like to store them in Big Query instead of locally. From the Big Query docs I've looked at this example:
rows_to_insert = [(u"Phred Phlyntstone", 32), (u"Wylma Phlyntstone", 29)]
Where can I find a detailed explanation of how this works? What should go where and how it should be formatted. I have created a table with a schema (name, date, age). When I create my own rows_to_insert do i treat each field ("Phred", 2345-02-19, 44) as the column defined by the schema?
If so, can I use a variable here? If I can, can someone give a quick example of what that looks like? (x, y, z) or ({x}, {y}, {z}) or ((x), (y), (z)).
In the example above each row entry starts with a 'u'. Why?
the general syntax I have seen is:
INSERT INTO ‘table_name’
(column1, column2, column3, - - - )
VALUES (value1, value2, value3 - - -)
Am I able to use this syntax?
Thanks for reading my post. If I've made a mistake in how I've phrased my question of if you have a suggestion on how to present it more clearly please let me know and I'll adjust.