arrow_flight/sql/arrow.flight.protocol.sql.rs
1// This file was automatically generated through the build.rs script, and should not be edited.
2
3// This file is @generated by prost-build.
4///
5/// Represents a metadata request. Used in the command member of FlightDescriptor
6/// for the following RPC calls:
7/// - GetSchema: return the Arrow schema of the query.
8/// - GetFlightInfo: execute the metadata request.
9///
10/// The returned Arrow schema will be:
11/// <
12/// info_name: uint32 not null,
13/// value: dense_union<
14/// string_value: utf8,
15/// bool_value: bool,
16/// bigint_value: int64,
17/// int32_bitmask: int32,
18/// string_list: list<string_data: utf8>
19/// int32_to_int32_list_map: map<key: int32, value: list<$data$: int32>>
20/// >
21/// where there is one row per requested piece of metadata information.
22#[derive(Clone, PartialEq, ::prost::Message)]
23pub struct CommandGetSqlInfo {
24 ///
25 /// Values are modelled after ODBC's SQLGetInfo() function. This information is intended to provide
26 /// Flight SQL clients with basic, SQL syntax and SQL functions related information.
27 /// More information types can be added in future releases.
28 /// E.g. more SQL syntax support types, scalar functions support, type conversion support etc.
29 ///
30 /// Note that the set of metadata may expand.
31 ///
32 /// Initially, Flight SQL will support the following information types:
33 /// - Server Information - Range [0-500)
34 /// - Syntax Information - Range [500-1000)
35 /// Range [0-10,000) is reserved for defaults (see SqlInfo enum for default options).
36 /// Custom options should start at 10,000.
37 ///
38 /// If omitted, then all metadata will be retrieved.
39 /// Flight SQL Servers may choose to include additional metadata above and beyond the specified set, however they must
40 /// at least return the specified set. IDs ranging from 0 to 10,000 (exclusive) are reserved for future use.
41 /// If additional metadata is included, the metadata IDs should start from 10,000.
42 #[prost(uint32, repeated, tag = "1")]
43 pub info: ::prost::alloc::vec::Vec<u32>,
44}
45///
46/// Represents a request to retrieve information about data type supported on a Flight SQL enabled backend.
47/// Used in the command member of FlightDescriptor for the following RPC calls:
48/// - GetSchema: return the schema of the query.
49/// - GetFlightInfo: execute the catalog metadata request.
50///
51/// The returned schema will be:
52/// <
53/// type_name: utf8 not null (The name of the data type, for example: VARCHAR, INTEGER, etc),
54/// data_type: int32 not null (The SQL data type),
55/// column_size: int32 (The maximum size supported by that column.
56/// In case of exact numeric types, this represents the maximum precision.
57/// In case of string types, this represents the character length.
58/// In case of datetime data types, this represents the length in characters of the string representation.
59/// NULL is returned for data types where column size is not applicable.),
60/// literal_prefix: utf8 (Character or characters used to prefix a literal, NULL is returned for
61/// data types where a literal prefix is not applicable.),
62/// literal_suffix: utf8 (Character or characters used to terminate a literal,
63/// NULL is returned for data types where a literal suffix is not applicable.),
64/// create_params: list<utf8 not null>
65/// (A list of keywords corresponding to which parameters can be used when creating
66/// a column for that specific type.
67/// NULL is returned if there are no parameters for the data type definition.),
68/// nullable: int32 not null (Shows if the data type accepts a NULL value. The possible values can be seen in the
69/// Nullable enum.),
70/// case_sensitive: bool not null (Shows if a character data type is case-sensitive in collations and comparisons),
71/// searchable: int32 not null (Shows how the data type is used in a WHERE clause. The possible values can be seen in the
72/// Searchable enum.),
73/// unsigned_attribute: bool (Shows if the data type is unsigned. NULL is returned if the attribute is
74/// not applicable to the data type or the data type is not numeric.),
75/// fixed_prec_scale: bool not null (Shows if the data type has predefined fixed precision and scale.),
76/// auto_increment: bool (Shows if the data type is auto incremental. NULL is returned if the attribute
77/// is not applicable to the data type or the data type is not numeric.),
78/// local_type_name: utf8 (Localized version of the data source-dependent name of the data type. NULL
79/// is returned if a localized name is not supported by the data source),
80/// minimum_scale: int32 (The minimum scale of the data type on the data source.
81/// If a data type has a fixed scale, the MINIMUM_SCALE and MAXIMUM_SCALE
82/// columns both contain this value. NULL is returned if scale is not applicable.),
83/// maximum_scale: int32 (The maximum scale of the data type on the data source.
84/// NULL is returned if scale is not applicable.),
85/// sql_data_type: int32 not null (The value of the SQL DATA TYPE which has the same values
86/// as data_type value. Except for interval and datetime, which
87/// uses generic values. More info about those types can be
88/// obtained through datetime_subcode. The possible values can be seen
89/// in the XdbcDataType enum.),
90/// datetime_subcode: int32 (Only used when the SQL DATA TYPE is interval or datetime. It contains
91/// its sub types. For type different from interval and datetime, this value
92/// is NULL. The possible values can be seen in the XdbcDatetimeSubcode enum.),
93/// num_prec_radix: int32 (If the data type is an approximate numeric type, this column contains
94/// the value 2 to indicate that COLUMN_SIZE specifies a number of bits. For
95/// exact numeric types, this column contains the value 10 to indicate that
96/// column size specifies a number of decimal digits. Otherwise, this column is NULL.),
97/// interval_precision: int32 (If the data type is an interval data type, then this column contains the value
98/// of the interval leading precision. Otherwise, this column is NULL. This fields
99/// is only relevant to be used by ODBC).
100/// >
101/// The returned data should be ordered by data_type and then by type_name.
102#[derive(Clone, Copy, PartialEq, ::prost::Message)]
103pub struct CommandGetXdbcTypeInfo {
104 ///
105 /// Specifies the data type to search for the info.
106 #[prost(int32, optional, tag = "1")]
107 pub data_type: ::core::option::Option<i32>,
108}
109///
110/// Represents a request to retrieve the list of catalogs on a Flight SQL enabled backend.
111/// The definition of a catalog depends on vendor/implementation. It is usually the database itself
112/// Used in the command member of FlightDescriptor for the following RPC calls:
113/// - GetSchema: return the Arrow schema of the query.
114/// - GetFlightInfo: execute the catalog metadata request.
115///
116/// The returned Arrow schema will be:
117/// <
118/// catalog_name: utf8 not null
119/// >
120/// The returned data should be ordered by catalog_name.
121#[derive(Clone, Copy, PartialEq, ::prost::Message)]
122pub struct CommandGetCatalogs {}
123///
124/// Represents a request to retrieve the list of database schemas on a Flight SQL enabled backend.
125/// The definition of a database schema depends on vendor/implementation. It is usually a collection of tables.
126/// Used in the command member of FlightDescriptor for the following RPC calls:
127/// - GetSchema: return the Arrow schema of the query.
128/// - GetFlightInfo: execute the catalog metadata request.
129///
130/// The returned Arrow schema will be:
131/// <
132/// catalog_name: utf8,
133/// db_schema_name: utf8 not null
134/// >
135/// The returned data should be ordered by catalog_name, then db_schema_name.
136#[derive(Clone, PartialEq, ::prost::Message)]
137pub struct CommandGetDbSchemas {
138 ///
139 /// Specifies the Catalog to search for the tables.
140 /// An empty string retrieves those without a catalog.
141 /// If omitted the catalog name should not be used to narrow the search.
142 #[prost(string, optional, tag = "1")]
143 pub catalog: ::core::option::Option<::prost::alloc::string::String>,
144 ///
145 /// Specifies a filter pattern for schemas to search for.
146 /// When no db_schema_filter_pattern is provided, the pattern will not be used to narrow the search.
147 /// In the pattern string, two special characters can be used to denote matching rules:
148 /// - "%" means to match any substring with 0 or more characters.
149 /// - "_" means to match any one character.
150 #[prost(string, optional, tag = "2")]
151 pub db_schema_filter_pattern: ::core::option::Option<::prost::alloc::string::String>,
152}
153///
154/// Represents a request to retrieve the list of tables, and optionally their schemas, on a Flight SQL enabled backend.
155/// Used in the command member of FlightDescriptor for the following RPC calls:
156/// - GetSchema: return the Arrow schema of the query.
157/// - GetFlightInfo: execute the catalog metadata request.
158///
159/// The returned Arrow schema will be:
160/// <
161/// catalog_name: utf8,
162/// db_schema_name: utf8,
163/// table_name: utf8 not null,
164/// table_type: utf8 not null,
165/// \[optional\] table_schema: bytes not null (schema of the table as described in Schema.fbs::Schema,
166/// it is serialized as an IPC message.)
167/// >
168/// Fields on table_schema may contain the following metadata:
169/// - ARROW:FLIGHT:SQL:CATALOG_NAME - Table's catalog name
170/// - ARROW:FLIGHT:SQL:DB_SCHEMA_NAME - Database schema name
171/// - ARROW:FLIGHT:SQL:TABLE_NAME - Table name
172/// - ARROW:FLIGHT:SQL:TYPE_NAME - The data source-specific name for the data type of the column.
173/// - ARROW:FLIGHT:SQL:PRECISION - Column precision/size
174/// - ARROW:FLIGHT:SQL:SCALE - Column scale/decimal digits if applicable
175/// - ARROW:FLIGHT:SQL:IS_AUTO_INCREMENT - "1" indicates if the column is auto incremented, "0" otherwise.
176/// - ARROW:FLIGHT:SQL:IS_CASE_SENSITIVE - "1" indicates if the column is case-sensitive, "0" otherwise.
177/// - ARROW:FLIGHT:SQL:IS_READ_ONLY - "1" indicates if the column is read only, "0" otherwise.
178/// - ARROW:FLIGHT:SQL:IS_SEARCHABLE - "1" indicates if the column is searchable via WHERE clause, "0" otherwise.
179/// The returned data should be ordered by catalog_name, db_schema_name, table_name, then table_type, followed by table_schema if requested.
180#[derive(Clone, PartialEq, ::prost::Message)]
181pub struct CommandGetTables {
182 ///
183 /// Specifies the Catalog to search for the tables.
184 /// An empty string retrieves those without a catalog.
185 /// If omitted the catalog name should not be used to narrow the search.
186 #[prost(string, optional, tag = "1")]
187 pub catalog: ::core::option::Option<::prost::alloc::string::String>,
188 ///
189 /// Specifies a filter pattern for schemas to search for.
190 /// When no db_schema_filter_pattern is provided, all schemas matching other filters are searched.
191 /// In the pattern string, two special characters can be used to denote matching rules:
192 /// - "%" means to match any substring with 0 or more characters.
193 /// - "_" means to match any one character.
194 #[prost(string, optional, tag = "2")]
195 pub db_schema_filter_pattern: ::core::option::Option<::prost::alloc::string::String>,
196 ///
197 /// Specifies a filter pattern for tables to search for.
198 /// When no table_name_filter_pattern is provided, all tables matching other filters are searched.
199 /// In the pattern string, two special characters can be used to denote matching rules:
200 /// - "%" means to match any substring with 0 or more characters.
201 /// - "_" means to match any one character.
202 #[prost(string, optional, tag = "3")]
203 pub table_name_filter_pattern: ::core::option::Option<
204 ::prost::alloc::string::String,
205 >,
206 ///
207 /// Specifies a filter of table types which must match.
208 /// The table types depend on vendor/implementation. It is usually used to separate tables from views or system tables.
209 /// TABLE, VIEW, and SYSTEM TABLE are commonly supported.
210 #[prost(string, repeated, tag = "4")]
211 pub table_types: ::prost::alloc::vec::Vec<::prost::alloc::string::String>,
212 /// Specifies if the Arrow schema should be returned for found tables.
213 #[prost(bool, tag = "5")]
214 pub include_schema: bool,
215}
216///
217/// Represents a request to retrieve the list of table types on a Flight SQL enabled backend.
218/// The table types depend on vendor/implementation. It is usually used to separate tables from views or system tables.
219/// TABLE, VIEW, and SYSTEM TABLE are commonly supported.
220/// Used in the command member of FlightDescriptor for the following RPC calls:
221/// - GetSchema: return the Arrow schema of the query.
222/// - GetFlightInfo: execute the catalog metadata request.
223///
224/// The returned Arrow schema will be:
225/// <
226/// table_type: utf8 not null
227/// >
228/// The returned data should be ordered by table_type.
229#[derive(Clone, Copy, PartialEq, ::prost::Message)]
230pub struct CommandGetTableTypes {}
231///
232/// Represents a request to retrieve the primary keys of a table on a Flight SQL enabled backend.
233/// Used in the command member of FlightDescriptor for the following RPC calls:
234/// - GetSchema: return the Arrow schema of the query.
235/// - GetFlightInfo: execute the catalog metadata request.
236///
237/// The returned Arrow schema will be:
238/// <
239/// catalog_name: utf8,
240/// db_schema_name: utf8,
241/// table_name: utf8 not null,
242/// column_name: utf8 not null,
243/// key_name: utf8,
244/// key_sequence: int32 not null
245/// >
246/// The returned data should be ordered by catalog_name, db_schema_name, table_name, key_name, then key_sequence.
247#[derive(Clone, PartialEq, ::prost::Message)]
248pub struct CommandGetPrimaryKeys {
249 ///
250 /// Specifies the catalog to search for the table.
251 /// An empty string retrieves those without a catalog.
252 /// If omitted the catalog name should not be used to narrow the search.
253 #[prost(string, optional, tag = "1")]
254 pub catalog: ::core::option::Option<::prost::alloc::string::String>,
255 ///
256 /// Specifies the schema to search for the table.
257 /// An empty string retrieves those without a schema.
258 /// If omitted the schema name should not be used to narrow the search.
259 #[prost(string, optional, tag = "2")]
260 pub db_schema: ::core::option::Option<::prost::alloc::string::String>,
261 /// Specifies the table to get the primary keys for.
262 #[prost(string, tag = "3")]
263 pub table: ::prost::alloc::string::String,
264}
265///
266/// Represents a request to retrieve a description of the foreign key columns that reference the given table's
267/// primary key columns (the foreign keys exported by a table) of a table on a Flight SQL enabled backend.
268/// Used in the command member of FlightDescriptor for the following RPC calls:
269/// - GetSchema: return the Arrow schema of the query.
270/// - GetFlightInfo: execute the catalog metadata request.
271///
272/// The returned Arrow schema will be:
273/// <
274/// pk_catalog_name: utf8,
275/// pk_db_schema_name: utf8,
276/// pk_table_name: utf8 not null,
277/// pk_column_name: utf8 not null,
278/// fk_catalog_name: utf8,
279/// fk_db_schema_name: utf8,
280/// fk_table_name: utf8 not null,
281/// fk_column_name: utf8 not null,
282/// key_sequence: int32 not null,
283/// fk_key_name: utf8,
284/// pk_key_name: utf8,
285/// update_rule: uint8 not null,
286/// delete_rule: uint8 not null
287/// >
288/// The returned data should be ordered by fk_catalog_name, fk_db_schema_name, fk_table_name, fk_key_name, then key_sequence.
289/// update_rule and delete_rule returns a byte that is equivalent to actions declared on UpdateDeleteRules enum.
290#[derive(Clone, PartialEq, ::prost::Message)]
291pub struct CommandGetExportedKeys {
292 ///
293 /// Specifies the catalog to search for the foreign key table.
294 /// An empty string retrieves those without a catalog.
295 /// If omitted the catalog name should not be used to narrow the search.
296 #[prost(string, optional, tag = "1")]
297 pub catalog: ::core::option::Option<::prost::alloc::string::String>,
298 ///
299 /// Specifies the schema to search for the foreign key table.
300 /// An empty string retrieves those without a schema.
301 /// If omitted the schema name should not be used to narrow the search.
302 #[prost(string, optional, tag = "2")]
303 pub db_schema: ::core::option::Option<::prost::alloc::string::String>,
304 /// Specifies the foreign key table to get the foreign keys for.
305 #[prost(string, tag = "3")]
306 pub table: ::prost::alloc::string::String,
307}
308///
309/// Represents a request to retrieve the foreign keys of a table on a Flight SQL enabled backend.
310/// Used in the command member of FlightDescriptor for the following RPC calls:
311/// - GetSchema: return the Arrow schema of the query.
312/// - GetFlightInfo: execute the catalog metadata request.
313///
314/// The returned Arrow schema will be:
315/// <
316/// pk_catalog_name: utf8,
317/// pk_db_schema_name: utf8,
318/// pk_table_name: utf8 not null,
319/// pk_column_name: utf8 not null,
320/// fk_catalog_name: utf8,
321/// fk_db_schema_name: utf8,
322/// fk_table_name: utf8 not null,
323/// fk_column_name: utf8 not null,
324/// key_sequence: int32 not null,
325/// fk_key_name: utf8,
326/// pk_key_name: utf8,
327/// update_rule: uint8 not null,
328/// delete_rule: uint8 not null
329/// >
330/// The returned data should be ordered by pk_catalog_name, pk_db_schema_name, pk_table_name, pk_key_name, then key_sequence.
331/// update_rule and delete_rule returns a byte that is equivalent to actions:
332/// - 0 = CASCADE
333/// - 1 = RESTRICT
334/// - 2 = SET NULL
335/// - 3 = NO ACTION
336/// - 4 = SET DEFAULT
337#[derive(Clone, PartialEq, ::prost::Message)]
338pub struct CommandGetImportedKeys {
339 ///
340 /// Specifies the catalog to search for the primary key table.
341 /// An empty string retrieves those without a catalog.
342 /// If omitted the catalog name should not be used to narrow the search.
343 #[prost(string, optional, tag = "1")]
344 pub catalog: ::core::option::Option<::prost::alloc::string::String>,
345 ///
346 /// Specifies the schema to search for the primary key table.
347 /// An empty string retrieves those without a schema.
348 /// If omitted the schema name should not be used to narrow the search.
349 #[prost(string, optional, tag = "2")]
350 pub db_schema: ::core::option::Option<::prost::alloc::string::String>,
351 /// Specifies the primary key table to get the foreign keys for.
352 #[prost(string, tag = "3")]
353 pub table: ::prost::alloc::string::String,
354}
355///
356/// Represents a request to retrieve a description of the foreign key columns in the given foreign key table that
357/// reference the primary key or the columns representing a unique constraint of the parent table (could be the same
358/// or a different table) on a Flight SQL enabled backend.
359/// Used in the command member of FlightDescriptor for the following RPC calls:
360/// - GetSchema: return the Arrow schema of the query.
361/// - GetFlightInfo: execute the catalog metadata request.
362///
363/// The returned Arrow schema will be:
364/// <
365/// pk_catalog_name: utf8,
366/// pk_db_schema_name: utf8,
367/// pk_table_name: utf8 not null,
368/// pk_column_name: utf8 not null,
369/// fk_catalog_name: utf8,
370/// fk_db_schema_name: utf8,
371/// fk_table_name: utf8 not null,
372/// fk_column_name: utf8 not null,
373/// key_sequence: int32 not null,
374/// fk_key_name: utf8,
375/// pk_key_name: utf8,
376/// update_rule: uint8 not null,
377/// delete_rule: uint8 not null
378/// >
379/// The returned data should be ordered by pk_catalog_name, pk_db_schema_name, pk_table_name, pk_key_name, then key_sequence.
380/// update_rule and delete_rule returns a byte that is equivalent to actions:
381/// - 0 = CASCADE
382/// - 1 = RESTRICT
383/// - 2 = SET NULL
384/// - 3 = NO ACTION
385/// - 4 = SET DEFAULT
386#[derive(Clone, PartialEq, ::prost::Message)]
387pub struct CommandGetCrossReference {
388 /// *
389 /// The catalog name where the parent table is.
390 /// An empty string retrieves those without a catalog.
391 /// If omitted the catalog name should not be used to narrow the search.
392 #[prost(string, optional, tag = "1")]
393 pub pk_catalog: ::core::option::Option<::prost::alloc::string::String>,
394 /// *
395 /// The Schema name where the parent table is.
396 /// An empty string retrieves those without a schema.
397 /// If omitted the schema name should not be used to narrow the search.
398 #[prost(string, optional, tag = "2")]
399 pub pk_db_schema: ::core::option::Option<::prost::alloc::string::String>,
400 /// *
401 /// The parent table name. It cannot be null.
402 #[prost(string, tag = "3")]
403 pub pk_table: ::prost::alloc::string::String,
404 /// *
405 /// The catalog name where the foreign table is.
406 /// An empty string retrieves those without a catalog.
407 /// If omitted the catalog name should not be used to narrow the search.
408 #[prost(string, optional, tag = "4")]
409 pub fk_catalog: ::core::option::Option<::prost::alloc::string::String>,
410 /// *
411 /// The schema name where the foreign table is.
412 /// An empty string retrieves those without a schema.
413 /// If omitted the schema name should not be used to narrow the search.
414 #[prost(string, optional, tag = "5")]
415 pub fk_db_schema: ::core::option::Option<::prost::alloc::string::String>,
416 /// *
417 /// The foreign table name. It cannot be null.
418 #[prost(string, tag = "6")]
419 pub fk_table: ::prost::alloc::string::String,
420}
421///
422/// Request message for the "CreatePreparedStatement" action on a Flight SQL enabled backend.
423#[derive(Clone, PartialEq, ::prost::Message)]
424pub struct ActionCreatePreparedStatementRequest {
425 /// The valid SQL string to create a prepared statement for.
426 #[prost(string, tag = "1")]
427 pub query: ::prost::alloc::string::String,
428 /// Create/execute the prepared statement as part of this transaction (if
429 /// unset, executions of the prepared statement will be auto-committed).
430 #[prost(bytes = "bytes", optional, tag = "2")]
431 pub transaction_id: ::core::option::Option<::prost::bytes::Bytes>,
432}
433///
434/// An embedded message describing a Substrait plan to execute.
435#[derive(Clone, PartialEq, ::prost::Message)]
436pub struct SubstraitPlan {
437 /// The serialized substrait.Plan to create a prepared statement for.
438 /// XXX(ARROW-16902): this is bytes instead of an embedded message
439 /// because Protobuf does not really support one DLL using Protobuf
440 /// definitions from another DLL.
441 #[prost(bytes = "bytes", tag = "1")]
442 pub plan: ::prost::bytes::Bytes,
443 /// The Substrait release, e.g. "0.12.0". This information is not
444 /// tracked in the plan itself, so this is the only way for consumers
445 /// to potentially know if they can handle the plan.
446 #[prost(string, tag = "2")]
447 pub version: ::prost::alloc::string::String,
448}
449///
450/// Request message for the "CreatePreparedSubstraitPlan" action on a Flight SQL enabled backend.
451#[derive(Clone, PartialEq, ::prost::Message)]
452pub struct ActionCreatePreparedSubstraitPlanRequest {
453 /// The serialized substrait.Plan to create a prepared statement for.
454 #[prost(message, optional, tag = "1")]
455 pub plan: ::core::option::Option<SubstraitPlan>,
456 /// Create/execute the prepared statement as part of this transaction (if
457 /// unset, executions of the prepared statement will be auto-committed).
458 #[prost(bytes = "bytes", optional, tag = "2")]
459 pub transaction_id: ::core::option::Option<::prost::bytes::Bytes>,
460}
461///
462/// Wrap the result of a "CreatePreparedStatement" or "CreatePreparedSubstraitPlan" action.
463///
464/// The resultant PreparedStatement can be closed either:
465/// - Manually, through the "ClosePreparedStatement" action;
466/// - Automatically, by a server timeout.
467///
468/// The result should be wrapped in a google.protobuf.Any message.
469#[derive(Clone, PartialEq, ::prost::Message)]
470pub struct ActionCreatePreparedStatementResult {
471 /// Opaque handle for the prepared statement on the server.
472 #[prost(bytes = "bytes", tag = "1")]
473 pub prepared_statement_handle: ::prost::bytes::Bytes,
474 /// If a result set generating query was provided, dataset_schema contains the
475 /// schema of the result set. It should be an IPC-encapsulated Schema, as described in Schema.fbs.
476 /// For some queries, the schema of the results may depend on the schema of the parameters. The server
477 /// should provide its best guess as to the schema at this point. Clients must not assume that this
478 /// schema, if provided, will be accurate.
479 #[prost(bytes = "bytes", tag = "2")]
480 pub dataset_schema: ::prost::bytes::Bytes,
481 /// If the query provided contained parameters, parameter_schema contains the
482 /// schema of the expected parameters. It should be an IPC-encapsulated Schema, as described in Schema.fbs.
483 #[prost(bytes = "bytes", tag = "3")]
484 pub parameter_schema: ::prost::bytes::Bytes,
485}
486///
487/// Request message for the "ClosePreparedStatement" action on a Flight SQL enabled backend.
488/// Closes server resources associated with the prepared statement handle.
489#[derive(Clone, PartialEq, ::prost::Message)]
490pub struct ActionClosePreparedStatementRequest {
491 /// Opaque handle for the prepared statement on the server.
492 #[prost(bytes = "bytes", tag = "1")]
493 pub prepared_statement_handle: ::prost::bytes::Bytes,
494}
495///
496/// Request message for the "BeginTransaction" action.
497/// Begins a transaction.
498#[derive(Clone, Copy, PartialEq, ::prost::Message)]
499pub struct ActionBeginTransactionRequest {}
500///
501/// Request message for the "BeginSavepoint" action.
502/// Creates a savepoint within a transaction.
503///
504/// Only supported if FLIGHT_SQL_TRANSACTION is
505/// FLIGHT_SQL_TRANSACTION_SUPPORT_SAVEPOINT.
506#[derive(Clone, PartialEq, ::prost::Message)]
507pub struct ActionBeginSavepointRequest {
508 /// The transaction to which a savepoint belongs.
509 #[prost(bytes = "bytes", tag = "1")]
510 pub transaction_id: ::prost::bytes::Bytes,
511 /// Name for the savepoint.
512 #[prost(string, tag = "2")]
513 pub name: ::prost::alloc::string::String,
514}
515///
516/// The result of a "BeginTransaction" action.
517///
518/// The transaction can be manipulated with the "EndTransaction" action, or
519/// automatically via server timeout. If the transaction times out, then it is
520/// automatically rolled back.
521///
522/// The result should be wrapped in a google.protobuf.Any message.
523#[derive(Clone, PartialEq, ::prost::Message)]
524pub struct ActionBeginTransactionResult {
525 /// Opaque handle for the transaction on the server.
526 #[prost(bytes = "bytes", tag = "1")]
527 pub transaction_id: ::prost::bytes::Bytes,
528}
529///
530/// The result of a "BeginSavepoint" action.
531///
532/// The transaction can be manipulated with the "EndSavepoint" action.
533/// If the associated transaction is committed, rolled back, or times
534/// out, then the savepoint is also invalidated.
535///
536/// The result should be wrapped in a google.protobuf.Any message.
537#[derive(Clone, PartialEq, ::prost::Message)]
538pub struct ActionBeginSavepointResult {
539 /// Opaque handle for the savepoint on the server.
540 #[prost(bytes = "bytes", tag = "1")]
541 pub savepoint_id: ::prost::bytes::Bytes,
542}
543///
544/// Request message for the "EndTransaction" action.
545///
546/// Commit (COMMIT) or rollback (ROLLBACK) the transaction.
547///
548/// If the action completes successfully, the transaction handle is
549/// invalidated, as are all associated savepoints.
550#[derive(Clone, PartialEq, ::prost::Message)]
551pub struct ActionEndTransactionRequest {
552 /// Opaque handle for the transaction on the server.
553 #[prost(bytes = "bytes", tag = "1")]
554 pub transaction_id: ::prost::bytes::Bytes,
555 /// Whether to commit/rollback the given transaction.
556 #[prost(enumeration = "action_end_transaction_request::EndTransaction", tag = "2")]
557 pub action: i32,
558}
559/// Nested message and enum types in `ActionEndTransactionRequest`.
560pub mod action_end_transaction_request {
561 #[derive(
562 Clone,
563 Copy,
564 Debug,
565 PartialEq,
566 Eq,
567 Hash,
568 PartialOrd,
569 Ord,
570 ::prost::Enumeration
571 )]
572 #[repr(i32)]
573 pub enum EndTransaction {
574 Unspecified = 0,
575 /// Commit the transaction.
576 Commit = 1,
577 /// Roll back the transaction.
578 Rollback = 2,
579 }
580 impl EndTransaction {
581 /// String value of the enum field names used in the ProtoBuf definition.
582 ///
583 /// The values are not transformed in any way and thus are considered stable
584 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
585 pub fn as_str_name(&self) -> &'static str {
586 match self {
587 Self::Unspecified => "END_TRANSACTION_UNSPECIFIED",
588 Self::Commit => "END_TRANSACTION_COMMIT",
589 Self::Rollback => "END_TRANSACTION_ROLLBACK",
590 }
591 }
592 /// Creates an enum from field names used in the ProtoBuf definition.
593 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
594 match value {
595 "END_TRANSACTION_UNSPECIFIED" => Some(Self::Unspecified),
596 "END_TRANSACTION_COMMIT" => Some(Self::Commit),
597 "END_TRANSACTION_ROLLBACK" => Some(Self::Rollback),
598 _ => None,
599 }
600 }
601 }
602}
603///
604/// Request message for the "EndSavepoint" action.
605///
606/// Release (RELEASE) the savepoint or rollback (ROLLBACK) to the
607/// savepoint.
608///
609/// Releasing a savepoint invalidates that savepoint. Rolling back to
610/// a savepoint does not invalidate the savepoint, but invalidates all
611/// savepoints created after the current savepoint.
612#[derive(Clone, PartialEq, ::prost::Message)]
613pub struct ActionEndSavepointRequest {
614 /// Opaque handle for the savepoint on the server.
615 #[prost(bytes = "bytes", tag = "1")]
616 pub savepoint_id: ::prost::bytes::Bytes,
617 /// Whether to rollback/release the given savepoint.
618 #[prost(enumeration = "action_end_savepoint_request::EndSavepoint", tag = "2")]
619 pub action: i32,
620}
621/// Nested message and enum types in `ActionEndSavepointRequest`.
622pub mod action_end_savepoint_request {
623 #[derive(
624 Clone,
625 Copy,
626 Debug,
627 PartialEq,
628 Eq,
629 Hash,
630 PartialOrd,
631 Ord,
632 ::prost::Enumeration
633 )]
634 #[repr(i32)]
635 pub enum EndSavepoint {
636 Unspecified = 0,
637 /// Release the savepoint.
638 Release = 1,
639 /// Roll back to a savepoint.
640 Rollback = 2,
641 }
642 impl EndSavepoint {
643 /// String value of the enum field names used in the ProtoBuf definition.
644 ///
645 /// The values are not transformed in any way and thus are considered stable
646 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
647 pub fn as_str_name(&self) -> &'static str {
648 match self {
649 Self::Unspecified => "END_SAVEPOINT_UNSPECIFIED",
650 Self::Release => "END_SAVEPOINT_RELEASE",
651 Self::Rollback => "END_SAVEPOINT_ROLLBACK",
652 }
653 }
654 /// Creates an enum from field names used in the ProtoBuf definition.
655 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
656 match value {
657 "END_SAVEPOINT_UNSPECIFIED" => Some(Self::Unspecified),
658 "END_SAVEPOINT_RELEASE" => Some(Self::Release),
659 "END_SAVEPOINT_ROLLBACK" => Some(Self::Rollback),
660 _ => None,
661 }
662 }
663 }
664}
665///
666/// Represents a SQL query. Used in the command member of FlightDescriptor
667/// for the following RPC calls:
668/// - GetSchema: return the Arrow schema of the query.
669/// Fields on this schema may contain the following metadata:
670/// - ARROW:FLIGHT:SQL:CATALOG_NAME - Table's catalog name
671/// - ARROW:FLIGHT:SQL:DB_SCHEMA_NAME - Database schema name
672/// - ARROW:FLIGHT:SQL:TABLE_NAME - Table name
673/// - ARROW:FLIGHT:SQL:TYPE_NAME - The data source-specific name for the data type of the column.
674/// - ARROW:FLIGHT:SQL:PRECISION - Column precision/size
675/// - ARROW:FLIGHT:SQL:SCALE - Column scale/decimal digits if applicable
676/// - ARROW:FLIGHT:SQL:IS_AUTO_INCREMENT - "1" indicates if the column is auto incremented, "0" otherwise.
677/// - ARROW:FLIGHT:SQL:IS_CASE_SENSITIVE - "1" indicates if the column is case-sensitive, "0" otherwise.
678/// - ARROW:FLIGHT:SQL:IS_READ_ONLY - "1" indicates if the column is read only, "0" otherwise.
679/// - ARROW:FLIGHT:SQL:IS_SEARCHABLE - "1" indicates if the column is searchable via WHERE clause, "0" otherwise.
680/// - GetFlightInfo: execute the query.
681#[derive(Clone, PartialEq, ::prost::Message)]
682pub struct CommandStatementQuery {
683 /// The SQL syntax.
684 #[prost(string, tag = "1")]
685 pub query: ::prost::alloc::string::String,
686 /// Include the query as part of this transaction (if unset, the query is auto-committed).
687 #[prost(bytes = "bytes", optional, tag = "2")]
688 pub transaction_id: ::core::option::Option<::prost::bytes::Bytes>,
689}
690///
691/// Represents a Substrait plan. Used in the command member of FlightDescriptor
692/// for the following RPC calls:
693/// - GetSchema: return the Arrow schema of the query.
694/// Fields on this schema may contain the following metadata:
695/// - ARROW:FLIGHT:SQL:CATALOG_NAME - Table's catalog name
696/// - ARROW:FLIGHT:SQL:DB_SCHEMA_NAME - Database schema name
697/// - ARROW:FLIGHT:SQL:TABLE_NAME - Table name
698/// - ARROW:FLIGHT:SQL:TYPE_NAME - The data source-specific name for the data type of the column.
699/// - ARROW:FLIGHT:SQL:PRECISION - Column precision/size
700/// - ARROW:FLIGHT:SQL:SCALE - Column scale/decimal digits if applicable
701/// - ARROW:FLIGHT:SQL:IS_AUTO_INCREMENT - "1" indicates if the column is auto incremented, "0" otherwise.
702/// - ARROW:FLIGHT:SQL:IS_CASE_SENSITIVE - "1" indicates if the column is case-sensitive, "0" otherwise.
703/// - ARROW:FLIGHT:SQL:IS_READ_ONLY - "1" indicates if the column is read only, "0" otherwise.
704/// - ARROW:FLIGHT:SQL:IS_SEARCHABLE - "1" indicates if the column is searchable via WHERE clause, "0" otherwise.
705/// - GetFlightInfo: execute the query.
706/// - DoPut: execute the query.
707#[derive(Clone, PartialEq, ::prost::Message)]
708pub struct CommandStatementSubstraitPlan {
709 /// A serialized substrait.Plan
710 #[prost(message, optional, tag = "1")]
711 pub plan: ::core::option::Option<SubstraitPlan>,
712 /// Include the query as part of this transaction (if unset, the query is auto-committed).
713 #[prost(bytes = "bytes", optional, tag = "2")]
714 pub transaction_id: ::core::option::Option<::prost::bytes::Bytes>,
715}
716/// *
717/// Represents a ticket resulting from GetFlightInfo with a CommandStatementQuery.
718/// This should be used only once and treated as an opaque value, that is, clients should not attempt to parse this.
719#[derive(Clone, PartialEq, ::prost::Message)]
720pub struct TicketStatementQuery {
721 /// Unique identifier for the instance of the statement to execute.
722 #[prost(bytes = "bytes", tag = "1")]
723 pub statement_handle: ::prost::bytes::Bytes,
724}
725///
726/// Represents an instance of executing a prepared statement. Used in the command member of FlightDescriptor for
727/// the following RPC calls:
728/// - GetSchema: return the Arrow schema of the query.
729/// Fields on this schema may contain the following metadata:
730/// - ARROW:FLIGHT:SQL:CATALOG_NAME - Table's catalog name
731/// - ARROW:FLIGHT:SQL:DB_SCHEMA_NAME - Database schema name
732/// - ARROW:FLIGHT:SQL:TABLE_NAME - Table name
733/// - ARROW:FLIGHT:SQL:TYPE_NAME - The data source-specific name for the data type of the column.
734/// - ARROW:FLIGHT:SQL:PRECISION - Column precision/size
735/// - ARROW:FLIGHT:SQL:SCALE - Column scale/decimal digits if applicable
736/// - ARROW:FLIGHT:SQL:IS_AUTO_INCREMENT - "1" indicates if the column is auto incremented, "0" otherwise.
737/// - ARROW:FLIGHT:SQL:IS_CASE_SENSITIVE - "1" indicates if the column is case-sensitive, "0" otherwise.
738/// - ARROW:FLIGHT:SQL:IS_READ_ONLY - "1" indicates if the column is read only, "0" otherwise.
739/// - ARROW:FLIGHT:SQL:IS_SEARCHABLE - "1" indicates if the column is searchable via WHERE clause, "0" otherwise.
740///
741/// If the schema is retrieved after parameter values have been bound with DoPut, then the server should account
742/// for the parameters when determining the schema.
743/// - DoPut: bind parameter values. All of the bound parameter sets will be executed as a single atomic execution.
744/// - GetFlightInfo: execute the prepared statement instance.
745#[derive(Clone, PartialEq, ::prost::Message)]
746pub struct CommandPreparedStatementQuery {
747 /// Opaque handle for the prepared statement on the server.
748 #[prost(bytes = "bytes", tag = "1")]
749 pub prepared_statement_handle: ::prost::bytes::Bytes,
750}
751///
752/// Represents a SQL update query. Used in the command member of FlightDescriptor
753/// for the RPC call DoPut to cause the server to execute the included SQL update.
754#[derive(Clone, PartialEq, ::prost::Message)]
755pub struct CommandStatementUpdate {
756 /// The SQL syntax.
757 #[prost(string, tag = "1")]
758 pub query: ::prost::alloc::string::String,
759 /// Include the query as part of this transaction (if unset, the query is auto-committed).
760 #[prost(bytes = "bytes", optional, tag = "2")]
761 pub transaction_id: ::core::option::Option<::prost::bytes::Bytes>,
762}
763///
764/// Represents a SQL update query. Used in the command member of FlightDescriptor
765/// for the RPC call DoPut to cause the server to execute the included
766/// prepared statement handle as an update.
767#[derive(Clone, PartialEq, ::prost::Message)]
768pub struct CommandPreparedStatementUpdate {
769 /// Opaque handle for the prepared statement on the server.
770 #[prost(bytes = "bytes", tag = "1")]
771 pub prepared_statement_handle: ::prost::bytes::Bytes,
772}
773///
774/// Represents a bulk ingestion request. Used in the command member of FlightDescriptor
775/// for the the RPC call DoPut to cause the server load the contents of the stream's
776/// FlightData into the target destination.
777#[derive(Clone, PartialEq, ::prost::Message)]
778pub struct CommandStatementIngest {
779 /// The behavior for handling the table definition.
780 #[prost(message, optional, tag = "1")]
781 pub table_definition_options: ::core::option::Option<
782 command_statement_ingest::TableDefinitionOptions,
783 >,
784 /// The table to load data into.
785 #[prost(string, tag = "2")]
786 pub table: ::prost::alloc::string::String,
787 /// The db_schema of the destination table to load data into. If unset, a backend-specific default may be used.
788 #[prost(string, optional, tag = "3")]
789 pub schema: ::core::option::Option<::prost::alloc::string::String>,
790 /// The catalog of the destination table to load data into. If unset, a backend-specific default may be used.
791 #[prost(string, optional, tag = "4")]
792 pub catalog: ::core::option::Option<::prost::alloc::string::String>,
793 ///
794 /// Store ingested data in a temporary table.
795 /// The effect of setting temporary is to place the table in a backend-defined namespace, and to drop the table at the end of the session.
796 /// The namespacing may make use of a backend-specific schema and/or catalog.
797 /// The server should return an error if an explicit choice of schema or catalog is incompatible with the server's namespacing decision.
798 #[prost(bool, tag = "5")]
799 pub temporary: bool,
800 /// Perform the ingestion as part of this transaction. If specified, results should not be committed in the event of an error/cancellation.
801 #[prost(bytes = "bytes", optional, tag = "6")]
802 pub transaction_id: ::core::option::Option<::prost::bytes::Bytes>,
803 /// Backend-specific options.
804 #[prost(map = "string, string", tag = "1000")]
805 pub options: ::std::collections::HashMap<
806 ::prost::alloc::string::String,
807 ::prost::alloc::string::String,
808 >,
809}
810/// Nested message and enum types in `CommandStatementIngest`.
811pub mod command_statement_ingest {
812 /// Options for table definition behavior
813 #[derive(Clone, Copy, PartialEq, ::prost::Message)]
814 pub struct TableDefinitionOptions {
815 #[prost(
816 enumeration = "table_definition_options::TableNotExistOption",
817 tag = "1"
818 )]
819 pub if_not_exist: i32,
820 #[prost(enumeration = "table_definition_options::TableExistsOption", tag = "2")]
821 pub if_exists: i32,
822 }
823 /// Nested message and enum types in `TableDefinitionOptions`.
824 pub mod table_definition_options {
825 /// The action to take if the target table does not exist
826 #[derive(
827 Clone,
828 Copy,
829 Debug,
830 PartialEq,
831 Eq,
832 Hash,
833 PartialOrd,
834 Ord,
835 ::prost::Enumeration
836 )]
837 #[repr(i32)]
838 pub enum TableNotExistOption {
839 /// Do not use. Servers should error if this is specified by a client.
840 Unspecified = 0,
841 /// Create the table if it does not exist
842 Create = 1,
843 /// Fail if the table does not exist
844 Fail = 2,
845 }
846 impl TableNotExistOption {
847 /// String value of the enum field names used in the ProtoBuf definition.
848 ///
849 /// The values are not transformed in any way and thus are considered stable
850 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
851 pub fn as_str_name(&self) -> &'static str {
852 match self {
853 Self::Unspecified => "TABLE_NOT_EXIST_OPTION_UNSPECIFIED",
854 Self::Create => "TABLE_NOT_EXIST_OPTION_CREATE",
855 Self::Fail => "TABLE_NOT_EXIST_OPTION_FAIL",
856 }
857 }
858 /// Creates an enum from field names used in the ProtoBuf definition.
859 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
860 match value {
861 "TABLE_NOT_EXIST_OPTION_UNSPECIFIED" => Some(Self::Unspecified),
862 "TABLE_NOT_EXIST_OPTION_CREATE" => Some(Self::Create),
863 "TABLE_NOT_EXIST_OPTION_FAIL" => Some(Self::Fail),
864 _ => None,
865 }
866 }
867 }
868 /// The action to take if the target table already exists
869 #[derive(
870 Clone,
871 Copy,
872 Debug,
873 PartialEq,
874 Eq,
875 Hash,
876 PartialOrd,
877 Ord,
878 ::prost::Enumeration
879 )]
880 #[repr(i32)]
881 pub enum TableExistsOption {
882 /// Do not use. Servers should error if this is specified by a client.
883 Unspecified = 0,
884 /// Fail if the table already exists
885 Fail = 1,
886 /// Append to the table if it already exists
887 Append = 2,
888 /// Drop and recreate the table if it already exists
889 Replace = 3,
890 }
891 impl TableExistsOption {
892 /// String value of the enum field names used in the ProtoBuf definition.
893 ///
894 /// The values are not transformed in any way and thus are considered stable
895 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
896 pub fn as_str_name(&self) -> &'static str {
897 match self {
898 Self::Unspecified => "TABLE_EXISTS_OPTION_UNSPECIFIED",
899 Self::Fail => "TABLE_EXISTS_OPTION_FAIL",
900 Self::Append => "TABLE_EXISTS_OPTION_APPEND",
901 Self::Replace => "TABLE_EXISTS_OPTION_REPLACE",
902 }
903 }
904 /// Creates an enum from field names used in the ProtoBuf definition.
905 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
906 match value {
907 "TABLE_EXISTS_OPTION_UNSPECIFIED" => Some(Self::Unspecified),
908 "TABLE_EXISTS_OPTION_FAIL" => Some(Self::Fail),
909 "TABLE_EXISTS_OPTION_APPEND" => Some(Self::Append),
910 "TABLE_EXISTS_OPTION_REPLACE" => Some(Self::Replace),
911 _ => None,
912 }
913 }
914 }
915 }
916}
917///
918/// Returned from the RPC call DoPut when a CommandStatementUpdate,
919/// CommandPreparedStatementUpdate, or CommandStatementIngest was
920/// in the request, containing results from the update.
921#[derive(Clone, Copy, PartialEq, ::prost::Message)]
922pub struct DoPutUpdateResult {
923 /// The number of records updated. A return value of -1 represents
924 /// an unknown updated record count.
925 #[prost(int64, tag = "1")]
926 pub record_count: i64,
927}
928/// An *optional* response returned when `DoPut` is called with `CommandPreparedStatementQuery`.
929///
930/// *Note on legacy behavior*: previous versions of the protocol did not return any result for
931/// this command, and that behavior should still be supported by clients. In that case, the client
932/// can continue as though the fields in this message were not provided or set to sensible default values.
933#[derive(Clone, PartialEq, ::prost::Message)]
934pub struct DoPutPreparedStatementResult {
935 /// Represents a (potentially updated) opaque handle for the prepared statement on the server.
936 /// Because the handle could potentially be updated, any previous handles for this prepared
937 /// statement should be considered invalid, and all subsequent requests for this prepared
938 /// statement must use this new handle.
939 /// The updated handle allows implementing query parameters with stateless services.
940 ///
941 /// When an updated handle is not provided by the server, clients should contiue
942 /// using the previous handle provided by `ActionCreatePreparedStatementResonse`.
943 #[prost(bytes = "bytes", optional, tag = "1")]
944 pub prepared_statement_handle: ::core::option::Option<::prost::bytes::Bytes>,
945}
946///
947/// Request message for the "CancelQuery" action.
948///
949/// Explicitly cancel a running query.
950///
951/// This lets a single client explicitly cancel work, no matter how many clients
952/// are involved/whether the query is distributed or not, given server support.
953/// The transaction/statement is not rolled back; it is the application's job to
954/// commit or rollback as appropriate. This only indicates the client no longer
955/// wishes to read the remainder of the query results or continue submitting
956/// data.
957///
958/// This command is idempotent.
959///
960/// This command is deprecated since 13.0.0. Use the "CancelFlightInfo"
961/// action with DoAction instead.
962#[derive(Clone, PartialEq, ::prost::Message)]
963pub struct ActionCancelQueryRequest {
964 /// The result of the GetFlightInfo RPC that initiated the query.
965 /// XXX(ARROW-16902): this must be a serialized FlightInfo, but is
966 /// rendered as bytes because Protobuf does not really support one
967 /// DLL using Protobuf definitions from another DLL.
968 #[prost(bytes = "bytes", tag = "1")]
969 pub info: ::prost::bytes::Bytes,
970}
971///
972/// The result of cancelling a query.
973///
974/// The result should be wrapped in a google.protobuf.Any message.
975///
976/// This command is deprecated since 13.0.0. Use the "CancelFlightInfo"
977/// action with DoAction instead.
978#[derive(Clone, Copy, PartialEq, ::prost::Message)]
979pub struct ActionCancelQueryResult {
980 #[prost(enumeration = "action_cancel_query_result::CancelResult", tag = "1")]
981 pub result: i32,
982}
983/// Nested message and enum types in `ActionCancelQueryResult`.
984pub mod action_cancel_query_result {
985 #[derive(
986 Clone,
987 Copy,
988 Debug,
989 PartialEq,
990 Eq,
991 Hash,
992 PartialOrd,
993 Ord,
994 ::prost::Enumeration
995 )]
996 #[repr(i32)]
997 pub enum CancelResult {
998 /// The cancellation status is unknown. Servers should avoid using
999 /// this value (send a NOT_FOUND error if the requested query is
1000 /// not known). Clients can retry the request.
1001 Unspecified = 0,
1002 /// The cancellation request is complete. Subsequent requests with
1003 /// the same payload may return CANCELLED or a NOT_FOUND error.
1004 Cancelled = 1,
1005 /// The cancellation request is in progress. The client may retry
1006 /// the cancellation request.
1007 Cancelling = 2,
1008 /// The query is not cancellable. The client should not retry the
1009 /// cancellation request.
1010 NotCancellable = 3,
1011 }
1012 impl CancelResult {
1013 /// String value of the enum field names used in the ProtoBuf definition.
1014 ///
1015 /// The values are not transformed in any way and thus are considered stable
1016 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1017 pub fn as_str_name(&self) -> &'static str {
1018 match self {
1019 Self::Unspecified => "CANCEL_RESULT_UNSPECIFIED",
1020 Self::Cancelled => "CANCEL_RESULT_CANCELLED",
1021 Self::Cancelling => "CANCEL_RESULT_CANCELLING",
1022 Self::NotCancellable => "CANCEL_RESULT_NOT_CANCELLABLE",
1023 }
1024 }
1025 /// Creates an enum from field names used in the ProtoBuf definition.
1026 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1027 match value {
1028 "CANCEL_RESULT_UNSPECIFIED" => Some(Self::Unspecified),
1029 "CANCEL_RESULT_CANCELLED" => Some(Self::Cancelled),
1030 "CANCEL_RESULT_CANCELLING" => Some(Self::Cancelling),
1031 "CANCEL_RESULT_NOT_CANCELLABLE" => Some(Self::NotCancellable),
1032 _ => None,
1033 }
1034 }
1035 }
1036}
1037/// Options for CommandGetSqlInfo.
1038#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1039#[repr(i32)]
1040pub enum SqlInfo {
1041 /// Retrieves a UTF-8 string with the name of the Flight SQL Server.
1042 FlightSqlServerName = 0,
1043 /// Retrieves a UTF-8 string with the native version of the Flight SQL Server.
1044 FlightSqlServerVersion = 1,
1045 /// Retrieves a UTF-8 string with the Arrow format version of the Flight SQL Server.
1046 FlightSqlServerArrowVersion = 2,
1047 ///
1048 /// Retrieves a boolean value indicating whether the Flight SQL Server is read only.
1049 ///
1050 /// Returns:
1051 /// - false: if read-write
1052 /// - true: if read only
1053 FlightSqlServerReadOnly = 3,
1054 ///
1055 /// Retrieves a boolean value indicating whether the Flight SQL Server supports executing
1056 /// SQL queries.
1057 ///
1058 /// Note that the absence of this info (as opposed to a false value) does not necessarily
1059 /// mean that SQL is not supported, as this property was not originally defined.
1060 FlightSqlServerSql = 4,
1061 ///
1062 /// Retrieves a boolean value indicating whether the Flight SQL Server supports executing
1063 /// Substrait plans.
1064 FlightSqlServerSubstrait = 5,
1065 ///
1066 /// Retrieves a string value indicating the minimum supported Substrait version, or null
1067 /// if Substrait is not supported.
1068 FlightSqlServerSubstraitMinVersion = 6,
1069 ///
1070 /// Retrieves a string value indicating the maximum supported Substrait version, or null
1071 /// if Substrait is not supported.
1072 FlightSqlServerSubstraitMaxVersion = 7,
1073 ///
1074 /// Retrieves an int32 indicating whether the Flight SQL Server supports the
1075 /// BeginTransaction/EndTransaction/BeginSavepoint/EndSavepoint actions.
1076 ///
1077 /// Even if this is not supported, the database may still support explicit "BEGIN
1078 /// TRANSACTION"/"COMMIT" SQL statements (see SQL_TRANSACTIONS_SUPPORTED); this property
1079 /// is only about whether the server implements the Flight SQL API endpoints.
1080 ///
1081 /// The possible values are listed in `SqlSupportedTransaction`.
1082 FlightSqlServerTransaction = 8,
1083 ///
1084 /// Retrieves a boolean value indicating whether the Flight SQL Server supports explicit
1085 /// query cancellation (the CancelQuery action).
1086 FlightSqlServerCancel = 9,
1087 ///
1088 /// Retrieves a boolean value indicating whether the Flight SQL Server supports executing
1089 /// bulk ingestion.
1090 FlightSqlServerBulkIngestion = 10,
1091 ///
1092 /// Retrieves a boolean value indicating whether transactions are supported for bulk ingestion. If not, invoking
1093 /// the method commit in the context of a bulk ingestion is a noop, and the isolation level is
1094 /// `arrow.flight.protocol.sql.SqlTransactionIsolationLevel.TRANSACTION_NONE`.
1095 ///
1096 /// Returns:
1097 /// - false: if bulk ingestion transactions are unsupported;
1098 /// - true: if bulk ingestion transactions are supported.
1099 FlightSqlServerIngestTransactionsSupported = 11,
1100 ///
1101 /// Retrieves an int32 indicating the timeout (in milliseconds) for prepared statement handles.
1102 ///
1103 /// If 0, there is no timeout. Servers should reset the timeout when the handle is used in a command.
1104 FlightSqlServerStatementTimeout = 100,
1105 ///
1106 /// Retrieves an int32 indicating the timeout (in milliseconds) for transactions, since transactions are not tied to a connection.
1107 ///
1108 /// If 0, there is no timeout. Servers should reset the timeout when the handle is used in a command.
1109 FlightSqlServerTransactionTimeout = 101,
1110 ///
1111 /// Retrieves a boolean value indicating whether the Flight SQL Server supports CREATE and DROP of catalogs.
1112 ///
1113 /// Returns:
1114 /// - false: if it doesn't support CREATE and DROP of catalogs.
1115 /// - true: if it supports CREATE and DROP of catalogs.
1116 SqlDdlCatalog = 500,
1117 ///
1118 /// Retrieves a boolean value indicating whether the Flight SQL Server supports CREATE and DROP of schemas.
1119 ///
1120 /// Returns:
1121 /// - false: if it doesn't support CREATE and DROP of schemas.
1122 /// - true: if it supports CREATE and DROP of schemas.
1123 SqlDdlSchema = 501,
1124 ///
1125 /// Indicates whether the Flight SQL Server supports CREATE and DROP of tables.
1126 ///
1127 /// Returns:
1128 /// - false: if it doesn't support CREATE and DROP of tables.
1129 /// - true: if it supports CREATE and DROP of tables.
1130 SqlDdlTable = 502,
1131 ///
1132 /// Retrieves a int32 ordinal representing the case sensitivity of catalog, table, schema and table names.
1133 ///
1134 /// The possible values are listed in `arrow.flight.protocol.sql.SqlSupportedCaseSensitivity`.
1135 SqlIdentifierCase = 503,
1136 /// Retrieves a UTF-8 string with the supported character(s) used to surround a delimited identifier.
1137 SqlIdentifierQuoteChar = 504,
1138 ///
1139 /// Retrieves a int32 describing the case sensitivity of quoted identifiers.
1140 ///
1141 /// The possible values are listed in `arrow.flight.protocol.sql.SqlSupportedCaseSensitivity`.
1142 SqlQuotedIdentifierCase = 505,
1143 ///
1144 /// Retrieves a boolean value indicating whether all tables are selectable.
1145 ///
1146 /// Returns:
1147 /// - false: if not all tables are selectable or if none are;
1148 /// - true: if all tables are selectable.
1149 SqlAllTablesAreSelectable = 506,
1150 ///
1151 /// Retrieves the null ordering.
1152 ///
1153 /// Returns a int32 ordinal for the null ordering being used, as described in
1154 /// `arrow.flight.protocol.sql.SqlNullOrdering`.
1155 SqlNullOrdering = 507,
1156 /// Retrieves a UTF-8 string list with values of the supported keywords.
1157 SqlKeywords = 508,
1158 /// Retrieves a UTF-8 string list with values of the supported numeric functions.
1159 SqlNumericFunctions = 509,
1160 /// Retrieves a UTF-8 string list with values of the supported string functions.
1161 SqlStringFunctions = 510,
1162 /// Retrieves a UTF-8 string list with values of the supported system functions.
1163 SqlSystemFunctions = 511,
1164 /// Retrieves a UTF-8 string list with values of the supported datetime functions.
1165 SqlDatetimeFunctions = 512,
1166 ///
1167 /// Retrieves the UTF-8 string that can be used to escape wildcard characters.
1168 /// This is the string that can be used to escape '_' or '%' in the catalog search parameters that are a pattern
1169 /// (and therefore use one of the wildcard characters).
1170 /// The '_' character represents any single character; the '%' character represents any sequence of zero or more
1171 /// characters.
1172 SqlSearchStringEscape = 513,
1173 ///
1174 /// Retrieves a UTF-8 string with all the "extra" characters that can be used in unquoted identifier names
1175 /// (those beyond a-z, A-Z, 0-9 and _).
1176 SqlExtraNameCharacters = 514,
1177 ///
1178 /// Retrieves a boolean value indicating whether column aliasing is supported.
1179 /// If so, the SQL AS clause can be used to provide names for computed columns or to provide alias names for columns
1180 /// as required.
1181 ///
1182 /// Returns:
1183 /// - false: if column aliasing is unsupported;
1184 /// - true: if column aliasing is supported.
1185 SqlSupportsColumnAliasing = 515,
1186 ///
1187 /// Retrieves a boolean value indicating whether concatenations between null and non-null values being
1188 /// null are supported.
1189 ///
1190 /// - Returns:
1191 /// - false: if concatenations between null and non-null values being null are unsupported;
1192 /// - true: if concatenations between null and non-null values being null are supported.
1193 SqlNullPlusNullIsNull = 516,
1194 ///
1195 /// Retrieves a map where the key is the type to convert from and the value is a list with the types to convert to,
1196 /// indicating the supported conversions. Each key and each item on the list value is a value to a predefined type on
1197 /// SqlSupportsConvert enum.
1198 /// The returned map will be: map<int32, list<int32>>
1199 SqlSupportsConvert = 517,
1200 ///
1201 /// Retrieves a boolean value indicating whether, when table correlation names are supported,
1202 /// they are restricted to being different from the names of the tables.
1203 ///
1204 /// Returns:
1205 /// - false: if table correlation names are unsupported;
1206 /// - true: if table correlation names are supported.
1207 SqlSupportsTableCorrelationNames = 518,
1208 ///
1209 /// Retrieves a boolean value indicating whether, when table correlation names are supported,
1210 /// they are restricted to being different from the names of the tables.
1211 ///
1212 /// Returns:
1213 /// - false: if different table correlation names are unsupported;
1214 /// - true: if different table correlation names are supported
1215 SqlSupportsDifferentTableCorrelationNames = 519,
1216 ///
1217 /// Retrieves a boolean value indicating whether expressions in ORDER BY lists are supported.
1218 ///
1219 /// Returns:
1220 /// - false: if expressions in ORDER BY are unsupported;
1221 /// - true: if expressions in ORDER BY are supported;
1222 SqlSupportsExpressionsInOrderBy = 520,
1223 ///
1224 /// Retrieves a boolean value indicating whether using a column that is not in the SELECT statement in a GROUP BY
1225 /// clause is supported.
1226 ///
1227 /// Returns:
1228 /// - false: if using a column that is not in the SELECT statement in a GROUP BY clause is unsupported;
1229 /// - true: if using a column that is not in the SELECT statement in a GROUP BY clause is supported.
1230 SqlSupportsOrderByUnrelated = 521,
1231 ///
1232 /// Retrieves the supported GROUP BY commands;
1233 ///
1234 /// Returns an int32 bitmask value representing the supported commands.
1235 /// The returned bitmask should be parsed in order to retrieve the supported commands.
1236 ///
1237 /// For instance:
1238 /// - return 0 (\b0) => \[\] (GROUP BY is unsupported);
1239 /// - return 1 (\b1) => \[SQL_GROUP_BY_UNRELATED\];
1240 /// - return 2 (\b10) => \[SQL_GROUP_BY_BEYOND_SELECT\];
1241 /// - return 3 (\b11) => \[SQL_GROUP_BY_UNRELATED, SQL_GROUP_BY_BEYOND_SELECT\].
1242 /// Valid GROUP BY types are described under `arrow.flight.protocol.sql.SqlSupportedGroupBy`.
1243 SqlSupportedGroupBy = 522,
1244 ///
1245 /// Retrieves a boolean value indicating whether specifying a LIKE escape clause is supported.
1246 ///
1247 /// Returns:
1248 /// - false: if specifying a LIKE escape clause is unsupported;
1249 /// - true: if specifying a LIKE escape clause is supported.
1250 SqlSupportsLikeEscapeClause = 523,
1251 ///
1252 /// Retrieves a boolean value indicating whether columns may be defined as non-nullable.
1253 ///
1254 /// Returns:
1255 /// - false: if columns cannot be defined as non-nullable;
1256 /// - true: if columns may be defined as non-nullable.
1257 SqlSupportsNonNullableColumns = 524,
1258 ///
1259 /// Retrieves the supported SQL grammar level as per the ODBC specification.
1260 ///
1261 /// Returns an int32 bitmask value representing the supported SQL grammar level.
1262 /// The returned bitmask should be parsed in order to retrieve the supported grammar levels.
1263 ///
1264 /// For instance:
1265 /// - return 0 (\b0) => \[\] (SQL grammar is unsupported);
1266 /// - return 1 (\b1) => \[SQL_MINIMUM_GRAMMAR\];
1267 /// - return 2 (\b10) => \[SQL_CORE_GRAMMAR\];
1268 /// - return 3 (\b11) => \[SQL_MINIMUM_GRAMMAR, SQL_CORE_GRAMMAR\];
1269 /// - return 4 (\b100) => \[SQL_EXTENDED_GRAMMAR\];
1270 /// - return 5 (\b101) => \[SQL_MINIMUM_GRAMMAR, SQL_EXTENDED_GRAMMAR\];
1271 /// - return 6 (\b110) => \[SQL_CORE_GRAMMAR, SQL_EXTENDED_GRAMMAR\];
1272 /// - return 7 (\b111) => \[SQL_MINIMUM_GRAMMAR, SQL_CORE_GRAMMAR, SQL_EXTENDED_GRAMMAR\].
1273 /// Valid SQL grammar levels are described under `arrow.flight.protocol.sql.SupportedSqlGrammar`.
1274 SqlSupportedGrammar = 525,
1275 ///
1276 /// Retrieves the supported ANSI92 SQL grammar level.
1277 ///
1278 /// Returns an int32 bitmask value representing the supported ANSI92 SQL grammar level.
1279 /// The returned bitmask should be parsed in order to retrieve the supported commands.
1280 ///
1281 /// For instance:
1282 /// - return 0 (\b0) => \[\] (ANSI92 SQL grammar is unsupported);
1283 /// - return 1 (\b1) => \[ANSI92_ENTRY_SQL\];
1284 /// - return 2 (\b10) => \[ANSI92_INTERMEDIATE_SQL\];
1285 /// - return 3 (\b11) => \[ANSI92_ENTRY_SQL, ANSI92_INTERMEDIATE_SQL\];
1286 /// - return 4 (\b100) => \[ANSI92_FULL_SQL\];
1287 /// - return 5 (\b101) => \[ANSI92_ENTRY_SQL, ANSI92_FULL_SQL\];
1288 /// - return 6 (\b110) => \[ANSI92_INTERMEDIATE_SQL, ANSI92_FULL_SQL\];
1289 /// - return 7 (\b111) => \[ANSI92_ENTRY_SQL, ANSI92_INTERMEDIATE_SQL, ANSI92_FULL_SQL\].
1290 /// Valid ANSI92 SQL grammar levels are described under `arrow.flight.protocol.sql.SupportedAnsi92SqlGrammarLevel`.
1291 SqlAnsi92SupportedLevel = 526,
1292 ///
1293 /// Retrieves a boolean value indicating whether the SQL Integrity Enhancement Facility is supported.
1294 ///
1295 /// Returns:
1296 /// - false: if the SQL Integrity Enhancement Facility is supported;
1297 /// - true: if the SQL Integrity Enhancement Facility is supported.
1298 SqlSupportsIntegrityEnhancementFacility = 527,
1299 ///
1300 /// Retrieves the support level for SQL OUTER JOINs.
1301 ///
1302 /// Returns a int32 ordinal for the SQL ordering being used, as described in
1303 /// `arrow.flight.protocol.sql.SqlOuterJoinsSupportLevel`.
1304 SqlOuterJoinsSupportLevel = 528,
1305 /// Retrieves a UTF-8 string with the preferred term for "schema".
1306 SqlSchemaTerm = 529,
1307 /// Retrieves a UTF-8 string with the preferred term for "procedure".
1308 SqlProcedureTerm = 530,
1309 ///
1310 /// Retrieves a UTF-8 string with the preferred term for "catalog".
1311 /// If a empty string is returned its assumed that the server does NOT supports catalogs.
1312 SqlCatalogTerm = 531,
1313 ///
1314 /// Retrieves a boolean value indicating whether a catalog appears at the start of a fully qualified table name.
1315 ///
1316 /// - false: if a catalog does not appear at the start of a fully qualified table name;
1317 /// - true: if a catalog appears at the start of a fully qualified table name.
1318 SqlCatalogAtStart = 532,
1319 ///
1320 /// Retrieves the supported actions for a SQL schema.
1321 ///
1322 /// Returns an int32 bitmask value representing the supported actions for a SQL schema.
1323 /// The returned bitmask should be parsed in order to retrieve the supported actions for a SQL schema.
1324 ///
1325 /// For instance:
1326 /// - return 0 (\b0) => \[\] (no supported actions for SQL schema);
1327 /// - return 1 (\b1) => \[SQL_ELEMENT_IN_PROCEDURE_CALLS\];
1328 /// - return 2 (\b10) => \[SQL_ELEMENT_IN_INDEX_DEFINITIONS\];
1329 /// - return 3 (\b11) => \[SQL_ELEMENT_IN_PROCEDURE_CALLS, SQL_ELEMENT_IN_INDEX_DEFINITIONS\];
1330 /// - return 4 (\b100) => \[SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS\];
1331 /// - return 5 (\b101) => \[SQL_ELEMENT_IN_PROCEDURE_CALLS, SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS\];
1332 /// - return 6 (\b110) => \[SQL_ELEMENT_IN_INDEX_DEFINITIONS, SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS\];
1333 /// - return 7 (\b111) => \[SQL_ELEMENT_IN_PROCEDURE_CALLS, SQL_ELEMENT_IN_INDEX_DEFINITIONS, SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS\].
1334 /// Valid actions for a SQL schema described under `arrow.flight.protocol.sql.SqlSupportedElementActions`.
1335 SqlSchemasSupportedActions = 533,
1336 ///
1337 /// Retrieves the supported actions for a SQL schema.
1338 ///
1339 /// Returns an int32 bitmask value representing the supported actions for a SQL catalog.
1340 /// The returned bitmask should be parsed in order to retrieve the supported actions for a SQL catalog.
1341 ///
1342 /// For instance:
1343 /// - return 0 (\b0) => \[\] (no supported actions for SQL catalog);
1344 /// - return 1 (\b1) => \[SQL_ELEMENT_IN_PROCEDURE_CALLS\];
1345 /// - return 2 (\b10) => \[SQL_ELEMENT_IN_INDEX_DEFINITIONS\];
1346 /// - return 3 (\b11) => \[SQL_ELEMENT_IN_PROCEDURE_CALLS, SQL_ELEMENT_IN_INDEX_DEFINITIONS\];
1347 /// - return 4 (\b100) => \[SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS\];
1348 /// - return 5 (\b101) => \[SQL_ELEMENT_IN_PROCEDURE_CALLS, SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS\];
1349 /// - return 6 (\b110) => \[SQL_ELEMENT_IN_INDEX_DEFINITIONS, SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS\];
1350 /// - return 7 (\b111) => \[SQL_ELEMENT_IN_PROCEDURE_CALLS, SQL_ELEMENT_IN_INDEX_DEFINITIONS, SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS\].
1351 /// Valid actions for a SQL catalog are described under `arrow.flight.protocol.sql.SqlSupportedElementActions`.
1352 SqlCatalogsSupportedActions = 534,
1353 ///
1354 /// Retrieves the supported SQL positioned commands.
1355 ///
1356 /// Returns an int32 bitmask value representing the supported SQL positioned commands.
1357 /// The returned bitmask should be parsed in order to retrieve the supported SQL positioned commands.
1358 ///
1359 /// For instance:
1360 /// - return 0 (\b0) => \[\] (no supported SQL positioned commands);
1361 /// - return 1 (\b1) => \[SQL_POSITIONED_DELETE\];
1362 /// - return 2 (\b10) => \[SQL_POSITIONED_UPDATE\];
1363 /// - return 3 (\b11) => \[SQL_POSITIONED_DELETE, SQL_POSITIONED_UPDATE\].
1364 /// Valid SQL positioned commands are described under `arrow.flight.protocol.sql.SqlSupportedPositionedCommands`.
1365 SqlSupportedPositionedCommands = 535,
1366 ///
1367 /// Retrieves a boolean value indicating whether SELECT FOR UPDATE statements are supported.
1368 ///
1369 /// Returns:
1370 /// - false: if SELECT FOR UPDATE statements are unsupported;
1371 /// - true: if SELECT FOR UPDATE statements are supported.
1372 SqlSelectForUpdateSupported = 536,
1373 ///
1374 /// Retrieves a boolean value indicating whether stored procedure calls that use the stored procedure escape syntax
1375 /// are supported.
1376 ///
1377 /// Returns:
1378 /// - false: if stored procedure calls that use the stored procedure escape syntax are unsupported;
1379 /// - true: if stored procedure calls that use the stored procedure escape syntax are supported.
1380 SqlStoredProceduresSupported = 537,
1381 ///
1382 /// Retrieves the supported SQL subqueries.
1383 ///
1384 /// Returns an int32 bitmask value representing the supported SQL subqueries.
1385 /// The returned bitmask should be parsed in order to retrieve the supported SQL subqueries.
1386 ///
1387 /// For instance:
1388 /// - return 0 (\b0) => \[\] (no supported SQL subqueries);
1389 /// - return 1 (\b1) => \[SQL_SUBQUERIES_IN_COMPARISONS\];
1390 /// - return 2 (\b10) => \[SQL_SUBQUERIES_IN_EXISTS\];
1391 /// - return 3 (\b11) => \[SQL_SUBQUERIES_IN_COMPARISONS, SQL_SUBQUERIES_IN_EXISTS\];
1392 /// - return 4 (\b100) => \[SQL_SUBQUERIES_IN_INS\];
1393 /// - return 5 (\b101) => \[SQL_SUBQUERIES_IN_COMPARISONS, SQL_SUBQUERIES_IN_INS\];
1394 /// - return 6 (\b110) => \[SQL_SUBQUERIES_IN_INS, SQL_SUBQUERIES_IN_EXISTS\];
1395 /// - return 7 (\b111) => \[SQL_SUBQUERIES_IN_COMPARISONS, SQL_SUBQUERIES_IN_EXISTS, SQL_SUBQUERIES_IN_INS\];
1396 /// - return 8 (\b1000) => \[SQL_SUBQUERIES_IN_QUANTIFIEDS\];
1397 /// - return 9 (\b1001) => \[SQL_SUBQUERIES_IN_COMPARISONS, SQL_SUBQUERIES_IN_QUANTIFIEDS\];
1398 /// - return 10 (\b1010) => \[SQL_SUBQUERIES_IN_EXISTS, SQL_SUBQUERIES_IN_QUANTIFIEDS\];
1399 /// - return 11 (\b1011) => \[SQL_SUBQUERIES_IN_COMPARISONS, SQL_SUBQUERIES_IN_EXISTS, SQL_SUBQUERIES_IN_QUANTIFIEDS\];
1400 /// - return 12 (\b1100) => \[SQL_SUBQUERIES_IN_INS, SQL_SUBQUERIES_IN_QUANTIFIEDS\];
1401 /// - return 13 (\b1101) => \[SQL_SUBQUERIES_IN_COMPARISONS, SQL_SUBQUERIES_IN_INS, SQL_SUBQUERIES_IN_QUANTIFIEDS\];
1402 /// - return 14 (\b1110) => \[SQL_SUBQUERIES_IN_EXISTS, SQL_SUBQUERIES_IN_INS, SQL_SUBQUERIES_IN_QUANTIFIEDS\];
1403 /// - return 15 (\b1111) => \[SQL_SUBQUERIES_IN_COMPARISONS, SQL_SUBQUERIES_IN_EXISTS, SQL_SUBQUERIES_IN_INS, SQL_SUBQUERIES_IN_QUANTIFIEDS\];
1404 /// - ...
1405 /// Valid SQL subqueries are described under `arrow.flight.protocol.sql.SqlSupportedSubqueries`.
1406 SqlSupportedSubqueries = 538,
1407 ///
1408 /// Retrieves a boolean value indicating whether correlated subqueries are supported.
1409 ///
1410 /// Returns:
1411 /// - false: if correlated subqueries are unsupported;
1412 /// - true: if correlated subqueries are supported.
1413 SqlCorrelatedSubqueriesSupported = 539,
1414 ///
1415 /// Retrieves the supported SQL UNIONs.
1416 ///
1417 /// Returns an int32 bitmask value representing the supported SQL UNIONs.
1418 /// The returned bitmask should be parsed in order to retrieve the supported SQL UNIONs.
1419 ///
1420 /// For instance:
1421 /// - return 0 (\b0) => \[\] (no supported SQL positioned commands);
1422 /// - return 1 (\b1) => \[SQL_UNION\];
1423 /// - return 2 (\b10) => \[SQL_UNION_ALL\];
1424 /// - return 3 (\b11) => \[SQL_UNION, SQL_UNION_ALL\].
1425 /// Valid SQL positioned commands are described under `arrow.flight.protocol.sql.SqlSupportedUnions`.
1426 SqlSupportedUnions = 540,
1427 /// Retrieves a int64 value representing the maximum number of hex characters allowed in an inline binary literal.
1428 SqlMaxBinaryLiteralLength = 541,
1429 /// Retrieves a int64 value representing the maximum number of characters allowed for a character literal.
1430 SqlMaxCharLiteralLength = 542,
1431 /// Retrieves a int64 value representing the maximum number of characters allowed for a column name.
1432 SqlMaxColumnNameLength = 543,
1433 /// Retrieves a int64 value representing the maximum number of columns allowed in a GROUP BY clause.
1434 SqlMaxColumnsInGroupBy = 544,
1435 /// Retrieves a int64 value representing the maximum number of columns allowed in an index.
1436 SqlMaxColumnsInIndex = 545,
1437 /// Retrieves a int64 value representing the maximum number of columns allowed in an ORDER BY clause.
1438 SqlMaxColumnsInOrderBy = 546,
1439 /// Retrieves a int64 value representing the maximum number of columns allowed in a SELECT list.
1440 SqlMaxColumnsInSelect = 547,
1441 /// Retrieves a int64 value representing the maximum number of columns allowed in a table.
1442 SqlMaxColumnsInTable = 548,
1443 /// Retrieves a int64 value representing the maximum number of concurrent connections possible.
1444 SqlMaxConnections = 549,
1445 /// Retrieves a int64 value the maximum number of characters allowed in a cursor name.
1446 SqlMaxCursorNameLength = 550,
1447 ///
1448 /// Retrieves a int64 value representing the maximum number of bytes allowed for an index,
1449 /// including all of the parts of the index.
1450 SqlMaxIndexLength = 551,
1451 /// Retrieves a int64 value representing the maximum number of characters allowed in a schema name.
1452 SqlDbSchemaNameLength = 552,
1453 /// Retrieves a int64 value representing the maximum number of characters allowed in a procedure name.
1454 SqlMaxProcedureNameLength = 553,
1455 /// Retrieves a int64 value representing the maximum number of characters allowed in a catalog name.
1456 SqlMaxCatalogNameLength = 554,
1457 /// Retrieves a int64 value representing the maximum number of bytes allowed in a single row.
1458 SqlMaxRowSize = 555,
1459 ///
1460 /// Retrieves a boolean indicating whether the return value for the JDBC method getMaxRowSize includes the SQL
1461 /// data types LONGVARCHAR and LONGVARBINARY.
1462 ///
1463 /// Returns:
1464 /// - false: if return value for the JDBC method getMaxRowSize does
1465 /// not include the SQL data types LONGVARCHAR and LONGVARBINARY;
1466 /// - true: if return value for the JDBC method getMaxRowSize includes
1467 /// the SQL data types LONGVARCHAR and LONGVARBINARY.
1468 SqlMaxRowSizeIncludesBlobs = 556,
1469 ///
1470 /// Retrieves a int64 value representing the maximum number of characters allowed for an SQL statement;
1471 /// a result of 0 (zero) means that there is no limit or the limit is not known.
1472 SqlMaxStatementLength = 557,
1473 /// Retrieves a int64 value representing the maximum number of active statements that can be open at the same time.
1474 SqlMaxStatements = 558,
1475 /// Retrieves a int64 value representing the maximum number of characters allowed in a table name.
1476 SqlMaxTableNameLength = 559,
1477 /// Retrieves a int64 value representing the maximum number of tables allowed in a SELECT statement.
1478 SqlMaxTablesInSelect = 560,
1479 /// Retrieves a int64 value representing the maximum number of characters allowed in a user name.
1480 SqlMaxUsernameLength = 561,
1481 ///
1482 /// Retrieves this database's default transaction isolation level as described in
1483 /// `arrow.flight.protocol.sql.SqlTransactionIsolationLevel`.
1484 ///
1485 /// Returns a int32 ordinal for the SQL transaction isolation level.
1486 SqlDefaultTransactionIsolation = 562,
1487 ///
1488 /// Retrieves a boolean value indicating whether transactions are supported. If not, invoking the method commit is a
1489 /// noop, and the isolation level is `arrow.flight.protocol.sql.SqlTransactionIsolationLevel.TRANSACTION_NONE`.
1490 ///
1491 /// Returns:
1492 /// - false: if transactions are unsupported;
1493 /// - true: if transactions are supported.
1494 SqlTransactionsSupported = 563,
1495 ///
1496 /// Retrieves the supported transactions isolation levels.
1497 ///
1498 /// Returns an int32 bitmask value representing the supported transactions isolation levels.
1499 /// The returned bitmask should be parsed in order to retrieve the supported transactions isolation levels.
1500 ///
1501 /// For instance:
1502 /// - return 0 (\b0) => \[\] (no supported SQL transactions isolation levels);
1503 /// - return 1 (\b1) => \[SQL_TRANSACTION_NONE\];
1504 /// - return 2 (\b10) => \[SQL_TRANSACTION_READ_UNCOMMITTED\];
1505 /// - return 3 (\b11) => \[SQL_TRANSACTION_NONE, SQL_TRANSACTION_READ_UNCOMMITTED\];
1506 /// - return 4 (\b100) => \[SQL_TRANSACTION_REPEATABLE_READ\];
1507 /// - return 5 (\b101) => \[SQL_TRANSACTION_NONE, SQL_TRANSACTION_REPEATABLE_READ\];
1508 /// - return 6 (\b110) => \[SQL_TRANSACTION_READ_UNCOMMITTED, SQL_TRANSACTION_REPEATABLE_READ\];
1509 /// - return 7 (\b111) => \[SQL_TRANSACTION_NONE, SQL_TRANSACTION_READ_UNCOMMITTED, SQL_TRANSACTION_REPEATABLE_READ\];
1510 /// - return 8 (\b1000) => \[SQL_TRANSACTION_REPEATABLE_READ\];
1511 /// - return 9 (\b1001) => \[SQL_TRANSACTION_NONE, SQL_TRANSACTION_REPEATABLE_READ\];
1512 /// - return 10 (\b1010) => \[SQL_TRANSACTION_READ_UNCOMMITTED, SQL_TRANSACTION_REPEATABLE_READ\];
1513 /// - return 11 (\b1011) => \[SQL_TRANSACTION_NONE, SQL_TRANSACTION_READ_UNCOMMITTED, SQL_TRANSACTION_REPEATABLE_READ\];
1514 /// - return 12 (\b1100) => \[SQL_TRANSACTION_REPEATABLE_READ, SQL_TRANSACTION_REPEATABLE_READ\];
1515 /// - return 13 (\b1101) => \[SQL_TRANSACTION_NONE, SQL_TRANSACTION_REPEATABLE_READ, SQL_TRANSACTION_REPEATABLE_READ\];
1516 /// - return 14 (\b1110) => \[SQL_TRANSACTION_READ_UNCOMMITTED, SQL_TRANSACTION_REPEATABLE_READ, SQL_TRANSACTION_REPEATABLE_READ\];
1517 /// - return 15 (\b1111) => \[SQL_TRANSACTION_NONE, SQL_TRANSACTION_READ_UNCOMMITTED, SQL_TRANSACTION_REPEATABLE_READ, SQL_TRANSACTION_REPEATABLE_READ\];
1518 /// - return 16 (\b10000) => \[SQL_TRANSACTION_SERIALIZABLE\];
1519 /// - ...
1520 /// Valid SQL positioned commands are described under `arrow.flight.protocol.sql.SqlTransactionIsolationLevel`.
1521 SqlSupportedTransactionsIsolationLevels = 564,
1522 ///
1523 /// Retrieves a boolean value indicating whether a data definition statement within a transaction forces
1524 /// the transaction to commit.
1525 ///
1526 /// Returns:
1527 /// - false: if a data definition statement within a transaction does not force the transaction to commit;
1528 /// - true: if a data definition statement within a transaction forces the transaction to commit.
1529 SqlDataDefinitionCausesTransactionCommit = 565,
1530 ///
1531 /// Retrieves a boolean value indicating whether a data definition statement within a transaction is ignored.
1532 ///
1533 /// Returns:
1534 /// - false: if a data definition statement within a transaction is taken into account;
1535 /// - true: a data definition statement within a transaction is ignored.
1536 SqlDataDefinitionsInTransactionsIgnored = 566,
1537 ///
1538 /// Retrieves an int32 bitmask value representing the supported result set types.
1539 /// The returned bitmask should be parsed in order to retrieve the supported result set types.
1540 ///
1541 /// For instance:
1542 /// - return 0 (\b0) => \[\] (no supported result set types);
1543 /// - return 1 (\b1) => \[SQL_RESULT_SET_TYPE_UNSPECIFIED\];
1544 /// - return 2 (\b10) => \[SQL_RESULT_SET_TYPE_FORWARD_ONLY\];
1545 /// - return 3 (\b11) => \[SQL_RESULT_SET_TYPE_UNSPECIFIED, SQL_RESULT_SET_TYPE_FORWARD_ONLY\];
1546 /// - return 4 (\b100) => \[SQL_RESULT_SET_TYPE_SCROLL_INSENSITIVE\];
1547 /// - return 5 (\b101) => \[SQL_RESULT_SET_TYPE_UNSPECIFIED, SQL_RESULT_SET_TYPE_SCROLL_INSENSITIVE\];
1548 /// - return 6 (\b110) => \[SQL_RESULT_SET_TYPE_FORWARD_ONLY, SQL_RESULT_SET_TYPE_SCROLL_INSENSITIVE\];
1549 /// - return 7 (\b111) => \[SQL_RESULT_SET_TYPE_UNSPECIFIED, SQL_RESULT_SET_TYPE_FORWARD_ONLY, SQL_RESULT_SET_TYPE_SCROLL_INSENSITIVE\];
1550 /// - return 8 (\b1000) => \[SQL_RESULT_SET_TYPE_SCROLL_SENSITIVE\];
1551 /// - ...
1552 /// Valid result set types are described under `arrow.flight.protocol.sql.SqlSupportedResultSetType`.
1553 SqlSupportedResultSetTypes = 567,
1554 ///
1555 /// Returns an int32 bitmask value concurrency types supported for
1556 /// `arrow.flight.protocol.sql.SqlSupportedResultSetType.SQL_RESULT_SET_TYPE_UNSPECIFIED`.
1557 ///
1558 /// For instance:
1559 /// - return 0 (\b0) => \[\] (no supported concurrency types for this result set type)
1560 /// - return 1 (\b1) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED\]
1561 /// - return 2 (\b10) => \[SQL_RESULT_SET_CONCURRENCY_READ_ONLY\]
1562 /// - return 3 (\b11) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_READ_ONLY\]
1563 /// - return 4 (\b100) => \[SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1564 /// - return 5 (\b101) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1565 /// - return 6 (\b110) => \[SQL_RESULT_SET_CONCURRENCY_READ_ONLY, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1566 /// - return 7 (\b111) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_READ_ONLY, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1567 /// Valid result set types are described under `arrow.flight.protocol.sql.SqlSupportedResultSetConcurrency`.
1568 SqlSupportedConcurrenciesForResultSetUnspecified = 568,
1569 ///
1570 /// Returns an int32 bitmask value concurrency types supported for
1571 /// `arrow.flight.protocol.sql.SqlSupportedResultSetType.SQL_RESULT_SET_TYPE_FORWARD_ONLY`.
1572 ///
1573 /// For instance:
1574 /// - return 0 (\b0) => \[\] (no supported concurrency types for this result set type)
1575 /// - return 1 (\b1) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED\]
1576 /// - return 2 (\b10) => \[SQL_RESULT_SET_CONCURRENCY_READ_ONLY\]
1577 /// - return 3 (\b11) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_READ_ONLY\]
1578 /// - return 4 (\b100) => \[SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1579 /// - return 5 (\b101) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1580 /// - return 6 (\b110) => \[SQL_RESULT_SET_CONCURRENCY_READ_ONLY, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1581 /// - return 7 (\b111) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_READ_ONLY, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1582 /// Valid result set types are described under `arrow.flight.protocol.sql.SqlSupportedResultSetConcurrency`.
1583 SqlSupportedConcurrenciesForResultSetForwardOnly = 569,
1584 ///
1585 /// Returns an int32 bitmask value concurrency types supported for
1586 /// `arrow.flight.protocol.sql.SqlSupportedResultSetType.SQL_RESULT_SET_TYPE_SCROLL_SENSITIVE`.
1587 ///
1588 /// For instance:
1589 /// - return 0 (\b0) => \[\] (no supported concurrency types for this result set type)
1590 /// - return 1 (\b1) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED\]
1591 /// - return 2 (\b10) => \[SQL_RESULT_SET_CONCURRENCY_READ_ONLY\]
1592 /// - return 3 (\b11) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_READ_ONLY\]
1593 /// - return 4 (\b100) => \[SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1594 /// - return 5 (\b101) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1595 /// - return 6 (\b110) => \[SQL_RESULT_SET_CONCURRENCY_READ_ONLY, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1596 /// - return 7 (\b111) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_READ_ONLY, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1597 /// Valid result set types are described under `arrow.flight.protocol.sql.SqlSupportedResultSetConcurrency`.
1598 SqlSupportedConcurrenciesForResultSetScrollSensitive = 570,
1599 ///
1600 /// Returns an int32 bitmask value concurrency types supported for
1601 /// `arrow.flight.protocol.sql.SqlSupportedResultSetType.SQL_RESULT_SET_TYPE_SCROLL_INSENSITIVE`.
1602 ///
1603 /// For instance:
1604 /// - return 0 (\b0) => \[\] (no supported concurrency types for this result set type)
1605 /// - return 1 (\b1) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED\]
1606 /// - return 2 (\b10) => \[SQL_RESULT_SET_CONCURRENCY_READ_ONLY\]
1607 /// - return 3 (\b11) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_READ_ONLY\]
1608 /// - return 4 (\b100) => \[SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1609 /// - return 5 (\b101) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1610 /// - return 6 (\b110) => \[SQL_RESULT_SET_CONCURRENCY_READ_ONLY, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1611 /// - return 7 (\b111) => \[SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED, SQL_RESULT_SET_CONCURRENCY_READ_ONLY, SQL_RESULT_SET_CONCURRENCY_UPDATABLE\]
1612 /// Valid result set types are described under `arrow.flight.protocol.sql.SqlSupportedResultSetConcurrency`.
1613 SqlSupportedConcurrenciesForResultSetScrollInsensitive = 571,
1614 ///
1615 /// Retrieves a boolean value indicating whether this database supports batch updates.
1616 ///
1617 /// - false: if this database does not support batch updates;
1618 /// - true: if this database supports batch updates.
1619 SqlBatchUpdatesSupported = 572,
1620 ///
1621 /// Retrieves a boolean value indicating whether this database supports savepoints.
1622 ///
1623 /// Returns:
1624 /// - false: if this database does not support savepoints;
1625 /// - true: if this database supports savepoints.
1626 SqlSavepointsSupported = 573,
1627 ///
1628 /// Retrieves a boolean value indicating whether named parameters are supported in callable statements.
1629 ///
1630 /// Returns:
1631 /// - false: if named parameters in callable statements are unsupported;
1632 /// - true: if named parameters in callable statements are supported.
1633 SqlNamedParametersSupported = 574,
1634 ///
1635 /// Retrieves a boolean value indicating whether updates made to a LOB are made on a copy or directly to the LOB.
1636 ///
1637 /// Returns:
1638 /// - false: if updates made to a LOB are made directly to the LOB;
1639 /// - true: if updates made to a LOB are made on a copy.
1640 SqlLocatorsUpdateCopy = 575,
1641 ///
1642 /// Retrieves a boolean value indicating whether invoking user-defined or vendor functions
1643 /// using the stored procedure escape syntax is supported.
1644 ///
1645 /// Returns:
1646 /// - false: if invoking user-defined or vendor functions using the stored procedure escape syntax is unsupported;
1647 /// - true: if invoking user-defined or vendor functions using the stored procedure escape syntax is supported.
1648 SqlStoredFunctionsUsingCallSyntaxSupported = 576,
1649}
1650impl SqlInfo {
1651 /// String value of the enum field names used in the ProtoBuf definition.
1652 ///
1653 /// The values are not transformed in any way and thus are considered stable
1654 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1655 pub fn as_str_name(&self) -> &'static str {
1656 match self {
1657 Self::FlightSqlServerName => "FLIGHT_SQL_SERVER_NAME",
1658 Self::FlightSqlServerVersion => "FLIGHT_SQL_SERVER_VERSION",
1659 Self::FlightSqlServerArrowVersion => "FLIGHT_SQL_SERVER_ARROW_VERSION",
1660 Self::FlightSqlServerReadOnly => "FLIGHT_SQL_SERVER_READ_ONLY",
1661 Self::FlightSqlServerSql => "FLIGHT_SQL_SERVER_SQL",
1662 Self::FlightSqlServerSubstrait => "FLIGHT_SQL_SERVER_SUBSTRAIT",
1663 Self::FlightSqlServerSubstraitMinVersion => {
1664 "FLIGHT_SQL_SERVER_SUBSTRAIT_MIN_VERSION"
1665 }
1666 Self::FlightSqlServerSubstraitMaxVersion => {
1667 "FLIGHT_SQL_SERVER_SUBSTRAIT_MAX_VERSION"
1668 }
1669 Self::FlightSqlServerTransaction => "FLIGHT_SQL_SERVER_TRANSACTION",
1670 Self::FlightSqlServerCancel => "FLIGHT_SQL_SERVER_CANCEL",
1671 Self::FlightSqlServerBulkIngestion => "FLIGHT_SQL_SERVER_BULK_INGESTION",
1672 Self::FlightSqlServerIngestTransactionsSupported => {
1673 "FLIGHT_SQL_SERVER_INGEST_TRANSACTIONS_SUPPORTED"
1674 }
1675 Self::FlightSqlServerStatementTimeout => {
1676 "FLIGHT_SQL_SERVER_STATEMENT_TIMEOUT"
1677 }
1678 Self::FlightSqlServerTransactionTimeout => {
1679 "FLIGHT_SQL_SERVER_TRANSACTION_TIMEOUT"
1680 }
1681 Self::SqlDdlCatalog => "SQL_DDL_CATALOG",
1682 Self::SqlDdlSchema => "SQL_DDL_SCHEMA",
1683 Self::SqlDdlTable => "SQL_DDL_TABLE",
1684 Self::SqlIdentifierCase => "SQL_IDENTIFIER_CASE",
1685 Self::SqlIdentifierQuoteChar => "SQL_IDENTIFIER_QUOTE_CHAR",
1686 Self::SqlQuotedIdentifierCase => "SQL_QUOTED_IDENTIFIER_CASE",
1687 Self::SqlAllTablesAreSelectable => "SQL_ALL_TABLES_ARE_SELECTABLE",
1688 Self::SqlNullOrdering => "SQL_NULL_ORDERING",
1689 Self::SqlKeywords => "SQL_KEYWORDS",
1690 Self::SqlNumericFunctions => "SQL_NUMERIC_FUNCTIONS",
1691 Self::SqlStringFunctions => "SQL_STRING_FUNCTIONS",
1692 Self::SqlSystemFunctions => "SQL_SYSTEM_FUNCTIONS",
1693 Self::SqlDatetimeFunctions => "SQL_DATETIME_FUNCTIONS",
1694 Self::SqlSearchStringEscape => "SQL_SEARCH_STRING_ESCAPE",
1695 Self::SqlExtraNameCharacters => "SQL_EXTRA_NAME_CHARACTERS",
1696 Self::SqlSupportsColumnAliasing => "SQL_SUPPORTS_COLUMN_ALIASING",
1697 Self::SqlNullPlusNullIsNull => "SQL_NULL_PLUS_NULL_IS_NULL",
1698 Self::SqlSupportsConvert => "SQL_SUPPORTS_CONVERT",
1699 Self::SqlSupportsTableCorrelationNames => {
1700 "SQL_SUPPORTS_TABLE_CORRELATION_NAMES"
1701 }
1702 Self::SqlSupportsDifferentTableCorrelationNames => {
1703 "SQL_SUPPORTS_DIFFERENT_TABLE_CORRELATION_NAMES"
1704 }
1705 Self::SqlSupportsExpressionsInOrderBy => {
1706 "SQL_SUPPORTS_EXPRESSIONS_IN_ORDER_BY"
1707 }
1708 Self::SqlSupportsOrderByUnrelated => "SQL_SUPPORTS_ORDER_BY_UNRELATED",
1709 Self::SqlSupportedGroupBy => "SQL_SUPPORTED_GROUP_BY",
1710 Self::SqlSupportsLikeEscapeClause => "SQL_SUPPORTS_LIKE_ESCAPE_CLAUSE",
1711 Self::SqlSupportsNonNullableColumns => "SQL_SUPPORTS_NON_NULLABLE_COLUMNS",
1712 Self::SqlSupportedGrammar => "SQL_SUPPORTED_GRAMMAR",
1713 Self::SqlAnsi92SupportedLevel => "SQL_ANSI92_SUPPORTED_LEVEL",
1714 Self::SqlSupportsIntegrityEnhancementFacility => {
1715 "SQL_SUPPORTS_INTEGRITY_ENHANCEMENT_FACILITY"
1716 }
1717 Self::SqlOuterJoinsSupportLevel => "SQL_OUTER_JOINS_SUPPORT_LEVEL",
1718 Self::SqlSchemaTerm => "SQL_SCHEMA_TERM",
1719 Self::SqlProcedureTerm => "SQL_PROCEDURE_TERM",
1720 Self::SqlCatalogTerm => "SQL_CATALOG_TERM",
1721 Self::SqlCatalogAtStart => "SQL_CATALOG_AT_START",
1722 Self::SqlSchemasSupportedActions => "SQL_SCHEMAS_SUPPORTED_ACTIONS",
1723 Self::SqlCatalogsSupportedActions => "SQL_CATALOGS_SUPPORTED_ACTIONS",
1724 Self::SqlSupportedPositionedCommands => "SQL_SUPPORTED_POSITIONED_COMMANDS",
1725 Self::SqlSelectForUpdateSupported => "SQL_SELECT_FOR_UPDATE_SUPPORTED",
1726 Self::SqlStoredProceduresSupported => "SQL_STORED_PROCEDURES_SUPPORTED",
1727 Self::SqlSupportedSubqueries => "SQL_SUPPORTED_SUBQUERIES",
1728 Self::SqlCorrelatedSubqueriesSupported => {
1729 "SQL_CORRELATED_SUBQUERIES_SUPPORTED"
1730 }
1731 Self::SqlSupportedUnions => "SQL_SUPPORTED_UNIONS",
1732 Self::SqlMaxBinaryLiteralLength => "SQL_MAX_BINARY_LITERAL_LENGTH",
1733 Self::SqlMaxCharLiteralLength => "SQL_MAX_CHAR_LITERAL_LENGTH",
1734 Self::SqlMaxColumnNameLength => "SQL_MAX_COLUMN_NAME_LENGTH",
1735 Self::SqlMaxColumnsInGroupBy => "SQL_MAX_COLUMNS_IN_GROUP_BY",
1736 Self::SqlMaxColumnsInIndex => "SQL_MAX_COLUMNS_IN_INDEX",
1737 Self::SqlMaxColumnsInOrderBy => "SQL_MAX_COLUMNS_IN_ORDER_BY",
1738 Self::SqlMaxColumnsInSelect => "SQL_MAX_COLUMNS_IN_SELECT",
1739 Self::SqlMaxColumnsInTable => "SQL_MAX_COLUMNS_IN_TABLE",
1740 Self::SqlMaxConnections => "SQL_MAX_CONNECTIONS",
1741 Self::SqlMaxCursorNameLength => "SQL_MAX_CURSOR_NAME_LENGTH",
1742 Self::SqlMaxIndexLength => "SQL_MAX_INDEX_LENGTH",
1743 Self::SqlDbSchemaNameLength => "SQL_DB_SCHEMA_NAME_LENGTH",
1744 Self::SqlMaxProcedureNameLength => "SQL_MAX_PROCEDURE_NAME_LENGTH",
1745 Self::SqlMaxCatalogNameLength => "SQL_MAX_CATALOG_NAME_LENGTH",
1746 Self::SqlMaxRowSize => "SQL_MAX_ROW_SIZE",
1747 Self::SqlMaxRowSizeIncludesBlobs => "SQL_MAX_ROW_SIZE_INCLUDES_BLOBS",
1748 Self::SqlMaxStatementLength => "SQL_MAX_STATEMENT_LENGTH",
1749 Self::SqlMaxStatements => "SQL_MAX_STATEMENTS",
1750 Self::SqlMaxTableNameLength => "SQL_MAX_TABLE_NAME_LENGTH",
1751 Self::SqlMaxTablesInSelect => "SQL_MAX_TABLES_IN_SELECT",
1752 Self::SqlMaxUsernameLength => "SQL_MAX_USERNAME_LENGTH",
1753 Self::SqlDefaultTransactionIsolation => "SQL_DEFAULT_TRANSACTION_ISOLATION",
1754 Self::SqlTransactionsSupported => "SQL_TRANSACTIONS_SUPPORTED",
1755 Self::SqlSupportedTransactionsIsolationLevels => {
1756 "SQL_SUPPORTED_TRANSACTIONS_ISOLATION_LEVELS"
1757 }
1758 Self::SqlDataDefinitionCausesTransactionCommit => {
1759 "SQL_DATA_DEFINITION_CAUSES_TRANSACTION_COMMIT"
1760 }
1761 Self::SqlDataDefinitionsInTransactionsIgnored => {
1762 "SQL_DATA_DEFINITIONS_IN_TRANSACTIONS_IGNORED"
1763 }
1764 Self::SqlSupportedResultSetTypes => "SQL_SUPPORTED_RESULT_SET_TYPES",
1765 Self::SqlSupportedConcurrenciesForResultSetUnspecified => {
1766 "SQL_SUPPORTED_CONCURRENCIES_FOR_RESULT_SET_UNSPECIFIED"
1767 }
1768 Self::SqlSupportedConcurrenciesForResultSetForwardOnly => {
1769 "SQL_SUPPORTED_CONCURRENCIES_FOR_RESULT_SET_FORWARD_ONLY"
1770 }
1771 Self::SqlSupportedConcurrenciesForResultSetScrollSensitive => {
1772 "SQL_SUPPORTED_CONCURRENCIES_FOR_RESULT_SET_SCROLL_SENSITIVE"
1773 }
1774 Self::SqlSupportedConcurrenciesForResultSetScrollInsensitive => {
1775 "SQL_SUPPORTED_CONCURRENCIES_FOR_RESULT_SET_SCROLL_INSENSITIVE"
1776 }
1777 Self::SqlBatchUpdatesSupported => "SQL_BATCH_UPDATES_SUPPORTED",
1778 Self::SqlSavepointsSupported => "SQL_SAVEPOINTS_SUPPORTED",
1779 Self::SqlNamedParametersSupported => "SQL_NAMED_PARAMETERS_SUPPORTED",
1780 Self::SqlLocatorsUpdateCopy => "SQL_LOCATORS_UPDATE_COPY",
1781 Self::SqlStoredFunctionsUsingCallSyntaxSupported => {
1782 "SQL_STORED_FUNCTIONS_USING_CALL_SYNTAX_SUPPORTED"
1783 }
1784 }
1785 }
1786 /// Creates an enum from field names used in the ProtoBuf definition.
1787 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1788 match value {
1789 "FLIGHT_SQL_SERVER_NAME" => Some(Self::FlightSqlServerName),
1790 "FLIGHT_SQL_SERVER_VERSION" => Some(Self::FlightSqlServerVersion),
1791 "FLIGHT_SQL_SERVER_ARROW_VERSION" => Some(Self::FlightSqlServerArrowVersion),
1792 "FLIGHT_SQL_SERVER_READ_ONLY" => Some(Self::FlightSqlServerReadOnly),
1793 "FLIGHT_SQL_SERVER_SQL" => Some(Self::FlightSqlServerSql),
1794 "FLIGHT_SQL_SERVER_SUBSTRAIT" => Some(Self::FlightSqlServerSubstrait),
1795 "FLIGHT_SQL_SERVER_SUBSTRAIT_MIN_VERSION" => {
1796 Some(Self::FlightSqlServerSubstraitMinVersion)
1797 }
1798 "FLIGHT_SQL_SERVER_SUBSTRAIT_MAX_VERSION" => {
1799 Some(Self::FlightSqlServerSubstraitMaxVersion)
1800 }
1801 "FLIGHT_SQL_SERVER_TRANSACTION" => Some(Self::FlightSqlServerTransaction),
1802 "FLIGHT_SQL_SERVER_CANCEL" => Some(Self::FlightSqlServerCancel),
1803 "FLIGHT_SQL_SERVER_BULK_INGESTION" => {
1804 Some(Self::FlightSqlServerBulkIngestion)
1805 }
1806 "FLIGHT_SQL_SERVER_INGEST_TRANSACTIONS_SUPPORTED" => {
1807 Some(Self::FlightSqlServerIngestTransactionsSupported)
1808 }
1809 "FLIGHT_SQL_SERVER_STATEMENT_TIMEOUT" => {
1810 Some(Self::FlightSqlServerStatementTimeout)
1811 }
1812 "FLIGHT_SQL_SERVER_TRANSACTION_TIMEOUT" => {
1813 Some(Self::FlightSqlServerTransactionTimeout)
1814 }
1815 "SQL_DDL_CATALOG" => Some(Self::SqlDdlCatalog),
1816 "SQL_DDL_SCHEMA" => Some(Self::SqlDdlSchema),
1817 "SQL_DDL_TABLE" => Some(Self::SqlDdlTable),
1818 "SQL_IDENTIFIER_CASE" => Some(Self::SqlIdentifierCase),
1819 "SQL_IDENTIFIER_QUOTE_CHAR" => Some(Self::SqlIdentifierQuoteChar),
1820 "SQL_QUOTED_IDENTIFIER_CASE" => Some(Self::SqlQuotedIdentifierCase),
1821 "SQL_ALL_TABLES_ARE_SELECTABLE" => Some(Self::SqlAllTablesAreSelectable),
1822 "SQL_NULL_ORDERING" => Some(Self::SqlNullOrdering),
1823 "SQL_KEYWORDS" => Some(Self::SqlKeywords),
1824 "SQL_NUMERIC_FUNCTIONS" => Some(Self::SqlNumericFunctions),
1825 "SQL_STRING_FUNCTIONS" => Some(Self::SqlStringFunctions),
1826 "SQL_SYSTEM_FUNCTIONS" => Some(Self::SqlSystemFunctions),
1827 "SQL_DATETIME_FUNCTIONS" => Some(Self::SqlDatetimeFunctions),
1828 "SQL_SEARCH_STRING_ESCAPE" => Some(Self::SqlSearchStringEscape),
1829 "SQL_EXTRA_NAME_CHARACTERS" => Some(Self::SqlExtraNameCharacters),
1830 "SQL_SUPPORTS_COLUMN_ALIASING" => Some(Self::SqlSupportsColumnAliasing),
1831 "SQL_NULL_PLUS_NULL_IS_NULL" => Some(Self::SqlNullPlusNullIsNull),
1832 "SQL_SUPPORTS_CONVERT" => Some(Self::SqlSupportsConvert),
1833 "SQL_SUPPORTS_TABLE_CORRELATION_NAMES" => {
1834 Some(Self::SqlSupportsTableCorrelationNames)
1835 }
1836 "SQL_SUPPORTS_DIFFERENT_TABLE_CORRELATION_NAMES" => {
1837 Some(Self::SqlSupportsDifferentTableCorrelationNames)
1838 }
1839 "SQL_SUPPORTS_EXPRESSIONS_IN_ORDER_BY" => {
1840 Some(Self::SqlSupportsExpressionsInOrderBy)
1841 }
1842 "SQL_SUPPORTS_ORDER_BY_UNRELATED" => Some(Self::SqlSupportsOrderByUnrelated),
1843 "SQL_SUPPORTED_GROUP_BY" => Some(Self::SqlSupportedGroupBy),
1844 "SQL_SUPPORTS_LIKE_ESCAPE_CLAUSE" => Some(Self::SqlSupportsLikeEscapeClause),
1845 "SQL_SUPPORTS_NON_NULLABLE_COLUMNS" => {
1846 Some(Self::SqlSupportsNonNullableColumns)
1847 }
1848 "SQL_SUPPORTED_GRAMMAR" => Some(Self::SqlSupportedGrammar),
1849 "SQL_ANSI92_SUPPORTED_LEVEL" => Some(Self::SqlAnsi92SupportedLevel),
1850 "SQL_SUPPORTS_INTEGRITY_ENHANCEMENT_FACILITY" => {
1851 Some(Self::SqlSupportsIntegrityEnhancementFacility)
1852 }
1853 "SQL_OUTER_JOINS_SUPPORT_LEVEL" => Some(Self::SqlOuterJoinsSupportLevel),
1854 "SQL_SCHEMA_TERM" => Some(Self::SqlSchemaTerm),
1855 "SQL_PROCEDURE_TERM" => Some(Self::SqlProcedureTerm),
1856 "SQL_CATALOG_TERM" => Some(Self::SqlCatalogTerm),
1857 "SQL_CATALOG_AT_START" => Some(Self::SqlCatalogAtStart),
1858 "SQL_SCHEMAS_SUPPORTED_ACTIONS" => Some(Self::SqlSchemasSupportedActions),
1859 "SQL_CATALOGS_SUPPORTED_ACTIONS" => Some(Self::SqlCatalogsSupportedActions),
1860 "SQL_SUPPORTED_POSITIONED_COMMANDS" => {
1861 Some(Self::SqlSupportedPositionedCommands)
1862 }
1863 "SQL_SELECT_FOR_UPDATE_SUPPORTED" => Some(Self::SqlSelectForUpdateSupported),
1864 "SQL_STORED_PROCEDURES_SUPPORTED" => Some(Self::SqlStoredProceduresSupported),
1865 "SQL_SUPPORTED_SUBQUERIES" => Some(Self::SqlSupportedSubqueries),
1866 "SQL_CORRELATED_SUBQUERIES_SUPPORTED" => {
1867 Some(Self::SqlCorrelatedSubqueriesSupported)
1868 }
1869 "SQL_SUPPORTED_UNIONS" => Some(Self::SqlSupportedUnions),
1870 "SQL_MAX_BINARY_LITERAL_LENGTH" => Some(Self::SqlMaxBinaryLiteralLength),
1871 "SQL_MAX_CHAR_LITERAL_LENGTH" => Some(Self::SqlMaxCharLiteralLength),
1872 "SQL_MAX_COLUMN_NAME_LENGTH" => Some(Self::SqlMaxColumnNameLength),
1873 "SQL_MAX_COLUMNS_IN_GROUP_BY" => Some(Self::SqlMaxColumnsInGroupBy),
1874 "SQL_MAX_COLUMNS_IN_INDEX" => Some(Self::SqlMaxColumnsInIndex),
1875 "SQL_MAX_COLUMNS_IN_ORDER_BY" => Some(Self::SqlMaxColumnsInOrderBy),
1876 "SQL_MAX_COLUMNS_IN_SELECT" => Some(Self::SqlMaxColumnsInSelect),
1877 "SQL_MAX_COLUMNS_IN_TABLE" => Some(Self::SqlMaxColumnsInTable),
1878 "SQL_MAX_CONNECTIONS" => Some(Self::SqlMaxConnections),
1879 "SQL_MAX_CURSOR_NAME_LENGTH" => Some(Self::SqlMaxCursorNameLength),
1880 "SQL_MAX_INDEX_LENGTH" => Some(Self::SqlMaxIndexLength),
1881 "SQL_DB_SCHEMA_NAME_LENGTH" => Some(Self::SqlDbSchemaNameLength),
1882 "SQL_MAX_PROCEDURE_NAME_LENGTH" => Some(Self::SqlMaxProcedureNameLength),
1883 "SQL_MAX_CATALOG_NAME_LENGTH" => Some(Self::SqlMaxCatalogNameLength),
1884 "SQL_MAX_ROW_SIZE" => Some(Self::SqlMaxRowSize),
1885 "SQL_MAX_ROW_SIZE_INCLUDES_BLOBS" => Some(Self::SqlMaxRowSizeIncludesBlobs),
1886 "SQL_MAX_STATEMENT_LENGTH" => Some(Self::SqlMaxStatementLength),
1887 "SQL_MAX_STATEMENTS" => Some(Self::SqlMaxStatements),
1888 "SQL_MAX_TABLE_NAME_LENGTH" => Some(Self::SqlMaxTableNameLength),
1889 "SQL_MAX_TABLES_IN_SELECT" => Some(Self::SqlMaxTablesInSelect),
1890 "SQL_MAX_USERNAME_LENGTH" => Some(Self::SqlMaxUsernameLength),
1891 "SQL_DEFAULT_TRANSACTION_ISOLATION" => {
1892 Some(Self::SqlDefaultTransactionIsolation)
1893 }
1894 "SQL_TRANSACTIONS_SUPPORTED" => Some(Self::SqlTransactionsSupported),
1895 "SQL_SUPPORTED_TRANSACTIONS_ISOLATION_LEVELS" => {
1896 Some(Self::SqlSupportedTransactionsIsolationLevels)
1897 }
1898 "SQL_DATA_DEFINITION_CAUSES_TRANSACTION_COMMIT" => {
1899 Some(Self::SqlDataDefinitionCausesTransactionCommit)
1900 }
1901 "SQL_DATA_DEFINITIONS_IN_TRANSACTIONS_IGNORED" => {
1902 Some(Self::SqlDataDefinitionsInTransactionsIgnored)
1903 }
1904 "SQL_SUPPORTED_RESULT_SET_TYPES" => Some(Self::SqlSupportedResultSetTypes),
1905 "SQL_SUPPORTED_CONCURRENCIES_FOR_RESULT_SET_UNSPECIFIED" => {
1906 Some(Self::SqlSupportedConcurrenciesForResultSetUnspecified)
1907 }
1908 "SQL_SUPPORTED_CONCURRENCIES_FOR_RESULT_SET_FORWARD_ONLY" => {
1909 Some(Self::SqlSupportedConcurrenciesForResultSetForwardOnly)
1910 }
1911 "SQL_SUPPORTED_CONCURRENCIES_FOR_RESULT_SET_SCROLL_SENSITIVE" => {
1912 Some(Self::SqlSupportedConcurrenciesForResultSetScrollSensitive)
1913 }
1914 "SQL_SUPPORTED_CONCURRENCIES_FOR_RESULT_SET_SCROLL_INSENSITIVE" => {
1915 Some(Self::SqlSupportedConcurrenciesForResultSetScrollInsensitive)
1916 }
1917 "SQL_BATCH_UPDATES_SUPPORTED" => Some(Self::SqlBatchUpdatesSupported),
1918 "SQL_SAVEPOINTS_SUPPORTED" => Some(Self::SqlSavepointsSupported),
1919 "SQL_NAMED_PARAMETERS_SUPPORTED" => Some(Self::SqlNamedParametersSupported),
1920 "SQL_LOCATORS_UPDATE_COPY" => Some(Self::SqlLocatorsUpdateCopy),
1921 "SQL_STORED_FUNCTIONS_USING_CALL_SYNTAX_SUPPORTED" => {
1922 Some(Self::SqlStoredFunctionsUsingCallSyntaxSupported)
1923 }
1924 _ => None,
1925 }
1926 }
1927}
1928/// The level of support for Flight SQL transaction RPCs.
1929#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1930#[repr(i32)]
1931pub enum SqlSupportedTransaction {
1932 /// Unknown/not indicated/no support
1933 None = 0,
1934 /// Transactions, but not savepoints.
1935 /// A savepoint is a mark within a transaction that can be individually
1936 /// rolled back to. Not all databases support savepoints.
1937 Transaction = 1,
1938 /// Transactions and savepoints
1939 Savepoint = 2,
1940}
1941impl SqlSupportedTransaction {
1942 /// String value of the enum field names used in the ProtoBuf definition.
1943 ///
1944 /// The values are not transformed in any way and thus are considered stable
1945 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1946 pub fn as_str_name(&self) -> &'static str {
1947 match self {
1948 Self::None => "SQL_SUPPORTED_TRANSACTION_NONE",
1949 Self::Transaction => "SQL_SUPPORTED_TRANSACTION_TRANSACTION",
1950 Self::Savepoint => "SQL_SUPPORTED_TRANSACTION_SAVEPOINT",
1951 }
1952 }
1953 /// Creates an enum from field names used in the ProtoBuf definition.
1954 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1955 match value {
1956 "SQL_SUPPORTED_TRANSACTION_NONE" => Some(Self::None),
1957 "SQL_SUPPORTED_TRANSACTION_TRANSACTION" => Some(Self::Transaction),
1958 "SQL_SUPPORTED_TRANSACTION_SAVEPOINT" => Some(Self::Savepoint),
1959 _ => None,
1960 }
1961 }
1962}
1963#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
1964#[repr(i32)]
1965pub enum SqlSupportedCaseSensitivity {
1966 SqlCaseSensitivityUnknown = 0,
1967 SqlCaseSensitivityCaseInsensitive = 1,
1968 SqlCaseSensitivityUppercase = 2,
1969 SqlCaseSensitivityLowercase = 3,
1970}
1971impl SqlSupportedCaseSensitivity {
1972 /// String value of the enum field names used in the ProtoBuf definition.
1973 ///
1974 /// The values are not transformed in any way and thus are considered stable
1975 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
1976 pub fn as_str_name(&self) -> &'static str {
1977 match self {
1978 Self::SqlCaseSensitivityUnknown => "SQL_CASE_SENSITIVITY_UNKNOWN",
1979 Self::SqlCaseSensitivityCaseInsensitive => {
1980 "SQL_CASE_SENSITIVITY_CASE_INSENSITIVE"
1981 }
1982 Self::SqlCaseSensitivityUppercase => "SQL_CASE_SENSITIVITY_UPPERCASE",
1983 Self::SqlCaseSensitivityLowercase => "SQL_CASE_SENSITIVITY_LOWERCASE",
1984 }
1985 }
1986 /// Creates an enum from field names used in the ProtoBuf definition.
1987 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
1988 match value {
1989 "SQL_CASE_SENSITIVITY_UNKNOWN" => Some(Self::SqlCaseSensitivityUnknown),
1990 "SQL_CASE_SENSITIVITY_CASE_INSENSITIVE" => {
1991 Some(Self::SqlCaseSensitivityCaseInsensitive)
1992 }
1993 "SQL_CASE_SENSITIVITY_UPPERCASE" => Some(Self::SqlCaseSensitivityUppercase),
1994 "SQL_CASE_SENSITIVITY_LOWERCASE" => Some(Self::SqlCaseSensitivityLowercase),
1995 _ => None,
1996 }
1997 }
1998}
1999#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2000#[repr(i32)]
2001pub enum SqlNullOrdering {
2002 SqlNullsSortedHigh = 0,
2003 SqlNullsSortedLow = 1,
2004 SqlNullsSortedAtStart = 2,
2005 SqlNullsSortedAtEnd = 3,
2006}
2007impl SqlNullOrdering {
2008 /// String value of the enum field names used in the ProtoBuf definition.
2009 ///
2010 /// The values are not transformed in any way and thus are considered stable
2011 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2012 pub fn as_str_name(&self) -> &'static str {
2013 match self {
2014 Self::SqlNullsSortedHigh => "SQL_NULLS_SORTED_HIGH",
2015 Self::SqlNullsSortedLow => "SQL_NULLS_SORTED_LOW",
2016 Self::SqlNullsSortedAtStart => "SQL_NULLS_SORTED_AT_START",
2017 Self::SqlNullsSortedAtEnd => "SQL_NULLS_SORTED_AT_END",
2018 }
2019 }
2020 /// Creates an enum from field names used in the ProtoBuf definition.
2021 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2022 match value {
2023 "SQL_NULLS_SORTED_HIGH" => Some(Self::SqlNullsSortedHigh),
2024 "SQL_NULLS_SORTED_LOW" => Some(Self::SqlNullsSortedLow),
2025 "SQL_NULLS_SORTED_AT_START" => Some(Self::SqlNullsSortedAtStart),
2026 "SQL_NULLS_SORTED_AT_END" => Some(Self::SqlNullsSortedAtEnd),
2027 _ => None,
2028 }
2029 }
2030}
2031#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2032#[repr(i32)]
2033pub enum SupportedSqlGrammar {
2034 SqlMinimumGrammar = 0,
2035 SqlCoreGrammar = 1,
2036 SqlExtendedGrammar = 2,
2037}
2038impl SupportedSqlGrammar {
2039 /// String value of the enum field names used in the ProtoBuf definition.
2040 ///
2041 /// The values are not transformed in any way and thus are considered stable
2042 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2043 pub fn as_str_name(&self) -> &'static str {
2044 match self {
2045 Self::SqlMinimumGrammar => "SQL_MINIMUM_GRAMMAR",
2046 Self::SqlCoreGrammar => "SQL_CORE_GRAMMAR",
2047 Self::SqlExtendedGrammar => "SQL_EXTENDED_GRAMMAR",
2048 }
2049 }
2050 /// Creates an enum from field names used in the ProtoBuf definition.
2051 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2052 match value {
2053 "SQL_MINIMUM_GRAMMAR" => Some(Self::SqlMinimumGrammar),
2054 "SQL_CORE_GRAMMAR" => Some(Self::SqlCoreGrammar),
2055 "SQL_EXTENDED_GRAMMAR" => Some(Self::SqlExtendedGrammar),
2056 _ => None,
2057 }
2058 }
2059}
2060#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2061#[repr(i32)]
2062pub enum SupportedAnsi92SqlGrammarLevel {
2063 Ansi92EntrySql = 0,
2064 Ansi92IntermediateSql = 1,
2065 Ansi92FullSql = 2,
2066}
2067impl SupportedAnsi92SqlGrammarLevel {
2068 /// String value of the enum field names used in the ProtoBuf definition.
2069 ///
2070 /// The values are not transformed in any way and thus are considered stable
2071 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2072 pub fn as_str_name(&self) -> &'static str {
2073 match self {
2074 Self::Ansi92EntrySql => "ANSI92_ENTRY_SQL",
2075 Self::Ansi92IntermediateSql => "ANSI92_INTERMEDIATE_SQL",
2076 Self::Ansi92FullSql => "ANSI92_FULL_SQL",
2077 }
2078 }
2079 /// Creates an enum from field names used in the ProtoBuf definition.
2080 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2081 match value {
2082 "ANSI92_ENTRY_SQL" => Some(Self::Ansi92EntrySql),
2083 "ANSI92_INTERMEDIATE_SQL" => Some(Self::Ansi92IntermediateSql),
2084 "ANSI92_FULL_SQL" => Some(Self::Ansi92FullSql),
2085 _ => None,
2086 }
2087 }
2088}
2089#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2090#[repr(i32)]
2091pub enum SqlOuterJoinsSupportLevel {
2092 SqlJoinsUnsupported = 0,
2093 SqlLimitedOuterJoins = 1,
2094 SqlFullOuterJoins = 2,
2095}
2096impl SqlOuterJoinsSupportLevel {
2097 /// String value of the enum field names used in the ProtoBuf definition.
2098 ///
2099 /// The values are not transformed in any way and thus are considered stable
2100 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2101 pub fn as_str_name(&self) -> &'static str {
2102 match self {
2103 Self::SqlJoinsUnsupported => "SQL_JOINS_UNSUPPORTED",
2104 Self::SqlLimitedOuterJoins => "SQL_LIMITED_OUTER_JOINS",
2105 Self::SqlFullOuterJoins => "SQL_FULL_OUTER_JOINS",
2106 }
2107 }
2108 /// Creates an enum from field names used in the ProtoBuf definition.
2109 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2110 match value {
2111 "SQL_JOINS_UNSUPPORTED" => Some(Self::SqlJoinsUnsupported),
2112 "SQL_LIMITED_OUTER_JOINS" => Some(Self::SqlLimitedOuterJoins),
2113 "SQL_FULL_OUTER_JOINS" => Some(Self::SqlFullOuterJoins),
2114 _ => None,
2115 }
2116 }
2117}
2118#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2119#[repr(i32)]
2120pub enum SqlSupportedGroupBy {
2121 SqlGroupByUnrelated = 0,
2122 SqlGroupByBeyondSelect = 1,
2123}
2124impl SqlSupportedGroupBy {
2125 /// String value of the enum field names used in the ProtoBuf definition.
2126 ///
2127 /// The values are not transformed in any way and thus are considered stable
2128 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2129 pub fn as_str_name(&self) -> &'static str {
2130 match self {
2131 Self::SqlGroupByUnrelated => "SQL_GROUP_BY_UNRELATED",
2132 Self::SqlGroupByBeyondSelect => "SQL_GROUP_BY_BEYOND_SELECT",
2133 }
2134 }
2135 /// Creates an enum from field names used in the ProtoBuf definition.
2136 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2137 match value {
2138 "SQL_GROUP_BY_UNRELATED" => Some(Self::SqlGroupByUnrelated),
2139 "SQL_GROUP_BY_BEYOND_SELECT" => Some(Self::SqlGroupByBeyondSelect),
2140 _ => None,
2141 }
2142 }
2143}
2144#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2145#[repr(i32)]
2146pub enum SqlSupportedElementActions {
2147 SqlElementInProcedureCalls = 0,
2148 SqlElementInIndexDefinitions = 1,
2149 SqlElementInPrivilegeDefinitions = 2,
2150}
2151impl SqlSupportedElementActions {
2152 /// String value of the enum field names used in the ProtoBuf definition.
2153 ///
2154 /// The values are not transformed in any way and thus are considered stable
2155 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2156 pub fn as_str_name(&self) -> &'static str {
2157 match self {
2158 Self::SqlElementInProcedureCalls => "SQL_ELEMENT_IN_PROCEDURE_CALLS",
2159 Self::SqlElementInIndexDefinitions => "SQL_ELEMENT_IN_INDEX_DEFINITIONS",
2160 Self::SqlElementInPrivilegeDefinitions => {
2161 "SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS"
2162 }
2163 }
2164 }
2165 /// Creates an enum from field names used in the ProtoBuf definition.
2166 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2167 match value {
2168 "SQL_ELEMENT_IN_PROCEDURE_CALLS" => Some(Self::SqlElementInProcedureCalls),
2169 "SQL_ELEMENT_IN_INDEX_DEFINITIONS" => {
2170 Some(Self::SqlElementInIndexDefinitions)
2171 }
2172 "SQL_ELEMENT_IN_PRIVILEGE_DEFINITIONS" => {
2173 Some(Self::SqlElementInPrivilegeDefinitions)
2174 }
2175 _ => None,
2176 }
2177 }
2178}
2179#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2180#[repr(i32)]
2181pub enum SqlSupportedPositionedCommands {
2182 SqlPositionedDelete = 0,
2183 SqlPositionedUpdate = 1,
2184}
2185impl SqlSupportedPositionedCommands {
2186 /// String value of the enum field names used in the ProtoBuf definition.
2187 ///
2188 /// The values are not transformed in any way and thus are considered stable
2189 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2190 pub fn as_str_name(&self) -> &'static str {
2191 match self {
2192 Self::SqlPositionedDelete => "SQL_POSITIONED_DELETE",
2193 Self::SqlPositionedUpdate => "SQL_POSITIONED_UPDATE",
2194 }
2195 }
2196 /// Creates an enum from field names used in the ProtoBuf definition.
2197 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2198 match value {
2199 "SQL_POSITIONED_DELETE" => Some(Self::SqlPositionedDelete),
2200 "SQL_POSITIONED_UPDATE" => Some(Self::SqlPositionedUpdate),
2201 _ => None,
2202 }
2203 }
2204}
2205#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2206#[repr(i32)]
2207pub enum SqlSupportedSubqueries {
2208 SqlSubqueriesInComparisons = 0,
2209 SqlSubqueriesInExists = 1,
2210 SqlSubqueriesInIns = 2,
2211 SqlSubqueriesInQuantifieds = 3,
2212}
2213impl SqlSupportedSubqueries {
2214 /// String value of the enum field names used in the ProtoBuf definition.
2215 ///
2216 /// The values are not transformed in any way and thus are considered stable
2217 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2218 pub fn as_str_name(&self) -> &'static str {
2219 match self {
2220 Self::SqlSubqueriesInComparisons => "SQL_SUBQUERIES_IN_COMPARISONS",
2221 Self::SqlSubqueriesInExists => "SQL_SUBQUERIES_IN_EXISTS",
2222 Self::SqlSubqueriesInIns => "SQL_SUBQUERIES_IN_INS",
2223 Self::SqlSubqueriesInQuantifieds => "SQL_SUBQUERIES_IN_QUANTIFIEDS",
2224 }
2225 }
2226 /// Creates an enum from field names used in the ProtoBuf definition.
2227 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2228 match value {
2229 "SQL_SUBQUERIES_IN_COMPARISONS" => Some(Self::SqlSubqueriesInComparisons),
2230 "SQL_SUBQUERIES_IN_EXISTS" => Some(Self::SqlSubqueriesInExists),
2231 "SQL_SUBQUERIES_IN_INS" => Some(Self::SqlSubqueriesInIns),
2232 "SQL_SUBQUERIES_IN_QUANTIFIEDS" => Some(Self::SqlSubqueriesInQuantifieds),
2233 _ => None,
2234 }
2235 }
2236}
2237#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2238#[repr(i32)]
2239pub enum SqlSupportedUnions {
2240 SqlUnion = 0,
2241 SqlUnionAll = 1,
2242}
2243impl SqlSupportedUnions {
2244 /// String value of the enum field names used in the ProtoBuf definition.
2245 ///
2246 /// The values are not transformed in any way and thus are considered stable
2247 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2248 pub fn as_str_name(&self) -> &'static str {
2249 match self {
2250 Self::SqlUnion => "SQL_UNION",
2251 Self::SqlUnionAll => "SQL_UNION_ALL",
2252 }
2253 }
2254 /// Creates an enum from field names used in the ProtoBuf definition.
2255 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2256 match value {
2257 "SQL_UNION" => Some(Self::SqlUnion),
2258 "SQL_UNION_ALL" => Some(Self::SqlUnionAll),
2259 _ => None,
2260 }
2261 }
2262}
2263#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2264#[repr(i32)]
2265pub enum SqlTransactionIsolationLevel {
2266 SqlTransactionNone = 0,
2267 SqlTransactionReadUncommitted = 1,
2268 SqlTransactionReadCommitted = 2,
2269 SqlTransactionRepeatableRead = 3,
2270 SqlTransactionSerializable = 4,
2271}
2272impl SqlTransactionIsolationLevel {
2273 /// String value of the enum field names used in the ProtoBuf definition.
2274 ///
2275 /// The values are not transformed in any way and thus are considered stable
2276 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2277 pub fn as_str_name(&self) -> &'static str {
2278 match self {
2279 Self::SqlTransactionNone => "SQL_TRANSACTION_NONE",
2280 Self::SqlTransactionReadUncommitted => "SQL_TRANSACTION_READ_UNCOMMITTED",
2281 Self::SqlTransactionReadCommitted => "SQL_TRANSACTION_READ_COMMITTED",
2282 Self::SqlTransactionRepeatableRead => "SQL_TRANSACTION_REPEATABLE_READ",
2283 Self::SqlTransactionSerializable => "SQL_TRANSACTION_SERIALIZABLE",
2284 }
2285 }
2286 /// Creates an enum from field names used in the ProtoBuf definition.
2287 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2288 match value {
2289 "SQL_TRANSACTION_NONE" => Some(Self::SqlTransactionNone),
2290 "SQL_TRANSACTION_READ_UNCOMMITTED" => {
2291 Some(Self::SqlTransactionReadUncommitted)
2292 }
2293 "SQL_TRANSACTION_READ_COMMITTED" => Some(Self::SqlTransactionReadCommitted),
2294 "SQL_TRANSACTION_REPEATABLE_READ" => Some(Self::SqlTransactionRepeatableRead),
2295 "SQL_TRANSACTION_SERIALIZABLE" => Some(Self::SqlTransactionSerializable),
2296 _ => None,
2297 }
2298 }
2299}
2300#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2301#[repr(i32)]
2302pub enum SqlSupportedTransactions {
2303 SqlTransactionUnspecified = 0,
2304 SqlDataDefinitionTransactions = 1,
2305 SqlDataManipulationTransactions = 2,
2306}
2307impl SqlSupportedTransactions {
2308 /// String value of the enum field names used in the ProtoBuf definition.
2309 ///
2310 /// The values are not transformed in any way and thus are considered stable
2311 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2312 pub fn as_str_name(&self) -> &'static str {
2313 match self {
2314 Self::SqlTransactionUnspecified => "SQL_TRANSACTION_UNSPECIFIED",
2315 Self::SqlDataDefinitionTransactions => "SQL_DATA_DEFINITION_TRANSACTIONS",
2316 Self::SqlDataManipulationTransactions => "SQL_DATA_MANIPULATION_TRANSACTIONS",
2317 }
2318 }
2319 /// Creates an enum from field names used in the ProtoBuf definition.
2320 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2321 match value {
2322 "SQL_TRANSACTION_UNSPECIFIED" => Some(Self::SqlTransactionUnspecified),
2323 "SQL_DATA_DEFINITION_TRANSACTIONS" => {
2324 Some(Self::SqlDataDefinitionTransactions)
2325 }
2326 "SQL_DATA_MANIPULATION_TRANSACTIONS" => {
2327 Some(Self::SqlDataManipulationTransactions)
2328 }
2329 _ => None,
2330 }
2331 }
2332}
2333#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2334#[repr(i32)]
2335pub enum SqlSupportedResultSetType {
2336 SqlResultSetTypeUnspecified = 0,
2337 SqlResultSetTypeForwardOnly = 1,
2338 SqlResultSetTypeScrollInsensitive = 2,
2339 SqlResultSetTypeScrollSensitive = 3,
2340}
2341impl SqlSupportedResultSetType {
2342 /// String value of the enum field names used in the ProtoBuf definition.
2343 ///
2344 /// The values are not transformed in any way and thus are considered stable
2345 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2346 pub fn as_str_name(&self) -> &'static str {
2347 match self {
2348 Self::SqlResultSetTypeUnspecified => "SQL_RESULT_SET_TYPE_UNSPECIFIED",
2349 Self::SqlResultSetTypeForwardOnly => "SQL_RESULT_SET_TYPE_FORWARD_ONLY",
2350 Self::SqlResultSetTypeScrollInsensitive => {
2351 "SQL_RESULT_SET_TYPE_SCROLL_INSENSITIVE"
2352 }
2353 Self::SqlResultSetTypeScrollSensitive => {
2354 "SQL_RESULT_SET_TYPE_SCROLL_SENSITIVE"
2355 }
2356 }
2357 }
2358 /// Creates an enum from field names used in the ProtoBuf definition.
2359 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2360 match value {
2361 "SQL_RESULT_SET_TYPE_UNSPECIFIED" => Some(Self::SqlResultSetTypeUnspecified),
2362 "SQL_RESULT_SET_TYPE_FORWARD_ONLY" => Some(Self::SqlResultSetTypeForwardOnly),
2363 "SQL_RESULT_SET_TYPE_SCROLL_INSENSITIVE" => {
2364 Some(Self::SqlResultSetTypeScrollInsensitive)
2365 }
2366 "SQL_RESULT_SET_TYPE_SCROLL_SENSITIVE" => {
2367 Some(Self::SqlResultSetTypeScrollSensitive)
2368 }
2369 _ => None,
2370 }
2371 }
2372}
2373#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2374#[repr(i32)]
2375pub enum SqlSupportedResultSetConcurrency {
2376 SqlResultSetConcurrencyUnspecified = 0,
2377 SqlResultSetConcurrencyReadOnly = 1,
2378 SqlResultSetConcurrencyUpdatable = 2,
2379}
2380impl SqlSupportedResultSetConcurrency {
2381 /// String value of the enum field names used in the ProtoBuf definition.
2382 ///
2383 /// The values are not transformed in any way and thus are considered stable
2384 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2385 pub fn as_str_name(&self) -> &'static str {
2386 match self {
2387 Self::SqlResultSetConcurrencyUnspecified => {
2388 "SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED"
2389 }
2390 Self::SqlResultSetConcurrencyReadOnly => {
2391 "SQL_RESULT_SET_CONCURRENCY_READ_ONLY"
2392 }
2393 Self::SqlResultSetConcurrencyUpdatable => {
2394 "SQL_RESULT_SET_CONCURRENCY_UPDATABLE"
2395 }
2396 }
2397 }
2398 /// Creates an enum from field names used in the ProtoBuf definition.
2399 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2400 match value {
2401 "SQL_RESULT_SET_CONCURRENCY_UNSPECIFIED" => {
2402 Some(Self::SqlResultSetConcurrencyUnspecified)
2403 }
2404 "SQL_RESULT_SET_CONCURRENCY_READ_ONLY" => {
2405 Some(Self::SqlResultSetConcurrencyReadOnly)
2406 }
2407 "SQL_RESULT_SET_CONCURRENCY_UPDATABLE" => {
2408 Some(Self::SqlResultSetConcurrencyUpdatable)
2409 }
2410 _ => None,
2411 }
2412 }
2413}
2414#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2415#[repr(i32)]
2416pub enum SqlSupportsConvert {
2417 SqlConvertBigint = 0,
2418 SqlConvertBinary = 1,
2419 SqlConvertBit = 2,
2420 SqlConvertChar = 3,
2421 SqlConvertDate = 4,
2422 SqlConvertDecimal = 5,
2423 SqlConvertFloat = 6,
2424 SqlConvertInteger = 7,
2425 SqlConvertIntervalDayTime = 8,
2426 SqlConvertIntervalYearMonth = 9,
2427 SqlConvertLongvarbinary = 10,
2428 SqlConvertLongvarchar = 11,
2429 SqlConvertNumeric = 12,
2430 SqlConvertReal = 13,
2431 SqlConvertSmallint = 14,
2432 SqlConvertTime = 15,
2433 SqlConvertTimestamp = 16,
2434 SqlConvertTinyint = 17,
2435 SqlConvertVarbinary = 18,
2436 SqlConvertVarchar = 19,
2437}
2438impl SqlSupportsConvert {
2439 /// String value of the enum field names used in the ProtoBuf definition.
2440 ///
2441 /// The values are not transformed in any way and thus are considered stable
2442 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2443 pub fn as_str_name(&self) -> &'static str {
2444 match self {
2445 Self::SqlConvertBigint => "SQL_CONVERT_BIGINT",
2446 Self::SqlConvertBinary => "SQL_CONVERT_BINARY",
2447 Self::SqlConvertBit => "SQL_CONVERT_BIT",
2448 Self::SqlConvertChar => "SQL_CONVERT_CHAR",
2449 Self::SqlConvertDate => "SQL_CONVERT_DATE",
2450 Self::SqlConvertDecimal => "SQL_CONVERT_DECIMAL",
2451 Self::SqlConvertFloat => "SQL_CONVERT_FLOAT",
2452 Self::SqlConvertInteger => "SQL_CONVERT_INTEGER",
2453 Self::SqlConvertIntervalDayTime => "SQL_CONVERT_INTERVAL_DAY_TIME",
2454 Self::SqlConvertIntervalYearMonth => "SQL_CONVERT_INTERVAL_YEAR_MONTH",
2455 Self::SqlConvertLongvarbinary => "SQL_CONVERT_LONGVARBINARY",
2456 Self::SqlConvertLongvarchar => "SQL_CONVERT_LONGVARCHAR",
2457 Self::SqlConvertNumeric => "SQL_CONVERT_NUMERIC",
2458 Self::SqlConvertReal => "SQL_CONVERT_REAL",
2459 Self::SqlConvertSmallint => "SQL_CONVERT_SMALLINT",
2460 Self::SqlConvertTime => "SQL_CONVERT_TIME",
2461 Self::SqlConvertTimestamp => "SQL_CONVERT_TIMESTAMP",
2462 Self::SqlConvertTinyint => "SQL_CONVERT_TINYINT",
2463 Self::SqlConvertVarbinary => "SQL_CONVERT_VARBINARY",
2464 Self::SqlConvertVarchar => "SQL_CONVERT_VARCHAR",
2465 }
2466 }
2467 /// Creates an enum from field names used in the ProtoBuf definition.
2468 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2469 match value {
2470 "SQL_CONVERT_BIGINT" => Some(Self::SqlConvertBigint),
2471 "SQL_CONVERT_BINARY" => Some(Self::SqlConvertBinary),
2472 "SQL_CONVERT_BIT" => Some(Self::SqlConvertBit),
2473 "SQL_CONVERT_CHAR" => Some(Self::SqlConvertChar),
2474 "SQL_CONVERT_DATE" => Some(Self::SqlConvertDate),
2475 "SQL_CONVERT_DECIMAL" => Some(Self::SqlConvertDecimal),
2476 "SQL_CONVERT_FLOAT" => Some(Self::SqlConvertFloat),
2477 "SQL_CONVERT_INTEGER" => Some(Self::SqlConvertInteger),
2478 "SQL_CONVERT_INTERVAL_DAY_TIME" => Some(Self::SqlConvertIntervalDayTime),
2479 "SQL_CONVERT_INTERVAL_YEAR_MONTH" => Some(Self::SqlConvertIntervalYearMonth),
2480 "SQL_CONVERT_LONGVARBINARY" => Some(Self::SqlConvertLongvarbinary),
2481 "SQL_CONVERT_LONGVARCHAR" => Some(Self::SqlConvertLongvarchar),
2482 "SQL_CONVERT_NUMERIC" => Some(Self::SqlConvertNumeric),
2483 "SQL_CONVERT_REAL" => Some(Self::SqlConvertReal),
2484 "SQL_CONVERT_SMALLINT" => Some(Self::SqlConvertSmallint),
2485 "SQL_CONVERT_TIME" => Some(Self::SqlConvertTime),
2486 "SQL_CONVERT_TIMESTAMP" => Some(Self::SqlConvertTimestamp),
2487 "SQL_CONVERT_TINYINT" => Some(Self::SqlConvertTinyint),
2488 "SQL_CONVERT_VARBINARY" => Some(Self::SqlConvertVarbinary),
2489 "SQL_CONVERT_VARCHAR" => Some(Self::SqlConvertVarchar),
2490 _ => None,
2491 }
2492 }
2493}
2494/// *
2495/// The JDBC/ODBC-defined type of any object.
2496/// All the values here are the same as in the JDBC and ODBC specs.
2497#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2498#[repr(i32)]
2499pub enum XdbcDataType {
2500 XdbcUnknownType = 0,
2501 XdbcChar = 1,
2502 XdbcNumeric = 2,
2503 XdbcDecimal = 3,
2504 XdbcInteger = 4,
2505 XdbcSmallint = 5,
2506 XdbcFloat = 6,
2507 XdbcReal = 7,
2508 XdbcDouble = 8,
2509 XdbcDatetime = 9,
2510 XdbcInterval = 10,
2511 XdbcVarchar = 12,
2512 XdbcDate = 91,
2513 XdbcTime = 92,
2514 XdbcTimestamp = 93,
2515 XdbcLongvarchar = -1,
2516 XdbcBinary = -2,
2517 XdbcVarbinary = -3,
2518 XdbcLongvarbinary = -4,
2519 XdbcBigint = -5,
2520 XdbcTinyint = -6,
2521 XdbcBit = -7,
2522 XdbcWchar = -8,
2523 XdbcWvarchar = -9,
2524}
2525impl XdbcDataType {
2526 /// String value of the enum field names used in the ProtoBuf definition.
2527 ///
2528 /// The values are not transformed in any way and thus are considered stable
2529 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2530 pub fn as_str_name(&self) -> &'static str {
2531 match self {
2532 Self::XdbcUnknownType => "XDBC_UNKNOWN_TYPE",
2533 Self::XdbcChar => "XDBC_CHAR",
2534 Self::XdbcNumeric => "XDBC_NUMERIC",
2535 Self::XdbcDecimal => "XDBC_DECIMAL",
2536 Self::XdbcInteger => "XDBC_INTEGER",
2537 Self::XdbcSmallint => "XDBC_SMALLINT",
2538 Self::XdbcFloat => "XDBC_FLOAT",
2539 Self::XdbcReal => "XDBC_REAL",
2540 Self::XdbcDouble => "XDBC_DOUBLE",
2541 Self::XdbcDatetime => "XDBC_DATETIME",
2542 Self::XdbcInterval => "XDBC_INTERVAL",
2543 Self::XdbcVarchar => "XDBC_VARCHAR",
2544 Self::XdbcDate => "XDBC_DATE",
2545 Self::XdbcTime => "XDBC_TIME",
2546 Self::XdbcTimestamp => "XDBC_TIMESTAMP",
2547 Self::XdbcLongvarchar => "XDBC_LONGVARCHAR",
2548 Self::XdbcBinary => "XDBC_BINARY",
2549 Self::XdbcVarbinary => "XDBC_VARBINARY",
2550 Self::XdbcLongvarbinary => "XDBC_LONGVARBINARY",
2551 Self::XdbcBigint => "XDBC_BIGINT",
2552 Self::XdbcTinyint => "XDBC_TINYINT",
2553 Self::XdbcBit => "XDBC_BIT",
2554 Self::XdbcWchar => "XDBC_WCHAR",
2555 Self::XdbcWvarchar => "XDBC_WVARCHAR",
2556 }
2557 }
2558 /// Creates an enum from field names used in the ProtoBuf definition.
2559 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2560 match value {
2561 "XDBC_UNKNOWN_TYPE" => Some(Self::XdbcUnknownType),
2562 "XDBC_CHAR" => Some(Self::XdbcChar),
2563 "XDBC_NUMERIC" => Some(Self::XdbcNumeric),
2564 "XDBC_DECIMAL" => Some(Self::XdbcDecimal),
2565 "XDBC_INTEGER" => Some(Self::XdbcInteger),
2566 "XDBC_SMALLINT" => Some(Self::XdbcSmallint),
2567 "XDBC_FLOAT" => Some(Self::XdbcFloat),
2568 "XDBC_REAL" => Some(Self::XdbcReal),
2569 "XDBC_DOUBLE" => Some(Self::XdbcDouble),
2570 "XDBC_DATETIME" => Some(Self::XdbcDatetime),
2571 "XDBC_INTERVAL" => Some(Self::XdbcInterval),
2572 "XDBC_VARCHAR" => Some(Self::XdbcVarchar),
2573 "XDBC_DATE" => Some(Self::XdbcDate),
2574 "XDBC_TIME" => Some(Self::XdbcTime),
2575 "XDBC_TIMESTAMP" => Some(Self::XdbcTimestamp),
2576 "XDBC_LONGVARCHAR" => Some(Self::XdbcLongvarchar),
2577 "XDBC_BINARY" => Some(Self::XdbcBinary),
2578 "XDBC_VARBINARY" => Some(Self::XdbcVarbinary),
2579 "XDBC_LONGVARBINARY" => Some(Self::XdbcLongvarbinary),
2580 "XDBC_BIGINT" => Some(Self::XdbcBigint),
2581 "XDBC_TINYINT" => Some(Self::XdbcTinyint),
2582 "XDBC_BIT" => Some(Self::XdbcBit),
2583 "XDBC_WCHAR" => Some(Self::XdbcWchar),
2584 "XDBC_WVARCHAR" => Some(Self::XdbcWvarchar),
2585 _ => None,
2586 }
2587 }
2588}
2589/// *
2590/// Detailed subtype information for XDBC_TYPE_DATETIME and XDBC_TYPE_INTERVAL.
2591#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2592#[repr(i32)]
2593pub enum XdbcDatetimeSubcode {
2594 XdbcSubcodeUnknown = 0,
2595 XdbcSubcodeYear = 1,
2596 XdbcSubcodeTime = 2,
2597 XdbcSubcodeTimestamp = 3,
2598 XdbcSubcodeTimeWithTimezone = 4,
2599 XdbcSubcodeTimestampWithTimezone = 5,
2600 XdbcSubcodeSecond = 6,
2601 XdbcSubcodeYearToMonth = 7,
2602 XdbcSubcodeDayToHour = 8,
2603 XdbcSubcodeDayToMinute = 9,
2604 XdbcSubcodeDayToSecond = 10,
2605 XdbcSubcodeHourToMinute = 11,
2606 XdbcSubcodeHourToSecond = 12,
2607 XdbcSubcodeMinuteToSecond = 13,
2608 XdbcSubcodeIntervalYear = 101,
2609 XdbcSubcodeIntervalMonth = 102,
2610 XdbcSubcodeIntervalDay = 103,
2611 XdbcSubcodeIntervalHour = 104,
2612 XdbcSubcodeIntervalMinute = 105,
2613 XdbcSubcodeIntervalSecond = 106,
2614 XdbcSubcodeIntervalYearToMonth = 107,
2615 XdbcSubcodeIntervalDayToHour = 108,
2616 XdbcSubcodeIntervalDayToMinute = 109,
2617 XdbcSubcodeIntervalDayToSecond = 110,
2618 XdbcSubcodeIntervalHourToMinute = 111,
2619 XdbcSubcodeIntervalHourToSecond = 112,
2620 XdbcSubcodeIntervalMinuteToSecond = 113,
2621}
2622impl XdbcDatetimeSubcode {
2623 /// String value of the enum field names used in the ProtoBuf definition.
2624 ///
2625 /// The values are not transformed in any way and thus are considered stable
2626 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2627 pub fn as_str_name(&self) -> &'static str {
2628 match self {
2629 Self::XdbcSubcodeUnknown => "XDBC_SUBCODE_UNKNOWN",
2630 Self::XdbcSubcodeYear => "XDBC_SUBCODE_YEAR",
2631 Self::XdbcSubcodeTime => "XDBC_SUBCODE_TIME",
2632 Self::XdbcSubcodeTimestamp => "XDBC_SUBCODE_TIMESTAMP",
2633 Self::XdbcSubcodeTimeWithTimezone => "XDBC_SUBCODE_TIME_WITH_TIMEZONE",
2634 Self::XdbcSubcodeTimestampWithTimezone => {
2635 "XDBC_SUBCODE_TIMESTAMP_WITH_TIMEZONE"
2636 }
2637 Self::XdbcSubcodeSecond => "XDBC_SUBCODE_SECOND",
2638 Self::XdbcSubcodeYearToMonth => "XDBC_SUBCODE_YEAR_TO_MONTH",
2639 Self::XdbcSubcodeDayToHour => "XDBC_SUBCODE_DAY_TO_HOUR",
2640 Self::XdbcSubcodeDayToMinute => "XDBC_SUBCODE_DAY_TO_MINUTE",
2641 Self::XdbcSubcodeDayToSecond => "XDBC_SUBCODE_DAY_TO_SECOND",
2642 Self::XdbcSubcodeHourToMinute => "XDBC_SUBCODE_HOUR_TO_MINUTE",
2643 Self::XdbcSubcodeHourToSecond => "XDBC_SUBCODE_HOUR_TO_SECOND",
2644 Self::XdbcSubcodeMinuteToSecond => "XDBC_SUBCODE_MINUTE_TO_SECOND",
2645 Self::XdbcSubcodeIntervalYear => "XDBC_SUBCODE_INTERVAL_YEAR",
2646 Self::XdbcSubcodeIntervalMonth => "XDBC_SUBCODE_INTERVAL_MONTH",
2647 Self::XdbcSubcodeIntervalDay => "XDBC_SUBCODE_INTERVAL_DAY",
2648 Self::XdbcSubcodeIntervalHour => "XDBC_SUBCODE_INTERVAL_HOUR",
2649 Self::XdbcSubcodeIntervalMinute => "XDBC_SUBCODE_INTERVAL_MINUTE",
2650 Self::XdbcSubcodeIntervalSecond => "XDBC_SUBCODE_INTERVAL_SECOND",
2651 Self::XdbcSubcodeIntervalYearToMonth => "XDBC_SUBCODE_INTERVAL_YEAR_TO_MONTH",
2652 Self::XdbcSubcodeIntervalDayToHour => "XDBC_SUBCODE_INTERVAL_DAY_TO_HOUR",
2653 Self::XdbcSubcodeIntervalDayToMinute => "XDBC_SUBCODE_INTERVAL_DAY_TO_MINUTE",
2654 Self::XdbcSubcodeIntervalDayToSecond => "XDBC_SUBCODE_INTERVAL_DAY_TO_SECOND",
2655 Self::XdbcSubcodeIntervalHourToMinute => {
2656 "XDBC_SUBCODE_INTERVAL_HOUR_TO_MINUTE"
2657 }
2658 Self::XdbcSubcodeIntervalHourToSecond => {
2659 "XDBC_SUBCODE_INTERVAL_HOUR_TO_SECOND"
2660 }
2661 Self::XdbcSubcodeIntervalMinuteToSecond => {
2662 "XDBC_SUBCODE_INTERVAL_MINUTE_TO_SECOND"
2663 }
2664 }
2665 }
2666 /// Creates an enum from field names used in the ProtoBuf definition.
2667 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2668 match value {
2669 "XDBC_SUBCODE_UNKNOWN" => Some(Self::XdbcSubcodeUnknown),
2670 "XDBC_SUBCODE_YEAR" => Some(Self::XdbcSubcodeYear),
2671 "XDBC_SUBCODE_TIME" => Some(Self::XdbcSubcodeTime),
2672 "XDBC_SUBCODE_TIMESTAMP" => Some(Self::XdbcSubcodeTimestamp),
2673 "XDBC_SUBCODE_TIME_WITH_TIMEZONE" => Some(Self::XdbcSubcodeTimeWithTimezone),
2674 "XDBC_SUBCODE_TIMESTAMP_WITH_TIMEZONE" => {
2675 Some(Self::XdbcSubcodeTimestampWithTimezone)
2676 }
2677 "XDBC_SUBCODE_SECOND" => Some(Self::XdbcSubcodeSecond),
2678 "XDBC_SUBCODE_YEAR_TO_MONTH" => Some(Self::XdbcSubcodeYearToMonth),
2679 "XDBC_SUBCODE_DAY_TO_HOUR" => Some(Self::XdbcSubcodeDayToHour),
2680 "XDBC_SUBCODE_DAY_TO_MINUTE" => Some(Self::XdbcSubcodeDayToMinute),
2681 "XDBC_SUBCODE_DAY_TO_SECOND" => Some(Self::XdbcSubcodeDayToSecond),
2682 "XDBC_SUBCODE_HOUR_TO_MINUTE" => Some(Self::XdbcSubcodeHourToMinute),
2683 "XDBC_SUBCODE_HOUR_TO_SECOND" => Some(Self::XdbcSubcodeHourToSecond),
2684 "XDBC_SUBCODE_MINUTE_TO_SECOND" => Some(Self::XdbcSubcodeMinuteToSecond),
2685 "XDBC_SUBCODE_INTERVAL_YEAR" => Some(Self::XdbcSubcodeIntervalYear),
2686 "XDBC_SUBCODE_INTERVAL_MONTH" => Some(Self::XdbcSubcodeIntervalMonth),
2687 "XDBC_SUBCODE_INTERVAL_DAY" => Some(Self::XdbcSubcodeIntervalDay),
2688 "XDBC_SUBCODE_INTERVAL_HOUR" => Some(Self::XdbcSubcodeIntervalHour),
2689 "XDBC_SUBCODE_INTERVAL_MINUTE" => Some(Self::XdbcSubcodeIntervalMinute),
2690 "XDBC_SUBCODE_INTERVAL_SECOND" => Some(Self::XdbcSubcodeIntervalSecond),
2691 "XDBC_SUBCODE_INTERVAL_YEAR_TO_MONTH" => {
2692 Some(Self::XdbcSubcodeIntervalYearToMonth)
2693 }
2694 "XDBC_SUBCODE_INTERVAL_DAY_TO_HOUR" => {
2695 Some(Self::XdbcSubcodeIntervalDayToHour)
2696 }
2697 "XDBC_SUBCODE_INTERVAL_DAY_TO_MINUTE" => {
2698 Some(Self::XdbcSubcodeIntervalDayToMinute)
2699 }
2700 "XDBC_SUBCODE_INTERVAL_DAY_TO_SECOND" => {
2701 Some(Self::XdbcSubcodeIntervalDayToSecond)
2702 }
2703 "XDBC_SUBCODE_INTERVAL_HOUR_TO_MINUTE" => {
2704 Some(Self::XdbcSubcodeIntervalHourToMinute)
2705 }
2706 "XDBC_SUBCODE_INTERVAL_HOUR_TO_SECOND" => {
2707 Some(Self::XdbcSubcodeIntervalHourToSecond)
2708 }
2709 "XDBC_SUBCODE_INTERVAL_MINUTE_TO_SECOND" => {
2710 Some(Self::XdbcSubcodeIntervalMinuteToSecond)
2711 }
2712 _ => None,
2713 }
2714 }
2715}
2716#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2717#[repr(i32)]
2718pub enum Nullable {
2719 /// *
2720 /// Indicates that the fields does not allow the use of null values.
2721 NullabilityNoNulls = 0,
2722 /// *
2723 /// Indicates that the fields allow the use of null values.
2724 NullabilityNullable = 1,
2725 /// *
2726 /// Indicates that nullability of the fields cannot be determined.
2727 NullabilityUnknown = 2,
2728}
2729impl Nullable {
2730 /// String value of the enum field names used in the ProtoBuf definition.
2731 ///
2732 /// The values are not transformed in any way and thus are considered stable
2733 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2734 pub fn as_str_name(&self) -> &'static str {
2735 match self {
2736 Self::NullabilityNoNulls => "NULLABILITY_NO_NULLS",
2737 Self::NullabilityNullable => "NULLABILITY_NULLABLE",
2738 Self::NullabilityUnknown => "NULLABILITY_UNKNOWN",
2739 }
2740 }
2741 /// Creates an enum from field names used in the ProtoBuf definition.
2742 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2743 match value {
2744 "NULLABILITY_NO_NULLS" => Some(Self::NullabilityNoNulls),
2745 "NULLABILITY_NULLABLE" => Some(Self::NullabilityNullable),
2746 "NULLABILITY_UNKNOWN" => Some(Self::NullabilityUnknown),
2747 _ => None,
2748 }
2749 }
2750}
2751#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2752#[repr(i32)]
2753pub enum Searchable {
2754 /// *
2755 /// Indicates that column cannot be used in a WHERE clause.
2756 None = 0,
2757 /// *
2758 /// Indicates that the column can be used in a WHERE clause if it is using a
2759 /// LIKE operator.
2760 Char = 1,
2761 /// *
2762 /// Indicates that the column can be used In a WHERE clause with any
2763 /// operator other than LIKE.
2764 ///
2765 /// - Allowed operators: comparison, quantified comparison, BETWEEN,
2766 /// DISTINCT, IN, MATCH, and UNIQUE.
2767 Basic = 2,
2768 /// *
2769 /// Indicates that the column can be used in a WHERE clause using any operator.
2770 Full = 3,
2771}
2772impl Searchable {
2773 /// String value of the enum field names used in the ProtoBuf definition.
2774 ///
2775 /// The values are not transformed in any way and thus are considered stable
2776 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2777 pub fn as_str_name(&self) -> &'static str {
2778 match self {
2779 Self::None => "SEARCHABLE_NONE",
2780 Self::Char => "SEARCHABLE_CHAR",
2781 Self::Basic => "SEARCHABLE_BASIC",
2782 Self::Full => "SEARCHABLE_FULL",
2783 }
2784 }
2785 /// Creates an enum from field names used in the ProtoBuf definition.
2786 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2787 match value {
2788 "SEARCHABLE_NONE" => Some(Self::None),
2789 "SEARCHABLE_CHAR" => Some(Self::Char),
2790 "SEARCHABLE_BASIC" => Some(Self::Basic),
2791 "SEARCHABLE_FULL" => Some(Self::Full),
2792 _ => None,
2793 }
2794 }
2795}
2796#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)]
2797#[repr(i32)]
2798pub enum UpdateDeleteRules {
2799 Cascade = 0,
2800 Restrict = 1,
2801 SetNull = 2,
2802 NoAction = 3,
2803 SetDefault = 4,
2804}
2805impl UpdateDeleteRules {
2806 /// String value of the enum field names used in the ProtoBuf definition.
2807 ///
2808 /// The values are not transformed in any way and thus are considered stable
2809 /// (if the ProtoBuf definition does not change) and safe for programmatic use.
2810 pub fn as_str_name(&self) -> &'static str {
2811 match self {
2812 Self::Cascade => "CASCADE",
2813 Self::Restrict => "RESTRICT",
2814 Self::SetNull => "SET_NULL",
2815 Self::NoAction => "NO_ACTION",
2816 Self::SetDefault => "SET_DEFAULT",
2817 }
2818 }
2819 /// Creates an enum from field names used in the ProtoBuf definition.
2820 pub fn from_str_name(value: &str) -> ::core::option::Option<Self> {
2821 match value {
2822 "CASCADE" => Some(Self::Cascade),
2823 "RESTRICT" => Some(Self::Restrict),
2824 "SET_NULL" => Some(Self::SetNull),
2825 "NO_ACTION" => Some(Self::NoAction),
2826 "SET_DEFAULT" => Some(Self::SetDefault),
2827 _ => None,
2828 }
2829 }
2830}