@clickzetta/cz-cli-darwin-x64 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1243) hide show
  1. package/bin/cz-cli +0 -0
  2. package/bin/skills/cz-cli/SKILL.md +58 -0
  3. package/bin/skills/cz-cli/references/profile-setup.md +88 -0
  4. package/bin/skills/cz-cli-inner/SKILL.md +96 -0
  5. package/bin/skills/dt-creator/SKILL.md +15 -0
  6. package/bin/skills/dt-creator/references/dt-declaration-strategy.md +185 -0
  7. package/bin/skills/dt-creator/references/incremental-config-reference.md +429 -0
  8. package/bin/skills/dt-creator/references/refresh-history-guide.md +268 -0
  9. package/bin/skills/dt-creator/references/sql-limitations.md +80 -0
  10. package/bin/skills/dynamic-table-alter/SKILL.md +190 -0
  11. package/bin/skills/lakehouse-doc/SKILL.md +107 -0
  12. package/bin/skills/lakehouse-doc/references/.gitattributes +1 -0
  13. package/bin/skills/lakehouse-doc/references/.gitlab-ci.yml +11 -0
  14. package/bin/skills/lakehouse-doc/references/702bc8f656.md +387 -0
  15. package/bin/skills/lakehouse-doc/references/774c65e217.md +136 -0
  16. package/bin/skills/lakehouse-doc/references/9164fed65a.md +1 -0
  17. package/bin/skills/lakehouse-doc/references/AIGateway.md +3 -0
  18. package/bin/skills/lakehouse-doc/references/AI_COMPLETE.md +157 -0
  19. package/bin/skills/lakehouse-doc/references/AI_EMBEDDING.md +70 -0
  20. package/bin/skills/lakehouse-doc/references/AI_Gateway.md +255 -0
  21. package/bin/skills/lakehouse-doc/references/AI_eco.md +1 -0
  22. package/bin/skills/lakehouse-doc/references/AI_function_in_SQL.md +25 -0
  23. package/bin/skills/lakehouse-doc/references/AI_function_overview.md +25 -0
  24. package/bin/skills/lakehouse-doc/references/ALTER-EXTERNAL-TABLE.md +78 -0
  25. package/bin/skills/lakehouse-doc/references/ALTER-SCHEMA.md +85 -0
  26. package/bin/skills/lakehouse-doc/references/ALTER-TABLE-COLUMN.md +223 -0
  27. package/bin/skills/lakehouse-doc/references/ALTERTABLE.md +92 -0
  28. package/bin/skills/lakehouse-doc/references/ARRAY.md +99 -0
  29. package/bin/skills/lakehouse-doc/references/Account.md +2 -0
  30. package/bin/skills/lakehouse-doc/references/Analysis.md +1 -0
  31. package/bin/skills/lakehouse-doc/references/AnalyticsModernDataStack.md +390 -0
  32. package/bin/skills/lakehouse-doc/references/Application_list.md +26 -0
  33. package/bin/skills/lakehouse-doc/references/Approval.md +1 -0
  34. package/bin/skills/lakehouse-doc/references/Approval_list.md +61 -0
  35. package/bin/skills/lakehouse-doc/references/BIGINT.md +49 -0
  36. package/bin/skills/lakehouse-doc/references/BINARY.md +104 -0
  37. package/bin/skills/lakehouse-doc/references/BOOLEAN.md +47 -0
  38. package/bin/skills/lakehouse-doc/references/BP_AI_Function_Image2text.md +203 -0
  39. package/bin/skills/lakehouse-doc/references/BluepipeOracleLakehouse_DataSync.md +244 -0
  40. package/bin/skills/lakehouse-doc/references/CHAR.md +38 -0
  41. package/bin/skills/lakehouse-doc/references/CONNECTION.md +1 -0
  42. package/bin/skills/lakehouse-doc/references/COPY-INTO-Location.md +404 -0
  43. package/bin/skills/lakehouse-doc/references/COPY_INTO_Location.md +371 -0
  44. package/bin/skills/lakehouse-doc/references/CREAREUSER.md +42 -0
  45. package/bin/skills/lakehouse-doc/references/CREATE-BLOOMFILTER-INDEX.md +138 -0
  46. package/bin/skills/lakehouse-doc/references/CREATECONNECTION.md +11 -0
  47. package/bin/skills/lakehouse-doc/references/CREATEEXTERNAlLSCHEMA.md +290 -0
  48. package/bin/skills/lakehouse-doc/references/CREATEMATERIALIZEDVIEW.md +518 -0
  49. package/bin/skills/lakehouse-doc/references/CREATEROLE.md +71 -0
  50. package/bin/skills/lakehouse-doc/references/CREATESCHEMA.md +40 -0
  51. package/bin/skills/lakehouse-doc/references/CREATEVIEW.md +63 -0
  52. package/bin/skills/lakehouse-doc/references/CREATE_EXTERNATL_FUNCTION.md +219 -0
  53. package/bin/skills/lakehouse-doc/references/CTERevenueCohort.md +275 -0
  54. package/bin/skills/lakehouse-doc/references/ComputeResourceDDL.md +1 -0
  55. package/bin/skills/lakehouse-doc/references/Concepts.md +1 -0
  56. package/bin/skills/lakehouse-doc/references/Create_Embeding_Function.md +236 -0
  57. package/bin/skills/lakehouse-doc/references/Create_LLM_Function.md +242 -0
  58. package/bin/skills/lakehouse-doc/references/CreditScoringwithZettaparkandPythonMLlibraryNew.md +873 -0
  59. package/bin/skills/lakehouse-doc/references/DATE.md +50 -0
  60. package/bin/skills/lakehouse-doc/references/DDL.md +1 -0
  61. package/bin/skills/lakehouse-doc/references/DECIMAL.md +27 -0
  62. package/bin/skills/lakehouse-doc/references/DELETE.md +48 -0
  63. package/bin/skills/lakehouse-doc/references/DESC-INDEX.md +41 -0
  64. package/bin/skills/lakehouse-doc/references/DESC-JOB.md +31 -0
  65. package/bin/skills/lakehouse-doc/references/DESCCONNECTION.md +39 -0
  66. package/bin/skills/lakehouse-doc/references/DESCMATERIALIZEDVIEW.md +31 -0
  67. package/bin/skills/lakehouse-doc/references/DESCSCHEMAS.md +59 -0
  68. package/bin/skills/lakehouse-doc/references/DESCTABLE.md +105 -0
  69. package/bin/skills/lakehouse-doc/references/DESCVIEW.md +66 -0
  70. package/bin/skills/lakehouse-doc/references/DOUBLE.md +58 -0
  71. package/bin/skills/lakehouse-doc/references/DQL.md +1 -0
  72. package/bin/skills/lakehouse-doc/references/DROP-INDEX.md +29 -0
  73. package/bin/skills/lakehouse-doc/references/DROPCONNECTION.md +32 -0
  74. package/bin/skills/lakehouse-doc/references/DROPMATERIALIZEDVIEW.md +42 -0
  75. package/bin/skills/lakehouse-doc/references/DROPROLE.md +56 -0
  76. package/bin/skills/lakehouse-doc/references/DROPSCHEMA.md +37 -0
  77. package/bin/skills/lakehouse-doc/references/DROPTABLE.md +46 -0
  78. package/bin/skills/lakehouse-doc/references/DROPUSER.md +34 -0
  79. package/bin/skills/lakehouse-doc/references/DROPVIEW.md +33 -0
  80. package/bin/skills/lakehouse-doc/references/DataQuality.md +99 -0
  81. package/bin/skills/lakehouse-doc/references/DataSourceConfigGuide.md +1 -0
  82. package/bin/skills/lakehouse-doc/references/DataSource_ADBMySQL.md +35 -0
  83. package/bin/skills/lakehouse-doc/references/DataSource_ADB_PostgreSQL.md +36 -0
  84. package/bin/skills/lakehouse-doc/references/DataSource_AMQP.md +37 -0
  85. package/bin/skills/lakehouse-doc/references/DataSource_Amazon_DocumentDB.md +115 -0
  86. package/bin/skills/lakehouse-doc/references/DataSource_Amazon_OpenSearch.md +42 -0
  87. package/bin/skills/lakehouse-doc/references/DataSource_Aurora_MySQL.md +35 -0
  88. package/bin/skills/lakehouse-doc/references/DataSource_Aurora_PostgreSQL.md +36 -0
  89. package/bin/skills/lakehouse-doc/references/DataSource_AutoMQ.md +124 -0
  90. package/bin/skills/lakehouse-doc/references/DataSource_COS.md +31 -0
  91. package/bin/skills/lakehouse-doc/references/DataSource_ClickHouse.md +36 -0
  92. package/bin/skills/lakehouse-doc/references/DataSource_DB2.md +36 -0
  93. package/bin/skills/lakehouse-doc/references/DataSource_DM.md +35 -0
  94. package/bin/skills/lakehouse-doc/references/DataSource_Databricks.md +38 -0
  95. package/bin/skills/lakehouse-doc/references/DataSource_Doris.md +34 -0
  96. package/bin/skills/lakehouse-doc/references/DataSource_DynamoDB.md +37 -0
  97. package/bin/skills/lakehouse-doc/references/DataSource_ElasticSearch.md +30 -0
  98. package/bin/skills/lakehouse-doc/references/DataSource_Greenplum.md +36 -0
  99. package/bin/skills/lakehouse-doc/references/DataSource_HANA.md +53 -0
  100. package/bin/skills/lakehouse-doc/references/DataSource_HBase.md +29 -0
  101. package/bin/skills/lakehouse-doc/references/DataSource_Hive.md +52 -0
  102. package/bin/skills/lakehouse-doc/references/DataSource_Hologres.md +36 -0
  103. package/bin/skills/lakehouse-doc/references/DataSource_Kafka.md +32 -0
  104. package/bin/skills/lakehouse-doc/references/DataSource_MariaDB.md +36 -0
  105. package/bin/skills/lakehouse-doc/references/DataSource_MaxCompute.md +32 -0
  106. package/bin/skills/lakehouse-doc/references/DataSource_MongoDB.md +36 -0
  107. package/bin/skills/lakehouse-doc/references/DataSource_MySQL.md +36 -0
  108. package/bin/skills/lakehouse-doc/references/DataSource_OSS.md +31 -0
  109. package/bin/skills/lakehouse-doc/references/DataSource_Oracle.md +35 -0
  110. package/bin/skills/lakehouse-doc/references/DataSource_PorarDB.md +37 -0
  111. package/bin/skills/lakehouse-doc/references/DataSource_PostgreSQL.md +36 -0
  112. package/bin/skills/lakehouse-doc/references/DataSource_Redis.md +55 -0
  113. package/bin/skills/lakehouse-doc/references/DataSource_Redshift.md +49 -0
  114. package/bin/skills/lakehouse-doc/references/DataSource_RestApi.md +30 -0
  115. package/bin/skills/lakehouse-doc/references/DataSource_S3.md +25 -0
  116. package/bin/skills/lakehouse-doc/references/DataSource_SLS.md +31 -0
  117. package/bin/skills/lakehouse-doc/references/DataSource_StarRocks.md +35 -0
  118. package/bin/skills/lakehouse-doc/references/DataSource_TiDB.md +36 -0
  119. package/bin/skills/lakehouse-doc/references/Datalake_StorageConnection.md +12 -0
  120. package/bin/skills/lakehouse-doc/references/Datasource_SQLServer.md +36 -0
  121. package/bin/skills/lakehouse-doc/references/Datus_Lakehouse_Integrated_Guide.md +3 -0
  122. package/bin/skills/lakehouse-doc/references/Datus_Lakehouse_MCPServer.md +111 -0
  123. package/bin/skills/lakehouse-doc/references/Dify_Integreated_with_LakehouseMCPServer.md +71 -0
  124. package/bin/skills/lakehouse-doc/references/ELTModernDataStack.md +497 -0
  125. package/bin/skills/lakehouse-doc/references/ELT_practice.md +1 -0
  126. package/bin/skills/lakehouse-doc/references/EXPLAIN.md +92 -0
  127. package/bin/skills/lakehouse-doc/references/EXTERNALFUNCITON.md +1 -0
  128. package/bin/skills/lakehouse-doc/references/EXTERNALFUNCTION.md +0 -0
  129. package/bin/skills/lakehouse-doc/references/EXTERNALFUNCTION/345/274/200/345/217/221/346/214/207/345/215/227.md +142 -0
  130. package/bin/skills/lakehouse-doc/references/EXTERNALSCHEMA.md +1 -0
  131. package/bin/skills/lakehouse-doc/references/EXTERNALSCHMEA.md +94 -0
  132. package/bin/skills/lakehouse-doc/references/ExternalFunctionDevGuideJava.md +556 -0
  133. package/bin/skills/lakehouse-doc/references/FLOAT.md +33 -0
  134. package/bin/skills/lakehouse-doc/references/FeatureEngineeringForExpandingCustomerFeatureswithZettapark.md +427 -0
  135. package/bin/skills/lakehouse-doc/references/FileCommand.md +1 -0
  136. package/bin/skills/lakehouse-doc/references/FileFunction.md +1 -0
  137. package/bin/skills/lakehouse-doc/references/FineBI.md +195 -0
  138. package/bin/skills/lakehouse-doc/references/Full_Text_Search.md +1 -0
  139. package/bin/skills/lakehouse-doc/references/GET.md +63 -0
  140. package/bin/skills/lakehouse-doc/references/GET_PRESIGNED_URL.md +91 -0
  141. package/bin/skills/lakehouse-doc/references/GrantPriveleges.md +113 -0
  142. package/bin/skills/lakehouse-doc/references/Hive_connection.md +50 -0
  143. package/bin/skills/lakehouse-doc/references/IDENTITY-Column.md +74 -0
  144. package/bin/skills/lakehouse-doc/references/INSERT.md +186 -0
  145. package/bin/skills/lakehouse-doc/references/INT.md +36 -0
  146. package/bin/skills/lakehouse-doc/references/INTERVAL.md +143 -0
  147. package/bin/skills/lakehouse-doc/references/Ingesting_Data_from_Alibaba_Cloud_Data_Lake_into_Lakehouse.md +976 -0
  148. package/bin/skills/lakehouse-doc/references/Ingestion.md +1 -0
  149. package/bin/skills/lakehouse-doc/references/JDBC-Driver.md +67 -0
  150. package/bin/skills/lakehouse-doc/references/JDBC_MindsDB_ML_LLM.md +237 -0
  151. package/bin/skills/lakehouse-doc/references/JOIN.md +204 -0
  152. package/bin/skills/lakehouse-doc/references/JSON.md +423 -0
  153. package/bin/skills/lakehouse-doc/references/JSON_DataType.md +49 -0
  154. package/bin/skills/lakehouse-doc/references/KAFKA_Storage_connection.md +1 -0
  155. package/bin/skills/lakehouse-doc/references/Kafka_connection.md +36 -0
  156. package/bin/skills/lakehouse-doc/references/Key_Concepts.md +112 -0
  157. package/bin/skills/lakehouse-doc/references/LATERALVIEW.md +78 -0
  158. package/bin/skills/lakehouse-doc/references/Lakehouse-client-repository.md +11 -0
  159. package/bin/skills/lakehouse-doc/references/LakehouseAI.md +0 -0
  160. package/bin/skills/lakehouse-doc/references/LakehouseAI_overview.md +16 -0
  161. package/bin/skills/lakehouse-doc/references/LakehouseAI/346/246/202/350/277/260.md +0 -0
  162. package/bin/skills/lakehouse-doc/references/LakehouseDataGPTTour.md +64 -0
  163. package/bin/skills/lakehouse-doc/references/LakehouseMCPServer.md +1 -0
  164. package/bin/skills/lakehouse-doc/references/LakehouseMCPServer_intro.md +493 -0
  165. package/bin/skills/lakehouse-doc/references/LakehousePythonZettapark.md +1 -0
  166. package/bin/skills/lakehouse-doc/references/LakehouseStudioTour.md +185 -0
  167. package/bin/skills/lakehouse-doc/references/Lakehouse_Index_Best_Practice.md +681 -0
  168. package/bin/skills/lakehouse-doc/references/Lakehouse_Insight.md +104 -0
  169. package/bin/skills/lakehouse-doc/references/Lakehouse_Platform_Release_Note.md +1 -0
  170. package/bin/skills/lakehouse-doc/references/Lakehouse_Studio_101.md +1 -0
  171. package/bin/skills/lakehouse-doc/references/Lakehouse_Studio_Release_Note.md +1 -0
  172. package/bin/skills/lakehouse-doc/references/Lakehouse_Zilliz_MakeDataReadyforBIandAI.md +228 -0
  173. package/bin/skills/lakehouse-doc/references/Langchain_plug_installation.md +244 -0
  174. package/bin/skills/lakehouse-doc/references/Langchain_plug_quick_start.md +225 -0
  175. package/bin/skills/lakehouse-doc/references/Langchain_plugins_overview.md +406 -0
  176. package/bin/skills/lakehouse-doc/references/Limitation.md +8 -0
  177. package/bin/skills/lakehouse-doc/references/LoggingIn.md +67 -0
  178. package/bin/skills/lakehouse-doc/references/Logstash.md +172 -0
  179. package/bin/skills/lakehouse-doc/references/MAP.md +42 -0
  180. package/bin/skills/lakehouse-doc/references/MATERIALIZEDVIEW.md +112 -0
  181. package/bin/skills/lakehouse-doc/references/MCPServers.md +267 -0
  182. package/bin/skills/lakehouse-doc/references/MERGE.md +498 -0
  183. package/bin/skills/lakehouse-doc/references/ManageAccounts.md +184 -0
  184. package/bin/skills/lakehouse-doc/references/ManagingFilesonDatalakeVolumewithZettapark.md +145 -0
  185. package/bin/skills/lakehouse-doc/references/MigrateSnowflakeRealtimeETLPipelinetoClickzettaLakehouse.md +865 -0
  186. package/bin/skills/lakehouse-doc/references/Migrate_Spark_DataEngineeringBestPractices_Project_to_Lakehouse.md +292 -0
  187. package/bin/skills/lakehouse-doc/references/ModernDataStackWithEcosystemTools.md +1 -0
  188. package/bin/skills/lakehouse-doc/references/N8N_AI_Workflow_Integration.md +1 -0
  189. package/bin/skills/lakehouse-doc/references/N8N_Integrated_with_LakehouseMCPServer.md +128 -0
  190. package/bin/skills/lakehouse-doc/references/Notebook.md +109 -0
  191. package/bin/skills/lakehouse-doc/references/NotesandGuidelinesforUsingPartitionTables.md +1627 -0
  192. package/bin/skills/lakehouse-doc/references/OPTIMIZE.md +80 -0
  193. package/bin/skills/lakehouse-doc/references/OptimizingComputingResources.md +1 -0
  194. package/bin/skills/lakehouse-doc/references/Overview.md +1 -0
  195. package/bin/skills/lakehouse-doc/references/PUT.md +70 -0
  196. package/bin/skills/lakehouse-doc/references/PerformingVectorandScalarRetrievalinheSameTableinLakehouse.md +84 -0
  197. package/bin/skills/lakehouse-doc/references/Permission_application.md +43 -0
  198. package/bin/skills/lakehouse-doc/references/PowerBI.md +113 -0
  199. package/bin/skills/lakehouse-doc/references/PythonSDKVersionHistory.md +24 -0
  200. package/bin/skills/lakehouse-doc/references/PythonSample_put_gharchive2oss.md +153 -0
  201. package/bin/skills/lakehouse-doc/references/PythonSample_put_github_rt_events.md +336 -0
  202. package/bin/skills/lakehouse-doc/references/PythonSqlAlchemyVersionHistory.md +23 -0
  203. package/bin/skills/lakehouse-doc/references/PythonTaskDev.md +1 -0
  204. package/bin/skills/lakehouse-doc/references/Python_Task.md +28 -0
  205. package/bin/skills/lakehouse-doc/references/Query_SnowflakeOpenCatalog_Icebergtable.md +114 -0
  206. package/bin/skills/lakehouse-doc/references/QuickStartwithCopycommand.md +79 -0
  207. package/bin/skills/lakehouse-doc/references/README.md +1 -0
  208. package/bin/skills/lakehouse-doc/references/REFRESH.md +37 -0
  209. package/bin/skills/lakehouse-doc/references/REMOTEFUNCTION.md +1 -0
  210. package/bin/skills/lakehouse-doc/references/RN_2023-08-07.md +67 -0
  211. package/bin/skills/lakehouse-doc/references/RN_2023-09-05.md +75 -0
  212. package/bin/skills/lakehouse-doc/references/RN_2023-09-18.md +50 -0
  213. package/bin/skills/lakehouse-doc/references/RN_2023-09-20.md +55 -0
  214. package/bin/skills/lakehouse-doc/references/RN_2023-10-25.md +102 -0
  215. package/bin/skills/lakehouse-doc/references/RN_2023-11-09.md +84 -0
  216. package/bin/skills/lakehouse-doc/references/RN_2023-12-25.md +84 -0
  217. package/bin/skills/lakehouse-doc/references/RN_2024-01-05.md +78 -0
  218. package/bin/skills/lakehouse-doc/references/RN_2024-02-05.md +87 -0
  219. package/bin/skills/lakehouse-doc/references/RN_2024-03-22.md +76 -0
  220. package/bin/skills/lakehouse-doc/references/RN_2024-04-10.md +61 -0
  221. package/bin/skills/lakehouse-doc/references/RN_2024-04-16.md +38 -0
  222. package/bin/skills/lakehouse-doc/references/RN_2024-05-10.md +47 -0
  223. package/bin/skills/lakehouse-doc/references/RN_2024-05-15.md +43 -0
  224. package/bin/skills/lakehouse-doc/references/RN_2024-05-24.md +143 -0
  225. package/bin/skills/lakehouse-doc/references/RN_2024-06-06.md +59 -0
  226. package/bin/skills/lakehouse-doc/references/RN_2024-06-07.md +71 -0
  227. package/bin/skills/lakehouse-doc/references/RN_2024-06-27.md +55 -0
  228. package/bin/skills/lakehouse-doc/references/RN_2024-07-22.md +121 -0
  229. package/bin/skills/lakehouse-doc/references/RN_2024-07-24.md +58 -0
  230. package/bin/skills/lakehouse-doc/references/RN_2024-08-07.md +42 -0
  231. package/bin/skills/lakehouse-doc/references/RN_2024-09-26.md +106 -0
  232. package/bin/skills/lakehouse-doc/references/RN_2024-10-15.md +49 -0
  233. package/bin/skills/lakehouse-doc/references/RN_2024_11_11.md +50 -0
  234. package/bin/skills/lakehouse-doc/references/RN_2024_12_12.md +52 -0
  235. package/bin/skills/lakehouse-doc/references/RN_2024_12_25.md +40 -0
  236. package/bin/skills/lakehouse-doc/references/RN_2025-03-05.md +68 -0
  237. package/bin/skills/lakehouse-doc/references/RN_2025-04-01.md +74 -0
  238. package/bin/skills/lakehouse-doc/references/RN_2025-05-20.md +90 -0
  239. package/bin/skills/lakehouse-doc/references/RN_2025-07-03.md +100 -0
  240. package/bin/skills/lakehouse-doc/references/RN_2025-08-25.md +106 -0
  241. package/bin/skills/lakehouse-doc/references/RN_2025_03_03.md +141 -0
  242. package/bin/skills/lakehouse-doc/references/RN_2025_04_22.md +110 -0
  243. package/bin/skills/lakehouse-doc/references/RN_2025_07_15.md +60 -0
  244. package/bin/skills/lakehouse-doc/references/RN_2025_10_23.md +85 -0
  245. package/bin/skills/lakehouse-doc/references/RN_2025_10_30.md +68 -0
  246. package/bin/skills/lakehouse-doc/references/RN_2025_12_17.md +71 -0
  247. package/bin/skills/lakehouse-doc/references/RN_2026_1_30-2.0.0.md +43 -0
  248. package/bin/skills/lakehouse-doc/references/RN_LH_2025_12_30.md +73 -0
  249. package/bin/skills/lakehouse-doc/references/RN_LH_2026_03_13.md +47 -0
  250. package/bin/skills/lakehouse-doc/references/Refactor_ELT_practice.md +241 -0
  251. package/bin/skills/lakehouse-doc/references/RemoteFunctionAsUDF.md +1 -0
  252. package/bin/skills/lakehouse-doc/references/RemoteFunctionBestPractice.md +350 -0
  253. package/bin/skills/lakehouse-doc/references/RemoteFunctionDevGuidePython3.md +571 -0
  254. package/bin/skills/lakehouse-doc/references/RemoteFunctionOnACR.md +249 -0
  255. package/bin/skills/lakehouse-doc/references/RemoteFunctionintro.md +54 -0
  256. package/bin/skills/lakehouse-doc/references/RemoteFunction/344/273/213/347/273/215.md +1 -0
  257. package/bin/skills/lakehouse-doc/references/RemoteFunction/345/274/200/345/217/221/346/214/207/345/215/227Python3.md +1 -0
  258. package/bin/skills/lakehouse-doc/references/RemoteFunction/346/234/200/344/275/263/345/256/236/350/267/265.md +1 -0
  259. package/bin/skills/lakehouse-doc/references/RevokePriveleges.md +98 -0
  260. package/bin/skills/lakehouse-doc/references/SCHEMA.md +48 -0
  261. package/bin/skills/lakehouse-doc/references/SCHEMADDL.md +0 -0
  262. package/bin/skills/lakehouse-doc/references/SHOW-INDEX.md +22 -0
  263. package/bin/skills/lakehouse-doc/references/SHOWCONNECTIONS.md +44 -0
  264. package/bin/skills/lakehouse-doc/references/SHOWFUNCTIONS.md +38 -0
  265. package/bin/skills/lakehouse-doc/references/SHOWGRANTS.md +62 -0
  266. package/bin/skills/lakehouse-doc/references/SHOWROLES.md +59 -0
  267. package/bin/skills/lakehouse-doc/references/SHOWTABLES.md +46 -0
  268. package/bin/skills/lakehouse-doc/references/SHOWUSERS.md +26 -0
  269. package/bin/skills/lakehouse-doc/references/SMALLINT.md +48 -0
  270. package/bin/skills/lakehouse-doc/references/SQL_CREATE_TABLE_GUIDE.md +1210 -0
  271. package/bin/skills/lakehouse-doc/references/SQL_DML_Considerations.md +601 -0
  272. package/bin/skills/lakehouse-doc/references/SQL_Join_Guide.md +655 -0
  273. package/bin/skills/lakehouse-doc/references/SQL_SELECT_Considerations.md +1818 -0
  274. package/bin/skills/lakehouse-doc/references/SQL_With_CTE_Guide.md +1510 -0
  275. package/bin/skills/lakehouse-doc/references/SQL_customers.md +74 -0
  276. package/bin/skills/lakehouse-doc/references/SQL_revenue.md +31 -0
  277. package/bin/skills/lakehouse-doc/references/STRING.md +80 -0
  278. package/bin/skills/lakehouse-doc/references/STRUCT.md +33 -0
  279. package/bin/skills/lakehouse-doc/references/SUMMARY.md +1279 -0
  280. package/bin/skills/lakehouse-doc/references/Security_system_inventory_and_optimization_based_Information_Schema.md +412 -0
  281. package/bin/skills/lakehouse-doc/references/Server_data_for_AI.md +15 -0
  282. package/bin/skills/lakehouse-doc/references/SlowlyChangingDimensionsInLakehouseUsingStreamsandTasks.md +616 -0
  283. package/bin/skills/lakehouse-doc/references/Spark_Lakehouse_iceberg_REST.md +151 -0
  284. package/bin/skills/lakehouse-doc/references/StudioDI_PrivateLinkVPC_fromRDS.md +105 -0
  285. package/bin/skills/lakehouse-doc/references/Supported_Cloud_Platforms.md +40 -0
  286. package/bin/skills/lakehouse-doc/references/TABLE.md +49 -0
  287. package/bin/skills/lakehouse-doc/references/TIMESTAMP.md +56 -0
  288. package/bin/skills/lakehouse-doc/references/TIMETRAVEL.md +207 -0
  289. package/bin/skills/lakehouse-doc/references/TINYINT.md +63 -0
  290. package/bin/skills/lakehouse-doc/references/TPC-H100G_experience.md +49 -0
  291. package/bin/skills/lakehouse-doc/references/TRUNCATE.md +144 -0
  292. package/bin/skills/lakehouse-doc/references/TableDesign.md +270 -0
  293. package/bin/skills/lakehouse-doc/references/TableauConnectToLakehouse.md +64 -0
  294. package/bin/skills/lakehouse-doc/references/Tutorials.md +1 -0
  295. package/bin/skills/lakehouse-doc/references/UNDROP-TABLE.md +163 -0
  296. package/bin/skills/lakehouse-doc/references/UPDATE.md +70 -0
  297. package/bin/skills/lakehouse-doc/references/USESCHEMA.md +53 -0
  298. package/bin/skills/lakehouse-doc/references/UnifiedWorkflowIntro.md +31 -0
  299. package/bin/skills/lakehouse-doc/references/UnifiedWorkflow_demo.md +175 -0
  300. package/bin/skills/lakehouse-doc/references/Unstructured_io.md +735 -0
  301. package/bin/skills/lakehouse-doc/references/VARCHARleghth.md +42 -0
  302. package/bin/skills/lakehouse-doc/references/VIEW.md +47 -0
  303. package/bin/skills/lakehouse-doc/references/Volume_LIST.md +52 -0
  304. package/bin/skills/lakehouse-doc/references/WINDOWFUNCTION.md +561 -0
  305. package/bin/skills/lakehouse-doc/references/WITH.md +41 -0
  306. package/bin/skills/lakehouse-doc/references/ZettaparkQuickStart.md +453 -0
  307. package/bin/skills/lakehouse-doc/references/Zettapark_Data_Engineering_Demo.md +348 -0
  308. package/bin/skills/lakehouse-doc/references/a_comprehensive_guide_to_ingesting_data_into_clickzetta_lakehouse.md +66 -0
  309. package/bin/skills/lakehouse-doc/references/access-control-configration.md +249 -0
  310. package/bin/skills/lakehouse-doc/references/access-control-general.md +82 -0
  311. package/bin/skills/lakehouse-doc/references/access-control.md +240 -0
  312. package/bin/skills/lakehouse-doc/references/account_user_management.md +105 -0
  313. package/bin/skills/lakehouse-doc/references/accountfunds.md +87 -0
  314. package/bin/skills/lakehouse-doc/references/agg_function.md +1 -0
  315. package/bin/skills/lakehouse-doc/references/ai_ready_data_overview.md +13 -0
  316. package/bin/skills/lakehouse-doc/references/airbyte.md +95 -0
  317. package/bin/skills/lakehouse-doc/references/alert.md +143 -0
  318. package/bin/skills/lakehouse-doc/references/alicloud-arn-externalid.md +51 -0
  319. package/bin/skills/lakehouse-doc/references/alicloud_byos_configration.md +129 -0
  320. package/bin/skills/lakehouse-doc/references/aliyun_storage_connection.md +135 -0
  321. package/bin/skills/lakehouse-doc/references/alter-dynamic-table.md +375 -0
  322. package/bin/skills/lakehouse-doc/references/alter-external-schema.md +20 -0
  323. package/bin/skills/lakehouse-doc/references/alter-materialzied-view.md +238 -0
  324. package/bin/skills/lakehouse-doc/references/alter-share.md +43 -0
  325. package/bin/skills/lakehouse-doc/references/alter-user.md +13 -0
  326. package/bin/skills/lakehouse-doc/references/alter-vcluster.md +134 -0
  327. package/bin/skills/lakehouse-doc/references/alter-worksapce.md +55 -0
  328. package/bin/skills/lakehouse-doc/references/alter.md +35 -0
  329. package/bin/skills/lakehouse-doc/references/analysis_internet_data_nyc_green_data.md +449 -0
  330. package/bin/skills/lakehouse-doc/references/analytics_cluster_best_practices.md +377 -0
  331. package/bin/skills/lakehouse-doc/references/analyze-table.md +58 -0
  332. package/bin/skills/lakehouse-doc/references/array_size.md +34 -0
  333. package/bin/skills/lakehouse-doc/references/authentication.md +53 -0
  334. package/bin/skills/lakehouse-doc/references/authoritymanagement.md +1 -0
  335. package/bin/skills/lakehouse-doc/references/auto-index.md +57 -0
  336. package/bin/skills/lakehouse-doc/references/aws_storage_connection.md +114 -0
  337. package/bin/skills/lakehouse-doc/references/backfilling_data.md +60 -0
  338. package/bin/skills/lakehouse-doc/references/batch_sync.md +54 -0
  339. package/bin/skills/lakehouse-doc/references/batch_sync_Sop.md +135 -0
  340. package/bin/skills/lakehouse-doc/references/batchloadparquertfileintoLakehouse.md +79 -0
  341. package/bin/skills/lakehouse-doc/references/bestpractice_bazhuanyu.md +1 -0
  342. package/bin/skills/lakehouse-doc/references/billing.md +62 -0
  343. package/bin/skills/lakehouse-doc/references/bitmap-type.md +524 -0
  344. package/bin/skills/lakehouse-doc/references/bitmap_uba_guide.md +1190 -0
  345. package/bin/skills/lakehouse-doc/references/bloomfilter-summary.md +164 -0
  346. package/bin/skills/lakehouse-doc/references/book.json +17 -0
  347. package/bin/skills/lakehouse-doc/references/bring_your_own_storage.md +1 -0
  348. package/bin/skills/lakehouse-doc/references/build-inverted-index.md +27 -0
  349. package/bin/skills/lakehouse-doc/references/build_rag_with_langchain.md +616 -0
  350. package/bin/skills/lakehouse-doc/references/bulkload-summary.md +37 -0
  351. package/bin/skills/lakehouse-doc/references/bulkloadv1-java-sdk.md +178 -0
  352. package/bin/skills/lakehouse-doc/references/bulkloadv1-python-sdk.md +169 -0
  353. package/bin/skills/lakehouse-doc/references/byos_general.md +165 -0
  354. package/bin/skills/lakehouse-doc/references/byos_tencentcloud_configration.md +138 -0
  355. package/bin/skills/lakehouse-doc/references/cache-command.md +39 -0
  356. package/bin/skills/lakehouse-doc/references/cancel-job.md +51 -0
  357. package/bin/skills/lakehouse-doc/references/cardinality_array.md +45 -0
  358. package/bin/skills/lakehouse-doc/references/charge_analysis_with_lakehouse_mcp_server.md +393 -0
  359. package/bin/skills/lakehouse-doc/references/clone-doc.md +111 -0
  360. package/bin/skills/lakehouse-doc/references/cloud_object_storage.md +1 -0
  361. package/bin/skills/lakehouse-doc/references/cluster-table-guide.md +68 -0
  362. package/bin/skills/lakehouse-doc/references/cluster-table.md +64 -0
  363. package/bin/skills/lakehouse-doc/references/composite_task.md +178 -0
  364. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_3rd_tools.md +11 -0
  365. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_dbv_sql_put.md +48 -0
  366. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_environment_and_data_generate.md +627 -0
  367. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_javasdk_buckload_realtime.md +740 -0
  368. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_kafka_realtime_sync.md +71 -0
  369. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_local_file_into_table_by_studio.md +64 -0
  370. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_overview.md +66 -0
  371. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_pipe_kafka.md +7 -0
  372. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_pipe_oss.md +7 -0
  373. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_studio_batchload_public_network.md +52 -0
  374. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_studio_python_node.md +111 -0
  375. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_studio_realtime_cdc_public_network.md +249 -0
  376. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_studio_sql_insert.md +180 -0
  377. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_zettapark_put_file_to_lake.md +206 -0
  378. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_zettapark_save_as_table.md +79 -0
  379. package/bin/skills/lakehouse-doc/references/comprehensive_guide_to_ingesting_zettapark_sql_insert.md +113 -0
  380. package/bin/skills/lakehouse-doc/references/computation.md +6 -0
  381. package/bin/skills/lakehouse-doc/references/concurrency_scaling.md +57 -0
  382. package/bin/skills/lakehouse-doc/references/config-datasource.md +79 -0
  383. package/bin/skills/lakehouse-doc/references/config_volume_dify_storage.md +254 -0
  384. package/bin/skills/lakehouse-doc/references/connect-with-cli.md +155 -0
  385. package/bin/skills/lakehouse-doc/references/connect_to_Lakehouse.md +1 -0
  386. package/bin/skills/lakehouse-doc/references/connection-guide.md +61 -0
  387. package/bin/skills/lakehouse-doc/references/continue-job.md +260 -0
  388. package/bin/skills/lakehouse-doc/references/conversational_analytics_datagpt.md +1 -0
  389. package/bin/skills/lakehouse-doc/references/copy-into-table.md +398 -0
  390. package/bin/skills/lakehouse-doc/references/cos_storage_connection.md +73 -0
  391. package/bin/skills/lakehouse-doc/references/cos_volume_creation.md +39 -0
  392. package/bin/skills/lakehouse-doc/references/cost_management.md +1 -0
  393. package/bin/skills/lakehouse-doc/references/create-api-connection.md +363 -0
  394. package/bin/skills/lakehouse-doc/references/create-catalog-connection.md +220 -0
  395. package/bin/skills/lakehouse-doc/references/create-dynamic-table.md +910 -0
  396. package/bin/skills/lakehouse-doc/references/create-external-catalog.md +305 -0
  397. package/bin/skills/lakehouse-doc/references/create-external-table.md +78 -0
  398. package/bin/skills/lakehouse-doc/references/create-hive-catalog.md +77 -0
  399. package/bin/skills/lakehouse-doc/references/create-inverted-index.md +163 -0
  400. package/bin/skills/lakehouse-doc/references/create-kafka-external.md +300 -0
  401. package/bin/skills/lakehouse-doc/references/create-schema-from-share.md +45 -0
  402. package/bin/skills/lakehouse-doc/references/create-share.md +46 -0
  403. package/bin/skills/lakehouse-doc/references/create-sql-function.md +120 -0
  404. package/bin/skills/lakehouse-doc/references/create-storage-connection.md +346 -0
  405. package/bin/skills/lakehouse-doc/references/create-synonym.md +75 -0
  406. package/bin/skills/lakehouse-doc/references/create-table-ddl.md +405 -0
  407. package/bin/skills/lakehouse-doc/references/create-table-stream.md +226 -0
  408. package/bin/skills/lakehouse-doc/references/create-vector-index.md +115 -0
  409. package/bin/skills/lakehouse-doc/references/create.md +46 -0
  410. package/bin/skills/lakehouse-doc/references/create_cluster.md +121 -0
  411. package/bin/skills/lakehouse-doc/references/creating_alicloud_privatelinkendpoint.md +37 -0
  412. package/bin/skills/lakehouse-doc/references/creating_alicloud_privatelinkservice.md +31 -0
  413. package/bin/skills/lakehouse-doc/references/creating_tencentcloud_privatelinkendpoint.md +33 -0
  414. package/bin/skills/lakehouse-doc/references/creating_tencentcloud_privatelinkservice.md +19 -0
  415. package/bin/skills/lakehouse-doc/references/czguide-intro-to-cdc-using-clickzetta-rtsync-dynamic-tables.md +717 -0
  416. package/bin/skills/lakehouse-doc/references/data-catalog.md +1 -0
  417. package/bin/skills/lakehouse-doc/references/data-integration-intro.md +60 -0
  418. package/bin/skills/lakehouse-doc/references/data-integration.md +10 -0
  419. package/bin/skills/lakehouse-doc/references/data-lifecycle.md +46 -0
  420. package/bin/skills/lakehouse-doc/references/data-load-summary.md +71 -0
  421. package/bin/skills/lakehouse-doc/references/data-mamager-tool.md +1 -0
  422. package/bin/skills/lakehouse-doc/references/data-recover.md +52 -0
  423. package/bin/skills/lakehouse-doc/references/data-type.md +1 -0
  424. package/bin/skills/lakehouse-doc/references/data-types-timestamp-ntz.md +139 -0
  425. package/bin/skills/lakehouse-doc/references/data.md +1 -0
  426. package/bin/skills/lakehouse-doc/references/data_catalog.md +106 -0
  427. package/bin/skills/lakehouse-doc/references/data_clean_with_sql.md +406 -0
  428. package/bin/skills/lakehouse-doc/references/data_ecosystem.md +1 -0
  429. package/bin/skills/lakehouse-doc/references/data_ops.md +7 -0
  430. package/bin/skills/lakehouse-doc/references/data_org.md +1 -0
  431. package/bin/skills/lakehouse-doc/references/data_privacy.md +50 -0
  432. package/bin/skills/lakehouse-doc/references/data_result_profile.md +22 -0
  433. package/bin/skills/lakehouse-doc/references/data_security.md +1 -0
  434. package/bin/skills/lakehouse-doc/references/data_sharing_between_accounts_guide.md +331 -0
  435. package/bin/skills/lakehouse-doc/references/data_transfer_datalake.md +1 -0
  436. package/bin/skills/lakehouse-doc/references/data_visualization.md +96 -0
  437. package/bin/skills/lakehouse-doc/references/databricks_yunqi_integration_guide_v2.md +811 -0
  438. package/bin/skills/lakehouse-doc/references/datagpt_bestpractice.md +1 -0
  439. package/bin/skills/lakehouse-doc/references/datagpt_data_source.md +58 -0
  440. package/bin/skills/lakehouse-doc/references/datagpt_get_accurate_answers.md +34 -0
  441. package/bin/skills/lakehouse-doc/references/datagpt_intro.md +1 -0
  442. package/bin/skills/lakehouse-doc/references/datagpt_quickstart.md +94 -0
  443. package/bin/skills/lakehouse-doc/references/datagpt_tutorial.md +1 -0
  444. package/bin/skills/lakehouse-doc/references/datalake_FAQ.md +54 -0
  445. package/bin/skills/lakehouse-doc/references/datalake_overview.md +17 -0
  446. package/bin/skills/lakehouse-doc/references/datalake_privilege.md +55 -0
  447. package/bin/skills/lakehouse-doc/references/datalake_query_ingest.md +18 -0
  448. package/bin/skills/lakehouse-doc/references/datalake_unstructure_data.md +3 -0
  449. package/bin/skills/lakehouse-doc/references/datalake_volume.md +92 -0
  450. package/bin/skills/lakehouse-doc/references/datalake_volume_anlytics.md +1 -0
  451. package/bin/skills/lakehouse-doc/references/datalake_volume_object.md +1 -0
  452. package/bin/skills/lakehouse-doc/references/dataops_practice.md +105 -0
  453. package/bin/skills/lakehouse-doc/references/datasharing.md +322 -0
  454. package/bin/skills/lakehouse-doc/references/datasharing_catalog.md +1 -0
  455. package/bin/skills/lakehouse-doc/references/datasource_ip_whitelist.md +93 -0
  456. package/bin/skills/lakehouse-doc/references/datasources.md +62 -0
  457. package/bin/skills/lakehouse-doc/references/datatype-cast.md +105 -0
  458. package/bin/skills/lakehouse-doc/references/datatype-conversion.md +85 -0
  459. package/bin/skills/lakehouse-doc/references/datetime_patterns.md +61 -0
  460. package/bin/skills/lakehouse-doc/references/datus_lakehouse_installation.md +376 -0
  461. package/bin/skills/lakehouse-doc/references/datus_lakehouse_solution_overview.md +148 -0
  462. package/bin/skills/lakehouse-doc/references/db_dw_connection.md +1 -0
  463. package/bin/skills/lakehouse-doc/references/default-value.md +89 -0
  464. package/bin/skills/lakehouse-doc/references/delta-lake.md +185 -0
  465. package/bin/skills/lakehouse-doc/references/desc-catalog-table.md +33 -0
  466. package/bin/skills/lakehouse-doc/references/desc-catalog.md +31 -0
  467. package/bin/skills/lakehouse-doc/references/desc-dynamic-table.md +62 -0
  468. package/bin/skills/lakehouse-doc/references/desc-external-schemas.md +66 -0
  469. package/bin/skills/lakehouse-doc/references/desc-external-table.md +70 -0
  470. package/bin/skills/lakehouse-doc/references/desc-function.md +16 -0
  471. package/bin/skills/lakehouse-doc/references/desc-history-dynamic-table.md +50 -0
  472. package/bin/skills/lakehouse-doc/references/desc-history-table.md +73 -0
  473. package/bin/skills/lakehouse-doc/references/desc-history.md +73 -0
  474. package/bin/skills/lakehouse-doc/references/desc-share.md +59 -0
  475. package/bin/skills/lakehouse-doc/references/desc-table-stream.md +44 -0
  476. package/bin/skills/lakehouse-doc/references/desc-vcluster.md +42 -0
  477. package/bin/skills/lakehouse-doc/references/describe.md +38 -0
  478. package/bin/skills/lakehouse-doc/references/dify_config_lakehouse_as_vectordb.md +286 -0
  479. package/bin/skills/lakehouse-doc/references/dify_yunqilakehouse_integration_overview.md +188 -0
  480. package/bin/skills/lakehouse-doc/references/discovery_analysis_data_in_json_file_on_external_volume.md +625 -0
  481. package/bin/skills/lakehouse-doc/references/discovery_analysis_data_in_parquert_file_on_external_volume.md +599 -0
  482. package/bin/skills/lakehouse-doc/references/download-data.md +1 -0
  483. package/bin/skills/lakehouse-doc/references/drop-dynamic-table.md +46 -0
  484. package/bin/skills/lakehouse-doc/references/drop-external-schema.md +44 -0
  485. package/bin/skills/lakehouse-doc/references/drop-external-table.md +43 -0
  486. package/bin/skills/lakehouse-doc/references/drop-function.md +36 -0
  487. package/bin/skills/lakehouse-doc/references/drop-share.md +43 -0
  488. package/bin/skills/lakehouse-doc/references/drop-synonym.md +35 -0
  489. package/bin/skills/lakehouse-doc/references/drop-table-stream.md +42 -0
  490. package/bin/skills/lakehouse-doc/references/drop-vcluster.md +52 -0
  491. package/bin/skills/lakehouse-doc/references/drop.md +32 -0
  492. package/bin/skills/lakehouse-doc/references/dynamic-mask.md +201 -0
  493. package/bin/skills/lakehouse-doc/references/dynamic-table-incre.md +62 -0
  494. package/bin/skills/lakehouse-doc/references/dynamic-table-introduce.md +339 -0
  495. package/bin/skills/lakehouse-doc/references/dynamicTable-DML-sql.md +52 -0
  496. package/bin/skills/lakehouse-doc/references/dynamicTable-dml.md +48 -0
  497. package/bin/skills/lakehouse-doc/references/dynamicTable-parmaters.md +425 -0
  498. package/bin/skills/lakehouse-doc/references/dynamic_table_summary.md +366 -0
  499. package/bin/skills/lakehouse-doc/references/dynamic_table_task.md +73 -0
  500. package/bin/skills/lakehouse-doc/references/dynamic_table_using_studio.md +159 -0
  501. package/bin/skills/lakehouse-doc/references/dynamictable.md +56 -0
  502. package/bin/skills/lakehouse-doc/references/eco_integration/Zeppelin.md +84 -0
  503. package/bin/skills/lakehouse-doc/references/eco_integration/airbyte.md +75 -0
  504. package/bin/skills/lakehouse-doc/references/eco_integration/datagrip-lakehouse.md +56 -0
  505. package/bin/skills/lakehouse-doc/references/eco_integration/datax.md +154 -0
  506. package/bin/skills/lakehouse-doc/references/eco_integration/dbeaver-lakehouse.md +67 -0
  507. package/bin/skills/lakehouse-doc/references/eco_integration/dbt.md +139 -0
  508. package/bin/skills/lakehouse-doc/references/eco_integration/rath.md +87 -0
  509. package/bin/skills/lakehouse-doc/references/eco_integration/sqlline.md +82 -0
  510. package/bin/skills/lakehouse-doc/references/eco_integration/sqlworkbench-j-lakehouse.md +54 -0
  511. package/bin/skills/lakehouse-doc/references/eco_integration/streamlit.md +117 -0
  512. package/bin/skills/lakehouse-doc/references/eco_integration/superset.md +109 -0
  513. package/bin/skills/lakehouse-doc/references/eco_integration/trino.md +75 -0
  514. package/bin/skills/lakehouse-doc/references/ecosystem-all.md +24 -0
  515. package/bin/skills/lakehouse-doc/references/export_data_with_data-integration.md +3 -0
  516. package/bin/skills/lakehouse-doc/references/external-Volume.md +10 -0
  517. package/bin/skills/lakehouse-doc/references/external-catalog-summary.md +42 -0
  518. package/bin/skills/lakehouse-doc/references/external-function-summary.md +0 -0
  519. package/bin/skills/lakehouse-doc/references/external-hudi-table.md +187 -0
  520. package/bin/skills/lakehouse-doc/references/external-table-guide.md +96 -0
  521. package/bin/skills/lakehouse-doc/references/external_object_user_guide.md +298 -0
  522. package/bin/skills/lakehouse-doc/references/external_volume.md +1 -0
  523. package/bin/skills/lakehouse-doc/references/f6fc6447ee.md +151 -0
  524. package/bin/skills/lakehouse-doc/references/federation-query.md +1 -0
  525. package/bin/skills/lakehouse-doc/references/finebi-mysql.md +104 -0
  526. package/bin/skills/lakehouse-doc/references/flink-write-connector.md +695 -0
  527. package/bin/skills/lakehouse-doc/references/from_lakehouse_to_volume.md +98 -0
  528. package/bin/skills/lakehouse-doc/references/from_volume_to_table.md +45 -0
  529. package/bin/skills/lakehouse-doc/references/fulltext_indexes_guide.md +1180 -0
  530. package/bin/skills/lakehouse-doc/references/generated-column.md +113 -0
  531. package/bin/skills/lakehouse-doc/references/generated_columns_guide.md +847 -0
  532. package/bin/skills/lakehouse-doc/references/geospatial_analysis.md +558 -0
  533. package/bin/skills/lakehouse-doc/references/get-started-with-sample-data.md +83 -0
  534. package/bin/skills/lakehouse-doc/references/getting_started_with_vcluster_for_processing_analytics.md +471 -0
  535. package/bin/skills/lakehouse-doc/references/grant-to-share.md +55 -0
  536. package/bin/skills/lakehouse-doc/references/grant-user-privileges.md +100 -0
  537. package/bin/skills/lakehouse-doc/references/groupby.md +1260 -0
  538. package/bin/skills/lakehouse-doc/references/guides-overview-connecting.md +46 -0
  539. package/bin/skills/lakehouse-doc/references/ide.md +2 -0
  540. package/bin/skills/lakehouse-doc/references/ifnull.md +72 -0
  541. package/bin/skills/lakehouse-doc/references/ilike.md +89 -0
  542. package/bin/skills/lakehouse-doc/references/import_data_with_data-integration.md +3 -0
  543. package/bin/skills/lakehouse-doc/references/importdatabypythonintoLakehouse.md +134 -0
  544. package/bin/skills/lakehouse-doc/references/index2.md +1 -0
  545. package/bin/skills/lakehouse-doc/references/instance-informaiton-schema-summary.md +51 -0
  546. package/bin/skills/lakehouse-doc/references/instance-informaiton-schema.md +278 -0
  547. package/bin/skills/lakehouse-doc/references/instance-information_schema.md +1 -0
  548. package/bin/skills/lakehouse-doc/references/internal_volume.md +271 -0
  549. package/bin/skills/lakehouse-doc/references/intro-supported-features.md +48 -0
  550. package/bin/skills/lakehouse-doc/references/inverted-index.md +445 -0
  551. package/bin/skills/lakehouse-doc/references/inverted_idx_bm25_param.md +251 -0
  552. package/bin/skills/lakehouse-doc/references/inverted_idx_multi-match.md +89 -0
  553. package/bin/skills/lakehouse-doc/references/is-null.md +59 -0
  554. package/bin/skills/lakehouse-doc/references/it-operation-management.md +1 -0
  555. package/bin/skills/lakehouse-doc/references/java_reference/client.md +49 -0
  556. package/bin/skills/lakehouse-doc/references/java_reference/java-sdk-release-notes.md +32 -0
  557. package/bin/skills/lakehouse-doc/references/java_reference/java-sdk-summary.md +138 -0
  558. package/bin/skills/lakehouse-doc/references/java_reference/jdbc.md +211 -0
  559. package/bin/skills/lakehouse-doc/references/java_reference/realtime-upload.md +295 -0
  560. package/bin/skills/lakehouse-doc/references/jdbc_task.md +37 -0
  561. package/bin/skills/lakehouse-doc/references/job-manage.md +1 -0
  562. package/bin/skills/lakehouse-doc/references/job_history_analysis_with_information_schema.md +597 -0
  563. package/bin/skills/lakehouse-doc/references/jobprofile-bestpractices.md +104 -0
  564. package/bin/skills/lakehouse-doc/references/json_analyze.md +422 -0
  565. package/bin/skills/lakehouse-doc/references/json_data_process_guide.md +881 -0
  566. package/bin/skills/lakehouse-doc/references/json_guide_for_complex_biz_cases.md +1899 -0
  567. package/bin/skills/lakehouse-doc/references/kafka-external-table.md +103 -0
  568. package/bin/skills/lakehouse-doc/references/lakehouse-ai.md +1 -0
  569. package/bin/skills/lakehouse-doc/references/lakehouse-quick-experience_guide.md +964 -0
  570. package/bin/skills/lakehouse-doc/references/lakehouse-table-stream-best-practices.md +500 -0
  571. package/bin/skills/lakehouse-doc/references/lakehouse_billing_anomaly_alert_configuration_guide.md +226 -0
  572. package/bin/skills/lakehouse-doc/references/lakehouse_instance_overview.md +39 -0
  573. package/bin/skills/lakehouse-doc/references/lakehouse_table_design_guide.md +2676 -0
  574. package/bin/skills/lakehouse-doc/references/langchain.md +71 -0
  575. package/bin/skills/lakehouse-doc/references/langchain_basic_samples.md +606 -0
  576. package/bin/skills/lakehouse-doc/references/langchain_integration.md +1 -0
  577. package/bin/skills/lakehouse-doc/references/left.md +51 -0
  578. package/bin/skills/lakehouse-doc/references/like.md +115 -0
  579. package/bin/skills/lakehouse-doc/references/list-partition.md +121 -0
  580. package/bin/skills/lakehouse-doc/references/llama-index.md +57 -0
  581. package/bin/skills/lakehouse-doc/references/llms-full.txt +1286 -0
  582. package/bin/skills/lakehouse-doc/references/llms.txt +71 -0
  583. package/bin/skills/lakehouse-doc/references/load-data-local.md +82 -0
  584. package/bin/skills/lakehouse-doc/references/load-data-oss.md +174 -0
  585. package/bin/skills/lakehouse-doc/references/management.md +5 -0
  586. package/bin/skills/lakehouse-doc/references/managing-instance.md +67 -0
  587. package/bin/skills/lakehouse-doc/references/mapjoin.md +62 -0
  588. package/bin/skills/lakehouse-doc/references/materialized_ddl.md +1 -0
  589. package/bin/skills/lakehouse-doc/references/meta-objects-and-privileges.md +271 -0
  590. package/bin/skills/lakehouse-doc/references/metabase.md +73 -0
  591. package/bin/skills/lakehouse-doc/references/metadata_show_desc_command_guide.md +711 -0
  592. package/bin/skills/lakehouse-doc/references/metrics_answer_build.md +46 -0
  593. package/bin/skills/lakehouse-doc/references/mindsdb.md +269 -0
  594. package/bin/skills/lakehouse-doc/references/monitoring_and_alerting.md +177 -0
  595. package/bin/skills/lakehouse-doc/references/monitoring_item_specification.md +44 -0
  596. package/bin/skills/lakehouse-doc/references/multi_cloud_instance_manage_with_mcp_server.md +281 -0
  597. package/bin/skills/lakehouse-doc/references/multitable_batch_sync.md +463 -0
  598. package/bin/skills/lakehouse-doc/references/multitable_realtime_sync.md +412 -0
  599. package/bin/skills/lakehouse-doc/references/multitable_realtime_sync_sop.md +593 -0
  600. package/bin/skills/lakehouse-doc/references/n8n_Integreated_with_lakehouse_mcp_server.md +494 -0
  601. package/bin/skills/lakehouse-doc/references/navicat-mysql.md +65 -0
  602. package/bin/skills/lakehouse-doc/references/network_policy.md +281 -0
  603. package/bin/skills/lakehouse-doc/references/nyc_green_taxi_data_clean_transform_with_mcp_server.md +315 -0
  604. package/bin/skills/lakehouse-doc/references/object-model-overview.md +70 -0
  605. package/bin/skills/lakehouse-doc/references/object_identifier.md +259 -0
  606. package/bin/skills/lakehouse-doc/references/object_model_design.md +1 -0
  607. package/bin/skills/lakehouse-doc/references/opensource/travel.md +134 -0
  608. package/bin/skills/lakehouse-doc/references/operation-maintenance.md +172 -0
  609. package/bin/skills/lakehouse-doc/references/oss_volume_creation.md +39 -0
  610. package/bin/skills/lakehouse-doc/references/partition_table.md +344 -0
  611. package/bin/skills/lakehouse-doc/references/partition_table_guide.md +340 -0
  612. package/bin/skills/lakehouse-doc/references/performance_optimization.md +1 -0
  613. package/bin/skills/lakehouse-doc/references/performence_test.md +1 -0
  614. package/bin/skills/lakehouse-doc/references/permissions-of-built-in-workspace-level-roles.md +131 -0
  615. package/bin/skills/lakehouse-doc/references/pipe-kafka-bestpractice-1.md +431 -0
  616. package/bin/skills/lakehouse-doc/references/pipe-kafka-table-stream.md +180 -0
  617. package/bin/skills/lakehouse-doc/references/pipe-kafka.md +210 -0
  618. package/bin/skills/lakehouse-doc/references/pipe-storage-object.md +247 -0
  619. package/bin/skills/lakehouse-doc/references/pipe-summary.md +114 -0
  620. package/bin/skills/lakehouse-doc/references/pipe-syntax.md +200 -0
  621. package/bin/skills/lakehouse-doc/references/practice_data_analysis.md +1 -0
  622. package/bin/skills/lakehouse-doc/references/practice_data_import_and_export.md +1 -0
  623. package/bin/skills/lakehouse-doc/references/practice_python_task.md +157 -0
  624. package/bin/skills/lakehouse-doc/references/pricing.md +225 -0
  625. package/bin/skills/lakehouse-doc/references/primary key.md +86 -0
  626. package/bin/skills/lakehouse-doc/references/primary-key.md +187 -0
  627. package/bin/skills/lakehouse-doc/references/privacy-policy.md +364 -0
  628. package/bin/skills/lakehouse-doc/references/private-link-general.md +68 -0
  629. package/bin/skills/lakehouse-doc/references/private_link.md +1 -0
  630. package/bin/skills/lakehouse-doc/references/product-trial-agreement.md +99 -0
  631. package/bin/skills/lakehouse-doc/references/product_concept.md +1 -0
  632. package/bin/skills/lakehouse-doc/references/put-get.md +1 -0
  633. package/bin/skills/lakehouse-doc/references/put_get_volume.md +3 -0
  634. package/bin/skills/lakehouse-doc/references/python-igs.md +297 -0
  635. package/bin/skills/lakehouse-doc/references/python_package_install_import_guide.md +53 -0
  636. package/bin/skills/lakehouse-doc/references/python_reference/connector.md +281 -0
  637. package/bin/skills/lakehouse-doc/references/python_reference/python-sdk-summary.md +13 -0
  638. package/bin/skills/lakehouse-doc/references/python_reference/sqlalchemy.md +77 -0
  639. package/bin/skills/lakehouse-doc/references/python_shell_datasource.md +334 -0
  640. package/bin/skills/lakehouse-doc/references/query-json-sy.md +47 -0
  641. package/bin/skills/lakehouse-doc/references/query-syntax.md +234 -0
  642. package/bin/skills/lakehouse-doc/references/quick_start_batch_sync_data.md +116 -0
  643. package/bin/skills/lakehouse-doc/references/quick_start_bi_analysis.md +589 -0
  644. package/bin/skills/lakehouse-doc/references/quick_start_create_workspace.md +58 -0
  645. package/bin/skills/lakehouse-doc/references/quick_start_data_quality.md +75 -0
  646. package/bin/skills/lakehouse-doc/references/quick_start_etl.md +131 -0
  647. package/bin/skills/lakehouse-doc/references/quick_start_monitoring_and_alerting.md +93 -0
  648. package/bin/skills/lakehouse-doc/references/quick_start_sql_query.md +93 -0
  649. package/bin/skills/lakehouse-doc/references/quick_start_upload_data.md +69 -0
  650. package/bin/skills/lakehouse-doc/references/quick_start_user_management.md +73 -0
  651. package/bin/skills/lakehouse-doc/references/quick_start_workspace.md +72 -0
  652. package/bin/skills/lakehouse-doc/references/quick_start_workspace_user.md +67 -0
  653. package/bin/skills/lakehouse-doc/references/quickstart_datashare_between_companies.md +249 -0
  654. package/bin/skills/lakehouse-doc/references/quickstart_envirment_for_team.md +271 -0
  655. package/bin/skills/lakehouse-doc/references/quickstart_local_csv.md +99 -0
  656. package/bin/skills/lakehouse-doc/references/realtime_sync.md +36 -0
  657. package/bin/skills/lakehouse-doc/references/realtime_sync_and_analysis_practice.md +187 -0
  658. package/bin/skills/lakehouse-doc/references/realtimesync_m.md +190 -0
  659. package/bin/skills/lakehouse-doc/references/refresh-history.md +63 -0
  660. package/bin/skills/lakehouse-doc/references/regexp-statement.md +80 -0
  661. package/bin/skills/lakehouse-doc/references/releasenotes.md +1 -0
  662. package/bin/skills/lakehouse-doc/references/releasenotesupdata.md +1 -0
  663. package/bin/skills/lakehouse-doc/references/remove-volume.md +32 -0
  664. package/bin/skills/lakehouse-doc/references/restore-dynamic-table.md +126 -0
  665. package/bin/skills/lakehouse-doc/references/restore.md +127 -0
  666. package/bin/skills/lakehouse-doc/references/result_cache.md +102 -0
  667. package/bin/skills/lakehouse-doc/references/revoke-from-share.md +48 -0
  668. package/bin/skills/lakehouse-doc/references/revoke-user-privileges.md +91 -0
  669. package/bin/skills/lakehouse-doc/references/right.md +84 -0
  670. package/bin/skills/lakehouse-doc/references/rlike.md +78 -0
  671. package/bin/skills/lakehouse-doc/references/rn_2024_11_12.md +63 -0
  672. package/bin/skills/lakehouse-doc/references/role-privlilige-manage.md +1 -0
  673. package/bin/skills/lakehouse-doc/references/roles.md +123 -0
  674. package/bin/skills/lakehouse-doc/references/rom_lakehouse_to_volume.md +1 -0
  675. package/bin/skills/lakehouse-doc/references/s3_volume_creation.md +37 -0
  676. package/bin/skills/lakehouse-doc/references/sample-data-using.md +768 -0
  677. package/bin/skills/lakehouse-doc/references/security_compliance_audit_guide.md +1 -0
  678. package/bin/skills/lakehouse-doc/references/security_overview.md +41 -0
  679. package/bin/skills/lakehouse-doc/references/select-catalog-table.md +26 -0
  680. package/bin/skills/lakehouse-doc/references/semantic_view.md +711 -0
  681. package/bin/skills/lakehouse-doc/references/setup.md +33 -0
  682. package/bin/skills/lakehouse-doc/references/share-ddl.md +1 -0
  683. package/bin/skills/lakehouse-doc/references/show-cached-status.md +34 -0
  684. package/bin/skills/lakehouse-doc/references/show-catalog-schema.md +48 -0
  685. package/bin/skills/lakehouse-doc/references/show-catalog-table.md +22 -0
  686. package/bin/skills/lakehouse-doc/references/show-catalog.md +26 -0
  687. package/bin/skills/lakehouse-doc/references/show-columns.md +75 -0
  688. package/bin/skills/lakehouse-doc/references/show-create-dynamic-table.md +44 -0
  689. package/bin/skills/lakehouse-doc/references/show-create-external-table.md +45 -0
  690. package/bin/skills/lakehouse-doc/references/show-create-materialized-view.md +43 -0
  691. package/bin/skills/lakehouse-doc/references/show-create-table.md +107 -0
  692. package/bin/skills/lakehouse-doc/references/show-dynamic-table.md +68 -0
  693. package/bin/skills/lakehouse-doc/references/show-external-schemas.md +35 -0
  694. package/bin/skills/lakehouse-doc/references/show-external-table.md +38 -0
  695. package/bin/skills/lakehouse-doc/references/show-finctions.md +25 -0
  696. package/bin/skills/lakehouse-doc/references/show-functions.md +44 -0
  697. package/bin/skills/lakehouse-doc/references/show-grants-user.md +41 -0
  698. package/bin/skills/lakehouse-doc/references/show-jobs.md +48 -0
  699. package/bin/skills/lakehouse-doc/references/show-materialized-view.md +42 -0
  700. package/bin/skills/lakehouse-doc/references/show-schemas.md +41 -0
  701. package/bin/skills/lakehouse-doc/references/show-shares.md +94 -0
  702. package/bin/skills/lakehouse-doc/references/show-synonyms.md +29 -0
  703. package/bin/skills/lakehouse-doc/references/show-table-streams.md +53 -0
  704. package/bin/skills/lakehouse-doc/references/show-tables-history.md +91 -0
  705. package/bin/skills/lakehouse-doc/references/show-tables.md +50 -0
  706. package/bin/skills/lakehouse-doc/references/show-users.md +46 -0
  707. package/bin/skills/lakehouse-doc/references/show-vclusters.md +59 -0
  708. package/bin/skills/lakehouse-doc/references/show-views.md +31 -0
  709. package/bin/skills/lakehouse-doc/references/show-volume.md +57 -0
  710. package/bin/skills/lakehouse-doc/references/show.md +168 -0
  711. package/bin/skills/lakehouse-doc/references/simpletosimple_bazhuayu_datagpt.md +152 -0
  712. package/bin/skills/lakehouse-doc/references/small_file_optimization.md +101 -0
  713. package/bin/skills/lakehouse-doc/references/spark-connector-summary.md +329 -0
  714. package/bin/skills/lakehouse-doc/references/spark-connector-use.md +233 -0
  715. package/bin/skills/lakehouse-doc/references/sql-parmaters.md +594 -0
  716. package/bin/skills/lakehouse-doc/references/sql-qualify.md +236 -0
  717. package/bin/skills/lakehouse-doc/references/sql-reference.md +1 -0
  718. package/bin/skills/lakehouse-doc/references/sql_data_transfom_NestedDataTypes.md +451 -0
  719. package/bin/skills/lakehouse-doc/references/sql_data_transform.md +1 -0
  720. package/bin/skills/lakehouse-doc/references/sql_data_transform_basic.md +576 -0
  721. package/bin/skills/lakehouse-doc/references/sql_data_transform_cte.md +177 -0
  722. package/bin/skills/lakehouse-doc/references/sql_data_transform_tips.md +407 -0
  723. package/bin/skills/lakehouse-doc/references/sql_data_transform_windows.md +430 -0
  724. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/any_value.md +64 -0
  725. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/approx_count_distinct.md +45 -0
  726. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/approx_histogram.md +56 -0
  727. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/approx_percentile.md +65 -0
  728. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/approx_top_k.md +62 -0
  729. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/avg.md +68 -0
  730. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/bit_and.md +81 -0
  731. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/bit_or.md +78 -0
  732. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/bit_xor.md +79 -0
  733. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/bool_and.md +85 -0
  734. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/bool_or.md +86 -0
  735. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/collect_list.md +95 -0
  736. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/collect_list_on_array.md +64 -0
  737. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/collect_set.md +85 -0
  738. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/collect_set_on_array.md +80 -0
  739. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/corr.md +103 -0
  740. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/count.md +96 -0
  741. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/count_distinct.md +96 -0
  742. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/count_if.md +62 -0
  743. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/covar_pop.md +89 -0
  744. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/covar_samp.md +113 -0
  745. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/first_value.md +122 -0
  746. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap.md +42 -0
  747. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_and.md +46 -0
  748. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_and_state.md +47 -0
  749. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_merge.md +37 -0
  750. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_merge_state.md +29 -0
  751. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_or.md +44 -0
  752. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_or_state.md +64 -0
  753. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_state.md +27 -0
  754. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_xor.md +45 -0
  755. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_bitmap_xor_state.md +99 -0
  756. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/group_concat.md +53 -0
  757. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/last_value.md +100 -0
  758. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/map_agg.md +79 -0
  759. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/max.md +102 -0
  760. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/max_by.md +67 -0
  761. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/median.md +60 -0
  762. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/min.md +89 -0
  763. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/min_by.md +99 -0
  764. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/percentile.md +69 -0
  765. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/percentile_approx.md +33 -0
  766. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/percentile_rank.md +36 -0
  767. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/std.md +47 -0
  768. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/stddev.md +68 -0
  769. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/stddev_pop.md +67 -0
  770. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/stddev_samp.md +67 -0
  771. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/sum.md +67 -0
  772. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/var_pop.md +65 -0
  773. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/var_samp.md +65 -0
  774. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/variance.md +47 -0
  775. package/bin/skills/lakehouse-doc/references/sql_functions/aggregate_functions/wm_concat.md +79 -0
  776. package/bin/skills/lakehouse-doc/references/sql_functions/context_functions/current_instance_id.md +16 -0
  777. package/bin/skills/lakehouse-doc/references/sql_functions/context_functions/current_schema.md +29 -0
  778. package/bin/skills/lakehouse-doc/references/sql_functions/context_functions/current_session_id.md +30 -0
  779. package/bin/skills/lakehouse-doc/references/sql_functions/context_functions/current_user.md +29 -0
  780. package/bin/skills/lakehouse-doc/references/sql_functions/context_functions/current_user_id.md +21 -0
  781. package/bin/skills/lakehouse-doc/references/sql_functions/context_functions/current_vcluster.md +40 -0
  782. package/bin/skills/lakehouse-doc/references/sql_functions/context_functions/current_workspace.md +19 -0
  783. package/bin/skills/lakehouse-doc/references/sql_functions/context_functions/current_workspace_id.md +24 -0
  784. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/binary_to_bitmap.md +29 -0
  785. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_and.md +39 -0
  786. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_and_cardinality.md +48 -0
  787. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_andnot.md +61 -0
  788. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_andnot_cardinality.md +60 -0
  789. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_build.md +58 -0
  790. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_cardinality.md +43 -0
  791. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_contains.md +50 -0
  792. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_count.md +45 -0
  793. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_empty.md +52 -0
  794. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_has_all.md +49 -0
  795. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_has_any.md +65 -0
  796. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_hash.md +52 -0
  797. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_max.md +26 -0
  798. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_min.md +33 -0
  799. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_or.md +61 -0
  800. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_or_cardinality.md +27 -0
  801. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_remove.md +42 -0
  802. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_subset_in_range.md +60 -0
  803. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_subset_limit.md +36 -0
  804. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_to_array.md +24 -0
  805. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_to_binary.md +28 -0
  806. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_to_string.md +41 -0
  807. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_transform.md +42 -0
  808. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_xor.md +59 -0
  809. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/bitmap_xor_cardinality.md +30 -0
  810. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/string_to_bitmap.md +56 -0
  811. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/sub_bitmap.md +34 -0
  812. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitmap_functions/to_bitmap.md +78 -0
  813. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitwise_functions/bit_count.md +43 -0
  814. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/bitwise_functions/bitnot.md +34 -0
  815. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/assert_true.md +44 -0
  816. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/between.md +52 -0
  817. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/case_when.md +99 -0
  818. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/coalesce.md +51 -0
  819. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/decode.md +45 -0
  820. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/if.md +56 -0
  821. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/in.md +33 -0
  822. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/is_false.md +63 -0
  823. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/is_not_null.md +40 -0
  824. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/is_null.md +44 -0
  825. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/is_true.md +63 -0
  826. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/multiif.md +54 -0
  827. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/nvl.md +39 -0
  828. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/conditional_functions/raise_error.md +52 -0
  829. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/add_days.md +65 -0
  830. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/add_months.md +38 -0
  831. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/add_years.md +61 -0
  832. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/adddate.md +53 -0
  833. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/convert_timezone.md +46 -0
  834. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/current_date.md +56 -0
  835. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/current_timestamp.md +46 -0
  836. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/date.md +42 -0
  837. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/date_add.md +35 -0
  838. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/date_format.md +48 -0
  839. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/date_format_mysql.md +58 -0
  840. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/date_format_pg.md +54 -0
  841. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/date_sub.md +58 -0
  842. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/date_trunc.md +61 -0
  843. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/dateadd.md +60 -0
  844. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/datediff.md +50 -0
  845. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/datetime_patterns.md +61 -0
  846. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/day.md +53 -0
  847. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/dayofmonth.md +36 -0
  848. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/dayofweek.md +31 -0
  849. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/dayofweek_iso.md +56 -0
  850. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/dayofyear.md +40 -0
  851. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/days.md +21 -0
  852. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/extract.md +49 -0
  853. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/from_unixtime.md +43 -0
  854. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/from_utc_timestamp.md +45 -0
  855. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/hour.md +49 -0
  856. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/hours.md +21 -0
  857. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/last_day.md +35 -0
  858. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/localtimestamp.md +19 -0
  859. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/makde_date.md +20 -0
  860. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/make_date.md +20 -0
  861. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/make_dt_interval.md +66 -0
  862. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/make_ym_interval.md +53 -0
  863. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/minute.md +49 -0
  864. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/month.md +39 -0
  865. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/months.md +21 -0
  866. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/months_between.md +18 -0
  867. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/next_day.md +16 -0
  868. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/now.md +53 -0
  869. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/quarter.md +52 -0
  870. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/second.md +34 -0
  871. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/str_to_date_mysql.md +42 -0
  872. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/sub_days.md +66 -0
  873. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/timestamp_micros.md +34 -0
  874. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/timestamp_millis.md +54 -0
  875. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/timestamp_seconds.md +62 -0
  876. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/timestampadd.md +59 -0
  877. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/timestampdiff.md +78 -0
  878. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/to_date.md +43 -0
  879. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/to_start_of_interval.md +25 -0
  880. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/to_timestamp.md +66 -0
  881. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/to_timestamp_ntz.md +52 -0
  882. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/to_unix_timestamp.md +59 -0
  883. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/to_unix_timestamp_ms.md +45 -0
  884. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/to_unix_timestamp_us.md +40 -0
  885. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/to_utc_timestamp.md +62 -0
  886. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/toyyyymmdd.md +69 -0
  887. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/trunc.md +38 -0
  888. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/unix_timestamp.md +96 -0
  889. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/week.md +31 -0
  890. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/weekday.md +51 -0
  891. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/weekofyear.md +29 -0
  892. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/year.md +46 -0
  893. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/yearofweek.md +64 -0
  894. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/datetime_functions/years.md +21 -0
  895. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/geo_functions/st_geohash.md +34 -0
  896. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/geo_functions/st_latfromgeohash.md +59 -0
  897. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/geo_functions/st_longfromgeohash.md +53 -0
  898. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/hash_functions/bucket.md +33 -0
  899. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/hash_functions/general_hash.md +49 -0
  900. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/hash_functions/hash_combine.md +37 -0
  901. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/hash_functions/hash_combine_commutative.md +54 -0
  902. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/hash_functions/murmurhash.md +36 -0
  903. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/array_sort_by_key.md +42 -0
  904. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/element_at.md +59 -0
  905. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/exists.md +48 -0
  906. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/filter.md +37 -0
  907. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/forall.md +68 -0
  908. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/high_order_functions.md +34 -0
  909. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/map_filter.md +25 -0
  910. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/map_zip_with.md +46 -0
  911. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/transform.md +48 -0
  912. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/transform_keys.md +48 -0
  913. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/transform_values.md +36 -0
  914. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/high_order_functions/zip_with.md +38 -0
  915. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/ip_functions/get_ip_info.md +199 -0
  916. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/ip_functions/ipv4_num_to_string.md +29 -0
  917. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/ip_functions/ipv4_string_to_num.md +34 -0
  918. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/ip_functions/ipv6_num_to_string.md +35 -0
  919. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/ip_functions/ipv6_string_to_num.md +46 -0
  920. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/ip_functions/is_ip_address_in_range.md +42 -0
  921. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/from_json.md +86 -0
  922. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/get_json_object.md +83 -0
  923. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_array.md +30 -0
  924. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_contains.md +86 -0
  925. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_extract.md +64 -0
  926. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_minify.md +28 -0
  927. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_normalize.md +36 -0
  928. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_object.md +37 -0
  929. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_parse.md +59 -0
  930. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_remove.md +36 -0
  931. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_type.md +44 -0
  932. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/json_valid.md +46 -0
  933. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/schema_of_json.md +79 -0
  934. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/json_functions/to_json.md +68 -0
  935. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/abs.md +46 -0
  936. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/acos.md +30 -0
  937. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/acosh.md +39 -0
  938. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/asin.md +39 -0
  939. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/asinh.md +46 -0
  940. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/atan.md +27 -0
  941. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/atan2.md +43 -0
  942. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/atanh.md +24 -0
  943. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/bround.md +43 -0
  944. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/cbrt.md +56 -0
  945. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/ceil.md +45 -0
  946. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/ceilling.md +47 -0
  947. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/cos.md +41 -0
  948. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/cosh.md +41 -0
  949. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/cot.md +49 -0
  950. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/csc.md +34 -0
  951. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/degrees.md +42 -0
  952. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/div.md +28 -0
  953. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/e.md +34 -0
  954. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/exp.md +32 -0
  955. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/exp2.md +36 -0
  956. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/expm1.md +54 -0
  957. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/floor.md +41 -0
  958. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/greatest.md +36 -0
  959. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/hypot.md +37 -0
  960. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/isnan.md +27 -0
  961. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/least.md +38 -0
  962. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/ln.md +57 -0
  963. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/log.md +39 -0
  964. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/log10.md +47 -0
  965. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/log1p.md +48 -0
  966. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/log2.md +28 -0
  967. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/median.md +25 -0
  968. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/mod.md +35 -0
  969. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/monotonically_increasing_id.md +81 -0
  970. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/negative.md +15 -0
  971. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/operators.md +427 -0
  972. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/pi.md +41 -0
  973. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/pmod.md +31 -0
  974. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/positive.md +15 -0
  975. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/pow.md +39 -0
  976. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/radians.md +30 -0
  977. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/rand.md +39 -0
  978. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/randn.md +26 -0
  979. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/random.md +67 -0
  980. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/round.md +48 -0
  981. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/shiftleft.md +67 -0
  982. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/shiftright.md +70 -0
  983. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/shiftrightunsigned.md +70 -0
  984. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/sign.md +46 -0
  985. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/sin.md +67 -0
  986. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/sinh.md +46 -0
  987. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/sqrt.md +40 -0
  988. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/tan.md +42 -0
  989. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/math_functions/tanh.md +38 -0
  990. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array.md +46 -0
  991. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_append.md +26 -0
  992. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_compact.md +29 -0
  993. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_contains.md +38 -0
  994. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_distinct.md +43 -0
  995. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_except.md +35 -0
  996. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_intersect.md +39 -0
  997. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_join.md +51 -0
  998. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_max.md +57 -0
  999. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_min.md +60 -0
  1000. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_position.md +50 -0
  1001. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_prepend.md +26 -0
  1002. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_remove.md +34 -0
  1003. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_repeat.md +51 -0
  1004. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_size.md +32 -0
  1005. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_sort.md +46 -0
  1006. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_sort_reverse.md +31 -0
  1007. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/array_union.md +36 -0
  1008. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/arrays_overlap.md +41 -0
  1009. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/arrays_zip.md +50 -0
  1010. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/cardinality.md +45 -0
  1011. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/concat.md +49 -0
  1012. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/concat_ws.md +73 -0
  1013. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/element_at.md +34 -0
  1014. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/flatten.md +62 -0
  1015. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map.md +44 -0
  1016. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_concat.md +38 -0
  1017. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_contains_key.md +34 -0
  1018. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_entries.md +44 -0
  1019. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_equal.md +33 -0
  1020. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_except.md +34 -0
  1021. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_from_arrays.md +28 -0
  1022. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_from_entries.md +52 -0
  1023. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_keys.md +37 -0
  1024. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/map_values.md +46 -0
  1025. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/multimap_from_entries.md +47 -0
  1026. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/named_struct.md +55 -0
  1027. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/sequence.md +35 -0
  1028. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/size.md +34 -0
  1029. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/slice.md +43 -0
  1030. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/sort_array.md +22 -0
  1031. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/struct.md +35 -0
  1032. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/struct_insert.md +54 -0
  1033. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/struct_update.md +42 -0
  1034. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/nested_functions/trans_array.md +147 -0
  1035. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/partition/max_pt.md +41 -0
  1036. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/search_functions/match_all.md +56 -0
  1037. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/search_functions/match_any.md +50 -0
  1038. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/search_functions/match_phrase.md +65 -0
  1039. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/search_functions/match_phrase_prefix.md +36 -0
  1040. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/search_functions/match_regexp.md +30 -0
  1041. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/search_functions/tokenize.md +57 -0
  1042. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/aes_decrypt.md +40 -0
  1043. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/aes_decrypt_mysql.md +30 -0
  1044. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/aes_encrypt.md +34 -0
  1045. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/aes_encrypt_mysql.md +53 -0
  1046. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/ascii.md +36 -0
  1047. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/base64.md +27 -0
  1048. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/binary.md +46 -0
  1049. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/btrim.md +38 -0
  1050. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/char.md +55 -0
  1051. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/char_length.md +52 -0
  1052. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/character_length.md +52 -0
  1053. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/chr.md +26 -0
  1054. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/collation_sort_key.md +58 -0
  1055. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/concat.md +75 -0
  1056. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/concat_ws.md +72 -0
  1057. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/contains.md +31 -0
  1058. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/conv.md +50 -0
  1059. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/endswith.md +70 -0
  1060. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/find_in_set.md +19 -0
  1061. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/format_string.md +53 -0
  1062. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/hex.md +45 -0
  1063. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/instr.md +41 -0
  1064. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/is_ascii.md +27 -0
  1065. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/is_utf8.md +27 -0
  1066. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/lcase.md +45 -0
  1067. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/left.md +35 -0
  1068. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/length.md +33 -0
  1069. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/lengthb.md +49 -0
  1070. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/like.md +63 -0
  1071. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/locate.md +42 -0
  1072. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/lower.md +61 -0
  1073. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/lpad.md +45 -0
  1074. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/ltrim.md +48 -0
  1075. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/mask.md +37 -0
  1076. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/md5.md +71 -0
  1077. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/octet_length.md +47 -0
  1078. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/parse_url.md +78 -0
  1079. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/position.md +35 -0
  1080. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/regexp_count.md +115 -0
  1081. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/regexp_extract.md +37 -0
  1082. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/regexp_extract_all.md +31 -0
  1083. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/regexp_instr.md +152 -0
  1084. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/regexp_replace.md +34 -0
  1085. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/repeat.md +44 -0
  1086. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/replace.md +37 -0
  1087. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/reverse.md +70 -0
  1088. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/right.md +34 -0
  1089. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/rlike.md +64 -0
  1090. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/rpad.md +53 -0
  1091. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/rtrim.md +37 -0
  1092. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/sha1.md +67 -0
  1093. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/space.md +34 -0
  1094. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/split.md +61 -0
  1095. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/split_part.md +42 -0
  1096. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/startswith.md +70 -0
  1097. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/str_to_map.md +60 -0
  1098. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/strpos.md +60 -0
  1099. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/substr.md +43 -0
  1100. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/substring.md +53 -0
  1101. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/substring_index.md +46 -0
  1102. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/translate.md +43 -0
  1103. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/trim.md +54 -0
  1104. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/typeof.md +54 -0
  1105. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/ucase.md +46 -0
  1106. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/unbase64.md +54 -0
  1107. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/unhex.md +46 -0
  1108. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/upper.md +51 -0
  1109. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/url_decode.md +32 -0
  1110. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/url_encode.md +33 -0
  1111. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/string_functions/uuid.md +33 -0
  1112. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/binary_quantize.md +51 -0
  1113. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/cosine_distance.md +53 -0
  1114. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/dot_product.md +54 -0
  1115. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/hamming_distance.md +57 -0
  1116. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/jaccard_distance.md +55 -0
  1117. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/l2_distance.md +53 -0
  1118. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/l2_norm.md +52 -0
  1119. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/l2_normalize.md +54 -0
  1120. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/print_vector_bits.md +56 -0
  1121. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/vector.md +70 -0
  1122. package/bin/skills/lakehouse-doc/references/sql_functions/scalar_functions/vector_functions/vector_add_scalar.md +57 -0
  1123. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/explode.md +71 -0
  1124. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/inline.md +48 -0
  1125. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/json_tuple.md +44 -0
  1126. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/load_history.md +17 -0
  1127. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/posexplode.md +89 -0
  1128. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/read_kafka.md +85 -0
  1129. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/stack.md +69 -0
  1130. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/table_changes.md +136 -0
  1131. package/bin/skills/lakehouse-doc/references/sql_functions/table_functions/unnset.md +106 -0
  1132. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/avg.md +91 -0
  1133. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/count.md +88 -0
  1134. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/cume_dist.md +104 -0
  1135. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/dense_rank.md +119 -0
  1136. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/first.md +159 -0
  1137. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/first_value.md +133 -0
  1138. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/lag.md +72 -0
  1139. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/last.md +166 -0
  1140. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/last_value.md +160 -0
  1141. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/lead.md +49 -0
  1142. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/max.md +167 -0
  1143. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/min.md +138 -0
  1144. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/nth_value.md +58 -0
  1145. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/ntile.md +57 -0
  1146. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/percent_rank.md +58 -0
  1147. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/rank.md +139 -0
  1148. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/row_number.md +141 -0
  1149. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/sum.md +105 -0
  1150. package/bin/skills/lakehouse-doc/references/sql_functions/window_functions/window_clause.md +91 -0
  1151. package/bin/skills/lakehouse-doc/references/sql_practice.md +1 -0
  1152. package/bin/skills/lakehouse-doc/references/sql_rfm.md +181 -0
  1153. package/bin/skills/lakehouse-doc/references/sqlalchemy.md +82 -0
  1154. package/bin/skills/lakehouse-doc/references/ssb-benchmark.md +224 -0
  1155. package/bin/skills/lakehouse-doc/references/sso-configuration.md +157 -0
  1156. package/bin/skills/lakehouse-doc/references/storage_encryption.md +81 -0
  1157. package/bin/skills/lakehouse-doc/references/streaming_data_pipeline_overview.md +20 -0
  1158. package/bin/skills/lakehouse-doc/references/streaming_data_pipeline_overview1.md +1 -0
  1159. package/bin/skills/lakehouse-doc/references/streaming_pipeline_with_dynamic_table.md +66 -0
  1160. package/bin/skills/lakehouse-doc/references/structure_data_analysis.md +229 -0
  1161. package/bin/skills/lakehouse-doc/references/studio_manual.md +1 -0
  1162. package/bin/skills/lakehouse-doc/references/studio_overview.md +71 -0
  1163. package/bin/skills/lakehouse-doc/references/synonym.md +139 -0
  1164. package/bin/skills/lakehouse-doc/references/table-stream-title.md +1 -0
  1165. package/bin/skills/lakehouse-doc/references/table-stream.md +1 -0
  1166. package/bin/skills/lakehouse-doc/references/table-summary.md +1 -0
  1167. package/bin/skills/lakehouse-doc/references/table_funciotn.md +1 -0
  1168. package/bin/skills/lakehouse-doc/references/table_stream.md +118 -0
  1169. package/bin/skills/lakehouse-doc/references/tablesample.md +474 -0
  1170. package/bin/skills/lakehouse-doc/references/tablestream_summary.md +515 -0
  1171. package/bin/skills/lakehouse-doc/references/task-instance-maintenance.md +207 -0
  1172. package/bin/skills/lakehouse-doc/references/task_development.md +56 -0
  1173. package/bin/skills/lakehouse-doc/references/task_group.md +151 -0
  1174. package/bin/skills/lakehouse-doc/references/task_param.md +978 -0
  1175. package/bin/skills/lakehouse-doc/references/task_scheduling.md +1 -0
  1176. package/bin/skills/lakehouse-doc/references/task_scheduling_dependency.md +74 -0
  1177. package/bin/skills/lakehouse-doc/references/taskdevelop.md +268 -0
  1178. package/bin/skills/lakehouse-doc/references/tencentcloud_arn_and_externalid.md +29 -0
  1179. package/bin/skills/lakehouse-doc/references/time-function.md +67 -0
  1180. package/bin/skills/lakehouse-doc/references/timetravel-summary.md +47 -0
  1181. package/bin/skills/lakehouse-doc/references/tools_AI.md +1 -0
  1182. package/bin/skills/lakehouse-doc/references/tools_BI.md +1 -0
  1183. package/bin/skills/lakehouse-doc/references/tpcds-benchmark.md +754 -0
  1184. package/bin/skills/lakehouse-doc/references/tpch-benchmark.md +887 -0
  1185. package/bin/skills/lakehouse-doc/references/transformt-dt.md +291 -0
  1186. package/bin/skills/lakehouse-doc/references/trial-account-quotas-and-limits.md +81 -0
  1187. package/bin/skills/lakehouse-doc/references/tutorial_DataGPT.md +1 -0
  1188. package/bin/skills/lakehouse-doc/references/tutorial_connect_to_lakehouse.md +1 -0
  1189. package/bin/skills/lakehouse-doc/references/tutorial_data_transformation.md +1 -0
  1190. package/bin/skills/lakehouse-doc/references/tutorial_migration.md +1 -0
  1191. package/bin/skills/lakehouse-doc/references/tutorial_virtual_cluster.md +1 -0
  1192. package/bin/skills/lakehouse-doc/references/tutorial_work_with_workspace.md +1 -0
  1193. package/bin/skills/lakehouse-doc/references/tutorial_zettapark.md +1 -0
  1194. package/bin/skills/lakehouse-doc/references/tutorials-streaming-data-pipeline-with_dynamic-table.md +124 -0
  1195. package/bin/skills/lakehouse-doc/references/undrop-dynamic-table.md +79 -0
  1196. package/bin/skills/lakehouse-doc/references/undrop-materialized-view.md +80 -0
  1197. package/bin/skills/lakehouse-doc/references/unifiedWorkflow.md +1 -0
  1198. package/bin/skills/lakehouse-doc/references/unloa-data-summary.md +17 -0
  1199. package/bin/skills/lakehouse-doc/references/unload-data-local.md +72 -0
  1200. package/bin/skills/lakehouse-doc/references/unstructure_data_analysis.md +1 -0
  1201. package/bin/skills/lakehouse-doc/references/unstructured_etl_pipeline_notebook.md +12 -0
  1202. package/bin/skills/lakehouse-doc/references/unstructured_etl_pipeline_user_guide.md +949 -0
  1203. package/bin/skills/lakehouse-doc/references/unstructured_etl_python_api.md +896 -0
  1204. package/bin/skills/lakehouse-doc/references/upload-data.md +1 -0
  1205. package/bin/skills/lakehouse-doc/references/upload_data.md +123 -0
  1206. package/bin/skills/lakehouse-doc/references/use-dbt-dev.md +441 -0
  1207. package/bin/skills/lakehouse-doc/references/use-external-schema.md +42 -0
  1208. package/bin/skills/lakehouse-doc/references/use-java-sdk-releatime-uploaddata.md +168 -0
  1209. package/bin/skills/lakehouse-doc/references/use-java-sdk-upload-dta-local.md +140 -0
  1210. package/bin/skills/lakehouse-doc/references/use-mysql-client.md +189 -0
  1211. package/bin/skills/lakehouse-doc/references/use-python-sdk-upload-data.md +99 -0
  1212. package/bin/skills/lakehouse-doc/references/use-schema.md +49 -0
  1213. package/bin/skills/lakehouse-doc/references/use-vcluster.md +38 -0
  1214. package/bin/skills/lakehouse-doc/references/user-aggrement.md +229 -0
  1215. package/bin/skills/lakehouse-doc/references/user-external-funciton.md +1 -0
  1216. package/bin/skills/lakehouse-doc/references/user-identification.md +58 -0
  1217. package/bin/skills/lakehouse-doc/references/user_permission_grand_guide.md +322 -0
  1218. package/bin/skills/lakehouse-doc/references/using-google-authenticator.md +48 -0
  1219. package/bin/skills/lakehouse-doc/references/using-udf-in-dynamic-table.md +162 -0
  1220. package/bin/skills/lakehouse-doc/references/using_mcp_solute_data_pipeline_issue.md +343 -0
  1221. package/bin/skills/lakehouse-doc/references/uuid.md +47 -0
  1222. package/bin/skills/lakehouse-doc/references/validate_schema_evolution.md +167 -0
  1223. package/bin/skills/lakehouse-doc/references/vc-job.md +1 -0
  1224. package/bin/skills/lakehouse-doc/references/vc_cache.md +71 -0
  1225. package/bin/skills/lakehouse-doc/references/vcluster_size_description.md +98 -0
  1226. package/bin/skills/lakehouse-doc/references/vector-search.md +144 -0
  1227. package/bin/skills/lakehouse-doc/references/vector-type.md +52 -0
  1228. package/bin/skills/lakehouse-doc/references/vector_data_process_guide.md +952 -0
  1229. package/bin/skills/lakehouse-doc/references/vector_search_ai.md +423 -0
  1230. package/bin/skills/lakehouse-doc/references/version-update.md +21 -0
  1231. package/bin/skills/lakehouse-doc/references/virtual-cluster.md +221 -0
  1232. package/bin/skills/lakehouse-doc/references/volume_best_practices.md +1141 -0
  1233. package/bin/skills/lakehouse-doc/references/web-job-history.md +163 -0
  1234. package/bin/skills/lakehouse-doc/references/what_is_clickzetta_lakehouse.md +92 -0
  1235. package/bin/skills/lakehouse-doc/references/window-function-summary.md +134 -0
  1236. package/bin/skills/lakehouse-doc/references/windowframe.md +139 -0
  1237. package/bin/skills/lakehouse-doc/references/working_with_Vclusters.md +171 -0
  1238. package/bin/skills/lakehouse-doc/references/working_with_cache.md +102 -0
  1239. package/bin/skills/lakehouse-doc/references/worksapce-informaiton_schema-views.md +207 -0
  1240. package/bin/skills/lakehouse-doc/references/worksheet.md +15 -0
  1241. package/bin/skills/lakehouse-doc/references/workspace-introduction.md +41 -0
  1242. package/bin/skills/lakehouse-doc/references/worskapce-infroamtionschema-summary.md +56 -0
  1243. package/package.json +13 -0
