summaryrefslogtreecommitdiffstats
path: root/docs/sqlglot/dialects/databricks.html
diff options
context:
space:
mode:
Diffstat (limited to 'docs/sqlglot/dialects/databricks.html')
-rw-r--r--docs/sqlglot/dialects/databricks.html83
1 files changed, 33 insertions, 50 deletions
diff --git a/docs/sqlglot/dialects/databricks.html b/docs/sqlglot/dialects/databricks.html
index c97eb16..3cd45cf 100644
--- a/docs/sqlglot/dialects/databricks.html
+++ b/docs/sqlglot/dialects/databricks.html
@@ -232,27 +232,19 @@
</span></pre></div>
- <div class="docstring"><p>Parser consumes a list of tokens produced by the <code><a href="../tokens.html#Tokenizer">sqlglot.tokens.Tokenizer</a></code> and produces
-a parsed syntax tree.</p>
+ <div class="docstring"><p>Parser consumes a list of tokens produced by the Tokenizer and produces a parsed syntax tree.</p>
<h6 id="arguments">Arguments:</h6>
<ul>
-<li><strong>error_level:</strong> the desired error level.
+<li><strong>error_level:</strong> The desired error level.
Default: ErrorLevel.IMMEDIATE</li>
-<li><strong>error_message_context:</strong> determines the amount of context to capture from a
+<li><strong>error_message_context:</strong> Determines the amount of context to capture from a
query string when displaying the error message (in number of characters).
-Default: 50.</li>
-<li><strong>index_offset:</strong> Index offset for arrays eg ARRAY[0] vs ARRAY[1] as the head of a list.
-Default: 0</li>
-<li><strong>alias_post_tablesample:</strong> If the table alias comes after tablesample.
-Default: False</li>
+Default: 100</li>
<li><strong>max_errors:</strong> Maximum number of error messages to include in a raised ParseError.
This is only relevant if error_level is ErrorLevel.RAISE.
Default: 3</li>
-<li><strong>null_ordering:</strong> Indicates the default null ordering method to use if not explicitly set.
-Options are "nulls_are_small", "nulls_are_large", "nulls_are_last".
-Default: "nulls_are_small"</li>
</ul>
</div>
@@ -304,49 +296,34 @@ Default: "nulls_are_small"</li>
</span></pre></div>
- <div class="docstring"><p>Generator interprets the given syntax tree and produces a SQL string as an output.</p>
+ <div class="docstring"><p>Generator converts a given syntax tree to the corresponding SQL string.</p>
<h6 id="arguments">Arguments:</h6>
<ul>
-<li><strong>time_mapping (dict):</strong> the dictionary of custom time mappings in which the key
-represents a python time format and the output the target time format</li>
-<li><strong>time_trie (trie):</strong> a trie of the time_mapping keys</li>
-<li><strong>pretty (bool):</strong> if set to True the returned string will be formatted. Default: False.</li>
-<li><strong>quote_start (str):</strong> specifies which starting character to use to delimit quotes. Default: '.</li>
-<li><strong>quote_end (str):</strong> specifies which ending character to use to delimit quotes. Default: '.</li>
-<li><strong>identifier_start (str):</strong> specifies which starting character to use to delimit identifiers. Default: ".</li>
-<li><strong>identifier_end (str):</strong> specifies which ending character to use to delimit identifiers. Default: ".</li>
-<li><strong>bit_start (str):</strong> specifies which starting character to use to delimit bit literals. Default: None.</li>
-<li><strong>bit_end (str):</strong> specifies which ending character to use to delimit bit literals. Default: None.</li>
-<li><strong>hex_start (str):</strong> specifies which starting character to use to delimit hex literals. Default: None.</li>
-<li><strong>hex_end (str):</strong> specifies which ending character to use to delimit hex literals. Default: None.</li>
-<li><strong>byte_start (str):</strong> specifies which starting character to use to delimit byte literals. Default: None.</li>
-<li><strong>byte_end (str):</strong> specifies which ending character to use to delimit byte literals. Default: None.</li>
-<li><strong>raw_start (str):</strong> specifies which starting character to use to delimit raw literals. Default: None.</li>
-<li><strong>raw_end (str):</strong> specifies which ending character to use to delimit raw literals. Default: None.</li>
-<li><strong>identify (bool | str):</strong> 'always': always quote, 'safe': quote identifiers if they don't contain an upcase, True defaults to always.</li>
-<li><strong>normalize (bool):</strong> if set to True all identifiers will lower cased</li>
-<li><strong>string_escape (str):</strong> specifies a string escape character. Default: '.</li>
-<li><strong>identifier_escape (str):</strong> specifies an identifier escape character. Default: ".</li>
-<li><strong>pad (int):</strong> determines padding in a formatted string. Default: 2.</li>
-<li><strong>indent (int):</strong> determines the size of indentation in a formatted string. Default: 4.</li>
-<li><strong>unnest_column_only (bool):</strong> if true unnest table aliases are considered only as column aliases</li>
-<li><strong>normalize_functions (str):</strong> normalize function names, "upper", "lower", or None
-Default: "upper"</li>
-<li><strong>alias_post_tablesample (bool):</strong> if the table alias comes after tablesample
-Default: False</li>
-<li><strong>identifiers_can_start_with_digit (bool):</strong> if an unquoted identifier can start with digit
-Default: False</li>
-<li><strong>unsupported_level (ErrorLevel):</strong> determines the generator's behavior when it encounters
-unsupported expressions. Default ErrorLevel.WARN.</li>
-<li><strong>null_ordering (str):</strong> Indicates the default null ordering method to use if not explicitly set.
-Options are "nulls_are_small", "nulls_are_large", "nulls_are_last".
-Default: "nulls_are_small"</li>
-<li><strong>max_unsupported (int):</strong> Maximum number of unsupported messages to include in a raised UnsupportedError.
+<li><strong>pretty:</strong> Whether or not to format the produced SQL string.
+Default: False.</li>
+<li><strong>identify:</strong> Determines when an identifier should be quoted. Possible values are:
+False (default): Never quote, except in cases where it's mandatory by the dialect.
+True or 'always': Always quote.
+'safe': Only quote identifiers that are case insensitive.</li>
+<li><strong>normalize:</strong> Whether or not to normalize identifiers to lowercase.
+Default: False.</li>
+<li><strong>pad:</strong> Determines the pad size in a formatted string.
+Default: 2.</li>
+<li><strong>indent:</strong> Determines the indentation size in a formatted string.
+Default: 2.</li>
+<li><strong>normalize_functions:</strong> Whether or not to normalize all function names. Possible values are:
+"upper" or True (default): Convert names to uppercase.
+"lower": Convert names to lowercase.
+False: Disables function name normalization.</li>
+<li><strong>unsupported_level:</strong> Determines the generator's behavior when it encounters unsupported expressions.
+Default ErrorLevel.WARN.</li>
+<li><strong>max_unsupported:</strong> Maximum number of unsupported messages to include in a raised UnsupportedError.
This is only relevant if unsupported_level is ErrorLevel.RAISE.
Default: 3</li>
-<li><strong>leading_comma (bool):</strong> if the the comma is leading or trailing in select statements
+<li><strong>leading_comma:</strong> Determines whether or not the comma is leading or trailing in select expressions.
+This is only relevant when generating in pretty mode.
Default: False</li>
<li><strong>max_text_width:</strong> The max number of characters in a segment before creating new lines in pretty mode.
The default is on the smaller end because the length only represents a segment and not the true
@@ -386,6 +363,7 @@ Default: True</li>
<dd id="Databricks.Generator.notnullcolumnconstraint_sql" class="function"><a href="../generator.html#Generator.notnullcolumnconstraint_sql">notnullcolumnconstraint_sql</a></dd>
<dd id="Databricks.Generator.primarykeycolumnconstraint_sql" class="function"><a href="../generator.html#Generator.primarykeycolumnconstraint_sql">primarykeycolumnconstraint_sql</a></dd>
<dd id="Databricks.Generator.uniquecolumnconstraint_sql" class="function"><a href="../generator.html#Generator.uniquecolumnconstraint_sql">uniquecolumnconstraint_sql</a></dd>
+ <dd id="Databricks.Generator.createable_sql" class="function"><a href="../generator.html#Generator.createable_sql">createable_sql</a></dd>
<dd id="Databricks.Generator.create_sql" class="function"><a href="../generator.html#Generator.create_sql">create_sql</a></dd>
<dd id="Databricks.Generator.clone_sql" class="function"><a href="../generator.html#Generator.clone_sql">clone_sql</a></dd>
<dd id="Databricks.Generator.describe_sql" class="function"><a href="../generator.html#Generator.describe_sql">describe_sql</a></dd>
@@ -466,9 +444,11 @@ Default: True</li>
<dd id="Databricks.Generator.ordered_sql" class="function"><a href="../generator.html#Generator.ordered_sql">ordered_sql</a></dd>
<dd id="Databricks.Generator.matchrecognize_sql" class="function"><a href="../generator.html#Generator.matchrecognize_sql">matchrecognize_sql</a></dd>
<dd id="Databricks.Generator.query_modifiers" class="function"><a href="../generator.html#Generator.query_modifiers">query_modifiers</a></dd>
+ <dd id="Databricks.Generator.offset_limit_modifiers" class="function"><a href="../generator.html#Generator.offset_limit_modifiers">offset_limit_modifiers</a></dd>
<dd id="Databricks.Generator.after_limit_modifiers" class="function"><a href="../generator.html#Generator.after_limit_modifiers">after_limit_modifiers</a></dd>
<dd id="Databricks.Generator.select_sql" class="function"><a href="../generator.html#Generator.select_sql">select_sql</a></dd>
<dd id="Databricks.Generator.schema_sql" class="function"><a href="../generator.html#Generator.schema_sql">schema_sql</a></dd>
+ <dd id="Databricks.Generator.schema_columns_sql" class="function"><a href="../generator.html#Generator.schema_columns_sql">schema_columns_sql</a></dd>
<dd id="Databricks.Generator.star_sql" class="function"><a href="../generator.html#Generator.star_sql">star_sql</a></dd>
<dd id="Databricks.Generator.parameter_sql" class="function"><a href="../generator.html#Generator.parameter_sql">parameter_sql</a></dd>
<dd id="Databricks.Generator.sessionparameter_sql" class="function"><a href="../generator.html#Generator.sessionparameter_sql">sessionparameter_sql</a></dd>
@@ -493,7 +473,7 @@ Default: True</li>
<dd id="Databricks.Generator.nextvaluefor_sql" class="function"><a href="../generator.html#Generator.nextvaluefor_sql">nextvaluefor_sql</a></dd>
<dd id="Databricks.Generator.extract_sql" class="function"><a href="../generator.html#Generator.extract_sql">extract_sql</a></dd>
<dd id="Databricks.Generator.trim_sql" class="function"><a href="../generator.html#Generator.trim_sql">trim_sql</a></dd>
- <dd id="Databricks.Generator.concat_sql" class="function"><a href="../generator.html#Generator.concat_sql">concat_sql</a></dd>
+ <dd id="Databricks.Generator.safeconcat_sql" class="function"><a href="../generator.html#Generator.safeconcat_sql">safeconcat_sql</a></dd>
<dd id="Databricks.Generator.check_sql" class="function"><a href="../generator.html#Generator.check_sql">check_sql</a></dd>
<dd id="Databricks.Generator.foreignkey_sql" class="function"><a href="../generator.html#Generator.foreignkey_sql">foreignkey_sql</a></dd>
<dd id="Databricks.Generator.primarykey_sql" class="function"><a href="../generator.html#Generator.primarykey_sql">primarykey_sql</a></dd>
@@ -543,6 +523,7 @@ Default: True</li>
<dd id="Databricks.Generator.respectnulls_sql" class="function"><a href="../generator.html#Generator.respectnulls_sql">respectnulls_sql</a></dd>
<dd id="Databricks.Generator.intdiv_sql" class="function"><a href="../generator.html#Generator.intdiv_sql">intdiv_sql</a></dd>
<dd id="Databricks.Generator.dpipe_sql" class="function"><a href="../generator.html#Generator.dpipe_sql">dpipe_sql</a></dd>
+ <dd id="Databricks.Generator.safedpipe_sql" class="function"><a href="../generator.html#Generator.safedpipe_sql">safedpipe_sql</a></dd>
<dd id="Databricks.Generator.div_sql" class="function"><a href="../generator.html#Generator.div_sql">div_sql</a></dd>
<dd id="Databricks.Generator.overlaps_sql" class="function"><a href="../generator.html#Generator.overlaps_sql">overlaps_sql</a></dd>
<dd id="Databricks.Generator.distance_sql" class="function"><a href="../generator.html#Generator.distance_sql">distance_sql</a></dd>
@@ -591,6 +572,7 @@ Default: True</li>
<dd id="Databricks.Generator.dictproperty_sql" class="function"><a href="../generator.html#Generator.dictproperty_sql">dictproperty_sql</a></dd>
<dd id="Databricks.Generator.dictrange_sql" class="function"><a href="../generator.html#Generator.dictrange_sql">dictrange_sql</a></dd>
<dd id="Databricks.Generator.dictsubproperty_sql" class="function"><a href="../generator.html#Generator.dictsubproperty_sql">dictsubproperty_sql</a></dd>
+ <dd id="Databricks.Generator.oncluster_sql" class="function"><a href="../generator.html#Generator.oncluster_sql">oncluster_sql</a></dd>
</div>
<div><dt><a href="spark.html#Spark.Generator">sqlglot.dialects.spark.Spark.Generator</a></dt>
@@ -641,6 +623,7 @@ Default: True</li>
<div><dt><a href="../tokens.html#Tokenizer">sqlglot.tokens.Tokenizer</a></dt>
<dd id="Databricks.Tokenizer.reset" class="function"><a href="../tokens.html#Tokenizer.reset">reset</a></dd>
<dd id="Databricks.Tokenizer.tokenize" class="function"><a href="../tokens.html#Tokenizer.tokenize">tokenize</a></dd>
+ <dd id="Databricks.Tokenizer.peek" class="function"><a href="../tokens.html#Tokenizer.peek">peek</a></dd>
</div>
</dl>