sqlframe 3.20.0__tar.gz → 3.21.1__tar.gz

Sign up to get free protection for your applications and to get access to all the features.
Files changed (387) hide show
  1. {sqlframe-3.20.0 → sqlframe-3.21.1}/PKG-INFO +1 -1
  2. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/bigquery.md +1 -0
  3. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/duckdb.md +1 -1
  4. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/postgres.md +1 -0
  5. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/snowflake.md +1 -1
  6. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/spark.md +1 -0
  7. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/standalone.md +1 -0
  8. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/_version.py +2 -2
  9. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/dataframe.py +131 -14
  10. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/function_alternatives.py +0 -4
  11. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/functions.py +22 -4
  12. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/util.py +1 -5
  13. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe.egg-info/PKG-INFO +1 -1
  14. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/test_engine_dataframe.py +31 -0
  15. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/test_int_functions.py +1 -5
  16. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/test_int_dataframe.py +48 -0
  17. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_dataframe.py +1 -1
  18. {sqlframe-3.20.0 → sqlframe-3.21.1}/.github/CODEOWNERS +0 -0
  19. {sqlframe-3.20.0 → sqlframe-3.21.1}/.github/workflows/main.workflow.yaml +0 -0
  20. {sqlframe-3.20.0 → sqlframe-3.21.1}/.github/workflows/publish.workflow.yaml +0 -0
  21. {sqlframe-3.20.0 → sqlframe-3.21.1}/.gitignore +0 -0
  22. {sqlframe-3.20.0 → sqlframe-3.21.1}/.pre-commit-config.yaml +0 -0
  23. {sqlframe-3.20.0 → sqlframe-3.21.1}/.readthedocs.yaml +0 -0
  24. {sqlframe-3.20.0 → sqlframe-3.21.1}/LICENSE +0 -0
  25. {sqlframe-3.20.0 → sqlframe-3.21.1}/Makefile +0 -0
  26. {sqlframe-3.20.0 → sqlframe-3.21.1}/README.md +0 -0
  27. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/add_chatgpt_support.md +0 -0
  28. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/add_chatgpt_support/adding_ai_to_meal.jpeg +0 -0
  29. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/add_chatgpt_support/hype_train.gif +0 -0
  30. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/add_chatgpt_support/marvin_paranoid_robot.gif +0 -0
  31. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/add_chatgpt_support/nonsense_sql.png +0 -0
  32. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/add_chatgpt_support/openai_full_rewrite.png +0 -0
  33. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/add_chatgpt_support/openai_replacing_cte_names.png +0 -0
  34. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/add_chatgpt_support/sqlglot_optimized_code.png +0 -0
  35. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/add_chatgpt_support/sunny_shake_head_no.gif +0 -0
  36. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/but_wait_theres_more.gif +0 -0
  37. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/cake.gif +0 -0
  38. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/images/you_get_pyspark_api.gif +0 -0
  39. {sqlframe-3.20.0 → sqlframe-3.21.1}/blogs/sqlframe_universal_dataframe_api.md +0 -0
  40. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/configuration.md +0 -0
  41. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/databricks.md +0 -0
  42. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/docs/bigquery.md +0 -0
  43. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/docs/duckdb.md +0 -0
  44. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/docs/images/SF.png +0 -0
  45. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/docs/images/favicon.png +0 -0
  46. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/docs/images/favicon_old.png +0 -0
  47. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/docs/images/sqlframe_diagram.png +0 -0
  48. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/docs/images/sqlframe_logo.png +0 -0
  49. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/docs/postgres.md +0 -0
  50. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/images/SF.png +0 -0
  51. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/images/favicon.png +0 -0
  52. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/images/favicon_old.png +0 -0
  53. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/images/sqlframe_diagram.png +0 -0
  54. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/images/sqlframe_logo.png +0 -0
  55. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/index.md +0 -0
  56. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/redshift.md +0 -0
  57. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/requirements.txt +0 -0
  58. {sqlframe-3.20.0 → sqlframe-3.21.1}/docs/stylesheets/extra.css +0 -0
  59. {sqlframe-3.20.0 → sqlframe-3.21.1}/mkdocs.yml +0 -0
  60. {sqlframe-3.20.0 → sqlframe-3.21.1}/pytest.ini +0 -0
  61. {sqlframe-3.20.0 → sqlframe-3.21.1}/renovate.json +0 -0
  62. {sqlframe-3.20.0 → sqlframe-3.21.1}/setup.cfg +0 -0
  63. {sqlframe-3.20.0 → sqlframe-3.21.1}/setup.py +0 -0
  64. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/LICENSE +0 -0
  65. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/__init__.py +0 -0
  66. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/__init__.py +0 -0
  67. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/_typing.py +0 -0
  68. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/catalog.py +0 -0
  69. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/column.py +0 -0
  70. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/decorators.py +0 -0
  71. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/exceptions.py +0 -0
  72. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/group.py +0 -0
  73. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/mixins/__init__.py +0 -0
  74. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/mixins/catalog_mixins.py +0 -0
  75. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/mixins/dataframe_mixins.py +0 -0
  76. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/mixins/readwriter_mixins.py +0 -0
  77. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/mixins/table_mixins.py +0 -0
  78. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/normalize.py +0 -0
  79. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/operations.py +0 -0
  80. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/readerwriter.py +0 -0
  81. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/session.py +0 -0
  82. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/table.py +0 -0
  83. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/transforms.py +0 -0
  84. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/types.py +0 -0
  85. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/udf.py +0 -0
  86. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/base/window.py +0 -0
  87. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/__init__.py +0 -0
  88. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/catalog.py +0 -0
  89. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/column.py +0 -0
  90. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/dataframe.py +0 -0
  91. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/functions.py +0 -0
  92. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/functions.pyi +0 -0
  93. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/group.py +0 -0
  94. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/readwriter.py +0 -0
  95. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/session.py +0 -0
  96. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/table.py +0 -0
  97. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/types.py +0 -0
  98. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/udf.py +0 -0
  99. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/bigquery/window.py +0 -0
  100. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/__init__.py +0 -0
  101. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/catalog.py +0 -0
  102. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/column.py +0 -0
  103. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/dataframe.py +0 -0
  104. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/functions.py +0 -0
  105. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/functions.pyi +0 -0
  106. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/group.py +0 -0
  107. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/readwriter.py +0 -0
  108. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/session.py +0 -0
  109. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/table.py +0 -0
  110. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/types.py +0 -0
  111. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/udf.py +0 -0
  112. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/databricks/window.py +0 -0
  113. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/__init__.py +0 -0
  114. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/catalog.py +0 -0
  115. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/column.py +0 -0
  116. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/dataframe.py +0 -0
  117. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/functions.py +0 -0
  118. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/functions.pyi +0 -0
  119. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/group.py +0 -0
  120. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/readwriter.py +0 -0
  121. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/session.py +0 -0
  122. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/table.py +0 -0
  123. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/types.py +0 -0
  124. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/udf.py +0 -0
  125. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/duckdb/window.py +0 -0
  126. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/__init__.py +0 -0
  127. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/catalog.py +0 -0
  128. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/column.py +0 -0
  129. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/dataframe.py +0 -0
  130. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/functions.py +0 -0
  131. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/functions.pyi +0 -0
  132. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/group.py +0 -0
  133. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/readwriter.py +0 -0
  134. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/session.py +0 -0
  135. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/table.py +0 -0
  136. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/types.py +0 -0
  137. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/udf.py +0 -0
  138. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/postgres/window.py +0 -0
  139. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/__init__.py +0 -0
  140. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/catalog.py +0 -0
  141. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/column.py +0 -0
  142. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/dataframe.py +0 -0
  143. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/functions.py +0 -0
  144. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/group.py +0 -0
  145. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/readwriter.py +0 -0
  146. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/session.py +0 -0
  147. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/table.py +0 -0
  148. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/types.py +0 -0
  149. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/udf.py +0 -0
  150. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/redshift/window.py +0 -0
  151. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/__init__.py +0 -0
  152. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/catalog.py +0 -0
  153. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/column.py +0 -0
  154. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/dataframe.py +0 -0
  155. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/functions.py +0 -0
  156. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/functions.pyi +0 -0
  157. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/group.py +0 -0
  158. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/readwriter.py +0 -0
  159. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/session.py +0 -0
  160. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/table.py +0 -0
  161. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/types.py +0 -0
  162. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/udf.py +0 -0
  163. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/snowflake/window.py +0 -0
  164. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/__init__.py +0 -0
  165. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/catalog.py +0 -0
  166. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/column.py +0 -0
  167. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/dataframe.py +0 -0
  168. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/functions.py +0 -0
  169. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/functions.pyi +0 -0
  170. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/group.py +0 -0
  171. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/readwriter.py +0 -0
  172. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/session.py +0 -0
  173. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/table.py +0 -0
  174. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/types.py +0 -0
  175. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/udf.py +0 -0
  176. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/spark/window.py +0 -0
  177. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/__init__.py +0 -0
  178. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/catalog.py +0 -0
  179. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/column.py +0 -0
  180. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/dataframe.py +0 -0
  181. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/functions.py +0 -0
  182. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/group.py +0 -0
  183. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/readwriter.py +0 -0
  184. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/session.py +0 -0
  185. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/table.py +0 -0
  186. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/types.py +0 -0
  187. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/udf.py +0 -0
  188. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/standalone/window.py +0 -0
  189. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/testing/__init__.py +0 -0
  190. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe/testing/utils.py +0 -0
  191. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe.egg-info/SOURCES.txt +0 -0
  192. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe.egg-info/dependency_links.txt +0 -0
  193. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe.egg-info/requires.txt +0 -0
  194. {sqlframe-3.20.0 → sqlframe-3.21.1}/sqlframe.egg-info/top_level.txt +0 -0
  195. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/__init__.py +0 -0
  196. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/common_fixtures.py +0 -0
  197. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/conftest.py +0 -0
  198. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee.csv +0 -0
  199. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee.json +0 -0
  200. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee.parquet +0 -0
  201. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/.part-00000-e5965c7b-e58f-4d3c-ad56-002876814e3a-c000.snappy.parquet.crc +0 -0
  202. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/.part-00002-3fed7f18-370f-4b16-b232-504d6194eb52-c000.snappy.parquet.crc +0 -0
  203. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/.part-00004-143c5da1-d5ab-4706-8e84-0d2a324c6894-c000.snappy.parquet.crc +0 -0
  204. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/.part-00006-64f07e25-c30e-4075-acc6-b3c69c4ce80b-c000.snappy.parquet.crc +0 -0
  205. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/.part-00008-89ccad8d-df73-4ad5-8850-82ef3884db60-c000.snappy.parquet.crc +0 -0
  206. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/.part-00010-812b3382-8c7f-4c4e-9bcd-09ce8664f6e0-c000.snappy.parquet.crc +0 -0
  207. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/_delta_log/.00000000000000000000.json.crc +0 -0
  208. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/_delta_log/00000000000000000000.json +0 -0
  209. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/part-00000-e5965c7b-e58f-4d3c-ad56-002876814e3a-c000.snappy.parquet +0 -0
  210. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/part-00002-3fed7f18-370f-4b16-b232-504d6194eb52-c000.snappy.parquet +0 -0
  211. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/part-00004-143c5da1-d5ab-4706-8e84-0d2a324c6894-c000.snappy.parquet +0 -0
  212. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/part-00006-64f07e25-c30e-4075-acc6-b3c69c4ce80b-c000.snappy.parquet +0 -0
  213. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/part-00008-89ccad8d-df73-4ad5-8850-82ef3884db60-c000.snappy.parquet +0 -0
  214. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_delta/part-00010-812b3382-8c7f-4c4e-9bcd-09ce8664f6e0-c000.snappy.parquet +0 -0
  215. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/employee_extra_line.csv +0 -0
  216. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/issue_219.csv +0 -0
  217. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds1.sql +0 -0
  218. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds10.sql +0 -0
  219. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds11.sql +0 -0
  220. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds12.sql +0 -0
  221. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds13.sql +0 -0
  222. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds14.sql +0 -0
  223. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds15.sql +0 -0
  224. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds16.sql +0 -0
  225. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds17.sql +0 -0
  226. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds18.sql +0 -0
  227. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds19.sql +0 -0
  228. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds2.sql +0 -0
  229. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds20.sql +0 -0
  230. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds21.sql +0 -0
  231. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds22.sql +0 -0
  232. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds23.sql +0 -0
  233. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds24.sql +0 -0
  234. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds25.sql +0 -0
  235. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds26.sql +0 -0
  236. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds27.sql +0 -0
  237. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds28.sql +0 -0
  238. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds29.sql +0 -0
  239. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds3.sql +0 -0
  240. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds30.sql +0 -0
  241. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds31.sql +0 -0
  242. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds32.sql +0 -0
  243. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds33.sql +0 -0
  244. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds34.sql +0 -0
  245. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds35.sql +0 -0
  246. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds36.sql +0 -0
  247. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds37.sql +0 -0
  248. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds38.sql +0 -0
  249. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds39.sql +0 -0
  250. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds4.sql +0 -0
  251. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds40.sql +0 -0
  252. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds41.sql +0 -0
  253. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds42.sql +0 -0
  254. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds43.sql +0 -0
  255. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds44.sql +0 -0
  256. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds45.sql +0 -0
  257. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds46.sql +0 -0
  258. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds47.sql +0 -0
  259. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds48.sql +0 -0
  260. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds49.sql +0 -0
  261. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds5.sql +0 -0
  262. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds50.sql +0 -0
  263. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds51.sql +0 -0
  264. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds52.sql +0 -0
  265. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds53.sql +0 -0
  266. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds54.sql +0 -0
  267. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds55.sql +0 -0
  268. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds56.sql +0 -0
  269. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds57.sql +0 -0
  270. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds58.sql +0 -0
  271. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds59.sql +0 -0
  272. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds6.sql +0 -0
  273. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds60.sql +0 -0
  274. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds61.sql +0 -0
  275. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds62.sql +0 -0
  276. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds63.sql +0 -0
  277. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds64.sql +0 -0
  278. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds65.sql +0 -0
  279. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds66.sql +0 -0
  280. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds67.sql +0 -0
  281. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds68.sql +0 -0
  282. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds69.sql +0 -0
  283. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds7.sql +0 -0
  284. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds70.sql +0 -0
  285. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds71.sql +0 -0
  286. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds72.sql +0 -0
  287. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds73.sql +0 -0
  288. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds74.sql +0 -0
  289. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds75.sql +0 -0
  290. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds76.sql +0 -0
  291. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds77.sql +0 -0
  292. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds78.sql +0 -0
  293. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds79.sql +0 -0
  294. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds8.sql +0 -0
  295. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds80.sql +0 -0
  296. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds81.sql +0 -0
  297. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds82.sql +0 -0
  298. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds83.sql +0 -0
  299. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds84.sql +0 -0
  300. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds85.sql +0 -0
  301. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds86.sql +0 -0
  302. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds87.sql +0 -0
  303. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds88.sql +0 -0
  304. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds89.sql +0 -0
  305. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds9.sql +0 -0
  306. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds90.sql +0 -0
  307. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds91.sql +0 -0
  308. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds92.sql +0 -0
  309. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds93.sql +0 -0
  310. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds94.sql +0 -0
  311. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds95.sql +0 -0
  312. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds96.sql +0 -0
  313. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds97.sql +0 -0
  314. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds98.sql +0 -0
  315. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/fixtures/tpcds/tpcds99.sql +0 -0
  316. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/__init__.py +0 -0
  317. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/__init__.py +0 -0
  318. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/bigquery/__init__.py +0 -0
  319. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/bigquery/test_bigquery_catalog.py +0 -0
  320. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/bigquery/test_bigquery_dataframe.py +0 -0
  321. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/bigquery/test_bigquery_session.py +0 -0
  322. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/databricks/__init__.py +0 -0
  323. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/databricks/test_databricks_catalog.py +0 -0
  324. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/databricks/test_databricks_dataframe.py +0 -0
  325. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/databricks/test_databricks_session.py +0 -0
  326. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/duck/__init__.py +0 -0
  327. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/duck/test_duckdb_activate.py +0 -0
  328. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/duck/test_duckdb_catalog.py +0 -0
  329. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/duck/test_duckdb_dataframe.py +0 -0
  330. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/duck/test_duckdb_reader.py +0 -0
  331. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/duck/test_duckdb_session.py +0 -0
  332. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/duck/test_duckdb_udf.py +0 -0
  333. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/duck/test_tpcds.py +0 -0
  334. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/postgres/__init__.py +0 -0
  335. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/postgres/test_postgres_activate.py +0 -0
  336. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/postgres/test_postgres_catalog.py +0 -0
  337. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/postgres/test_postgres_dataframe.py +0 -0
  338. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/postgres/test_postgres_session.py +0 -0
  339. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/redshift/__init__.py +0 -0
  340. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/redshift/test_redshift_catalog.py +0 -0
  341. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/redshift/test_redshift_session.py +0 -0
  342. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/snowflake/__init__.py +0 -0
  343. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/snowflake/test_snowflake_catalog.py +0 -0
  344. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/snowflake/test_snowflake_dataframe.py +0 -0
  345. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/snowflake/test_snowflake_session.py +0 -0
  346. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/spark/__init__.py +0 -0
  347. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/spark/test_spark_catalog.py +0 -0
  348. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/spark/test_spark_dataframe.py +0 -0
  349. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/test_engine_column.py +0 -0
  350. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/test_engine_reader.py +0 -0
  351. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/test_engine_session.py +0 -0
  352. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/test_engine_table.py +0 -0
  353. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/test_engine_writer.py +0 -0
  354. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/engines/test_int_testing.py +0 -0
  355. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/fixtures.py +0 -0
  356. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/test_int_dataframe_stats.py +0 -0
  357. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/test_int_grouped_data.py +0 -0
  358. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/integration/test_int_session.py +0 -0
  359. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/types.py +0 -0
  360. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/__init__.py +0 -0
  361. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/bigquery/__init__.py +0 -0
  362. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/bigquery/test_activate.py +0 -0
  363. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/conftest.py +0 -0
  364. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/databricks/__init__.py +0 -0
  365. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/databricks/test_activate.py +0 -0
  366. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/duck/__init__.py +0 -0
  367. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/duck/test_activate.py +0 -0
  368. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/postgres/__init__.py +0 -0
  369. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/postgres/test_activate.py +0 -0
  370. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/redshift/__init__.py +0 -0
  371. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/redshift/test_activate.py +0 -0
  372. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/snowflake/__init__.py +0 -0
  373. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/snowflake/test_activate.py +0 -0
  374. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/spark/__init__.py +0 -0
  375. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/spark/test_activate.py +0 -0
  376. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/__init__.py +0 -0
  377. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/fixtures.py +0 -0
  378. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_activate.py +0 -0
  379. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_column.py +0 -0
  380. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_dataframe_writer.py +0 -0
  381. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_functions.py +0 -0
  382. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_session.py +0 -0
  383. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_session_case_sensitivity.py +0 -0
  384. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_types.py +0 -0
  385. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/standalone/test_window.py +0 -0
  386. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/test_activate.py +0 -0
  387. {sqlframe-3.20.0 → sqlframe-3.21.1}/tests/unit/test_util.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: sqlframe
