|
| 1 | += Compatibility between TigerGraph 2 and TigerGraph 3.0 |
| 2 | +:description: lists the compatibility issues between TigerGraph 2 and TigerGraph 3, for users who plan to migrate |
| 3 | + |
| 4 | +Major revisions (e.g., from TigerGraph 2 to TigerGraph 3) are the opportunity to deliver significant improvements. While we make every effort to maintain backward compatibility, in selected cases APIs have changed or deprecated features have been dropped, in order to advance the overall product. |
| 5 | + |
| 6 | +*Data migration*: A tool is available to migrate the data in TigerGraph 2.6 to TigerGraph 3.0. Please contact TigerGraph Support for assistance. |
| 7 | + |
| 8 | +*Query and API compatibility*: |
| 9 | + |
| 10 | +* Some gadmin syntax has changed. Notably. `gadmin set config` is now `gadmin config set`. |
| 11 | +Please see xref:system-management:management-with-gadmin.adoc[Managing with gadmin]. |
| 12 | +* Some features which were previously deprecated have been dropped. Please see xref:compatibility/.v3.0-removal-of-deprecated-features.adoc[V3.0 Removal of Previously Deprecated Features] for a detailed list. |
| 13 | +
|
| 14 | +== V3.0 Removal of Previously Deprecated Features |
| 15 | + |
| 16 | +TigerGraph 2.x contained some features which were labeled as deprecated. |
| 17 | +These features are no longer necessary because they have been superseded already by improved approaches for using the TigerGraph platform. |
| 18 | + |
| 19 | +The new approaches were developed because they use more consistent grammar, are more extensible, or offer higher performance. |
| 20 | +Therefore, TigerGraph 3.0 and above has streamlined the product by removing support for some of these deprecated features, listed below: |
| 21 | + |
| 22 | +==== Data Types |
| 23 | + |
| 24 | +|=== |
| 25 | +| Deprecated type | Alternate approach |
| 26 | + |
| 27 | +| `REAL` |
| 28 | +| Use `FLOAT` or `DOUBLE` |
| 29 | + |
| 30 | +| `INT_SET` |
| 31 | +| Use `SET<INT>` |
| 32 | + |
| 33 | +| `INT_LIST` |
| 34 | +| Use `LIST<INT>` |
| 35 | + |
| 36 | +| `STRING_SET_COMPRESS` |
| 37 | +| Use `SET<STRING COMPRESS>` |
| 38 | + |
| 39 | +| `STRING_LIST_CONPRESS` |
| 40 | +| Use `LIST<STRING COMPRESS>` |
| 41 | + |
| 42 | +| `UINT_SET` |
| 43 | +| Use `SET<INT>` |
| 44 | + |
| 45 | +| `UINT32_UINT32_KV_LIST` |
| 46 | +| Use `MAP<UINT, UINT>` |
| 47 | + |
| 48 | +| `INT32_INT32_KV_LIST` |
| 49 | +| Use `MAP<INT, INT>` |
| 50 | + |
| 51 | +| `UINT32_UDT_KV_LIST` |
| 52 | +| Use `MAP<UINT, UDT_type>`, where `UDT_type` is a user-defined tuple type |
| 53 | + |
| 54 | +| `INT32_UDT_KV_LIST` |
| 55 | +| Use `MAP<INT, UDT_type>`, where `UDT_type` is a user-defined tuple type |
| 56 | +|=== |
| 57 | + |
| 58 | +==== Syntax for Control Flow Statements |
| 59 | + |
| 60 | + |
| 61 | + |
| 62 | +|=== |
| 63 | +|Deprecated statement |Alternate statement |
| 64 | + |
| 65 | +|`FOREACH ... DO ... DONE` |
| 66 | +|`FOREACH... DO... END` |
| 67 | + |
| 68 | +a| |
| 69 | +---- |
| 70 | +FOREACH (condition) { |
| 71 | + body |
| 72 | +} |
| 73 | +---- |
| 74 | +a| |
| 75 | +---- |
| 76 | +FOREACH condition DO |
| 77 | + body |
| 78 | +END |
| 79 | +---- |
| 80 | + |
| 81 | +a| |
| 82 | +---- |
| 83 | +IF (condition) { |
| 84 | + body1 |
| 85 | +} |
| 86 | +else { |
| 87 | + body2 |
| 88 | +} |
| 89 | +---- |
| 90 | +a| |
| 91 | +---- |
| 92 | +IF condition THEN |
| 93 | + body1 |
| 94 | +ELSE |
| 95 | + body2 |
| 96 | +END |
| 97 | +---- |
| 98 | +a| |
| 99 | +---- |
| 100 | +WHILE (condition) { |
| 101 | + body |
| 102 | +} |
| 103 | +---- |
| 104 | +a| |
| 105 | +---- |
| 106 | +WHILE condition DO |
| 107 | + body |
| 108 | +END |
| 109 | +---- |
| 110 | +|=== |
| 111 | + |
| 112 | + |
| 113 | + |
| 114 | +==== Vertex set variable declaration |
| 115 | + |
| 116 | +See xref:{page-component-version}@gsql-ref:querying:declaration-and-assignment-statements.adoc#_vertex_set_variables[Vertex Set Variable Declaration and Assignment] |
| 117 | + |
| 118 | +If a vertex type is specified, the vertex type must be within parentheses. |
| 119 | + |
| 120 | +|=== |
| 121 | +| Deprecated Statement | Alternate Statement |
| 122 | + |
| 123 | +| `MySet Person = ...` |
| 124 | +| `MySet (Person) = ...` |
| 125 | +|=== |
| 126 | + |
| 127 | + |
| 128 | +==== Query, Job, and Token Management |
| 129 | + |
| 130 | + |
| 131 | + |
| 132 | +|=== |
| 133 | +|Deprecated operation |Header 2 |
| 134 | + |
| 135 | +|`CREATE JOB` |
| 136 | +a|Job types need to be specified: |
| 137 | + |
| 138 | +* `CREATE LOADING JOB` |
| 139 | +* `CREATE SCHEMA_CHANGE JOB` |
| 140 | +* `CREATE GLOBAL SCHEMA_CHANGE JOB` |
| 141 | + |
| 142 | +|`RUN JOB` |
| 143 | +a|Job types need to be specified: |
| 144 | + |
| 145 | +* `RUN LOADING JOB` |
| 146 | +* `RUN SCHEMA_CHANGE JOB` |
| 147 | +* `RUN GLOBAL SCHEMA_CHANGE JOB` |
| 148 | + |
| 149 | +|`CREATE / SHOW/ REFRESH TOKEN` |
| 150 | +|To create a token, use the xref:API:built-in-endpoints.adoc#_request_a_token[REST endpoint GET /requesttoken]. |
| 151 | + |
| 152 | +|`offline2online` |
| 153 | +|The offline loading job mode was discontinued in v2.0. |
| 154 | +Do not write loading jobs using this syntax. |
| 155 | +|=== |
| 156 | + |
| 157 | + |
| 158 | + |
| 159 | +==== Output |
| 160 | + |
| 161 | +See xref:{page-component-version}@gsql-ref:querying:output-statements-and-file-objects.adoc#_print_statement_api_v2[PRINT Statement] |
| 162 | + |
| 163 | +|=== |
| 164 | +| Deprecated Syntax | Alternate Syntax |
| 165 | + |
| 166 | +| JSON API v1 |
| 167 | +| v2 has been the default JSON format since TigerGraph 1.1. No alternate JSON version will be available. |
| 168 | + |
| 169 | +| `PRINT ... TO_CSV [filepath]` |
| 170 | +| Define a file object, then `PRINT ... TO_CSV [file_object]` |
| 171 | +|=== |
| 172 | + |
| 173 | + |
| 174 | +==== Built-in Queries |
| 175 | + |
| 176 | +[Run Built-in Queries in 'GSQL 101'] |
| 177 | + |
| 178 | + |
| 179 | +|=== |
| 180 | +|Deprecated statement |Alternate statement |
| 181 | + |
| 182 | +|`SELECT count() FROM ...` |
| 183 | +a| |
| 184 | +* `SELECT approx_count(*) FROM ...` |
| 185 | +** May not include all the latest data updates |
| 186 | +* `SELECT count(*) FROM ...` |
| 187 | +** exact, but slower than `approx_count(*)` |
| 188 | +|=== |
0 commit comments