snowflake-cloud-data-platform

Fetching data with snowflake connector throws EmptyPyArrowIterator error

一世执手 提交于 2020-08-24 07:50:08
问题 I use python snowflake connector in my python script (plotly dash app) and today the app stopped working without me changing the code. I tried a couple of things to find out what might be the issue and I even tried to run the example code from Snowflake documentation and I got the same error: code: cur = conn.cursor() try: cur.execute("SELECT col1, col2 FROM test_table ORDER BY col1") for (col1, col2) in cur: print('{0}, {1}'.format(col1, col2)) finally: cur.close() error: Traceback (most

OperationalError: 250003: Failed to get the response. Hanging? method: post

与世无争的帅哥 提交于 2020-08-10 19:40:46
问题 I am trying to connect to snowflake using my login credentials. I'm using the following code: snowflake.connector.connect( user="<my_user_name>", password="<my_password>", account="<my_account_name_with_region_and_cloud>" ) When I try to run the above code, I'm getting the following error: OperationalError: 250003: Failed to get the response. Hanging? method: post, url: https://hm53485.us-east-2.aws.snowflakecomputing.com:443/session/v1/login-request?request_id=fcfdd77a-11ff-4956-9ed8

Facing classnotfound exception while reading a snowflake table using spark

空扰寡人 提交于 2020-08-06 05:54:26
问题 I am trying to read a snowflake table from spark-shell. To do that, I did the following. pyspark --jars spark-snowflake_2.11-2.8.0-spark_2.4.jar,jackson-dataformat-xml-2.10.3.jar Using Python version 2.7.5 (default, Feb 20 2018 09:19:12) SparkSession available as 'spark'. >>> from pyspark import SparkConf, SparkContext >>> from pyspark.sql import SQLContext >>> from pyspark.sql.types import * >>> from pyspark import SparkConf, SparkContext >>> sc = SparkContext("local", "Simple App") >>>

Facing classnotfound exception while reading a snowflake table using spark

折月煮酒 提交于 2020-08-06 05:54:13
问题 I am trying to read a snowflake table from spark-shell. To do that, I did the following. pyspark --jars spark-snowflake_2.11-2.8.0-spark_2.4.jar,jackson-dataformat-xml-2.10.3.jar Using Python version 2.7.5 (default, Feb 20 2018 09:19:12) SparkSession available as 'spark'. >>> from pyspark import SparkConf, SparkContext >>> from pyspark.sql import SQLContext >>> from pyspark.sql.types import * >>> from pyspark import SparkConf, SparkContext >>> sc = SparkContext("local", "Simple App") >>>

How to build a Snowflake query to get these results

♀尐吖头ヾ 提交于 2020-07-22 05:40:19
问题 The below table (TMP_RN_TC) in query is a temp table which would be used to load the data into the final table. This table has to get the data from stage-table and the output of temp-table data needs to be stored in final table. Stage table will get data for 15-days in every run. But the fact/final table should store all the data for the first run and then after only one day of data which would be changing (rest 14-days data would remain same). Since stage-table will hold even the duplicate