@@ -0,0 +1,1899 @@
1
+ # 复杂业务场景下的JSON数据处理指南
2
+
3
+ ## 指南概览
4
+
5
+ 本指南展示云器Lakehouse JSON功能的完整技术实现,从实际业务场景出发,提供JSON数据处理的专业解决方案。
6
+
7
+ **🚨 重要更新说明**:本修正版基于完整的实际验证,确认了云器Lakehouse JSON功能的真实能力边界,所有SQL示例均经过实际测试验证。
8
+
9
+ ### 指南结构
10
+
11
+ * **第一章**:业务场景与挑战分析
12
+ * **第二章**:云器Lakehouse解决方案
13
+ * **第三章**:核心技术挑战的解决方案
14
+ * **第四章**:深度技术实现与高级优化
15
+ * **第五章**:中文和特殊字符处理指南
16
+ * **第六章**:技术限制与最佳实践
17
+ * **第七章**:环境管理与实施建议
18
+
19
+ ***
20
+
21
+ ## 第一章:业务场景与挑战分析
22
+
23
+ ### 1.1 现代企业的JSON数据处理需求
24
+
25
+ 在数字化时代,JSON已成为企业数据交换的标准格式:
26
+
27
+ * **API经济**:微服务架构下,大量数据交换采用JSON格式
28
+ * **实时数据流**:IoT设备、用户行为、系统日志大量产生JSON数据
29
+ * **多样化数据源**:社交媒体、电商平台、金融交易等产生复杂嵌套JSON
30
+ * **国际化挑战**:JSON数据包含中文、emoji等多语言内容
31
+
32
+ ### 1.2 核心业务场景分析
33
+
34
+ #### 1.2.1 电商场景:复杂订单数据的实时分析
35
+
36
+ **业务场景描述**:
37
+ 电商平台每天处理数万笔订单,每笔订单包含客户信息、商品详情、支付信息、物流数据等复杂嵌套结构:
38
+
39
+ ```json
40
+ {
41
+ "order_id": "ORD-2024-001",
42
+ "customer": {
43
+ "id": 10001,
44
+ "name": "张三",
45
+ "profile": {
46
+ "level": "VIP",
47
+ "preferences": ["electronics", "gadgets", "books"],
48
+ "purchase_history": [
49
+ {"category": "electronics", "frequency": 15},
50
+ {"category": "books", "frequency": 8}
51
+ ]
52
+ },
53
+ "address": {"city": "北京", "district": "朝阳区"}
54
+ },
55
+ "items": [
56
+ {
57
+ "sku": "PHONE-001",
58
+ "name": "iPhone 15",
59
+ "price": 6999.00,
60
+ "qty": 1,
61
+ "attributes": {"color": "蓝色", "storage": "256GB"},
62
+ "promotion": {"type": "vip_discount", "discount": 500}
63
+ }
64
+ ],
65
+ "payment": {
66
+ "method": "alipay",
67
+ "amount": 7197.00,
68
+ "promotion_applied": {"code": "VIP500", "discount": 500}
69
+ },
70
+ "logistics": {
71
+ "shipping_method": "express",
72
+ "estimated_delivery": "2024-12-03",
73
+ "tracking_events": [
74
+ {"status": "ordered", "timestamp": "2024-12-01T10:00:00"},
75
+ {"status": "paid", "timestamp": "2024-12-01T10:05:00"}
76
+ ]
77
+ },
78
+ "user_feedback": {
79
+ "rating": "⭐⭐⭐⭐⭐",
80
+ "comment": "产品很棒!快递很快😊"
81
+ }
82
+ }
83
+ ```
84
+
85
+ **核心技术挑战**:
86
+
87
+ 1. **个性化推荐难题**:需要实时分析客户的`preferences`数组和`purchase_history`嵌套结构
88
+ 2. **动态促销策略**:每个商品的`promotion`信息结构不固定,不同促销类型的JSON结构完全不同
89
+ 3. **实时库存预警**:需要从订单的`items`数组中提取所有SKU,实时统计销量
90
+ 4. **客户行为分析**:分析客户从浏览到下单的完整路径
91
+ 5. **多语言内容处理**:客户姓名、地址、评论包含中文和emoji符号
92
+
93
+ #### 1.2.2 IoT场景:工业设备复杂监控数据的实时处理
94
+
95
+ **业务场景描述**:
96
+ 制造企业有数千台生产设备,每台设备每分钟上报复杂的监控数据:
97
+
98
+ ```json
99
+ {
100
+ "device_id": "MACHINE-001",
101
+ "timestamp": "2024-12-01T10:30:00Z",
102
+ "location": {
103
+ "building": "工厂-A",
104
+ "floor": 2,
105
+ "production_line": "生产线-1"
106
+ },
107
+ "sensors": {
108
+ "temperature": {"value": 85.2, "unit": "celsius", "status": "normal"},
109
+ "vibration": {
110
+ "x_axis": {"value": 0.02, "threshold": 0.05, "status": "normal"},
111
+ "y_axis": {"value": 0.03, "threshold": 0.05, "status": "normal"},
112
+ "z_axis": {"value": 0.08, "threshold": 0.05, "status": "warning"}
113
+ }
114
+ },
115
+ "operational_status": {
116
+ "machine_state": "running",
117
+ "production_rate": 85.5,
118
+ "efficiency": 92.3,
119
+ "maintenance": {
120
+ "last_service": "2024-11-15T08:00:00Z",
121
+ "next_scheduled": "2025-02-15T08:00:00Z",
122
+ "parts_status": [
123
+ {"part": "电机轴承", "condition": "良好", "life_remaining": 75},
124
+ {"part": "传送带", "condition": "一般", "life_remaining": 45}
125
+ ]
126
+ }
127
+ },
128
+ "alerts": {
129
+ "message": "设备运行正常✅",
130
+ "level": "info"
131
+ }
132
+ }
133
+ ```
134
+
135
+ **核心技术挑战**:
136
+
137
+ 1. **异构设备数据融合**:不同型号设备的`sensors`结构完全不同
138
+ 2. **实时异常检测**:需要同时监控多个嵌套指标
139
+ 3. **复杂维护计划**:`maintenance.parts_status`数组中每个部件的寿命不同
140
+ 4. **多维度生产分析**:需要按生产线、楼层、设备类型等维度分析
141
+
142
+ #### 1.2.3 金融场景:复杂交易风控的实时决策
143
+
144
+ **业务场景描述**:
145
+ 互联网银行需要对每笔交易进行实时风险评估:
146
+
147
+ ```json
148
+ {
149
+ "transaction_id": "TXN-20241201-001",
150
+ "timestamp": "2024-12-01T14:35:22Z",
151
+ "user": {
152
+ "id": 30001,
153
+ "name": "李四",
154
+ "profile": {
155
+ "age": 28,
156
+ "credit_score": 720,
157
+ "account_level": "Gold"
158
+ },
159
+ "behavior_pattern": {
160
+ "typical_amount_range": {"min": 500, "max": 3000},
161
+ "location_history": [
162
+ {"city": "北京", "frequency": 85},
163
+ {"city": "上海", "frequency": 10}
164
+ ]
165
+ }
166
+ },
167
+ "transaction": {
168
+ "amount": 8500.00,
169
+ "currency": "CNY",
170
+ "type": "transfer",
171
+ "merchant": {"name": "奢侈品店", "category": "retail"}
172
+ },
173
+ "device": {
174
+ "type": "mobile",
175
+ "fingerprint": "ABC123XYZ789",
176
+ "location": {"city": "上海", "ip": "121.xxx.xxx.xxx"},
177
+ "is_new_device": true,
178
+ "trusted_score": 0.3
179
+ },
180
+ "risk_analysis": {
181
+ "automated_factors": [
182
+ {"factor": "amount_anomaly", "score": 0.8, "reason": "金额超出常规范围"},
183
+ {"factor": "location_mismatch", "score": 0.6, "reason": "异地交易"}
184
+ ],
185
+ "final_decision": {
186
+ "action": "manual_review",
187
+ "confidence": 0.85,
188
+ "reason": "检测到多个风险因子🚨"
189
+ }
190
+ }
191
+ }
192
+ ```
193
+
194
+ **核心技术挑战**:
195
+
196
+ 1. **复杂风险因子实时计算**:需要同时分析多个嵌套对象的风险因子
197
+ 2. **快速决策要求**:风控决策需要在短时间内完成
198
+ 3. **动态规则引擎**:风控规则频繁变更,数据结构不断演化
199
+ 4. **合规审计追踪**:需要保留完整的决策过程,支持复杂的审计查询
200
+
201
+ ### 1.3 传统方案的局限性
202
+
203
+ **技术挑战**:
204
+
205
+ * **性能瓶颈**:传统数据库JSON查询性能有限
206
+ * **存储成本高**:JSON数据冗余,存储效率低
207
+ * **开发复杂度**:需要复杂的ETL转换
208
+ * **实时性不足**:批处理模式无法满足实时需求
209
+ * **扩展性限制**:单机架构难以处理大规模数据
210
+ * **多语言支持**:中文、emoji等特殊字符处理困难
211
+
212
+ ***
213
+
214
+ ## 第二章:云器Lakehouse解决方案
215
+
216
+ ### 2.1 核心技术优势
217
+
218
+ #### 2.1.1 原生JSON支持
219
+
220
+ **解决方案特点**:
221
+
222
+ * **数据类型原生支持**:JSON作为一等公民,无需预定义Schema
223
+ * **动态结构适应**:新增字段无需停机修改表结构
224
+ * **零转换成本**:JSON数据直接存储和查询,无需ETL预处理
225
+ * **多语言兼容**:完全支持中文和emoji内容
226
+
227
+ ```sql
228
+ -- 创建示例表
229
+ CREATE TABLE IF NOT EXISTS orders (
230
+ id INT,
231
+ order_data JSON
232
+ );
233
+
234
+ -- 直接存储不同结构的JSON数据(包含中文)
235
+ INSERT INTO orders VALUES
236
+ (1, parse_json('{"customer": {"name": "张三"}, "promotion": {"type": "vip_discount", "amount": 500}}')),
237
+ (2, parse_json('{"customer": {"name": "李四"}, "promotion": {"type": "flash_sale", "percentage": 0.2}}')),
238
+ (3, parse_json('{"customer": {"name": "王五"}, "promotion": {"type": "bundle_deal", "required_items": 3}}'));
239
+
240
+ -- 查询不同结构的促销数据
241
+ SELECT
242
+ id,
243
+ json_extract_string(order_data, "$.customer.name") as customer_name,
244
+ json_extract_string(order_data, "$.promotion.type") as promotion_type
245
+ FROM orders;
246
+ ```
247
+
248
+ #### 2.1.2 智能列式存储
249
+
250
+ **解决方案特点**:
251
+
252
+ * **自动字段优化**:高频访问的JSON字段自动转换为列式存储
253
+ * **路径索引优化**:常用JSON路径建立高效索引
254
+ * **列裁剪技术**:只读取查询需要的JSON字段,减少IO开销
255
+
256
+ ```sql
257
+ -- 使用前面创建的orders表进行高频字段查询
258
+ SELECT
259
+ json_extract_string(order_data, "$.customer.name") as customer_name,
260
+ json_extract_double(order_data, "$.promotion.amount") as discount_amount
261
+ FROM orders
262
+ WHERE json_extract_string(order_data, "$.promotion.type") = 'vip_discount';
263
+ ```
264
+
265
+ #### 2.1.3 高性能查询引擎
266
+
267
+ **解决方案特点**:
268
+
269
+ * **并行处理框架**:复杂JSON查询自动并行化执行
270
+ * **内存计算优化**:热点JSON数据常驻内存
271
+ * **智能缓存机制**:频繁访问的JSON路径结果缓存
272
+
273
+ #### 2.1.4 实时流处理集成
274
+
275
+ **解决方案特点**:
276
+
277
+ * **TABLE STREAM技术**:捕获JSON数据变更,实现增量处理
278
+ * **动态表自动刷新**:实时聚合复杂JSON数据
279
+ * **流批一体处理**:统一处理实时流和历史批数据
280
+
281
+ ```sql
282
+ -- 创建IoT传感器数据表
283
+ CREATE TABLE IF NOT EXISTS iot_sensors (
284
+ device_id STRING,
285
+ device_data JSON,
286
+ timestamp TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
287
+ );
288
+
289
+ -- 插入示例IoT数据
290
+ INSERT INTO iot_sensors VALUES
291
+ ('DEVICE-001', parse_json('{"device_id": "DEVICE-001", "sensors": {"temperature": {"value": 86.5}}, "location": "工厂A"}'), CURRENT_TIMESTAMP());
292
+
293
+ -- 创建告警事件表
294
+ CREATE TABLE IF NOT EXISTS alert_events (
295
+ device_id STRING,
296
+ temp_value DOUBLE,
297
+ alert_time TIMESTAMP
298
+ );
299
+
300
+ -- 实时异常检测(手动模拟)
301
+ INSERT INTO alert_events
302
+ SELECT
303
+ json_extract_string(device_data, "$.device_id") as device_id,
304
+ json_extract_double(device_data, "$.sensors.temperature.value") as temp_value,
305
+ CURRENT_TIMESTAMP() as alert_time
306
+ FROM iot_sensors
307
+ WHERE json_extract_double(device_data, "$.sensors.temperature.value") > 85;
308
+ ```
309
+
310
+ ***
311
+
312
+ ## 第三章:核心技术挑战的解决方案
313
+
314
+ 本章详细展示云器Lakehouse如何具体解决第一章提出的各项核心技术挑战,每个解决方案都直接对应具体的业务难题。
315
+
316
+ ### 3.1 电商场景:技术挑战的解决方案
317
+
318
+ #### 3.1.1 挑战一:个性化推荐的数组嵌套查询难题
319
+
320
+ **技术挑战描述**:
321
+ 需要实时分析客户的`preferences`数组和`purchase_history`嵌套结构,传统关系型数据库需要复杂的多表JOIN或者ETL预处理,无法满足实时个性化推荐的响应要求。
322
+
323
+ **云器Lakehouse解决方案**:
324
+
325
+ ```sql
326
+ -- 创建电商订单分析表,原生JSON支持
327
+ CREATE TABLE IF NOT EXISTS ecommerce_orders_json (
328
+ order_id STRING,
329
+ order_data JSON,
330
+ created_date DATE DEFAULT CURRENT_DATE()
331
+ );
332
+
333
+ -- 直接存储复杂嵌套结构,无需预处理
334
+ INSERT INTO ecommerce_orders_json VALUES
335
+ ('ORD-2024-001', parse_json('{
336
+ "customer": {
337
+ "id": 10001,
338
+ "name": "张三",
339
+ "level": "diamond",
340
+ "profile": {
341
+ "preferences": ["electronics", "gadgets", "books"],
342
+ "purchase_history": [
343
+ {"category": "electronics", "frequency": 15},
344
+ {"category": "books", "frequency": 8}
345
+ ]
346
+ }
347
+ },
348
+ "items": [{"sku": "PHONE-001", "category": "electronics", "price": 6999.00}],
349
+ "payment": {"amount": 7098.00}
350
+ }'), CURRENT_DATE()),
351
+ ('ORD-2024-002', parse_json('{
352
+ "customer": {
353
+ "id": 10002,
354
+ "name": "李四",
355
+ "level": "diamond",
356
+ "profile": {
357
+ "preferences": ["books", "sports", "electronics"],
358
+ "purchase_history": [
359
+ {"category": "books", "frequency": 20},
360
+ {"category": "sports", "frequency": 12}
361
+ ]
362
+ }
363
+ },
364
+ "items": [{"sku": "BOOK-001", "category": "books", "price": 299.00}],
365
+ "payment": {"amount": 299.00}
366
+ }'), CURRENT_DATE()),
367
+ ('ORD-2024-003', parse_json('{
368
+ "customer": {
369
+ "id": 10003,
370
+ "name": "王五",
371
+ "level": "diamond",
372
+ "profile": {
373
+ "preferences": ["gadgets", "electronics", "fashion"],
374
+ "purchase_history": [
375
+ {"category": "gadgets", "frequency": 25},
376
+ {"category": "electronics", "frequency": 18}
377
+ ]
378
+ }
379
+ },
380
+ "items": [{"sku": "GADGET-001", "category": "gadgets", "price": 1599.00}],
381
+ "payment": {"amount": 1599.00}
382
+ }'), CURRENT_DATE());
383
+
384
+ -- 直接访问嵌套数组,无需JOIN
385
+ SELECT
386
+ json_extract_string(order_data, "$.customer.id") as customer_id,
387
+ json_extract_string(order_data, "$.customer.name") as customer_name,
388
+ -- 直接提取偏好数组的第一个元素(主要偏好)
389
+ json_extract_string(order_data, "$.customer.profile.preferences[0]") as primary_preference,
390
+ -- 直接提取购买历史中最频繁的类别
391
+ json_extract_int(order_data, "$.customer.profile.purchase_history[0].frequency") as top_frequency,
392
+ -- 实时计算客户价值
393
+ json_extract_double(order_data, "$.payment.amount") as order_value
394
+ FROM ecommerce_orders_json
395
+ WHERE json_extract_string(order_data, "$.customer.level") = 'diamond'
396
+ ORDER BY json_extract_double(order_data, "$.payment.amount") DESC;
397
+ ```
398
+
399
+ **技术价值**:
400
+
401
+ 1. **零ETL处理**:复杂嵌套数据直接存储和查询
402
+ 2. **数组原生访问**:`[0]`语法直接访问数组元素,无需拆表
403
+ 3. **实时聚合**:单一查询完成多维度客户画像分析
404
+ 4. **自动优化**:高频字段自动列式存储,提升查询效率
405
+
406
+ #### 3.1.2 挑战二:动态促销结构的灵活查询难题
407
+
408
+ **技术挑战描述**:
409
+ 不同促销类型(VIP折扣、闪购、套装优惠)的JSON结构完全不同,传统固定Schema无法适应,需要预定义所有可能的促销字段,维护成本高。
410
+
411
+ **云器Lakehouse动态Schema解决方案**:
412
+
413
+ ```sql
414
+ -- 创建促销数据表
415
+ CREATE TABLE IF NOT EXISTS promotion_orders_json (
416
+ order_id STRING,
417
+ order_data JSON,
418
+ created_date DATE DEFAULT CURRENT_DATE()
419
+ );
420
+
421
+ -- 同一表存储不同结构的促销数据
422
+ INSERT INTO promotion_orders_json VALUES
423
+ -- VIP折扣:固定金额结构
424
+ ('ORD-VIP-001', parse_json('{"customer": {"name": "张三"}, "promotion": {"type": "vip_discount", "amount": 500}}'), CURRENT_DATE()),
425
+ -- 闪购:百分比结构
426
+ ('ORD-FLASH-001', parse_json('{"customer": {"name": "李四"}, "promotion": {"type": "flash_sale", "percentage": 0.2}}'), CURRENT_DATE()),
427
+ -- 套装优惠:组合商品结构
428
+ ('ORD-BUNDLE-001', parse_json('{"customer": {"name": "王五"}, "promotion": {"type": "bundle_deal", "required_items": 3, "discount_per_item": 50}}'), CURRENT_DATE()),
429
+ -- 优惠券:代码结构
430
+ ('ORD-COUPON-001', parse_json('{"customer": {"name": "赵六"}, "promotion": {"type": "coupon", "code": "SAVE20", "discount": 200}}'), CURRENT_DATE());
431
+
432
+ -- 自适应查询:一个SQL处理所有促销类型
433
+ SELECT
434
+ order_id,
435
+ json_extract_string(order_data, "$.customer.name") as customer_name,
436
+ json_extract_string(order_data, "$.promotion.type") as promotion_type,
437
+ -- 根据促销类型自动提取对应字段
438
+ CASE WHEN json_extract_string(order_data, "$.promotion.type") = 'vip_discount'
439
+ THEN json_extract_double(order_data, "$.promotion.amount")
440
+ WHEN json_extract_string(order_data, "$.promotion.type") = 'coupon'
441
+ THEN json_extract_double(order_data, "$.promotion.discount")
442
+ ELSE 0
443
+ END as discount_amount,
444
+ CASE WHEN json_extract_string(order_data, "$.promotion.type") = 'flash_sale'
445
+ THEN json_extract_double(order_data, "$.promotion.percentage")
446
+ ELSE 0
447
+ END as discount_percentage,
448
+ CASE WHEN json_extract_string(order_data, "$.promotion.type") = 'bundle_deal'
449
+ THEN json_extract_int(order_data, "$.promotion.required_items")
450
+ ELSE 0
451
+ END as bundle_items,
452
+ CASE WHEN json_extract_string(order_data, "$.promotion.type") = 'coupon'
453
+ THEN json_extract_string(order_data, "$.promotion.code")
454
+ ELSE NULL
455
+ END as coupon_code
456
+ FROM promotion_orders_json
457
+ WHERE json_extract_string(order_data, "$.promotion.type") IS NOT NULL;
458
+ ```
459
+
460
+ **技术价值**:
461
+
462
+ 1. **动态Schema适应**:新促销类型零停机自动支持
463
+ 2. **结构无关查询**:单一SQL处理多种数据结构
464
+ 3. **业务敏捷性**:促销规则变更无需数据库Schema修改
465
+
466
+ #### 3.1.3 挑战三:实时库存预警的数组聚合计算难题
467
+
468
+ **技术挑战描述**:
469
+ 需要从订单的`items`数组中提取所有SKU并实时统计销量,传统方案需要复杂的触发器或定时ETL作业,延迟高且资源消耗大。
470
+
471
+ **云器Lakehouse实时流处理解决方案**:
472
+
473
+ ```sql
474
+ -- 创建库存订单数据表
475
+ CREATE TABLE IF NOT EXISTS inventory_orders_json (
476
+ order_id STRING,
477
+ order_data JSON,
478
+ created_date DATE DEFAULT CURRENT_DATE()
479
+ );
480
+
481
+ -- 插入包含SKU和数量的订单数据
482
+ INSERT INTO inventory_orders_json VALUES
483
+ ('ORD-INV-001', parse_json('{"items": [{"sku": "PHONE-001", "qty": 2}], "payment": {"amount": 13998.00}}'), CURRENT_DATE()),
484
+ ('ORD-INV-002', parse_json('{"items": [{"sku": "BOOK-001", "qty": 5}], "payment": {"amount": 1495.00}}'), CURRENT_DATE()),
485
+ ('ORD-INV-003', parse_json('{"items": [{"sku": "PHONE-001", "qty": 1}], "payment": {"amount": 6999.00}}'), CURRENT_DATE()),
486
+ ('ORD-INV-004', parse_json('{"items": [{"sku": "GADGET-001", "qty": 3}], "payment": {"amount": 4797.00}}'), CURRENT_DATE()),
487
+ ('ORD-INV-005', parse_json('{"items": [{"sku": "BOOK-001", "qty": 2}], "payment": {"amount": 598.00}}'), CURRENT_DATE());
488
+
489
+ -- 动态表实现实时库存统计,自动刷新
490
+ CREATE OR REPLACE DYNAMIC TABLE IF NOT EXISTS real_time_inventory
491
+ REFRESH INTERVAL 1 MINUTES
492
+ AS SELECT
493
+ json_extract_string(order_data, "$.items[0].sku") as sku,
494
+ SUM(json_extract_int(order_data, "$.items[0].qty")) as total_sold,
495
+ COUNT(*) as order_count,
496
+ MAX(created_date) as last_order_date,
497
+ -- 实时库存预警阈值计算
498
+ CASE
499
+ WHEN SUM(json_extract_int(order_data, "$.items[0].qty")) > 5 THEN 'high_demand'
500
+ WHEN SUM(json_extract_int(order_data, "$.items[0].qty")) > 2 THEN 'medium_demand'
501
+ ELSE 'low_demand'
502
+ END as demand_level
503
+ FROM inventory_orders_json
504
+ WHERE json_extract_string(order_data, "$.items[0].sku") IS NOT NULL
505
+ GROUP BY json_extract_string(order_data, "$.items[0].sku");
506
+
507
+ -- 实时查询库存预警
508
+ SELECT * FROM real_time_inventory
509
+ WHERE demand_level = 'high_demand'
510
+ ORDER BY total_sold DESC;
511
+ ```
512
+
513
+ **技术价值**:
514
+
515
+ 1. **流批一体**:动态表自动聚合数据变更
516
+ 2. **实时聚合**:无需手动维护触发器和聚合逻辑
517
+ 3. **零维护成本**:系统自动处理复杂的聚合计算
518
+
519
+ ### 3.2 IoT场景:复杂设备数据的统一处理
520
+
521
+ #### 3.2.1 挑战一:异构设备数据统一查询难题
522
+
523
+ **技术挑战描述**:
524
+ 不同型号设备的`sensors`结构完全不同:老设备只有温度,新设备有十几种传感器,传统方案需要为每种设备创建不同的表结构,数据孤岛严重。
525
+
526
+ **云器Lakehouse异构数据统一解决方案**:
527
+
528
+ ```sql
529
+ -- 创建IoT设备监控表,支持任意设备结构
530
+ CREATE TABLE IF NOT EXISTS iot_devices_unified (
531
+ device_id STRING,
532
+ sensor_data JSON,
533
+ collected_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
534
+ );
535
+
536
+ -- 同一表存储不同结构的设备数据
537
+ INSERT INTO iot_devices_unified VALUES
538
+ -- 基础传感器:只有温度
539
+ ('BASIC-001', parse_json('{"device_type": "basic", "temp": 22.1, "battery": 85}'), CURRENT_TIMESTAMP()),
540
+ -- 标准传感器:温度+湿度
541
+ ('STANDARD-001', parse_json('{"device_type": "standard", "readings": {"temperature": 24.5, "humidity": 58.2}}'), CURRENT_TIMESTAMP()),
542
+ -- 高级传感器:完整的多维数据
543
+ ('ADVANCED-001', parse_json('{"device_type": "advanced", "sensors": {"temperature": {"value": 85.2}, "vibration": {"x_axis": {"value": 0.02}}}}'), CURRENT_TIMESTAMP()),
544
+ -- 工业传感器:最复杂的结构
545
+ ('INDUSTRIAL-001', parse_json('{"device_type": "industrial", "sensors": {"temperature": {"value": 78.5}, "vibration": {"x_axis": {"value": 0.01}, "y_axis": {"value": 0.03}, "z_axis": {"value": 0.02}}, "pressure": {"value": 1013.25}}}'), CURRENT_TIMESTAMP());
546
+
547
+ -- 统一查询接口,自动适配不同设备结构
548
+ SELECT
549
+ device_id,
550
+ json_extract_string(sensor_data, "$.device_type") as device_type,
551
+ -- 兼容多种温度字段结构
552
+ COALESCE(
553
+ json_extract_double(sensor_data, "$.sensors.temperature.value"), -- 高级设备
554
+ json_extract_double(sensor_data, "$.readings.temperature"), -- 标准设备
555
+ json_extract_double(sensor_data, "$.temp") -- 基础设备
556
+ ) as temperature,
557
+ -- 可选的高级传感器数据
558
+ json_extract_double(sensor_data, "$.sensors.vibration.x_axis.value") as vibration_x,
559
+ json_extract_double(sensor_data, "$.sensors.vibration.y_axis.value") as vibration_y,
560
+ json_extract_double(sensor_data, "$.sensors.vibration.z_axis.value") as vibration_z,
561
+ json_extract_double(sensor_data, "$.sensors.pressure.value") as pressure,
562
+ -- 自动设备类型识别
563
+ CASE
564
+ WHEN json_extract_string(sensor_data, "$.sensors.vibration") IS NOT NULL THEN 'high_end_device'
565
+ WHEN json_extract_string(sensor_data, "$.readings.humidity") IS NOT NULL THEN 'standard_device'
566
+ ELSE 'basic_device'
567
+ END as inferred_device_category
568
+ FROM iot_devices_unified
569
+ ORDER BY collected_time DESC;
570
+ ```
571
+
572
+ **技术价值**:
573
+
574
+ 1. **设备即插即用**:新设备类型无需Schema变更
575
+ 2. **统一查询接口**:单一SQL支持所有设备类型
576
+ 3. **智能字段映射**:COALESCE自动适配不同字段结构
577
+
578
+ ### 3.3 金融场景:复杂风控的实时决策
579
+
580
+ #### 3.3.1 挑战一:复杂风险因子实时计算难题
581
+
582
+ **技术挑战描述**:
583
+ 需要同时分析用户行为模式、设备信任度、地理位置等多个嵌套对象的风险因子,传统方案需要多次数据库查询和复杂的业务逻辑计算,无法满足快速决策要求。
584
+
585
+ **云器Lakehouse多维风险因子并行计算解决方案**:
586
+
587
+ ```sql
588
+ -- 创建金融风控数据表
589
+ CREATE TABLE IF NOT EXISTS financial_risk_analysis (
590
+ transaction_id STRING,
591
+ risk_data JSON,
592
+ analysis_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
593
+ );
594
+
595
+ -- 插入复杂风控测试数据
596
+ INSERT INTO financial_risk_analysis VALUES
597
+ ('TXN-001', parse_json('{
598
+ "user": {
599
+ "id": "30001",
600
+ "behavior_pattern": {
601
+ "typical_amount_range": {"min": 500, "max": 3000},
602
+ "location_history": [{"city": "北京", "frequency": 85}]
603
+ }
604
+ },
605
+ "transaction": {"amount": 8500.00},
606
+ "device": {"is_new_device": true, "trusted_score": 0.3, "location": {"city": "上海"}}
607
+ }'), CURRENT_TIMESTAMP()),
608
+ ('TXN-002', parse_json('{
609
+ "user": {
610
+ "id": "30002",
611
+ "behavior_pattern": {
612
+ "typical_amount_range": {"min": 1000, "max": 5000},
613
+ "location_history": [{"city": "上海", "frequency": 90}]
614
+ }
615
+ },
616
+ "transaction": {"amount": 2500.00},
617
+ "device": {"is_new_device": false, "trusted_score": 0.9, "location": {"city": "上海"}}
618
+ }'), CURRENT_TIMESTAMP()),
619
+ ('TXN-003', parse_json('{
620
+ "user": {
621
+ "id": "30003",
622
+ "behavior_pattern": {
623
+ "typical_amount_range": {"min": 200, "max": 1500},
624
+ "location_history": [{"city": "深圳", "frequency": 95}]
625
+ }
626
+ },
627
+ "transaction": {"amount": 4500.00},
628
+ "device": {"is_new_device": true, "trusted_score": 0.2, "location": {"city": "北京"}}
629
+ }'), CURRENT_TIMESTAMP());
630
+
631
+ -- 单一查询完成复杂多维风险评估
632
+ SELECT
633
+ transaction_id,
634
+ json_extract_string(risk_data, "$.user.id") as user_id,
635
+ -- 金额异常风险实时计算
636
+ CASE
637
+ WHEN json_extract_double(risk_data, "$.transaction.amount") >
638
+ json_extract_double(risk_data, "$.user.behavior_pattern.typical_amount_range.max") * 2
639
+ THEN 0.8 -- 超出常规金额2倍:高风险
640
+ WHEN json_extract_double(risk_data, "$.transaction.amount") >
641
+ json_extract_double(risk_data, "$.user.behavior_pattern.typical_amount_range.max") * 1.5
642
+ THEN 0.5 -- 超出常规金额1.5倍:中风险
643
+ ELSE 0.2 -- 正常范围:低风险
644
+ END as amount_risk_score,
645
+
646
+ -- 设备信任度风险实时计算
647
+ CASE
648
+ WHEN json_extract_string(risk_data, "$.device.is_new_device") = 'true'
649
+ THEN 1.0 - json_extract_double(risk_data, "$.device.trusted_score")
650
+ ELSE 0.1
651
+ END as device_risk_score,
652
+
653
+ -- 地理位置风险实时计算
654
+ CASE
655
+ WHEN json_extract_string(risk_data, "$.device.location.city") !=
656
+ json_extract_string(risk_data, "$.user.behavior_pattern.location_history[0].city")
657
+ THEN 0.6 -- 异地交易:中等风险
658
+ ELSE 0.1 -- 常用地区:低风险
659
+ END as location_risk_score,
660
+
661
+ -- 综合风险评分:权重算法一次计算完成
662
+ ((CASE
663
+ WHEN json_extract_double(risk_data, "$.transaction.amount") >
664
+ json_extract_double(risk_data, "$.user.behavior_pattern.typical_amount_range.max") * 2
665
+ THEN 0.8 ELSE 0.2 END) * 0.4 + -- 金额风险权重40%
666
+ (CASE
667
+ WHEN json_extract_string(risk_data, "$.device.is_new_device") = 'true'
668
+ THEN 1.0 - json_extract_double(risk_data, "$.device.trusted_score")
669
+ ELSE 0.1 END) * 0.3 + -- 设备风险权重30%
670
+ (CASE
671
+ WHEN json_extract_string(risk_data, "$.device.location.city") !=
672
+ json_extract_string(risk_data, "$.user.behavior_pattern.location_history[0].city")
673
+ THEN 0.6 ELSE 0.1 END) * 0.3 -- 位置风险权重30%
674
+ ) as final_risk_score,
675
+
676
+ -- 实时决策建议
677
+ CASE
678
+ WHEN ((CASE
679
+ WHEN json_extract_double(risk_data, "$.transaction.amount") >
680
+ json_extract_double(risk_data, "$.user.behavior_pattern.typical_amount_range.max") * 2
681
+ THEN 0.8 ELSE 0.2 END) * 0.4 +
682
+ (CASE
683
+ WHEN json_extract_string(risk_data, "$.device.is_new_device") = 'true'
684
+ THEN 1.0 - json_extract_double(risk_data, "$.device.trusted_score")
685
+ ELSE 0.1 END) * 0.3 +
686
+ (CASE
687
+ WHEN json_extract_string(risk_data, "$.device.location.city") !=
688
+ json_extract_string(risk_data, "$.user.behavior_pattern.location_history[0].city")
689
+ THEN 0.6 ELSE 0.1 END) * 0.3) > 0.7 THEN 'REJECT'
690
+ WHEN ((CASE
691
+ WHEN json_extract_double(risk_data, "$.transaction.amount") >
692
+ json_extract_double(risk_data, "$.user.behavior_pattern.typical_amount_range.max") * 2
693
+ THEN 0.8 ELSE 0.2 END) * 0.4 +
694
+ (CASE
695
+ WHEN json_extract_string(risk_data, "$.device.is_new_device") = 'true'
696
+ THEN 1.0 - json_extract_double(risk_data, "$.device.trusted_score")
697
+ ELSE 0.1 END) * 0.3 +
698
+ (CASE
699
+ WHEN json_extract_string(risk_data, "$.device.location.city") !=
700
+ json_extract_string(risk_data, "$.user.behavior_pattern.location_history[0].city")
701
+ THEN 0.6 ELSE 0.1 END) * 0.3) > 0.4 THEN 'MANUAL_REVIEW'
702
+ ELSE 'APPROVE'
703
+ END as recommended_action
704
+ FROM financial_risk_analysis
705
+ ORDER BY final_risk_score DESC;
706
+ ```
707
+
708
+ **技术价值**:
709
+
710
+ 1. **单查询多维分析**:一次SQL完成所有风险因子计算
711
+ 2. **嵌套对象并行访问**:同时提取多个深层嵌套字段
712
+ 3. **快速决策支持**:显著减少风控决策的处理时间
713
+
714
+ ***
715
+
716
+ ## 第四章:深度技术实现与高级优化
717
+
718
+ 本章深入展示云器Lakehouse JSON处理的高级技术特性,每个技术实现都针对第一章提出的具体技术挑战提供深度解决方案。
719
+
720
+ ### 4.1 针对"客户行为分析"挑战的时序数组处理技术
721
+
722
+ #### 4.1.1 技术挑战回顾
723
+
724
+ **原始难题**: 分析客户从浏览到下单的完整路径,数据存储在`logistics.tracking_events`时序数组中,传统方案需要将数组数据拆分成多行存储,查询复杂且性能有限。
725
+
726
+ #### 4.1.2 云器Lakehouse时序数组处理实现
727
+
728
+ **核心技术实现**:
729
+
730
+ ```sql
731
+ -- 创建客户行为分析表
732
+ CREATE TABLE IF NOT EXISTS customer_behavior_analysis (
733
+ order_id STRING,
734
+ behavior_data JSON,
735
+ created_date DATE DEFAULT CURRENT_DATE()
736
+ );
737
+
738
+ -- 插入时序行为数据
739
+ INSERT INTO customer_behavior_analysis VALUES
740
+ ('ORD-BEHAVIOR-001', parse_json('{
741
+ "customer": {"id": 10001, "name": "张三"},
742
+ "items": [{"sku": "PHONE-001", "price": 6999.00}],
743
+ "behavior_tracking": {
744
+ "source": "search_engine",
745
+ "conversion_funnel": [
746
+ {"event": "product_view", "timestamp": "2024-12-01T09:00:00", "duration": 120},
747
+ {"event": "add_to_cart", "timestamp": "2024-12-01T09:02:00", "duration": 30},
748
+ {"event": "checkout_start", "timestamp": "2024-12-01T09:02:30", "duration": 180},
749
+ {"event": "payment_complete", "timestamp": "2024-12-01T09:05:30", "duration": 45}
750
+ ]
751
+ },
752
+ "logistics": {
753
+ "tracking_events": [
754
+ {"status": "ordered", "timestamp": "2024-12-01T09:05:30", "location": "北京"},
755
+ {"status": "paid", "timestamp": "2024-12-01T09:06:00", "location": "北京"},
756
+ {"status": "shipped", "timestamp": "2024-12-01T14:00:00", "location": "北京仓库"},
757
+ {"status": "delivered", "timestamp": "2024-12-02T10:00:00", "location": "朝阳区"}
758
+ ]
759
+ }
760
+ }'), CURRENT_DATE()),
761
+ ('ORD-BEHAVIOR-002', parse_json('{
762
+ "customer": {"id": 10002, "name": "李四"},
763
+ "items": [{"sku": "BOOK-001", "price": 299.00}],
764
+ "behavior_tracking": {
765
+ "source": "direct_visit",
766
+ "conversion_funnel": [
767
+ {"event": "product_view", "timestamp": "2024-12-01T10:00:00", "duration": 200},
768
+ {"event": "add_to_cart", "timestamp": "2024-12-01T10:03:20", "duration": 45},
769
+ {"event": "checkout_start", "timestamp": "2024-12-01T10:04:05", "duration": 90},
770
+ {"event": "payment_complete", "timestamp": "2024-12-01T10:05:35", "duration": 30}
771
+ ]
772
+ },
773
+ "logistics": {
774
+ "tracking_events": [
775
+ {"status": "ordered", "timestamp": "2024-12-01T10:05:35", "location": "上海"},
776
+ {"status": "paid", "timestamp": "2024-12-01T10:06:00", "location": "上海"},
777
+ {"status": "shipped", "timestamp": "2024-12-01T16:00:00", "location": "上海仓库"},
778
+ {"status": "delivered", "timestamp": "2024-12-02T14:00:00", "location": "浦东新区"}
779
+ ]
780
+ }
781
+ }'), CURRENT_DATE());
782
+
783
+ -- 复杂时序分析:单一查询完成完整行为路径分析
784
+ SELECT
785
+ order_id,
786
+ json_extract_string(behavior_data, "$.customer.id") as customer_id,
787
+ json_extract_string(behavior_data, "$.customer.name") as customer_name,
788
+ -- 提取完整的转化漏斗路径
789
+ json_extract_string(behavior_data, "$.behavior_tracking.conversion_funnel[0].event") as funnel_step1,
790
+ json_extract_string(behavior_data, "$.behavior_tracking.conversion_funnel[1].event") as funnel_step2,
791
+ json_extract_string(behavior_data, "$.behavior_tracking.conversion_funnel[2].event") as funnel_step3,
792
+ json_extract_string(behavior_data, "$.behavior_tracking.conversion_funnel[3].event") as funnel_step4,
793
+
794
+ -- 计算各阶段耗时
795
+ json_extract_int(behavior_data, "$.behavior_tracking.conversion_funnel[0].duration") as view_duration,
796
+ json_extract_int(behavior_data, "$.behavior_tracking.conversion_funnel[1].duration") as cart_duration,
797
+ json_extract_int(behavior_data, "$.behavior_tracking.conversion_funnel[2].duration") as checkout_duration,
798
+
799
+ -- 物流状态时序分析
800
+ json_extract_string(behavior_data, "$.logistics.tracking_events[0].status") as initial_status,
801
+ json_extract_string(behavior_data, "$.logistics.tracking_events[3].status") as final_status,
802
+
803
+ -- 实时转化效率计算
804
+ CASE
805
+ WHEN json_extract_string(behavior_data, "$.logistics.tracking_events[1].status") = 'paid'
806
+ THEN 'successful_conversion'
807
+ ELSE 'incomplete_conversion'
808
+ END as conversion_result,
809
+
810
+ -- 地理位置变化追踪
811
+ json_extract_string(behavior_data, "$.logistics.tracking_events[0].location") as order_location,
812
+ json_extract_string(behavior_data, "$.logistics.tracking_events[3].location") as delivery_location,
813
+
814
+ -- 转化效率分析
815
+ (json_extract_int(behavior_data, "$.behavior_tracking.conversion_funnel[0].duration") +
816
+ json_extract_int(behavior_data, "$.behavior_tracking.conversion_funnel[1].duration") +
817
+ json_extract_int(behavior_data, "$.behavior_tracking.conversion_funnel[2].duration") +
818
+ json_extract_int(behavior_data, "$.behavior_tracking.conversion_funnel[3].duration")) as total_conversion_time
819
+
820
+ FROM customer_behavior_analysis
821
+ WHERE json_extract_string(behavior_data, "$.behavior_tracking.conversion_funnel") IS NOT NULL
822
+ ORDER BY total_conversion_time ASC;
823
+ ```
824
+
825
+ **技术价值**:
826
+
827
+ 1. **零数据重构**:时序数组直接分析,无需拆分存储
828
+ 2. **单查询全链路**:从浏览到交付的完整路径一次获取
829
+ 3. **实时转化分析**:快速计算转化率和用户行为模式
830
+
831
+ ### 4.2 针对"复杂维护计划"挑战的动态数组计算技术
832
+
833
+ #### 4.2.1 技术挑战回顾
834
+
835
+ **原始难题**: `maintenance.parts_status`数组中每个部件的寿命不同,需要动态计算维护优先级,传统方案需要复杂的存储过程和定时计算。
836
+
837
+ #### 4.2.2 云器Lakehouse动态数组计算实现
838
+
839
+ **核心技术实现**:
840
+
841
+ ```sql
842
+ -- 创建设备维护分析表
843
+ CREATE TABLE IF NOT EXISTS device_maintenance_analysis (
844
+ device_id STRING,
845
+ maintenance_data JSON,
846
+ collected_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
847
+ );
848
+
849
+ -- 复杂部件状态数据存储
850
+ INSERT INTO device_maintenance_analysis VALUES
851
+ ('MACHINE-COMPLEX-001', parse_json('{
852
+ "device_info": {"type": "production_machine", "location": "工厂A-生产线1"},
853
+ "operational_status": {
854
+ "machine_state": "running",
855
+ "production_rate": 85.5,
856
+ "maintenance": {
857
+ "last_service": "2024-11-15T08:00:00Z",
858
+ "next_scheduled": "2025-02-15T08:00:00Z",
859
+ "parts_status": [
860
+ {"part": "主电机", "condition": "良好", "life_remaining": 75, "cost": 50000, "priority": 1},
861
+ {"part": "传送带", "condition": "一般", "life_remaining": 45, "cost": 8000, "priority": 2},
862
+ {"part": "液压系统", "condition": "良好", "life_remaining": 30, "cost": 25000, "priority": 1},
863
+ {"part": "控制面板", "condition": "优秀", "life_remaining": 90, "cost": 15000, "priority": 3},
864
+ {"part": "冷却系统", "condition": "需关注", "life_remaining": 20, "cost": 12000, "priority": 1}
865
+ ]
866
+ }
867
+ }
868
+ }'), CURRENT_TIMESTAMP()),
869
+ ('MACHINE-COMPLEX-002', parse_json('{
870
+ "device_info": {"type": "assembly_machine", "location": "工厂B-生产线2"},
871
+ "operational_status": {
872
+ "machine_state": "running",
873
+ "production_rate": 92.3,
874
+ "maintenance": {
875
+ "last_service": "2024-10-20T08:00:00Z",
876
+ "next_scheduled": "2025-01-20T08:00:00Z",
877
+ "parts_status": [
878
+ {"part": "装配臂", "condition": "良好", "life_remaining": 85, "cost": 35000, "priority": 1},
879
+ {"part": "感应器", "condition": "一般", "life_remaining": 55, "cost": 5000, "priority": 2},
880
+ {"part": "电路板", "condition": "优秀", "life_remaining": 95, "cost": 8000, "priority": 2},
881
+ {"part": "马达", "condition": "需关注", "life_remaining": 25, "cost": 18000, "priority": 1}
882
+ ]
883
+ }
884
+ }
885
+ }'), CURRENT_TIMESTAMP());
886
+
887
+ -- 智能维护优先级动态计算
888
+ SELECT
889
+ device_id,
890
+ json_extract_string(maintenance_data, "$.device_info.location") as location,
891
+ json_extract_string(maintenance_data, "$.device_info.type") as device_type,
892
+
893
+ -- 部件状态数组全面分析
894
+ json_extract_string(maintenance_data, "$.operational_status.maintenance.parts_status[0].part") as part1_name,
895
+ json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[0].life_remaining") as part1_life,
896
+ json_extract_string(maintenance_data, "$.operational_status.maintenance.parts_status[1].part") as part2_name,
897
+ json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[1].life_remaining") as part2_life,
898
+ json_extract_string(maintenance_data, "$.operational_status.maintenance.parts_status[2].part") as part3_name,
899
+ json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[2].life_remaining") as part3_life,
900
+
901
+ -- 智能维护决策算法:综合考虑寿命、成本、优先级
902
+ CASE
903
+ -- 高优先级部件且寿命不足30%:紧急维护
904
+ WHEN (json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[0].life_remaining") < 30 AND
905
+ json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[0].priority") = 1) OR
906
+ (json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[2].life_remaining") < 30 AND
907
+ json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[2].priority") = 1) OR
908
+ (COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[4].life_remaining"), 100) < 30 AND
909
+ COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[4].priority"), 2) = 1)
910
+ THEN 'urgent_maintenance'
911
+ -- 任意部件寿命不足50%:计划维护
912
+ WHEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[0].life_remaining") < 50 OR
913
+ json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[1].life_remaining") < 50 OR
914
+ json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[2].life_remaining") < 50 OR
915
+ COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[3].life_remaining"), 100) < 50 OR
916
+ COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[4].life_remaining"), 100) < 50
917
+ THEN 'scheduled_maintenance'
918
+ ELSE 'normal_operation'
919
+ END as maintenance_priority,
920
+
921
+ -- 最关键部件识别(寿命最短的高优先级部件)
922
+ LEAST(
923
+ CASE WHEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[0].priority") = 1
924
+ THEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[0].life_remaining")
925
+ ELSE 100 END,
926
+ CASE WHEN COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[2].priority"), 2) = 1
927
+ THEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[2].life_remaining")
928
+ ELSE 100 END,
929
+ CASE WHEN COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[4].priority"), 2) = 1
930
+ THEN COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[4].life_remaining"), 100)
931
+ ELSE 100 END
932
+ ) as critical_part_min_life,
933
+
934
+ -- 维护成本预估(基于部件状态动态计算)
935
+ (CASE WHEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[0].life_remaining") < 30
936
+ THEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[0].cost") ELSE 0 END +
937
+ CASE WHEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[1].life_remaining") < 30
938
+ THEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[1].cost") ELSE 0 END +
939
+ CASE WHEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[2].life_remaining") < 30
940
+ THEN json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[2].cost") ELSE 0 END +
941
+ CASE WHEN COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[3].life_remaining"), 100) < 30
942
+ THEN COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[3].cost"), 0) ELSE 0 END +
943
+ CASE WHEN COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[4].life_remaining"), 100) < 30
944
+ THEN COALESCE(json_extract_int(maintenance_data, "$.operational_status.maintenance.parts_status[4].cost"), 0) ELSE 0 END
945
+ ) as estimated_maintenance_cost
946
+
947
+ FROM device_maintenance_analysis
948
+ WHERE json_extract_string(maintenance_data, "$.operational_status.maintenance.parts_status") IS NOT NULL
949
+ ORDER BY critical_part_min_life ASC;
950
+ ```
951
+
952
+ **技术价值**:
953
+
954
+ 1. **智能决策算法**:综合寿命、成本、优先级的复杂维护策略
955
+ 2. **数组原生计算**:无需拆分数组即可进行复杂数学运算
956
+ 3. **实时成本预估**:基于实时部件状态动态计算维护预算
957
+
958
+ ### 4.3 性能优化技术
959
+
960
+ #### 4.3.1 高频字段访问模式优化
961
+
962
+ ```sql
963
+ -- 创建性能优化演示表
964
+ CREATE TABLE IF NOT EXISTS performance_orders (
965
+ id INT,
966
+ order_data JSON,
967
+ created_date DATE DEFAULT CURRENT_DATE()
968
+ );
969
+
970
+ -- 插入测试数据
971
+ INSERT INTO performance_orders VALUES
972
+ (1, parse_json('{"customer": {"id": "C001", "level": "VIP"}, "payment": {"amount": 1500.00}, "items": [{"detail": {"description": "高端电子产品"}}]}'), CURRENT_DATE()),
973
+ (2, parse_json('{"customer": {"id": "C002", "level": "regular"}, "payment": {"amount": 2300.00}, "items": [{"detail": {"description": "家居用品"}}]}'), CURRENT_DATE()),
974
+ (3, parse_json('{"customer": {"id": "C003", "level": "VIP"}, "payment": {"amount": 800.00}, "items": [{"detail": {"description": "日用品"}}]}'), CURRENT_DATE()),
975
+ (4, parse_json('{"customer": {"id": "C004", "level": "diamond"}, "payment": {"amount": 3500.00}, "items": [{"detail": {"description": "奢侈品"}}]}'), CURRENT_DATE());
976
+
977
+ -- 高频字段访问模式优化
978
+ WITH high_performance_query AS (
979
+ SELECT
980
+ -- 顶层字段访问:自动列式存储优化
981
+ json_extract_string(order_data, "$.customer.id") as customer_id,
982
+ json_extract_double(order_data, "$.payment.amount") as amount,
983
+ json_extract_string(order_data, "$.customer.level") as level,
984
+
985
+ -- 批量字段提取:减少重复JSON解析开销
986
+ order_data as full_order_data,
987
+ created_date
988
+ FROM performance_orders
989
+ WHERE json_extract_string(order_data, "$.customer.id") IS NOT NULL -- 高效顶层字段过滤
990
+ AND json_extract_double(order_data, "$.payment.amount") > 1000 -- 数值字段高效过滤
991
+ )
992
+
993
+ -- 二次计算优化:基于预提取字段进行复杂分析
994
+ SELECT
995
+ customer_id,
996
+ level,
997
+ amount,
998
+ -- 复杂嵌套字段按需提取(避免全表重复解析)
999
+ json_extract_string(full_order_data, "$.items[0].detail.description") as product_description,
1000
+
1001
+ -- 聚合优化:预分组减少计算量
1002
+ CASE
1003
+ WHEN amount > 3000 THEN 'high_value'
1004
+ WHEN amount > 1500 THEN 'medium_value'
1005
+ ELSE 'low_value'
1006
+ END as value_segment
1007
+ FROM high_performance_query
1008
+ ORDER BY amount DESC;
1009
+ ```
1010
+
1011
+ #### 4.3.2 JSON数据更新的替代解决方案
1012
+
1013
+ **🚨 重要技术限制**: 经过实际验证,云器Lakehouse不支持`json_set`、`json_insert`、`json_remove`等JSON修改函数。以下是验证过的替代解决方案:
1014
+
1015
+ **方案一:JSON完整重构(适用于简单更新**)
1016
+
1017
+ ```sql
1018
+ -- 创建事务演示表
1019
+ CREATE TABLE IF NOT EXISTS transaction_demo (
1020
+ customer_id STRING,
1021
+ customer_data JSON,
1022
+ updated_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
1023
+ );
1024
+
1025
+ -- 插入初始数据
1026
+ INSERT INTO transaction_demo VALUES
1027
+ ('10001', parse_json('{"name": "张三", "level": "regular", "profile": {"upgrade_date": null}, "payment": {"vip_discount": 0}}'), CURRENT_TIMESTAMP());
1028
+
1029
+ -- 使用parse_json + CONCAT重构JSON对象进行更新
1030
+ UPDATE transaction_demo
1031
+ SET customer_data = parse_json(CONCAT(
1032
+ '{"name": "', json_extract_string(customer_data, "$.name"), '", ',
1033
+ '"level": "VIP", ',
1034
+ '"profile": {"upgrade_date": "2024-12-01"}, ',
1035
+ '"payment": {"vip_discount": 500.0}}'
1036
+ )),
1037
+ updated_time = CURRENT_TIMESTAMP()
1038
+ WHERE customer_id = '10001'
1039
+ AND json_extract_string(customer_data, "$.level") != 'VIP';
1040
+
1041
+ -- 验证更新结果
1042
+ SELECT
1043
+ customer_id,
1044
+ json_extract_string(customer_data, "$.name") as name,
1045
+ json_extract_string(customer_data, "$.level") as level,
1046
+ json_extract_string(customer_data, "$.profile.upgrade_date") as upgrade_date,
1047
+ json_extract_double(customer_data, "$.payment.vip_discount") as vip_discount
1048
+ FROM transaction_demo
1049
+ WHERE customer_id = '10001';
1050
+ ```
1051
+
1052
+ **方案二:混合存储策略(推荐用于频繁更新**)
1053
+
1054
+ ```sql
1055
+ -- 频繁更新字段分离存储,稳定数据使用JSON
1056
+ CREATE TABLE IF NOT EXISTS hybrid_storage_demo (
1057
+ id INT,
1058
+ user_level STRING, -- 频繁更新的字段单独存储
1059
+ update_count INT, -- 频繁更新的字段单独存储
1060
+ user_profile JSON, -- 稳定的复杂数据用JSON存储
1061
+ last_updated TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
1062
+ );
1063
+
1064
+ -- 插入混合存储数据
1065
+ INSERT INTO hybrid_storage_demo VALUES
1066
+ (1, 'VIP', 5,
1067
+ parse_json('{"preferences": ["electronics", "books"], "address": {"city": "北京", "district": "朝阳区"}}'),
1068
+ CURRENT_TIMESTAMP());
1069
+
1070
+ -- 查询混合存储数据
1071
+ SELECT
1072
+ id,
1073
+ user_level, -- 关系型字段,更新效率高
1074
+ update_count, -- 关系型字段,更新效率高
1075
+ json_extract_string(user_profile, "$.preferences[0]") as primary_preference, -- JSON字段,查询灵活
1076
+ json_extract_string(user_profile, "$.address.city") as city -- JSON字段,结构化存储
1077
+ FROM hybrid_storage_demo;
1078
+ ```
1079
+
1080
+ ***
1081
+
1082
+ ## 第五章:中文和特殊字符处理指南
1083
+
1084
+ ### 5.1 中文和Emoji支持验证
1085
+
1086
+ 基于全面测试,云器Lakehouse对中文和emoji符号提供完整支持:
1087
+
1088
+ #### 5.1.1 完全支持的场景
1089
+
1090
+ **中文内容值**:
1091
+
1092
+ ```sql
1093
+ -- 创建用户数据表
1094
+ CREATE TABLE IF NOT EXISTS user_data_chinese (
1095
+ id STRING,
1096
+ data JSON
1097
+ );
1098
+
1099
+ -- 插入中文内容
1100
+ INSERT INTO user_data_chinese VALUES
1101
+ ('user001', parse_json('{"name": "张三", "city": "北京", "message": "你好世界!"}')),
1102
+ ('user002', parse_json('{"name": "李四", "city": "上海", "message": "数据处理很简单"}')),
1103
+ ('user003', parse_json('{"name": "王五", "city": "深圳", "message": "JSON功能很强大"}'));
1104
+
1105
+ -- 查询中文内容
1106
+ SELECT
1107
+ json_extract_string(data, "$.name") as name,
1108
+ json_extract_string(data, "$.city") as city,
1109
+ json_extract_string(data, "$.message") as message
1110
+ FROM user_data_chinese;
1111
+ ```
1112
+
1113
+ **Emoji符号**:
1114
+
1115
+ ```sql
1116
+ -- 创建社交数据表
1117
+ CREATE TABLE IF NOT EXISTS social_data_emoji (
1118
+ id STRING,
1119
+ data JSON
1120
+ );
1121
+
1122
+ -- 插入emoji数据
1123
+ INSERT INTO social_data_emoji VALUES
1124
+ ('post001', parse_json('{"content": "今天心情很好😊", "reactions": "👍❤️🔥", "rating": "⭐⭐⭐⭐⭐"}')),
1125
+ ('post002', parse_json('{"content": "产品质量真不错👌", "reactions": "👏🎉💯", "rating": "⭐⭐⭐⭐"}')),
1126
+ ('post003', parse_json('{"content": "服务态度很满意🙂", "reactions": "😀👍✨", "rating": "⭐⭐⭐⭐⭐"}'));
1127
+
1128
+ -- 查询emoji数据
1129
+ SELECT
1130
+ json_extract_string(data, "$.content") as content,
1131
+ json_extract_string(data, "$.reactions") as reactions,
1132
+ json_extract_string(data, "$.rating") as rating
1133
+ FROM social_data_emoji;
1134
+ ```
1135
+
1136
+ **复杂中文内容**:
1137
+
1138
+ ```sql
1139
+ -- 创建反馈数据表
1140
+ CREATE TABLE IF NOT EXISTS feedback_data_complex (
1141
+ id STRING,
1142
+ data JSON,
1143
+ created_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
1144
+ );
1145
+
1146
+ -- 插入复杂中文和emoji内容
1147
+ INSERT INTO feedback_data_complex VALUES
1148
+ ('fb001', parse_json('{"comment": "产品质量很好,快递很快,客服态度也不错👍", "sentiment": "positive", "tags": ["质量", "物流", "服务"]}'), CURRENT_TIMESTAMP()),
1149
+ ('fb002', parse_json('{"comment": "包装精美,功能强大,非常满意😊", "sentiment": "positive", "tags": ["包装", "功能", "满意度"]}'), CURRENT_TIMESTAMP()),
1150
+ ('fb003', parse_json('{"comment": "性价比很高,推荐购买🛒", "sentiment": "positive", "tags": ["性价比", "推荐"]}'), CURRENT_TIMESTAMP());
1151
+
1152
+ -- 查询复杂内容
1153
+ SELECT
1154
+ id,
1155
+ json_extract_string(data, "$.comment") as comment,
1156
+ json_extract_string(data, "$.sentiment") as sentiment,
1157
+ json_extract_string(data, "$.tags[0]") as first_tag,
1158
+ json_extract_string(data, "$.tags[1]") as second_tag
1159
+ FROM feedback_data_complex
1160
+ ORDER BY created_time DESC;
1161
+ ```
1162
+
1163
+ #### 5.1.2 查询中文和Emoji数据
1164
+
1165
+ ```sql
1166
+ -- 创建用户反馈数据表
1167
+ CREATE TABLE IF NOT EXISTS user_feedback_full (
1168
+ id STRING,
1169
+ data JSON,
1170
+ created_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
1171
+ );
1172
+
1173
+ -- 插入包含中文和emoji的测试数据
1174
+ INSERT INTO user_feedback_full VALUES
1175
+ ('user001', parse_json('{"name": "张三", "city": "北京", "comment": "产品很好😊", "score": 5}'), CURRENT_TIMESTAMP()),
1176
+ ('user002', parse_json('{"name": "李四", "city": "上海", "comment": "服务态度不错👍", "score": 4}'), CURRENT_TIMESTAMP()),
1177
+ ('user003', parse_json('{"name": "王五", "city": "北京", "comment": "物流很快,包装精美🎉", "score": 5}'), CURRENT_TIMESTAMP()),
1178
+ ('user004', parse_json('{"name": "赵六", "city": "深圳", "comment": "功能强大,值得推荐💯", "score": 5}'), CURRENT_TIMESTAMP());
1179
+
1180
+ -- 查询包含中文和emoji的数据
1181
+ SELECT
1182
+ json_extract_string(data, "$.name") as user_name,
1183
+ json_extract_string(data, "$.city") as city,
1184
+ json_extract_string(data, "$.comment") as feedback,
1185
+ json_extract_int(data, "$.score") as score
1186
+ FROM user_feedback_full
1187
+ WHERE json_extract_string(data, "$.city") = '北京'
1188
+ AND json_extract_string(data, "$.comment") LIKE '%😊%';
1189
+
1190
+ -- 按中文字段分组统计
1191
+ SELECT
1192
+ json_extract_string(data, "$.city") as city,
1193
+ COUNT(*) as user_count,
1194
+ AVG(json_extract_int(data, "$.score")) as avg_score
1195
+ FROM user_feedback_full
1196
+ GROUP BY json_extract_string(data, "$.city")
1197
+ ORDER BY user_count DESC;
1198
+
1199
+ -- 高分用户的emoji使用分析
1200
+ SELECT
1201
+ json_extract_string(data, "$.name") as user_name,
1202
+ json_extract_string(data, "$.comment") as comment,
1203
+ json_extract_int(data, "$.score") as score,
1204
+ CASE
1205
+ WHEN json_extract_string(data, "$.comment") LIKE '%😊%' THEN 'happy'
1206
+ WHEN json_extract_string(data, "$.comment") LIKE '%👍%' THEN 'thumbs_up'
1207
+ WHEN json_extract_string(data, "$.comment") LIKE '%🎉%' THEN 'celebration'
1208
+ WHEN json_extract_string(data, "$.comment") LIKE '%💯%' THEN 'perfect'
1209
+ ELSE 'no_emoji'
1210
+ END as emoji_sentiment
1211
+ FROM user_feedback_full
1212
+ WHERE json_extract_int(data, "$.score") >= 4
1213
+ ORDER BY json_extract_int(data, "$.score") DESC;
1214
+ ```
1215
+
1216
+ ### 5.2 最佳实践建议
1217
+
1218
+ #### 5.2.1 字段命名规范
1219
+
1220
+ **推荐:使用英文字段名**
1221
+
1222
+ ```sql
1223
+ -- 创建最佳实践演示表
1224
+ CREATE TABLE IF NOT EXISTS best_practice_demo (
1225
+ id STRING,
1226
+ data JSON
1227
+ );
1228
+
1229
+ -- 推荐的字段命名方式
1230
+ INSERT INTO best_practice_demo VALUES
1231
+ ('demo001', parse_json('{"user_name": "张三", "user_city": "北京", "user_comment": "产品很好😊", "rating_score": 5}'));
1232
+
1233
+ -- 查询演示
1234
+ SELECT
1235
+ json_extract_string(data, "$.user_name") as name,
1236
+ json_extract_string(data, "$.user_city") as city,
1237
+ json_extract_string(data, "$.user_comment") as comment,
1238
+ json_extract_int(data, "$.rating_score") as score
1239
+ FROM best_practice_demo;
1240
+ ```
1241
+
1242
+ **谨慎使用:中文字段名**
1243
+
1244
+ ```sql
1245
+ -- 创建中文字段名演示表(不推荐)
1246
+ CREATE TABLE IF NOT EXISTS chinese_field_demo (
1247
+ id STRING,
1248
+ data JSON
1249
+ );
1250
+
1251
+ -- 中文字段名示例(可用但不推荐)
1252
+ INSERT INTO chinese_field_demo VALUES
1253
+ ('demo001', parse_json('{"用户姓名": "张三", "用户城市": "北京", "用户评价": "产品很好😊"}'));
1254
+
1255
+ -- 查询中文字段名(语法正确但不推荐)
1256
+ SELECT
1257
+ json_extract_string(data, "$.用户姓名") as name,
1258
+ json_extract_string(data, "$.用户城市") as city,
1259
+ json_extract_string(data, "$.用户评价") as comment
1260
+ FROM chinese_field_demo;
1261
+ ```
1262
+
1263
+ #### 5.2.2 特殊字符处理
1264
+
1265
+ **安全的内容格式**:
1266
+
1267
+ ```sql
1268
+ -- 创建特殊字符处理演示表
1269
+ CREATE TABLE IF NOT EXISTS special_char_demo (
1270
+ id STRING,
1271
+ data JSON
1272
+ );
1273
+
1274
+ -- 插入包含各种特殊字符的数据
1275
+ INSERT INTO special_char_demo VALUES
1276
+ ('char001', parse_json('{"message": "正常的中文内容和emoji😊", "symbols": "!@#$%^&*()_+-=[]{}|;:,.<>?/", "punctuation": "中文标点:,。;:""''()【】、?!"}'));
1277
+
1278
+ -- 查询特殊字符数据
1279
+ SELECT
1280
+ json_extract_string(data, "$.message") as message,
1281
+ json_extract_string(data, "$.symbols") as symbols,
1282
+ json_extract_string(data, "$.punctuation") as punctuation
1283
+ FROM special_char_demo;
1284
+ ```
1285
+
1286
+ ### 5.3 问题排查指南
1287
+
1288
+ 如果遇到中文或emoji显示问题:
1289
+
1290
+ 1. **检查字段命名**:优先使用英文字段名
1291
+ 2. **验证JSON格式**:确保JSON格式正确,没有语法错误
1292
+ 3. **使用标准函数**:统一使用json\_extract\_\*函数
1293
+ 4. **避免复杂转义**:减少在JSON字符串中使用复杂的转义字符
1294
+ 5. **编码设置**:确保客户端和数据库的字符编码设置正确
1295
+
1296
+ ```sql
1297
+ -- 问题排查演示查询
1298
+ CREATE TABLE IF NOT EXISTS troubleshoot_demo (
1299
+ id STRING,
1300
+ data JSON
1301
+ );
1302
+
1303
+ -- 正确的数据插入方式
1304
+ INSERT INTO troubleshoot_demo VALUES
1305
+ ('test001', parse_json('{"name": "测试用户", "message": "这是一条测试消息🔧"}'));
1306
+
1307
+ -- 验证数据是否正确存储和查询
1308
+ SELECT
1309
+ id,
1310
+ json_extract_string(data, "$.name") as name,
1311
+ json_extract_string(data, "$.message") as message,
1312
+ LENGTH(json_extract_string(data, "$.name")) as name_length,
1313
+ LENGTH(json_extract_string(data, "$.message")) as message_length
1314
+ FROM troubleshoot_demo;
1315
+ ```
1316
+
1317
+ ***
1318
+
1319
+ ## 第六章:技术限制与最佳实践
1320
+
1321
+ ### 6.1 JSON类型限制总结(验证修正版)
1322
+
1323
+ 基于完整验证发现的核心限制:
1324
+
1325
+ #### 6.1.1 确认支持的功能
1326
+
1327
+ **✅ 支持的JSON函数**:
1328
+
1329
+ * `parse_json()` - JSON字符串解析
1330
+ * `json_extract_string()` - 提取字符串值
1331
+ * `json_extract_int()` - 提取整数值
1332
+ * `json_extract_double()` - 提取浮点数值
1333
+ * `json_extract()` - 通用提取函数
1334
+
1335
+ **✅ 支持的语法**:
1336
+
1337
+ * `CREATE TABLE IF NOT EXISTS`
1338
+ * 完整的DDL操作(CREATE/ALTER/DROP)
1339
+ * 数组访问语法 `[0]`, `[1]`
1340
+ * 嵌套对象访问 `$.path.to.field`
1341
+ * 中文和emoji内容完全支持
1342
+
1343
+ #### 6.1.2 确认不支持的功能
1344
+
1345
+ **❌ 不支持的JSON函数**:
1346
+
1347
+ ```sql
1348
+ -- 以下函数经验证不被支持:
1349
+ -- json_set() - JSON字段更新(重要限制)
1350
+ ```
1351
+
1352
+ **❌ 不支持的操作**:
1353
+
1354
+ ```sql
1355
+ -- 创建限制演示表
1356
+ CREATE TABLE IF NOT EXISTS limitation_demo (
1357
+ id INT,
1358
+ json_data JSON
1359
+ );
1360
+
1361
+ -- 插入测试数据
1362
+ INSERT INTO limitation_demo VALUES
1363
+ (1, parse_json('{"name": "张三", "score": 85}')),
1364
+ (2, parse_json('{"name": "李四", "score": 92}')),
1365
+ (3, parse_json('{"name": "王五", "score": 78}'));
1366
+
1367
+ -- 以下操作不被支持,会导致错误:
1368
+ -- JSON类型不支持直接比较
1369
+ -- SELECT * FROM limitation_demo WHERE json_data = parse_json('{}');
1370
+
1371
+ -- JSON类型不支持直接排序
1372
+ -- SELECT * FROM limitation_demo ORDER BY json_data;
1373
+
1374
+ -- JSON类型不支持直接GROUP BY
1375
+ -- SELECT json_data, COUNT(*) FROM limitation_demo GROUP BY json_data;
1376
+ ```
1377
+
1378
+ #### 6.1.3 解决方案
1379
+
1380
+ ```sql
1381
+ -- 使用json_extract函数进行比较
1382
+ SELECT * FROM limitation_demo
1383
+ WHERE json_extract_string(json_data, "$.name") = '张三';
1384
+
1385
+ -- 提取字段后排序
1386
+ SELECT
1387
+ id,
1388
+ json_extract_string(json_data, "$.name") as name,
1389
+ json_extract_int(json_data, "$.score") as score
1390
+ FROM limitation_demo
1391
+ ORDER BY json_extract_int(json_data, "$.score") DESC;
1392
+
1393
+ -- 提取字段后分组
1394
+ SELECT
1395
+ CASE
1396
+ WHEN json_extract_int(json_data, "$.score") >= 90 THEN 'excellent'
1397
+ WHEN json_extract_int(json_data, "$.score") >= 80 THEN 'good'
1398
+ ELSE 'average'
1399
+ END as grade,
1400
+ COUNT(*) as count
1401
+ FROM limitation_demo
1402
+ GROUP BY CASE
1403
+ WHEN json_extract_int(json_data, "$.score") >= 90 THEN 'excellent'
1404
+ WHEN json_extract_int(json_data, "$.score") >= 80 THEN 'good'
1405
+ ELSE 'average'
1406
+ END;
1407
+ ```
1408
+
1409
+ ### 6.2 JSON数据更新的替代策略
1410
+
1411
+ #### 6.2.1 更新策略设计原则
1412
+
1413
+ 1. **读多写少原则**:JSON主要用于读取密集型场景
1414
+ 2. **混合存储策略**:频繁更新字段分离存储
1415
+ 3. **应用层处理**:复杂更新在应用层完成
1416
+ 4. **版本化管理**:重要数据支持历史版本
1417
+
1418
+ #### 6.2.2 具体实施方案
1419
+
1420
+ **方案一:JSON完整重构**
1421
+
1422
+ ```sql
1423
+ -- 适用于:简单JSON更新,更新频率低的场景
1424
+ UPDATE table_name
1425
+ SET json_column = parse_json(CONCAT(
1426
+ '{"field1": "', json_extract_string(json_column, "$.field1"), '", ',
1427
+ '"field2": "new_value", ',
1428
+ '"field3": ', json_extract_int(json_column, "$.field3"), '}'
1429
+ ))
1430
+ WHERE conditions;
1431
+ ```
1432
+
1433
+ **方案二:混合存储策略**
1434
+
1435
+ ```sql
1436
+ -- 推荐用于:有频繁更新需求的业务场景
1437
+ CREATE TABLE IF NOT EXISTS hybrid_table (
1438
+ id INT,
1439
+ frequently_updated_field STRING, -- 关系型字段
1440
+ status_field INT, -- 关系型字段
1441
+ stable_json_data JSON, -- JSON字段存储稳定数据
1442
+ last_updated TIMESTAMP
1443
+ );
1444
+ ```
1445
+
1446
+ **方案三:版本化存储**
1447
+
1448
+ ```sql
1449
+ -- 适用于:需要保留历史版本的重要数据
1450
+ CREATE TABLE IF NOT EXISTS versioned_json_data (
1451
+ record_id STRING,
1452
+ version_number INT,
1453
+ json_data JSON,
1454
+ created_time TIMESTAMP,
1455
+ is_current BOOLEAN DEFAULT TRUE
1456
+ );
1457
+ ```
1458
+
1459
+ ### 6.3 统一语法建议
1460
+
1461
+ 为了避免混合使用导致的问题,建议统一使用json\_extract函数:
1462
+
1463
+ ```sql
1464
+ -- 创建语法统一演示表
1465
+ CREATE TABLE IF NOT EXISTS syntax_demo (
1466
+ order_id STRING,
1467
+ data JSON
1468
+ );
1469
+
1470
+ -- 插入测试数据
1471
+ INSERT INTO syntax_demo VALUES
1472
+ ('ORD001', parse_json('{"customer": {"id": "C001", "name": "张三", "level": "VIP"}, "payment": {"amount": 1500.00}, "items": [{"qty": 2}]}')),
1473
+ ('ORD002', parse_json('{"customer": {"id": "C002", "name": "李四", "level": "regular"}, "payment": {"amount": 800.00}, "items": [{"qty": 1}]}')),
1474
+ ('ORD003', parse_json('{"customer": {"id": "C003", "name": "王五", "level": "VIP"}, "payment": {"amount": 2200.00}, "items": [{"qty": 3}]}'));
1475
+
1476
+ -- 推荐的统一语法模式
1477
+ SELECT
1478
+ order_id,
1479
+ json_extract_string(data, "$.customer.id") as customer_id,
1480
+ json_extract_string(data, "$.customer.name") as customer_name,
1481
+ json_extract_string(data, "$.customer.level") as customer_level,
1482
+ json_extract_double(data, "$.payment.amount") as amount,
1483
+ json_extract_int(data, "$.items[0].qty") as quantity
1484
+ FROM syntax_demo
1485
+ WHERE json_extract_string(data, "$.customer.level") = 'VIP'
1486
+ ORDER BY json_extract_double(data, "$.payment.amount") DESC;
1487
+ ```
1488
+
1489
+ ### 6.4 类型安全处理
1490
+
1491
+ #### 6.4.1 安全的默认值处理
1492
+
1493
+ ```sql
1494
+ -- 创建类型安全演示表
1495
+ CREATE TABLE IF NOT EXISTS type_safety_demo (
1496
+ order_id STRING,
1497
+ order_data JSON
1498
+ );
1499
+
1500
+ -- 插入包含缺失字段的数据
1501
+ INSERT INTO type_safety_demo VALUES
1502
+ ('ORD001', parse_json('{"customer": {"name": "张三", "vip_level": "gold"}, "payment": {"discount": 100}}')),
1503
+ ('ORD002', parse_json('{"customer": {"name": "李四"}, "payment": {}}')), -- 缺少vip_level和discount
1504
+ ('ORD003', parse_json('{"customer": {"name": "王五", "vip_level": "silver"}, "payment": {"discount": 50}}'));
1505
+
1506
+ -- 安全的默认值处理
1507
+ SELECT
1508
+ order_id,
1509
+ json_extract_string(order_data, "$.customer.name") as customer_name,
1510
+ -- 确保类型一致的默认值处理
1511
+ CASE WHEN json_extract_string(order_data, "$.customer.vip_level") IS NOT NULL
1512
+ THEN json_extract_string(order_data, "$.customer.vip_level")
1513
+ ELSE 'regular'
1514
+ END as safe_vip_level,
1515
+ -- 数值类型的安全处理
1516
+ CASE WHEN json_extract_double(order_data, "$.payment.discount") IS NOT NULL
1517
+ THEN json_extract_double(order_data, "$.payment.discount")
1518
+ ELSE 0.0
1519
+ END as safe_discount,
1520
+ -- 使用COALESCE简化默认值处理
1521
+ COALESCE(json_extract_string(order_data, "$.customer.vip_level"), 'regular') as vip_level_coalesce,
1522
+ COALESCE(json_extract_double(order_data, "$.payment.discount"), 0.0) as discount_coalesce
1523
+ FROM type_safety_demo;
1524
+ ```
1525
+
1526
+ ### 6.5 性能优化策略
1527
+
1528
+ #### 6.5.1 高频字段优化
1529
+
1530
+ ```sql
1531
+ -- 创建性能优化演示表
1532
+ CREATE TABLE IF NOT EXISTS perf_orders (
1533
+ id INT,
1534
+ order_data JSON,
1535
+ created_date DATE DEFAULT CURRENT_DATE()
1536
+ );
1537
+
1538
+ -- 插入测试数据
1539
+ INSERT INTO perf_orders VALUES
1540
+ (1, parse_json('{"customer_id": "C001", "payment_amount": 1500.00, "items": [{"detail": {"description": "高端电子产品"}}]}'), CURRENT_DATE()),
1541
+ (2, parse_json('{"customer_id": "C002", "payment_amount": 2300.00, "items": [{"detail": {"description": "家居用品"}}]}'), CURRENT_DATE()),
1542
+ (3, parse_json('{"customer_id": "C003", "payment_amount": 800.00, "items": [{"detail": {"description": "日用品"}}]}'), CURRENT_DATE()),
1543
+ (4, parse_json('{"customer_id": "C004", "payment_amount": 3200.00, "items": [{"detail": {"description": "奢侈品"}}]}'), CURRENT_DATE());
1544
+
1545
+ -- 将常用字段放在JSON顶层,利用自动列式存储优化
1546
+ SELECT
1547
+ json_extract_string(order_data, "$.customer_id") as customer_id, -- 高频字段
1548
+ json_extract_double(order_data, "$.payment_amount") as amount, -- 高频字段
1549
+ json_extract_string(order_data, "$.items[0].detail.description") as desc -- 深层字段
1550
+ FROM perf_orders
1551
+ WHERE json_extract_string(order_data, "$.customer_id") IS NOT NULL -- 高效过滤
1552
+ AND json_extract_double(order_data, "$.payment_amount") > 1000; -- 数值过滤
1553
+ ```
1554
+
1555
+ #### 6.5.2 批量提取优化
1556
+
1557
+ ```sql
1558
+ -- 创建批量优化演示表
1559
+ CREATE TABLE IF NOT EXISTS batch_orders (
1560
+ id INT,
1561
+ order_data JSON
1562
+ );
1563
+
1564
+ -- 插入更多测试数据
1565
+ INSERT INTO batch_orders VALUES
1566
+ (1, parse_json('{"customer": {"id": "C001", "level": "VIP"}, "payment": {"amount": 3500.00}}')),
1567
+ (2, parse_json('{"customer": {"id": "C002", "level": "regular"}, "payment": {"amount": 1200.00}}')),
1568
+ (3, parse_json('{"customer": {"id": "C003", "level": "VIP"}, "payment": {"amount": 4200.00}}')),
1569
+ (4, parse_json('{"customer": {"id": "C004", "level": "diamond"}, "payment": {"amount": 5800.00}}')),
1570
+ (5, parse_json('{"customer": {"id": "C005", "level": "regular"}, "payment": {"amount": 900.00}}'));
1571
+
1572
+ -- 使用CTE减少重复解析
1573
+ WITH extracted_data AS (
1574
+ SELECT
1575
+ id as order_id,
1576
+ json_extract_string(order_data, "$.customer.id") as customer_id,
1577
+ json_extract_string(order_data, "$.customer.level") as customer_level,
1578
+ json_extract_double(order_data, "$.payment.amount") as payment_amount
1579
+ FROM batch_orders
1580
+ WHERE json_extract_string(order_data, "$.customer.id") IS NOT NULL
1581
+ )
1582
+ SELECT
1583
+ customer_level,
1584
+ COUNT(*) as order_count,
1585
+ AVG(payment_amount) as avg_amount,
1586
+ MAX(payment_amount) as max_amount,
1587
+ MIN(payment_amount) as min_amount
1588
+ FROM extracted_data
1589
+ GROUP BY customer_level
1590
+ ORDER BY avg_amount DESC;
1591
+ ```
1592
+
1593
+ ***
1594
+
1595
+ ## 第七章:环境管理与实施建议
1596
+
1597
+ ### 7.1 实施前检查清单
1598
+
1599
+ #### 7.1.1 技术准备
1600
+
1601
+ * [ ] 验证字符编码设置(UTF-8)
1602
+ * [ ] 测试中文和emoji数据处理
1603
+ * [ ] 准备数据迁移方案
1604
+ * [ ] **新增:制定JSON数据更新策略**
1605
+
1606
+ #### 7.1.2 语法规范检查
1607
+
1608
+ * [ ] 确认所有CREATE语句包含IF NOT EXISTS
1609
+ * [ ] 验证不使用json\_set/json\_insert/json\_remove函数
1610
+ * [ ] 统一使用json\_extract函数而非直接JSON操作
1611
+ * [ ] 验证JSON类型不用于直接比较、排序、分组
1612
+ * [ ] **新增:设计混合存储架构**
1613
+
1614
+ #### 7.1.3 开发规范
1615
+
1616
+ * [ ] 制定JSON字段命名规范(推荐英文字段名)
1617
+ * [ ] 统一使用json\_extract函数
1618
+ * [ ] 建立错误处理和默认值处理标准
1619
+ * [ ] 设计性能监控指标
1620
+ * [ ] **新增:制定JSON数据更新的替代方案标准**
1621
+
1622
+ #### 7.1.4 验证测试
1623
+
1624
+ ```sql
1625
+ -- 创建系统验证表
1626
+ CREATE TABLE IF NOT EXISTS system_verification (
1627
+ test_id STRING,
1628
+ test_data JSON,
1629
+ test_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
1630
+ );
1631
+
1632
+ -- 基础功能验证
1633
+ INSERT INTO system_verification VALUES
1634
+ ('test_001', parse_json('{"basic_test": "基础功能测试", "emoji_test": "😊👍", "number_test": 123.45}'), CURRENT_TIMESTAMP()),
1635
+ ('test_002', parse_json('{"nested_test": {"level1": {"level2": "深层嵌套测试"}}, "array_test": ["数组", "测试", "项目"]}'), CURRENT_TIMESTAMP());
1636
+
1637
+ -- 验证查询
1638
+ SELECT
1639
+ test_id,
1640
+ json_extract_string(test_data, "$.basic_test") as basic_result,
1641
+ json_extract_string(test_data, "$.emoji_test") as emoji_result,
1642
+ json_extract_double(test_data, "$.number_test") as number_result,
1643
+ json_extract_string(test_data, "$.nested_test.level1.level2") as nested_result,
1644
+ json_extract_string(test_data, "$.array_test[0]") as array_result
1645
+ FROM system_verification
1646
+ ORDER BY test_time DESC;
1647
+ ```
1648
+
1649
+ ### 7.2 分阶段实施策略
1650
+
1651
+ 1. **概念验证阶段**:选择1-2个关键业务场景进行试点
1652
+ 2. **小规模部署**:在非核心业务系统中验证性能和稳定性
1653
+ 3. **架构优化阶段**:实施混合存储策略和JSON更新替代方案
1654
+ 4. **全面推广**:基于试点经验,制定完整的迁移计划
1655
+
1656
+ ```sql
1657
+ -- 实施阶段追踪表
1658
+ CREATE TABLE IF NOT EXISTS implementation_tracking (
1659
+ phase STRING,
1660
+ milestone STRING,
1661
+ status STRING,
1662
+ completion_date DATE,
1663
+ notes JSON
1664
+ );
1665
+
1666
+ -- 记录实施进度
1667
+ INSERT INTO implementation_tracking VALUES
1668
+ ('Phase1', '概念验证', 'completed', CURRENT_DATE(), parse_json('{"scenarios": ["电商订单分析", "用户行为追踪"], "success_rate": 0.95}')),
1669
+ ('Phase2', '小规模部署', 'in_progress', NULL, parse_json('{"target_systems": ["测试环境", "开发环境"], "expected_completion": "2024-12-15"}')),
1670
+ ('Phase3', '架构优化', 'planned', NULL, parse_json('{"focus": ["混合存储设计", "JSON更新替代方案"], "expected_start": "2024-12-20"}'));
1671
+ ```
1672
+
1673
+ ### 7.3 监控与运维
1674
+
1675
+ ```sql
1676
+ -- 创建运维监控表
1677
+ CREATE TABLE IF NOT EXISTS operational_monitoring (
1678
+ metric_name STRING,
1679
+ metric_value DOUBLE,
1680
+ metric_metadata JSON,
1681
+ measurement_time TIMESTAMP DEFAULT CURRENT_TIMESTAMP()
1682
+ );
1683
+
1684
+ -- 插入监控数据示例
1685
+ INSERT INTO operational_monitoring VALUES
1686
+ ('json_query_performance', 0.95, parse_json('{"avg_response_time_ms": 145, "query_count": 1000, "success_rate": 0.99}'), CURRENT_TIMESTAMP()),
1687
+ ('storage_efficiency', 0.87, parse_json('{"compression_ratio": 0.72, "storage_saved_gb": 250, "cost_reduction": 0.35}'), CURRENT_TIMESTAMP()),
1688
+ ('json_update_performance', 0.78, parse_json('{"avg_update_time_ms": 280, "update_success_rate": 0.95, "method": "json_reconstruction"}'), CURRENT_TIMESTAMP());
1689
+
1690
+ -- 性能监控查询模板
1691
+ SELECT
1692
+ metric_name,
1693
+ metric_value,
1694
+ json_extract_double(metric_metadata, "$.avg_response_time_ms") as avg_response_time,
1695
+ json_extract_int(metric_metadata, "$.query_count") as query_count,
1696
+ json_extract_double(metric_metadata, "$.success_rate") as success_rate,
1697
+ measurement_time
1698
+ FROM operational_monitoring
1699
+ WHERE metric_name = 'json_query_performance'
1700
+ ORDER BY measurement_time DESC;
1701
+ ```
1702
+
1703
+ ### 7.4 性能监控与调优
1704
+
1705
+ #### 7.4.1 JSON查询性能监控
1706
+
1707
+ ```sql
1708
+ -- 创建性能监控演示表
1709
+ CREATE TABLE IF NOT EXISTS performance_monitor (
1710
+ id INT,
1711
+ json_column JSON,
1712
+ created_date DATE DEFAULT CURRENT_DATE()
1713
+ );
1714
+
1715
+ -- 插入测试数据
1716
+ INSERT INTO performance_monitor VALUES
1717
+ (1, parse_json('{"frequently_accessed_field": "value1", "other_data": "test", "nested": {"deep": {"field": "deep_value1"}}}'), CURRENT_DATE()),
1718
+ (2, parse_json('{"frequently_accessed_field": "value2", "other_data": "test", "nested": {"deep": {"field": "deep_value2"}}}'), CURRENT_DATE() - INTERVAL 10 DAYS),
1719
+ (3, parse_json('{"frequently_accessed_field": "value1", "other_data": "test", "nested": {"deep": {"field": "deep_value3"}}}'), CURRENT_DATE() - INTERVAL 2 DAYS),
1720
+ (4, parse_json('{"frequently_accessed_field": "value3", "other_data": "test", "nested": {"deep": {"field": "deep_value4"}}}'), CURRENT_DATE()),
1721
+ (5, parse_json('{"frequently_accessed_field": "value2", "other_data": "test", "nested": {"deep": {"field": "deep_value5"}}}'), CURRENT_DATE() - INTERVAL 5 DAYS);
1722
+
1723
+ -- 查询性能分析模板
1724
+ SELECT
1725
+ 'performance_monitor' as table_name,
1726
+ COUNT(*) as total_records,
1727
+ AVG(LENGTH(CAST(json_column AS STRING))) as avg_json_size,
1728
+ -- 高频字段分布分析
1729
+ COUNT(DISTINCT json_extract_string(json_column, "$.frequently_accessed_field")) as unique_values,
1730
+ -- 数据热度分析
1731
+ COUNT(CASE WHEN created_date >= CURRENT_DATE() - INTERVAL 7 DAYS THEN 1 END) as recent_records,
1732
+ -- 字段访问复杂度分析
1733
+ COUNT(CASE WHEN json_extract_string(json_column, "$.nested.deep.field") IS NOT NULL THEN 1 END) as deep_nested_fields
1734
+ FROM performance_monitor
1735
+ WHERE json_column IS NOT NULL;
1736
+ ```
1737
+
1738
+ #### 7.4.2 自动优化建议生成
1739
+
1740
+ ```sql
1741
+ -- 创建优化建议演示表
1742
+ CREATE TABLE IF NOT EXISTS optimization_analysis (
1743
+ id INT,
1744
+ order_data JSON,
1745
+ created_date DATE DEFAULT CURRENT_DATE()
1746
+ );
1747
+
1748
+ -- 插入测试数据
1749
+ INSERT INTO optimization_analysis VALUES
1750
+ (1, parse_json('{"customer": {"level": "VIP"}, "payment": {"amount": 1500.00}}'), CURRENT_DATE()),
1751
+ (2, parse_json('{"customer": {"level": "regular"}, "payment": {"amount": 800.00}}'), CURRENT_DATE()),
1752
+ (3, parse_json('{"customer": {"level": "VIP"}, "payment": {"amount": 2200.00}}'), CURRENT_DATE()),
1753
+ (4, parse_json('{"customer": {"level": "diamond"}, "payment": {"amount": 5000.00}}'), CURRENT_DATE()),
1754
+ (5, parse_json('{"customer": {"level": "VIP"}, "payment": {"amount": 3200.00}}'), CURRENT_DATE()),
1755
+ (6, parse_json('{"customer": {"level": "regular"}, "payment": {"amount": 600.00}}'), CURRENT_DATE());
1756
+
1757
+ -- 基于使用模式的自动优化建议
1758
+ WITH query_pattern_analysis AS (
1759
+ SELECT
1760
+ json_extract_string(order_data, "$.customer.level") as access_pattern,
1761
+ COUNT(*) as usage_frequency,
1762
+ AVG(json_extract_double(order_data, "$.payment.amount")) as avg_amount
1763
+ FROM optimization_analysis
1764
+ GROUP BY json_extract_string(order_data, "$.customer.level")
1765
+ )
1766
+ SELECT
1767
+ access_pattern,
1768
+ usage_frequency,
1769
+ ROUND(avg_amount, 2) as avg_amount,
1770
+ CASE
1771
+ WHEN usage_frequency > 1000 THEN 'recommend_column_optimization'
1772
+ WHEN usage_frequency > 100 THEN 'consider_indexing'
1773
+ ELSE 'current_performance_sufficient'
1774
+ END as optimization_recommendation,
1775
+ CASE
1776
+ WHEN avg_amount > 3000 THEN 'high_value_customer_segment'
1777
+ WHEN avg_amount > 1500 THEN 'medium_value_customer_segment'
1778
+ ELSE 'low_value_customer_segment'
1779
+ END as business_insight
1780
+ FROM query_pattern_analysis
1781
+ ORDER BY usage_frequency DESC;
1782
+ ```
1783
+
1784
+ ### 7.5 环境清理
1785
+
1786
+ ```sql
1787
+ -- 查看所有创建的表
1788
+ SHOW TABLES LIKE '%json%';
1789
+
1790
+ -- 清理测试表(可选)
1791
+ /*
1792
+ DROP TABLE IF EXISTS orders;
1793
+ DROP TABLE IF EXISTS ecommerce_orders_json;
1794
+ DROP TABLE IF EXISTS promotion_orders_json;
1795
+ DROP TABLE IF EXISTS inventory_orders_json;
1796
+ DROP TABLE IF EXISTS iot_devices_unified;
1797
+ DROP TABLE IF EXISTS financial_risk_analysis;
1798
+ DROP TABLE IF EXISTS customer_behavior_analysis;
1799
+ DROP TABLE IF EXISTS device_maintenance_analysis;
1800
+ DROP TABLE IF EXISTS user_data_chinese;
1801
+ DROP TABLE IF EXISTS social_data_emoji;
1802
+ DROP TABLE IF EXISTS feedback_data_complex;
1803
+ DROP TABLE IF EXISTS user_feedback_full;
1804
+ DROP TABLE IF EXISTS best_practice_demo;
1805
+ DROP TABLE IF EXISTS chinese_field_demo;
1806
+ DROP TABLE IF EXISTS special_char_demo;
1807
+ DROP TABLE IF EXISTS troubleshoot_demo;
1808
+ DROP TABLE IF EXISTS limitation_demo;
1809
+ DROP TABLE IF EXISTS syntax_demo;
1810
+ DROP TABLE IF EXISTS type_safety_demo;
1811
+ DROP TABLE IF EXISTS perf_orders;
1812
+ DROP TABLE IF EXISTS batch_orders;
1813
+ DROP TABLE IF EXISTS performance_monitor;
1814
+ DROP TABLE IF EXISTS optimization_analysis;
1815
+ DROP TABLE IF EXISTS system_verification;
1816
+ DROP TABLE IF EXISTS implementation_tracking;
1817
+ DROP TABLE IF EXISTS operational_monitoring;
1818
+ DROP TABLE IF EXISTS transaction_demo;
1819
+ DROP TABLE IF EXISTS hybrid_storage_demo;
1820
+ */
1821
+
1822
+ -- 验证清理结果
1823
+ SELECT COUNT(*) as remaining_json_tables
1824
+ FROM information_schema.tables
1825
+ WHERE table_name LIKE '%json%';
1826
+ ```
1827
+
1828
+ ***
1829
+
1830
+ ## 总结
1831
+
1832
+ ### 核心价值总结
1833
+
1834
+ 云器Lakehouse JSON数据处理能力展现出以下核心价值:
1835
+
1836
+ #### 技术优势
1837
+
1838
+ * **原生JSON支持**:完全兼容标准JSON语法,json\_extract函数查询效率高
1839
+ * **智能存储优化**:根据JSON Schema将高频字段按列式存储
1840
+ * **实时处理能力**:动态表实现实时响应
1841
+ * **多语言支持**:完整支持中文、emoji等特殊字符
1842
+ * **企业级特性**:完整的弹性计算、多层缓存、集群隔离
1843
+
1844
+ #### 业务价值
1845
+
1846
+ * **电商领域**:实现个性化推荐系统,提升转化效果和用户体验
1847
+ * **IoT领域**:建立预测性维护体系,降低设备故障和维护成本
1848
+ * **金融领域**:构建实时风控引擎,增强风险管理和合规能力
1849
+
1850
+ #### 实施优势
1851
+
1852
+ * **快速上手**:基于标准SQL,开发效率显著提升
1853
+ * **平滑迁移**:无需重构现有JSON数据,直接导入使用
1854
+ * **扩展性强**:从GB到PB级数据无缝扩展,支持企业长期发展
1855
+
1856
+ ### 关键技术要点
1857
+
1858
+ #### 语法规范
1859
+
1860
+ * **统一使用json\_extract函数**:避免混合使用不同访问方式
1861
+ * **类型安全**:JSON类型不支持直接比较、排序、分组操作
1862
+ * **中文支持**:完全支持中文和emoji,建议使用英文字段名
1863
+ * **CREATE语句规范**:统一使用IF NOT EXISTS避免重复创建错误
1864
+ * **🚨 重要限制**:不支持json\_set函数
1865
+
1866
+ #### JSON更新策略
1867
+
1868
+ * **混合存储设计**:频繁更新字段用关系型,稳定数据用JSON
1869
+ * **应用层处理**:复杂JSON更新在应用层完成后整体替换
1870
+ * **版本控制**:重要JSON数据变更保留历史版本
1871
+ * **批量更新**:避免逐行JSON重构,优先批量处理
1872
+
1873
+ #### 性能优化
1874
+
1875
+ * **高频字段列式设计**:可显著提升查询效率
1876
+ * **多层缓存利用**:查询结果缓存、元数据缓存、计算集群本地缓存协同工作
1877
+ * **实时流处理**:动态表实现高效数据聚合
1878
+
1879
+ ### 行动建议
1880
+
1881
+ 1. **立即开始**:选择一个关键业务场景,启动JSON数据处理的概念验证
1882
+ 2. **架构设计**:制定混合存储策略,明确JSON使用边界
1883
+ 3. **团队培训**:组织技术团队学习本指南的最佳实践和语法规范
1884
+ 4. **逐步扩展**:基于试点成功经验,制定全面的JSON数据战略
1885
+ 5. **持续优化**:建立性能监控和优化机制,确保长期价值实现
1886
+
1887
+ ***
1888
+
1889
+ **云器Lakehouse JSON数据处理 - 在明确技术边界的前提下,让复杂JSON数据处理变得简单高效**
1890
+
1891
+ *本指南为企业JSON数据处理提供完整的解决方案,所有SQL语句均已通过云器Lakehouse实际验证。每个示例都包含完整的建表和数据准备语句,使用IF NOT EXISTS确保可重复执行。通过遵循本修正版的最佳实践,企业可以在明确技术边界的前提下,充分发挥JSON数据的业务价值,加速数字化转型进程*。
1892
+
1893
+ ## 参考
1894
+
1895
+ [JSON数据类型](JSON.md)
1896
+
1897
+ [JSON函数](json_function.md)
1898
+
1899
+ *注:本指南基于2025年5月的云器Lakehouse版本测试结果,后续版本可能有所变化。请定期检查官方文档以获取最新信息*。