3
- Version: 3.20.0
3
+ Version: 3.21.1
4
4
  Summary: Turning PySpark Into a Universal DataFrame API
5
5
  Home-page: https://github.com/eakmanrq/sqlframe
6
6
  Author: Ryan Eakman
@@ -289,6 +289,7 @@ See something that you would like to see supported? [Open an issue](https://gith
289
289
  * [union](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.union.html)
290
290
  * [unionAll](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionAll.html)
291
291
  * [unionByName](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionByName.html)
292
+ * [unpivot](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unpivot.html)
292
293
  * [where](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.where.html)
293
294
  * [withColumn](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumn.html)
294
295
  * [withColumnRenamed](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumnRenamed.html)
@@ -255,6 +255,7 @@ See something that you would like to see supported? [Open an issue](https://gith
255
255
  * [union](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.union.html)
256
256
  * [unionAll](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionAll.html)
257
257
  * [unionByName](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionByName.html)
258
+ * [unpivot](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unpivot.html)
258
259
  * [where](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.where.html)
259
260
  * [withColumn](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumn.html)
260
261
  * [withColumnRenamed](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumnRenamed.html)
@@ -447,7 +448,6 @@ See something that you would like to see supported? [Open an issue](https://gith
447
448
  * [sin](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.sin.html)
448
449
  * [size](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.size.html)
449
450
  * [skewness](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.skewness.html)
450
- * Returned value is different but is still calculating the same thing. Need to investigate difference in calculation
451
451
  * [slice](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.slice.html)
452
452
  * [sort_array](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.sort_array.html)
453
453
  * [soundex](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.soundex.html)
@@ -269,6 +269,7 @@ See something that you would like to see supported? [Open an issue](https://gith
269
269
  * [union](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.union.html)
270
270
  * [unionAll](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionAll.html)
271
271
  * [unionByName](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionByName.html)
272
+ * [unpivot](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unpivot.html)
272
273
  * [where](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.where.html)
273
274
  * [withColumn](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumn.html)
274
275
  * [withColumnRenamed](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumnRenamed.html)
@@ -285,6 +285,7 @@ See something that you would like to see supported? [Open an issue](https://gith
285
285
  * [union](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.union.html)
286
286
  * [unionAll](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionAll.html)
287
287
  * [unionByName](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionByName.html)
288
+ * [unpivot](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unpivot.html)
288
289
  * [where](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.where.html)
289
290
  * [withColumn](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumn.html)
290
291
  * [withColumnRenamed](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumnRenamed.html)
@@ -486,7 +487,6 @@ See something that you would like to see supported? [Open an issue](https://gith
486
487
  * [sinh](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.sinh.html)
487
488
  * [size](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.size.html)
488
489
  * [skewness](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.skewness.html)
489
- * Skewness is calculated differently
490
490
  * [slice](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.slice.html)
491
491
  * [sort_array](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.sort_array.html)
492
492
  * [soundex](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.functions.soundex.html)
@@ -174,6 +174,7 @@ df.show(5)
174
174
  * [union](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.union.html)
175
175
  * [unionAll](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionAll.html)
176
176
  * [unionByName](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionByName.html)
177
+ * [unpivot](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unpivot.html)
177
178
  * [where](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.where.html)
178
179
  * [withColumn](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumn.html)
179
180
  * [withColumnRenamed](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumnRenamed.html)
@@ -181,6 +181,7 @@ See something that you would like to see supported? [Open an issue](https://gith
181
181
  * [union](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.union.html)
182
182
  * [unionAll](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionAll.html)
183
183
  * [unionByName](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unionByName.html)
184
+ * [unpivot](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.unpivot.html)
184
185
  * [where](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.where.html)
185
186
  * [withColumn](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumn.html)
186
187
  * [withColumnRenamed](https://spark.apache.org/docs/latest/api/python/reference/pyspark.sql/api/pyspark.sql.DataFrame.withColumnRenamed.html)
@@ -12,5 +12,5 @@ __version__: str
12
12
  __version_tuple__: VERSION_TUPLE
13
13
  version_tuple: VERSION_TUPLE
14
14
 
15
- __version__ = version = '3.20.0'
16
- __version_tuple__ = version_tuple = (3, 20, 0)
15
+ __version__ = version = '3.21.1'
16
+ __version_tuple__ = version_tuple = (3, 21, 1)
@@ -296,6 +296,12 @@ class BaseDataFrame(t.Generic[SESSION, WRITER, NA, STAT, GROUP_DATA]):
296
296
 
297
297
  @property
298
298
  def columns(self) -> t.List[str]:
299
+ expression_display_names = self.expression.copy()
300
+ self._set_display_names(expression_display_names)
301
+ return expression_display_names.named_selects
302
+
303
+ @property
304
+ def _columns(self) -> t.List[str]:
299
305
  return self.expression.named_selects
300
306
 
301
307
  @property
@@ -611,6 +617,18 @@ class BaseDataFrame(t.Generic[SESSION, WRITER, NA, STAT, GROUP_DATA]):
611
617
  }
612
618
  self.display_name_mapping.update(zipped)
613
619
 
620
+ def _set_display_names(self, select_expression: exp.Select) -> None:
621
+ for index, column in enumerate(select_expression.expressions):
622
+ column_name = quote_preserving_alias_or_name(column)
623
+ if column_name in self.display_name_mapping:
624
+ display_name_identifier = exp.to_identifier(
625
+ self.display_name_mapping[column_name], quoted=True
626
+ )
627
+ display_name_identifier._meta = {"case_sensitive": True, **(column._meta or {})}
628
+ select_expression.expressions[index] = exp.alias_(
629
+ column.unalias(), display_name_identifier, quoted=True
630
+ )
631
+
614
632
  def _get_expressions(
615
633
  self,
616
634
  optimize: bool = True,
@@ -631,16 +649,7 @@ class BaseDataFrame(t.Generic[SESSION, WRITER, NA, STAT, GROUP_DATA]):
631
649
  select_expression = select_expression.transform(
632
650
  replace_id_value, replacement_mapping
633
651
  ).assert_is(exp.Select)
634
- for index, column in enumerate(select_expression.expressions):
635
- column_name = quote_preserving_alias_or_name(column)
636
- if column_name in self.display_name_mapping:
637
- display_name_identifier = exp.to_identifier(
638
- self.display_name_mapping[column_name], quoted=True
639
- )
640
- display_name_identifier._meta = {"case_sensitive": True, **(column._meta or {})}
641
- select_expression.expressions[index] = exp.alias_(
642
- column.unalias(), display_name_identifier, quoted=True
643
- )
652
+ self._set_display_names(select_expression)
644
653
  if optimize:
645
654
  select_expression = t.cast(
646
655
  exp.Select,
@@ -1158,8 +1167,8 @@ class BaseDataFrame(t.Generic[SESSION, WRITER, NA, STAT, GROUP_DATA]):
1158
1167
 
1159
1168
  @operation(Operation.FROM)
1160
1169
  def unionByName(self, other: Self, allowMissingColumns: bool = False) -> Self:
1161
- l_columns = self.columns
1162
- r_columns = other.columns
1170
+ l_columns = self._columns
1171
+ r_columns = other._columns
1163
1172
  if not allowMissingColumns:
1164
1173
  l_expressions = l_columns
1165
1174
  r_expressions = l_columns
@@ -1619,9 +1628,9 @@ class BaseDataFrame(t.Generic[SESSION, WRITER, NA, STAT, GROUP_DATA]):
1619
1628
  | 16| Bob|
1620
1629
  +---+-----+
1621
1630
  """
1622
- if len(cols) != len(self.columns):
1631
+ if len(cols) != len(self._columns):
1623
1632
  raise ValueError(
1624
- f"Number of column names does not match number of columns: {len(cols)} != {len(self.columns)}"
1633
+ f"Number of column names does not match number of columns: {len(cols)} != {len(self._columns)}"
1625
1634
  )
1626
1635
  expression = self.expression.copy()
1627
1636
  expression = expression.select(
@@ -1718,6 +1727,114 @@ class BaseDataFrame(t.Generic[SESSION, WRITER, NA, STAT, GROUP_DATA]):
1718
1727
  grouping_columns.extend([list(x) for x in itertools.combinations(columns, i)])
1719
1728
  return self._group_data(self, grouping_columns, self.last_op)
1720
1729
 
1730
+ @operation(Operation.SELECT)
1731
+ def unpivot(
1732
+ self,
1733
+ ids: t.Union[ColumnOrName, t.List[ColumnOrName], t.Tuple[ColumnOrName, ...]],
1734
+ values: t.Optional[t.Union[ColumnOrName, t.List[ColumnOrName], t.Tuple[ColumnOrName, ...]]],
1735
+ variableColumnName: str,
1736
+ valueColumnName: str,
1737
+ ) -> Self:
1738
+ """
1739
+ Unpivot a DataFrame from wide format to long format, optionally leaving
1740
+ identifier columns set. This is the reverse to `groupBy(...).pivot(...).agg(...)`,
1741
+ except for the aggregation, which cannot be reversed.
1742
+
1743
+ This function is useful to massage a DataFrame into a format where some
1744
+ columns are identifier columns ("ids"), while all other columns ("values")
1745
+ are "unpivoted" to the rows, leaving just two non-id columns, named as given
1746
+ by `variableColumnName` and `valueColumnName`.
1747
+
1748
+ When no "id" columns are given, the unpivoted DataFrame consists of only the
1749
+ "variable" and "value" columns.
1750
+
1751
+ The `values` columns must not be empty so at least one value must be given to be unpivoted.
1752
+ When `values` is `None`, all non-id columns will be unpivoted.
1753
+
1754
+ All "value" columns must share a least common data type. Unless they are the same data type,
1755
+ all "value" columns are cast to the nearest common data type. For instance, types
1756
+ `IntegerType` and `LongType` are cast to `LongType`, while `IntegerType` and `StringType`
1757
+ do not have a common data type and `unpivot` fails.
1758
+
1759
+ .. versionadded:: 3.4.0
1760
+
1761
+ Parameters
1762
+ ----------
1763
+ ids : str, Column, tuple, list
1764
+ Column(s) to use as identifiers. Can be a single column or column name,
1765
+ or a list or tuple for multiple columns.
1766
+ values : str, Column, tuple, list, optional
1767
+ Column(s) to unpivot. Can be a single column or column name, or a list or tuple
1768
+ for multiple columns. If specified, must not be empty. If not specified, uses all
1769
+ columns that are not set as `ids`.
1770
+ variableColumnName : str
1771
+ Name of the variable column.
1772
+ valueColumnName : str
1773
+ Name of the value column.
1774
+
1775
+ Returns
1776
+ -------
1777
+ :class:`DataFrame`
1778
+ Unpivoted DataFrame.
1779
+
1780
+ Notes
1781
+ -----
1782
+ Supports Spark Connect.
1783
+
1784
+ Examples
1785
+ --------
1786
+ >>> df = spark.createDataFrame(
1787
+ ... [(1, 11, 1.1), (2, 12, 1.2)],
1788
+ ... ["id", "int", "double"],
1789
+ ... )
1790
+ >>> df.show()
1791
+ +---+---+------+
1792
+ | id|int|double|
1793
+ +---+---+------+
1794
+ | 1| 11| 1.1|
1795
+ | 2| 12| 1.2|
1796
+ +---+---+------+
1797
+
1798
+ >>> df.unpivot("id", ["int", "double"], "var", "val").show()
1799
+ +---+------+----+
1800
+ | id| var| val|
1801
+ +---+------+----+
1802
+ | 1| int|11.0|
1803
+ | 1|double| 1.1|
1804
+ | 2| int|12.0|
1805
+ | 2|double| 1.2|
1806
+ +---+------+----+
1807
+
1808
+ See Also
1809
+ --------
1810
+ DataFrame.melt
1811
+ """
1812
+ from sqlframe.base import functions as F
1813
+
1814
+ id_columns = self._ensure_and_normalize_cols(ids)
1815
+ if not values:
1816
+ outer_selects = self._get_outer_select_columns(self.expression)
1817
+ values = [
1818
+ column
1819
+ for column in outer_selects
1820
+ if column.alias_or_name not in {x.alias_or_name for x in id_columns}
1821
+ ]
1822
+ value_columns = self._ensure_and_normalize_cols(values)
1823
+
1824
+ df = self._convert_leaf_to_cte()
1825
+ selects = []
1826
+ for value in value_columns:
1827
+ selects.append(
1828
+ exp.select(
1829
+ *[x.column_expression for x in id_columns],
1830
+ F.lit(value.alias_or_name).alias(variableColumnName).expression,
1831
+ value.alias(valueColumnName).expression,
1832
+ ).from_(df.expression.ctes[-1].alias_or_name)
1833
+ )
1834
+ unioned_expression = functools.reduce(lambda x, y: x.union(y, distinct=False), selects) # type: ignore
1835
+ final_expression = self._add_ctes_to_expression(unioned_expression, df.expression.ctes)
1836
+ return self.copy(expression=final_expression)._convert_leaf_to_cte()
1837
+
1721
1838
  def collect(self) -> t.List[Row]:
1722
1839
  return self._collect()
1723
1840
 
@@ -193,10 +193,6 @@ def factorial_ensure_int(col: ColumnOrName) -> Column:
193
193
  return Column.invoke_anonymous_function(col_func(col).cast("integer"), "FACTORIAL")
194
194
 
195
195
 
196
- def skewness_from_skew(col: ColumnOrName) -> Column:
197
- return Column.invoke_anonymous_function(col, "SKEW")
198
-
199
-
200
196
  def isnan_using_equal(col: ColumnOrName) -> Column:
201
197
  lit = get_func_from_session("lit")
202
198
  return Column(
@@ -486,14 +486,32 @@ def var_pop(col: ColumnOrName) -> Column:
486
486
 
487
487
  @meta(unsupported_engines=["bigquery", "postgres"])
488
488
  def skewness(col: ColumnOrName) -> Column:
489
- from sqlframe.base.function_alternatives import skewness_from_skew
490
-
491
489
  session = _get_session()
492
490
 
491
+ func_name = "SKEWNESS"
492
+
493
493
  if session._is_snowflake:
494
- return skewness_from_skew(col)
494
+ func_name = "SKEW"
495
+
496
+ if session._is_duckdb or session._is_snowflake:
497
+ when_func = get_func_from_session("when")
498
+ count_func = get_func_from_session("count")
499
+ count_star = count_func("*")
500
+ lit_func = get_func_from_session("lit")
501
+ sqrt_func = get_func_from_session("sqrt")
502
+ col = Column.ensure_col(col)
503
+ return (
504
+ when_func(count_star == lit_func(0), lit_func(None))
505
+ .when(count_star == lit_func(1), lit_func(float("nan")))
506
+ .when(count_star == lit_func(2), lit_func(0.0))
507
+ .otherwise(
508
+ Column.invoke_anonymous_function(col, func_name)
509
+ * (count_star - lit_func(2))
510
+ / (sqrt_func(count_star * (count_star - lit_func(1))))
511
+ )
512
+ )
495
513
 
496
- return Column.invoke_anonymous_function(col, "SKEWNESS")
514
+ return Column.invoke_anonymous_function(col, func_name)
497
515
 
498
516
 
499
517
  @meta(unsupported_engines=["bigquery", "postgres"])
@@ -97,12 +97,8 @@ def get_column_mapping_from_schema_input(
97
97
  else:
98
98
  value = {x.strip(): None for x in schema}
99
99
  return {
100
- exp.to_column(k).sql(dialect=dialect): exp.DataType.build(v, dialect=dialect)
101
- if v is not None
102
- else v
103
- for k, v in value.items()
100
+ k: exp.DataType.build(v, dialect=dialect) if v is not None else v for k, v in value.items()
104
101
  }
105
- # return {x.strip(): None for x in schema} # type: ignore
106
102
 
107
103
 
108
104
  def get_tables_from_expression_with_join(expression: exp.Select) -> t.List[exp.Table]:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: sqlframe
3
- Version: 3.20.0
3
+ Version: 3.21.1
4
4
  Summary: Turning PySpark Into a Universal DataFrame API
5
5
  Home-page: https://github.com/eakmanrq/sqlframe
6
6
  Author: Ryan Eakman
@@ -109,6 +109,7 @@ def test_show_from_create_version_1(get_session: t.Callable[[], _BaseSession], c
109
109
  +-----+-----+
110
110
  """.strip()
111
111
  )
112
+ assert df.columns == ["foo", "BAR"]
112
113
 
113
114
 
114
115
  # https://github.com/eakmanrq/sqlframe/issues/294
@@ -133,8 +134,10 @@ def test_show_from_create_version_2(get_session: t.Callable[[], _BaseSession], c
133
134
  +---+-----+
134
135
  """.strip()
135
136
  )
137
+ assert df.columns == ["a", "BAR"]
136
138
 
137
139
 
140
+ # https://github.com/eakmanrq/sqlframe/issues/291
138
141
  def test_show_from_create_with_space(get_session: t.Callable[[], _BaseSession], capsys):
139
142
  session = get_session()
140
143
  df = session.createDataFrame(
@@ -154,3 +157,31 @@ def test_show_from_create_with_space(get_session: t.Callable[[], _BaseSession],
154
157
  +--------+
155
158
  """.strip()
156
159
  )
160
+
161
+
162
+ # https://github.com/eakmanrq/sqlframe/issues/291
163
+ def test_show_from_create_with_space_with_schema(get_session: t.Callable[[], _BaseSession], capsys):
164
+ session = get_session()
165
+ data = {"an tan": [1, 3, 2], "b": [4, 4, 6], "z": [7.0, 8.0, 9.0]}
166
+
167
+ df = session.createDataFrame([*zip(*data.values())], schema=[*data.keys()])
168
+ df.show()
169
+ captured = capsys.readouterr()
170
+ assert (
171
+ captured.out.strip()
172
+ == """
173
+ +--------+---+-----+
174
+ | an tan | b | z |
175
+ +--------+---+-----+
176
+ | 1 | 4 | 7.0 |
177
+ | 3 | 4 | 8.0 |
178
+ | 2 | 6 | 9.0 |
179
+ +--------+---+-----+
180
+ """.strip()
181
+ )
182
+ assert df.columns == ["an tan", "b", "z"]
183
+ assert df.collect() == [
184
+ Row(**{"an tan": 1, "b": 4, "z": 7.0}),
185
+ Row(**{"an tan": 3, "b": 4, "z": 8.0}),
186
+ Row(**{"an tan": 2, "b": 6, "z": 9.0}),
187
+ ]
@@ -690,11 +690,7 @@ def test_var_pop(get_session_and_func):
690
690
  def test_skewness(get_session_and_func):
691
691
  session, skewness = get_session_and_func("skewness")
692
692
  df = session.createDataFrame([[1], [1], [2]], ["c"])
693
- if isinstance(session, (DuckDBSession, SnowflakeSession)):
694
- # DuckDB calculates skewness differently than spark
695
- assert round(df.select(skewness("c")).first()[0], 4) == 1.7321
696
- else:
697
- assert math.isclose(df.select(skewness(df.c)).first()[0], 0.7071067811865475)
693
+ assert math.isclose(df.select(skewness(df.c)).first()[0], 0.7071067811865475, rel_tol=1e-5)
698
694
 
699
695
 
700
696
  def test_kurtosis(get_session_and_func):
@@ -2164,6 +2164,54 @@ def test_transform(
2164
2164
  compare_frames(df, dfs)
2165
2165
 
2166
2166
 
2167
+ def test_unpivot(
2168
+ pyspark_employee: PySparkDataFrame,
2169
+ get_df: t.Callable[[str], BaseDataFrame],
2170
+ compare_frames: t.Callable,
2171
+ ):
2172
+ employee = get_df("employee")
2173
+ df = pyspark_employee.unpivot(
2174
+ pyspark_employee.columns, # type: ignore
2175
+ ["fname", "lname"],
2176
+ "attribute",
2177
+ "value",
2178
+ )
2179
+ dfs = employee.unpivot(employee.columns, ["fname", "lname"], "attribute", "value")
2180
+ compare_frames(df, dfs, sort=True)
2181
+
2182
+
2183
+ def test_unpivot_no_values(
2184
+ pyspark_employee: PySparkDataFrame,
2185
+ get_df: t.Callable[[str], BaseDataFrame],
2186
+ compare_frames: t.Callable,
2187
+ ):
2188
+ employee = get_df("employee")
2189
+ df = pyspark_employee.unpivot(["employee_id", "fname", "lname"], None, "attribute", "value")
2190
+ dfs = employee.unpivot(["employee_id", "fname", "lname"], None, "attribute", "value")
2191
+ compare_frames(df, dfs, sort=True)
2192
+
2193
+
2194
+ def test_unpivot_doc_example(
2195
+ pyspark_employee: PySparkDataFrame,
2196
+ get_df: t.Callable[[str], BaseDataFrame],
2197
+ compare_frames: t.Callable,
2198
+ ):
2199
+ df = pyspark_employee._session.createDataFrame(
2200
+ [(1, 11, 1.1), (2, 12, 1.2)],
2201
+ ["id", "int", "double"],
2202
+ ).unpivot("id", ["int", "double"], "var", "val")
2203
+
2204
+ dfs = (
2205
+ get_df("employee")
2206
+ .session.createDataFrame(
2207
+ [(1, 11, 1.1), (2, 12, 1.2)],
2208
+ ["id", "int", "double"],
2209
+ )
2210
+ .unpivot("id", ["int", "double"], "var", "val")
2211
+ )
2212
+ compare_frames(df, dfs, sort=True, compare_schema=False)
2213
+
2214
+
2167
2215
  # https://github.com/eakmanrq/sqlframe/issues/51
2168
2216
  def test_join_full_outer_no_match(
2169
2217
  pyspark_employee: PySparkDataFrame,
@@ -51,7 +51,7 @@ def test_persist_storagelevel(standalone_employee: StandaloneDataFrame, compare_
51
51
 
52
52
  def test_with_column_duplicate_alias(standalone_employee: StandaloneDataFrame):
53
53
  df = standalone_employee.withColumn("fName", F.col("age").cast("string"))
54
- assert df.columns == ["employee_id", "fname", "lname", "age", "store_id"]
54
+ assert df.columns == ["employee_id", "fName", "lname", "age", "store_id"]
55
55
  # Make sure that the new columns is added with an alias to `fname`
56
56
  assert (
57
57
  df.sql(pretty=False)
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes