SnowConvert AI – Netezza – CREATE TABLE

Übersetzung von Netezza in Snowflake

Beschreibung

Erstellt eine neue Tabelle in Netezza. Weitere Informationen dazu finden Sie in der Dokumentation zu CREATE TABLE.

Warnung

Diese Syntax wird in Snowflake teilweise unterstützt. Übersetzung für diese Tabellenoptionen ausstehend:

[ ORGANIZE ON { (<col>) | NONE } ]
[ ROW SECURITY ]
[ DATA_VERSION_RETENTION_TIME <number-of-days> ]
Copy

Grammatikalische Syntax

CREATE [ TEMPORARY | TEMP ] TABLE [IF NOT EXISTS] <table>
( <col> <type> [<col_constraint>][,<col> <type> [<col_constraint>]]
<table_constraint> [,<table_constraint> ] )
[ DISTRIBUTE ON { RANDOM | [HASH] (<col>[,<col>]) } ]
[ ORGANIZE ON { (<col>) | NONE } ]
[ ROW SECURITY ]
[ DATA_VERSION_RETENTION_TIME <number-of-days> ]
Copy

DISTRIBUTE ON RANDOM - DISTRIBUTE ON HASH

Bemerkung

Diese Syntax wird in Snowflake nicht benötigt.

Diese Klausel steuert, wie die Tabellendaten physisch über die Segmente des Systems verteilt werden. Da Snowflake die Datenspeicherung automatisch handhabt, werden diese Optionen bei der Migration entfernt.

Grammatikalische Syntax

DISTRIBUTE ON { RANDOM | [HASH] (<col>[,<col>]) }
Copy

Beispielhafte Quellcode-Muster

Eingabecode:

Greenplum
CREATE TABLE table1 (colum1 int, colum2 int, colum3 smallint, colum4 int )
DISTRIBUTE ON RANDOM;
Copy

Ausgabecode:

Snowflake
CREATE TABLE table1 (colum1 int, colum2 int, colum3 smallint, colum4 int )
COMMENT = '{ "origin": "sf_sc", "name": "snowconvert", "version": {  "major": 0,  "minor": 0,  "patch": "0" }, "attributes": {  "component": "netezza",  "convertedOn": "05/11/2025",  "domain": "test" }}'
;
Copy