You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@beam.apache.org by ro...@apache.org on 2016/12/01 17:40:47 UTC

[1/2] incubator-beam git commit: Add snippet for standard sql

Repository: incubator-beam
Updated Branches:
  refs/heads/python-sdk 4414e20a6 -> 9ded359da


Add snippet for standard sql


Project: http://git-wip-us.apache.org/repos/asf/incubator-beam/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-beam/commit/dc68365f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-beam/tree/dc68365f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-beam/diff/dc68365f

Branch: refs/heads/python-sdk
Commit: dc68365f01b4e33ac459abbe2c6fd5567f7b5bc7
Parents: 4414e20
Author: Sourabh Bajaj <so...@google.com>
Authored: Wed Nov 30 14:59:15 2016 -0800
Committer: Robert Bradshaw <ro...@gmail.com>
Committed: Thu Dec 1 09:40:31 2016 -0800

----------------------------------------------------------------------
 sdks/python/apache_beam/examples/snippets/snippets.py | 9 +++++++++
 1 file changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-beam/blob/dc68365f/sdks/python/apache_beam/examples/snippets/snippets.py
----------------------------------------------------------------------
diff --git a/sdks/python/apache_beam/examples/snippets/snippets.py b/sdks/python/apache_beam/examples/snippets/snippets.py
index 891f464..8d05130 100644
--- a/sdks/python/apache_beam/examples/snippets/snippets.py
+++ b/sdks/python/apache_beam/examples/snippets/snippets.py
@@ -915,6 +915,15 @@ def model_bigqueryio():
           query='SELECT year, mean_temp FROM samples.weather_stations'))
   # [END model_bigqueryio_query]
 
+  # [START model_bigqueryio_query_standard_sql]
+  p = beam.Pipeline(options=PipelineOptions())
+  weather_data = p | beam.io.Read(
+      'ReadYearAndTemp',
+      beam.io.BigQuerySource(
+          query='SELECT year, mean_temp FROM `samples.weather_stations`',
+          use_legacy_sql=False))
+  # [END model_bigqueryio_query_standard_sql]
+
   # [START model_bigqueryio_schema]
   schema = 'source:STRING, quote:STRING'
   # [END model_bigqueryio_schema]


[2/2] incubator-beam git commit: Closes #1472

Posted by ro...@apache.org.
Closes #1472


Project: http://git-wip-us.apache.org/repos/asf/incubator-beam/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-beam/commit/9ded359d
Tree: http://git-wip-us.apache.org/repos/asf/incubator-beam/tree/9ded359d
Diff: http://git-wip-us.apache.org/repos/asf/incubator-beam/diff/9ded359d

Branch: refs/heads/python-sdk
Commit: 9ded359daefc6040d61a1f33c77563474fcb09b6
Parents: 4414e20 dc68365
Author: Robert Bradshaw <ro...@gmail.com>
Authored: Thu Dec 1 09:40:32 2016 -0800
Committer: Robert Bradshaw <ro...@gmail.com>
Committed: Thu Dec 1 09:40:32 2016 -0800

----------------------------------------------------------------------
 sdks/python/apache_beam/examples/snippets/snippets.py | 9 +++++++++
 1 file changed, 9 insertions(+)
----------------------------------------------------------------------