;; From gda-batch.h

;; Original typedef:
;; typedef enum {
;; 	GDA_BATCH_CONFLICTING_PARAMETER_ERROR
;; } GdaBatchError;

(define-enum-extended BatchError
  (in-module "Gda")
  (c-name "GdaBatchError")
  (values
    '("conflicting-parameter-error" "GDA_BATCH_CONFLICTING_PARAMETER_ERROR" "0")
  )
)

;; From gda-binreloc.h

;; Original typedef:
;; typedef enum {
;; 	GDA_NO_DIR,
;; 	GDA_BIN_DIR,
;; 	GDA_SBIN_DIR,
;; 	GDA_DATA_DIR,
;; 	GDA_LOCALE_DIR,
;; 	GDA_LIB_DIR,
;; 	GDA_LIBEXEC_DIR,
;; 	GDA_ETC_DIR
;; } GdaPrefixDir;

(define-enum-extended PrefixDir
  (in-module "Gda")
  (c-name "GdaPrefixDir")
  (values
    '("no-dir" "GDA_NO_DIR" "0")
    '("bin-dir" "GDA_BIN_DIR" "1")
    '("sbin-dir" "GDA_SBIN_DIR" "2")
    '("data-dir" "GDA_DATA_DIR" "3")
    '("locale-dir" "GDA_LOCALE_DIR" "4")
    '("lib-dir" "GDA_LIB_DIR" "5")
    '("libexec-dir" "GDA_LIBEXEC_DIR" "6")
    '("etc-dir" "GDA_ETC_DIR" "7")
  )
)

;; From gda-config.h

;; Original typedef:
;; typedef enum {
;;         GDA_CONFIG_DSN_NOT_FOUND_ERROR,
;; 	GDA_CONFIG_PERMISSION_ERROR,
;; 	GDA_CONFIG_PROVIDER_NOT_FOUND_ERROR,
;; 	GDA_CONFIG_PROVIDER_CREATION_ERROR
;; } GdaConfigError;

(define-enum-extended ConfigError
  (in-module "Gda")
  (c-name "GdaConfigError")
  (values
    '("dsn-not-found-error" "GDA_CONFIG_DSN_NOT_FOUND_ERROR" "0")
    '("permission-error" "GDA_CONFIG_PERMISSION_ERROR" "1")
    '("provider-not-found-error" "GDA_CONFIG_PROVIDER_NOT_FOUND_ERROR" "2")
    '("provider-creation-error" "GDA_CONFIG_PROVIDER_CREATION_ERROR" "3")
  )
)

;; From gda-connection-event.h

;; Original typedef:
;; typedef enum {
;; 	GDA_CONNECTION_EVENT_NOTICE,
;; 	GDA_CONNECTION_EVENT_WARNING,
;; 	GDA_CONNECTION_EVENT_ERROR,
;; 	GDA_CONNECTION_EVENT_COMMAND
;; 	
;; } GdaConnectionEventType;

(define-enum-extended ConnectionEventType
  (in-module "Gda")
  (c-name "GdaConnectionEventType")
  (values
    '("notice" "GDA_CONNECTION_EVENT_NOTICE" "0")
    '("warning" "GDA_CONNECTION_EVENT_WARNING" "1")
    '("error" "GDA_CONNECTION_EVENT_ERROR" "2")
    '("command" "GDA_CONNECTION_EVENT_COMMAND" "3")
  )
)

;; Original typedef:
;; typedef enum
;; {
;;        GDA_CONNECTION_EVENT_CODE_CONSTRAINT_VIOLATION,
;;        GDA_CONNECTION_EVENT_CODE_RESTRICT_VIOLATION,
;;        GDA_CONNECTION_EVENT_CODE_NOT_NULL_VIOLATION,
;;        GDA_CONNECTION_EVENT_CODE_FOREIGN_KEY_VIOLATION,
;;        GDA_CONNECTION_EVENT_CODE_UNIQUE_VIOLATION,
;;        GDA_CONNECTION_EVENT_CODE_CHECK_VIOLATION,
;;        GDA_CONNECTION_EVENT_CODE_INSUFFICIENT_PRIVILEGES,
;;        GDA_CONNECTION_EVENT_CODE_UNDEFINED_COLUMN,
;;        GDA_CONNECTION_EVENT_CODE_UNDEFINED_FUNCTION,
;;        GDA_CONNECTION_EVENT_CODE_UNDEFINED_TABLE,
;;        GDA_CONNECTION_EVENT_CODE_DUPLICATE_COLUMN,
;;        GDA_CONNECTION_EVENT_CODE_DUPLICATE_DATABASE,
;;        GDA_CONNECTION_EVENT_CODE_DUPLICATE_FUNCTION,
;;        GDA_CONNECTION_EVENT_CODE_DUPLICATE_SCHEMA,
;;        GDA_CONNECTION_EVENT_CODE_DUPLICATE_TABLE,
;;        GDA_CONNECTION_EVENT_CODE_DUPLICATE_ALIAS,
;;        GDA_CONNECTION_EVENT_CODE_DUPLICATE_OBJECT,
;;        GDA_CONNECTION_EVENT_CODE_SYNTAX_ERROR,
;;        GDA_CONNECTION_EVENT_CODE_UNKNOWN
;; } GdaConnectionEventCode;

(define-enum-extended ConnectionEventCode
  (in-module "Gda")
  (c-name "GdaConnectionEventCode")
  (values
    '("constraint-violation" "GDA_CONNECTION_EVENT_CODE_CONSTRAINT_VIOLATION" "0")
    '("restrict-violation" "GDA_CONNECTION_EVENT_CODE_RESTRICT_VIOLATION" "1")
    '("not-null-violation" "GDA_CONNECTION_EVENT_CODE_NOT_NULL_VIOLATION" "2")
    '("foreign-key-violation" "GDA_CONNECTION_EVENT_CODE_FOREIGN_KEY_VIOLATION" "3")
    '("unique-violation" "GDA_CONNECTION_EVENT_CODE_UNIQUE_VIOLATION" "4")
    '("check-violation" "GDA_CONNECTION_EVENT_CODE_CHECK_VIOLATION" "5")
    '("insufficient-privileges" "GDA_CONNECTION_EVENT_CODE_INSUFFICIENT_PRIVILEGES" "6")
    '("undefined-column" "GDA_CONNECTION_EVENT_CODE_UNDEFINED_COLUMN" "7")
    '("undefined-function" "GDA_CONNECTION_EVENT_CODE_UNDEFINED_FUNCTION" "8")
    '("undefined-table" "GDA_CONNECTION_EVENT_CODE_UNDEFINED_TABLE" "9")
    '("duplicate-column" "GDA_CONNECTION_EVENT_CODE_DUPLICATE_COLUMN" "10")
    '("duplicate-database" "GDA_CONNECTION_EVENT_CODE_DUPLICATE_DATABASE" "11")
    '("duplicate-function" "GDA_CONNECTION_EVENT_CODE_DUPLICATE_FUNCTION" "12")
    '("duplicate-schema" "GDA_CONNECTION_EVENT_CODE_DUPLICATE_SCHEMA" "13")
    '("duplicate-table" "GDA_CONNECTION_EVENT_CODE_DUPLICATE_TABLE" "14")
    '("duplicate-alias" "GDA_CONNECTION_EVENT_CODE_DUPLICATE_ALIAS" "15")
    '("duplicate-object" "GDA_CONNECTION_EVENT_CODE_DUPLICATE_OBJECT" "16")
    '("syntax-error" "GDA_CONNECTION_EVENT_CODE_SYNTAX_ERROR" "17")
    '("unknown" "GDA_CONNECTION_EVENT_CODE_UNKNOWN" "18")
  )
)

;; From gda-connection.h

;; Original typedef:
;; typedef enum {
;; 	GDA_CONNECTION_DSN_NOT_FOUND_ERROR,
;; 	GDA_CONNECTION_PROVIDER_NOT_FOUND_ERROR,
;; 	GDA_CONNECTION_PROVIDER_ERROR,
;; 	GDA_CONNECTION_NO_CNC_SPEC_ERROR,
;; 	GDA_CONNECTION_NO_PROVIDER_SPEC_ERROR,
;; 	GDA_CONNECTION_OPEN_ERROR,
;; 	GDA_CONNECTION_STATEMENT_TYPE_ERROR,
;; 	GDA_CONNECTION_CANT_LOCK_ERROR,
;; 	GDA_CONNECTION_TASK_NOT_FOUND_ERROR,
;; 	GDA_CONNECTION_UNSUPPORTED_THREADS_ERROR,
;; 	GDA_CONNECTION_CLOSED_ERROR,
;; 	GDA_CONNECTION_META_DATA_CONTEXT_ERROR
;; } GdaConnectionError;

(define-enum-extended ConnectionError
  (in-module "Gda")
  (c-name "GdaConnectionError")
  (values
    '("dsn-not-found-error" "GDA_CONNECTION_DSN_NOT_FOUND_ERROR" "0")
    '("provider-not-found-error" "GDA_CONNECTION_PROVIDER_NOT_FOUND_ERROR" "1")
    '("provider-error" "GDA_CONNECTION_PROVIDER_ERROR" "2")
    '("no-cnc-spec-error" "GDA_CONNECTION_NO_CNC_SPEC_ERROR" "3")
    '("no-provider-spec-error" "GDA_CONNECTION_NO_PROVIDER_SPEC_ERROR" "4")
    '("open-error" "GDA_CONNECTION_OPEN_ERROR" "5")
    '("statement-type-error" "GDA_CONNECTION_STATEMENT_TYPE_ERROR" "6")
    '("cant-lock-error" "GDA_CONNECTION_CANT_LOCK_ERROR" "7")
    '("task-not-found-error" "GDA_CONNECTION_TASK_NOT_FOUND_ERROR" "8")
    '("unsupported-threads-error" "GDA_CONNECTION_UNSUPPORTED_THREADS_ERROR" "9")
    '("closed-error" "GDA_CONNECTION_CLOSED_ERROR" "10")
    '("meta-data-context-error" "GDA_CONNECTION_META_DATA_CONTEXT_ERROR" "11")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_CONNECTION_OPTIONS_NONE = 0,
;; 	GDA_CONNECTION_OPTIONS_READ_ONLY = 1 << 0,
;; 	GDA_CONNECTION_OPTIONS_SQL_IDENTIFIERS_CASE_SENSITIVE = 1 << 1,
;; 	GDA_CONNECTION_OPTIONS_THREAD_SAFE = 1 << 2,
;; 	GDA_CONNECTION_OPTIONS_THREAD_ISOLATED = 1 << 3,
;; 	GDA_CONNECTION_OPTIONS_AUTO_META_DATA = 1 << 4
;; } GdaConnectionOptions;

(define-flags-extended ConnectionOptions
  (in-module "Gda")
  (c-name "GdaConnectionOptions")
  (values
    '("none" "GDA_CONNECTION_OPTIONS_NONE" "0x0")
    '("read-only" "GDA_CONNECTION_OPTIONS_READ_ONLY" "1 << 0")
    '("sql-identifiers-case-sensitive" "GDA_CONNECTION_OPTIONS_SQL_IDENTIFIERS_CASE_SENSITIVE" "1 << 1")
    '("thread-safe" "GDA_CONNECTION_OPTIONS_THREAD_SAFE" "1 << 2")
    '("thread-isolated" "GDA_CONNECTION_OPTIONS_THREAD_ISOLATED" "1 << 3")
    '("auto-meta-data" "GDA_CONNECTION_OPTIONS_AUTO_META_DATA" "1 << 4")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_CONNECTION_FEATURE_AGGREGATES,
;; 	GDA_CONNECTION_FEATURE_BLOBS,
;; 	GDA_CONNECTION_FEATURE_INDEXES,
;; 	GDA_CONNECTION_FEATURE_INHERITANCE,
;; 	GDA_CONNECTION_FEATURE_NAMESPACES,
;; 	GDA_CONNECTION_FEATURE_PROCEDURES,
;; 	GDA_CONNECTION_FEATURE_SEQUENCES,
;; 	GDA_CONNECTION_FEATURE_SQL,
;; 	GDA_CONNECTION_FEATURE_TRANSACTIONS,
;; 	GDA_CONNECTION_FEATURE_SAVEPOINTS,
;; 	GDA_CONNECTION_FEATURE_SAVEPOINTS_REMOVE,
;; 	GDA_CONNECTION_FEATURE_TRIGGERS,
;; 	GDA_CONNECTION_FEATURE_UPDATABLE_CURSOR,
;; 	GDA_CONNECTION_FEATURE_USERS,
;; 	GDA_CONNECTION_FEATURE_VIEWS,
;; 	GDA_CONNECTION_FEATURE_XA_TRANSACTIONS,
;; 	
;; 	GDA_CONNECTION_FEATURE_MULTI_THREADING,
;; 
;; 	GDA_CONNECTION_FEATURE_LAST
;; } GdaConnectionFeature;

(define-enum-extended ConnectionFeature
  (in-module "Gda")
  (c-name "GdaConnectionFeature")
  (values
    '("aggregates" "GDA_CONNECTION_FEATURE_AGGREGATES" "0")
    '("blobs" "GDA_CONNECTION_FEATURE_BLOBS" "1")
    '("indexes" "GDA_CONNECTION_FEATURE_INDEXES" "2")
    '("inheritance" "GDA_CONNECTION_FEATURE_INHERITANCE" "3")
    '("namespaces" "GDA_CONNECTION_FEATURE_NAMESPACES" "4")
    '("procedures" "GDA_CONNECTION_FEATURE_PROCEDURES" "5")
    '("sequences" "GDA_CONNECTION_FEATURE_SEQUENCES" "6")
    '("sql" "GDA_CONNECTION_FEATURE_SQL" "7")
    '("transactions" "GDA_CONNECTION_FEATURE_TRANSACTIONS" "8")
    '("savepoints" "GDA_CONNECTION_FEATURE_SAVEPOINTS" "9")
    '("savepoints-remove" "GDA_CONNECTION_FEATURE_SAVEPOINTS_REMOVE" "10")
    '("triggers" "GDA_CONNECTION_FEATURE_TRIGGERS" "11")
    '("updatable-cursor" "GDA_CONNECTION_FEATURE_UPDATABLE_CURSOR" "12")
    '("users" "GDA_CONNECTION_FEATURE_USERS" "13")
    '("views" "GDA_CONNECTION_FEATURE_VIEWS" "14")
    '("xa-transactions" "GDA_CONNECTION_FEATURE_XA_TRANSACTIONS" "15")
    '("multi-threading" "GDA_CONNECTION_FEATURE_MULTI_THREADING" "16")
    '("last" "GDA_CONNECTION_FEATURE_LAST" "17")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_CONNECTION_META_NAMESPACES,
;; 	GDA_CONNECTION_META_TYPES,
;; 	GDA_CONNECTION_META_TABLES,
;; 	GDA_CONNECTION_META_VIEWS,
;; 	GDA_CONNECTION_META_FIELDS,
;; 	GDA_CONNECTION_META_INDEXES
;; } GdaConnectionMetaType;

(define-enum-extended ConnectionMetaType
  (in-module "Gda")
  (c-name "GdaConnectionMetaType")
  (values
    '("namespaces" "GDA_CONNECTION_META_NAMESPACES" "0")
    '("types" "GDA_CONNECTION_META_TYPES" "1")
    '("tables" "GDA_CONNECTION_META_TABLES" "2")
    '("views" "GDA_CONNECTION_META_VIEWS" "3")
    '("fields" "GDA_CONNECTION_META_FIELDS" "4")
    '("indexes" "GDA_CONNECTION_META_INDEXES" "5")
  )
)

;; From gda-data-comparator.h

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_COMPARATOR_MISSING_DATA_MODEL_ERROR,
;; 	GDA_DATA_COMPARATOR_COLUMN_TYPES_MISMATCH_ERROR,
;; 	GDA_DATA_COMPARATOR_MODEL_ACCESS_ERROR,
;; 	GDA_DATA_COMPARATOR_USER_CANCELLED_ERROR
;; } GdaDataComparatorError;

(define-enum-extended DataComparatorError
  (in-module "Gda")
  (c-name "GdaDataComparatorError")
  (values
    '("missing-data-model-error" "GDA_DATA_COMPARATOR_MISSING_DATA_MODEL_ERROR" "0")
    '("column-types-mismatch-error" "GDA_DATA_COMPARATOR_COLUMN_TYPES_MISMATCH_ERROR" "1")
    '("model-access-error" "GDA_DATA_COMPARATOR_MODEL_ACCESS_ERROR" "2")
    '("user-cancelled-error" "GDA_DATA_COMPARATOR_USER_CANCELLED_ERROR" "3")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_DIFF_ADD_ROW,
;; 	GDA_DIFF_REMOVE_ROW,
;; 	GDA_DIFF_MODIFY_ROW
;; } GdaDiffType;

(define-enum-extended DiffType
  (in-module "Gda")
  (c-name "GdaDiffType")
  (values
    '("add-row" "GDA_DIFF_ADD_ROW" "0")
    '("remove-row" "GDA_DIFF_REMOVE_ROW" "1")
    '("modify-row" "GDA_DIFF_MODIFY_ROW" "2")
  )
)

;; From gda-data-model.h

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_MODEL_ACCESS_RANDOM = 1 << 0,
;; 	GDA_DATA_MODEL_ACCESS_CURSOR_FORWARD = 1 << 1,
;; 	GDA_DATA_MODEL_ACCESS_CURSOR_BACKWARD = 1 << 2,
;; 	GDA_DATA_MODEL_ACCESS_CURSOR = GDA_DATA_MODEL_ACCESS_CURSOR_FORWARD | GDA_DATA_MODEL_ACCESS_CURSOR_BACKWARD,
;; 	GDA_DATA_MODEL_ACCESS_INSERT  = 1 << 3,
;; 	GDA_DATA_MODEL_ACCESS_UPDATE  = 1 << 4,
;; 	GDA_DATA_MODEL_ACCESS_DELETE  = 1 << 5,
;; 	GDA_DATA_MODEL_ACCESS_WRITE = GDA_DATA_MODEL_ACCESS_INSERT | GDA_DATA_MODEL_ACCESS_UPDATE |
;; 	GDA_DATA_MODEL_ACCESS_DELETE
;; } GdaDataModelAccessFlags;

(define-flags-extended DataModelAccessFlags
  (in-module "Gda")
  (c-name "GdaDataModelAccessFlags")
  (values
    '("random" "GDA_DATA_MODEL_ACCESS_RANDOM" "1 << 0")
    '("cursor-forward" "GDA_DATA_MODEL_ACCESS_CURSOR_FORWARD" "1 << 1")
    '("cursor-backward" "GDA_DATA_MODEL_ACCESS_CURSOR_BACKWARD" "1 << 2")
    '("cursor" "GDA_DATA_MODEL_ACCESS_CURSOR" "0x6")
    '("insert" "GDA_DATA_MODEL_ACCESS_INSERT" "1 << 3")
    '("update" "GDA_DATA_MODEL_ACCESS_UPDATE" "1 << 4")
    '("delete" "GDA_DATA_MODEL_ACCESS_DELETE" "1 << 5")
    '("write" "GDA_DATA_MODEL_ACCESS_WRITE" "0x38")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_MODEL_HINT_START_BATCH_UPDATE,
;; 	GDA_DATA_MODEL_HINT_END_BATCH_UPDATE,
;; 	GDA_DATA_MODEL_HINT_REFRESH
;; } GdaDataModelHint;

(define-enum-extended DataModelHint
  (in-module "Gda")
  (c-name "GdaDataModelHint")
  (values
    '("start-batch-update" "GDA_DATA_MODEL_HINT_START_BATCH_UPDATE" "0")
    '("end-batch-update" "GDA_DATA_MODEL_HINT_END_BATCH_UPDATE" "1")
    '("refresh" "GDA_DATA_MODEL_HINT_REFRESH" "2")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_MODEL_IO_DATA_ARRAY_XML,
;; 	GDA_DATA_MODEL_IO_TEXT_SEPARATED
;; } GdaDataModelIOFormat;

(define-enum-extended DataModelIOFormat
  (in-module "Gda")
  (c-name "GdaDataModelIOFormat")
  (values
    '("data-array-xml" "GDA_DATA_MODEL_IO_DATA_ARRAY_XML" "0")
    '("text-separated" "GDA_DATA_MODEL_IO_TEXT_SEPARATED" "1")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_MODEL_ROW_OUT_OF_RANGE_ERROR,
;; 	GDA_DATA_MODEL_COLUMN_OUT_OF_RANGE_ERROR,
;; 	GDA_DATA_MODEL_VALUES_LIST_ERROR,
;; 	GDA_DATA_MODEL_VALUE_TYPE_ERROR,
;; 	GDA_DATA_MODEL_ROW_NOT_FOUND_ERROR,
;; 	GDA_DATA_MODEL_ACCESS_ERROR,
;; 	GDA_DATA_MODEL_FEATURE_NON_SUPPORTED_ERROR,
;; 	GDA_DATA_MODEL_FILE_EXIST_ERROR,
;; 	GDA_DATA_MODEL_XML_FORMAT_ERROR,
;; 
;; 	GDA_DATA_MODEL_TRUNCATED_ERROR,
;; 	GDA_DATA_MODEL_OTHER_ERROR
;; } GdaDataModelError;

(define-enum-extended DataModelError
  (in-module "Gda")
  (c-name "GdaDataModelError")
  (values
    '("row-out-of-range-error" "GDA_DATA_MODEL_ROW_OUT_OF_RANGE_ERROR" "0")
    '("column-out-of-range-error" "GDA_DATA_MODEL_COLUMN_OUT_OF_RANGE_ERROR" "1")
    '("values-list-error" "GDA_DATA_MODEL_VALUES_LIST_ERROR" "2")
    '("value-type-error" "GDA_DATA_MODEL_VALUE_TYPE_ERROR" "3")
    '("row-not-found-error" "GDA_DATA_MODEL_ROW_NOT_FOUND_ERROR" "4")
    '("access-error" "GDA_DATA_MODEL_ACCESS_ERROR" "5")
    '("feature-non-supported-error" "GDA_DATA_MODEL_FEATURE_NON_SUPPORTED_ERROR" "6")
    '("file-exist-error" "GDA_DATA_MODEL_FILE_EXIST_ERROR" "7")
    '("xml-format-error" "GDA_DATA_MODEL_XML_FORMAT_ERROR" "8")
    '("truncated-error" "GDA_DATA_MODEL_TRUNCATED_ERROR" "9")
    '("other-error" "GDA_DATA_MODEL_OTHER_ERROR" "10")
  )
)

;; From gda-data-model-iter.h

;; Original typedef:
;; typedef enum
;; {
;; 	GDA_DATA_MODEL_ITER_COLUMN_OUT_OF_RANGE_ERROR
;; } GdaDataModelIterError;

(define-enum-extended DataModelIterError
  (in-module "Gda")
  (c-name "GdaDataModelIterError")
  (values
    '("column-out-of-range-error" "GDA_DATA_MODEL_ITER_COLUMN_OUT_OF_RANGE_ERROR" "0")
  )
)

;; From gda-data-model-ldap.h

;; Original typedef:
;; typedef enum {	
;; 	GDA_LDAP_SEARCH_BASE     = 1,
;; 	GDA_LDAP_SEARCH_ONELEVEL = 2,
;; 	GDA_LDAP_SEARCH_SUBTREE  = 3
;; } GdaLdapSearchScope;

(define-enum-extended LdapSearchScope
  (in-module "Gda")
  (c-name "GdaLdapSearchScope")
  (values
    '("base" "GDA_LDAP_SEARCH_BASE" "1")
    '("onelevel" "GDA_LDAP_SEARCH_ONELEVEL" "2")
    '("subtree" "GDA_LDAP_SEARCH_SUBTREE" "3")
  )
)

;; From gda-data-pivot.h

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_PIVOT_INTERNAL_ERROR,
;; 	GDA_DATA_PIVOT_SOURCE_MODEL_ERROR,
;;         GDA_DATA_PIVOT_FIELD_FORMAT_ERROR,
;; 	GDA_DATA_PIVOT_USAGE_ERROR,
;; 	GDA_DATA_PIVOT_OVERFLOW_ERROR
;; } GdaDataPivotError;

(define-enum-extended DataPivotError
  (in-module "Gda")
  (c-name "GdaDataPivotError")
  (values
    '("internal-error" "GDA_DATA_PIVOT_INTERNAL_ERROR" "0")
    '("source-model-error" "GDA_DATA_PIVOT_SOURCE_MODEL_ERROR" "1")
    '("field-format-error" "GDA_DATA_PIVOT_FIELD_FORMAT_ERROR" "2")
    '("usage-error" "GDA_DATA_PIVOT_USAGE_ERROR" "3")
    '("overflow-error" "GDA_DATA_PIVOT_OVERFLOW_ERROR" "4")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_PIVOT_AVG,
;; 	GDA_DATA_PIVOT_COUNT,
;; 	GDA_DATA_PIVOT_MAX,
;; 	GDA_DATA_PIVOT_MIN,
;; 	GDA_DATA_PIVOT_SUM
;; } GdaDataPivotAggregate;

(define-enum-extended DataPivotAggregate
  (in-module "Gda")
  (c-name "GdaDataPivotAggregate")
  (values
    '("avg" "GDA_DATA_PIVOT_AVG" "0")
    '("count" "GDA_DATA_PIVOT_COUNT" "1")
    '("max" "GDA_DATA_PIVOT_MAX" "2")
    '("min" "GDA_DATA_PIVOT_MIN" "3")
    '("sum" "GDA_DATA_PIVOT_SUM" "4")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_PIVOT_FIELD_ROW,
;; 	GDA_DATA_PIVOT_FIELD_COLUMN
;; } GdaDataPivotFieldType;

(define-enum-extended DataPivotFieldType
  (in-module "Gda")
  (c-name "GdaDataPivotFieldType")
  (values
    '("row" "GDA_DATA_PIVOT_FIELD_ROW" "0")
    '("column" "GDA_DATA_PIVOT_FIELD_COLUMN" "1")
  )
)

;; From gda-data-proxy.h

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_PROXY_COMMIT_ERROR,
;; 	GDA_DATA_PROXY_COMMIT_CANCELLED,
;; 	GDA_DATA_PROXY_READ_ONLY_VALUE,
;; 	GDA_DATA_PROXY_READ_ONLY_ROW,
;; 	GDA_DATA_PROXY_FILTER_ERROR
;; } GdaDataProxyError;

(define-enum-extended DataProxyError
  (in-module "Gda")
  (c-name "GdaDataProxyError")
  (values
    '("commit-error" "GDA_DATA_PROXY_COMMIT_ERROR" "0")
    '("commit-cancelled" "GDA_DATA_PROXY_COMMIT_CANCELLED" "1")
    '("read-only-value" "GDA_DATA_PROXY_READ_ONLY_VALUE" "2")
    '("read-only-row" "GDA_DATA_PROXY_READ_ONLY_ROW" "3")
    '("filter-error" "GDA_DATA_PROXY_FILTER_ERROR" "4")
  )
)

;; From gda-data-select.h

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_SELECT_MODIFICATION_STATEMENT_ERROR,
;; 	GDA_DATA_SELECT_MISSING_MODIFICATION_STATEMENT_ERROR,
;; 	GDA_DATA_SELECT_CONNECTION_ERROR,
;; 	GDA_DATA_SELECT_ACCESS_ERROR,
;; 	GDA_DATA_SELECT_SQL_ERROR,
;; 	GDA_DATA_SELECT_SAFETY_LOCKED_ERROR
;; } GdaDataSelectError;

(define-enum-extended DataSelectError
  (in-module "Gda")
  (c-name "GdaDataSelectError")
  (values
    '("modification-statement-error" "GDA_DATA_SELECT_MODIFICATION_STATEMENT_ERROR" "0")
    '("missing-modification-statement-error" "GDA_DATA_SELECT_MISSING_MODIFICATION_STATEMENT_ERROR" "1")
    '("connection-error" "GDA_DATA_SELECT_CONNECTION_ERROR" "2")
    '("access-error" "GDA_DATA_SELECT_ACCESS_ERROR" "3")
    '("sql-error" "GDA_DATA_SELECT_SQL_ERROR" "4")
    '("safety-locked-error" "GDA_DATA_SELECT_SAFETY_LOCKED_ERROR" "5")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_DATA_SELECT_COND_PK,
;; 	GDA_DATA_SELECT_COND_ALL_COLUMNS
;; } GdaDataSelectConditionType;

(define-enum-extended DataSelectConditionType
  (in-module "Gda")
  (c-name "GdaDataSelectConditionType")
  (values
    '("pk" "GDA_DATA_SELECT_COND_PK" "0")
    '("all-columns" "GDA_DATA_SELECT_COND_ALL_COLUMNS" "1")
  )
)

;; From gda-enums.h

;; Original typedef:
;; typedef enum {
;; 	GDA_TRANSACTION_ISOLATION_UNKNOWN,
;; 	GDA_TRANSACTION_ISOLATION_READ_COMMITTED,
;; 	GDA_TRANSACTION_ISOLATION_READ_UNCOMMITTED,
;; 	GDA_TRANSACTION_ISOLATION_REPEATABLE_READ,
;; 	GDA_TRANSACTION_ISOLATION_SERIALIZABLE
;; } GdaTransactionIsolation;

(define-enum-extended TransactionIsolation
  (in-module "Gda")
  (c-name "GdaTransactionIsolation")
  (values
    '("unknown" "GDA_TRANSACTION_ISOLATION_UNKNOWN" "0")
    '("read-committed" "GDA_TRANSACTION_ISOLATION_READ_COMMITTED" "1")
    '("read-uncommitted" "GDA_TRANSACTION_ISOLATION_READ_UNCOMMITTED" "2")
    '("repeatable-read" "GDA_TRANSACTION_ISOLATION_REPEATABLE_READ" "3")
    '("serializable" "GDA_TRANSACTION_ISOLATION_SERIALIZABLE" "4")
  )
)

;; Original typedef:
;; typedef enum  {
;; 	GDA_VALUE_ATTR_NONE           = 0,
;;         GDA_VALUE_ATTR_IS_NULL        = 1 << 0,
;;         GDA_VALUE_ATTR_CAN_BE_NULL    = 1 << 1,
;;         GDA_VALUE_ATTR_IS_DEFAULT     = 1 << 2,
;;         GDA_VALUE_ATTR_CAN_BE_DEFAULT = 1 << 3,
;;         GDA_VALUE_ATTR_IS_UNCHANGED   = 1 << 4,
;;         GDA_VALUE_ATTR_ACTIONS_SHOWN  = 1 << 5,
;;         GDA_VALUE_ATTR_DATA_NON_VALID = 1 << 6,
;;         GDA_VALUE_ATTR_HAS_VALUE_ORIG = 1 << 7,
;; 	GDA_VALUE_ATTR_NO_MODIF       = 1 << 8,
;; 	GDA_VALUE_ATTR_UNUSED         = 1 << 9
;; } GdaValueAttribute;

(define-flags-extended ValueAttribute
  (in-module "Gda")
  (c-name "GdaValueAttribute")
  (values
    '("none" "GDA_VALUE_ATTR_NONE" "0x0")
    '("is-null" "GDA_VALUE_ATTR_IS_NULL" "1 << 0")
    '("can-be-null" "GDA_VALUE_ATTR_CAN_BE_NULL" "1 << 1")
    '("is-default" "GDA_VALUE_ATTR_IS_DEFAULT" "1 << 2")
    '("can-be-default" "GDA_VALUE_ATTR_CAN_BE_DEFAULT" "1 << 3")
    '("is-unchanged" "GDA_VALUE_ATTR_IS_UNCHANGED" "1 << 4")
    '("actions-shown" "GDA_VALUE_ATTR_ACTIONS_SHOWN" "1 << 5")
    '("data-non-valid" "GDA_VALUE_ATTR_DATA_NON_VALID" "1 << 6")
    '("has-value-orig" "GDA_VALUE_ATTR_HAS_VALUE_ORIG" "1 << 7")
    '("no-modif" "GDA_VALUE_ATTR_NO_MODIF" "1 << 8")
    '("unused" "GDA_VALUE_ATTR_UNUSED" "1 << 9")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_SQL_IDENTIFIERS_LOWER_CASE = 1 << 0,
;; 	GDA_SQL_IDENTIFIERS_UPPER_CASE = 1 << 1
;; } GdaSqlIdentifierStyle;

(define-flags-extended SqlIdentifierStyle
  (in-module "Gda")
  (c-name "GdaSqlIdentifierStyle")
  (values
    '("lower-case" "GDA_SQL_IDENTIFIERS_LOWER_CASE" "1 << 0")
    '("upper-case" "GDA_SQL_IDENTIFIERS_UPPER_CASE" "1 << 1")
  )
)

;; From gda-holder.h

;; Original typedef:
;; typedef enum {
;; 	GDA_HOLDER_STRING_CONVERSION_ERROR,
;; 	GDA_HOLDER_VALUE_TYPE_ERROR,
;; 	GDA_HOLDER_VALUE_NULL_ERROR
;; } GdaHolderError;

(define-enum-extended HolderError
  (in-module "Gda")
  (c-name "GdaHolderError")
  (values
    '("string-conversion-error" "GDA_HOLDER_STRING_CONVERSION_ERROR" "0")
    '("value-type-error" "GDA_HOLDER_VALUE_TYPE_ERROR" "1")
    '("value-null-error" "GDA_HOLDER_VALUE_NULL_ERROR" "2")
  )
)

;; From gda-meta-store.h

;; Original typedef:
;; typedef enum {
;; 	GDA_META_STORE_INCORRECT_SCHEMA_ERROR,
;; 	GDA_META_STORE_UNSUPPORTED_PROVIDER_ERROR,
;; 	GDA_META_STORE_INTERNAL_ERROR,
;; 	GDA_META_STORE_META_CONTEXT_ERROR,
;; 	GDA_META_STORE_MODIFY_CONTENTS_ERROR,
;; 	GDA_META_STORE_EXTRACT_SQL_ERROR,
;; 	GDA_META_STORE_ATTRIBUTE_NOT_FOUND_ERROR,
;; 	GDA_META_STORE_ATTRIBUTE_ERROR,
;; 	GDA_META_STORE_SCHEMA_OBJECT_NOT_FOUND_ERROR,
;; 	GDA_META_STORE_SCHEMA_OBJECT_CONFLICT_ERROR,
;; 	GDA_META_STORE_SCHEMA_OBJECT_DESCR_ERROR,
;; 	GDA_META_STORE_TRANSACTION_ALREADY_STARTED_ERROR
;; } GdaMetaStoreError;

(define-enum-extended MetaStoreError
  (in-module "Gda")
  (c-name "GdaMetaStoreError")
  (values
    '("incorrect-schema-error" "GDA_META_STORE_INCORRECT_SCHEMA_ERROR" "0")
    '("unsupported-provider-error" "GDA_META_STORE_UNSUPPORTED_PROVIDER_ERROR" "1")
    '("internal-error" "GDA_META_STORE_INTERNAL_ERROR" "2")
    '("meta-context-error" "GDA_META_STORE_META_CONTEXT_ERROR" "3")
    '("modify-contents-error" "GDA_META_STORE_MODIFY_CONTENTS_ERROR" "4")
    '("extract-sql-error" "GDA_META_STORE_EXTRACT_SQL_ERROR" "5")
    '("attribute-not-found-error" "GDA_META_STORE_ATTRIBUTE_NOT_FOUND_ERROR" "6")
    '("attribute-error" "GDA_META_STORE_ATTRIBUTE_ERROR" "7")
    '("schema-object-not-found-error" "GDA_META_STORE_SCHEMA_OBJECT_NOT_FOUND_ERROR" "8")
    '("schema-object-conflict-error" "GDA_META_STORE_SCHEMA_OBJECT_CONFLICT_ERROR" "9")
    '("schema-object-descr-error" "GDA_META_STORE_SCHEMA_OBJECT_DESCR_ERROR" "10")
    '("transaction-already-started-error" "GDA_META_STORE_TRANSACTION_ALREADY_STARTED_ERROR" "11")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_META_STORE_ADD,
;; 	GDA_META_STORE_REMOVE,
;; 	GDA_META_STORE_MODIFY
;; } GdaMetaStoreChangeType;

(define-enum-extended MetaStoreChangeType
  (in-module "Gda")
  (c-name "GdaMetaStoreChangeType")
  (values
    '("add" "GDA_META_STORE_ADD" "0")
    '("remove" "GDA_META_STORE_REMOVE" "1")
    '("modify" "GDA_META_STORE_MODIFY" "2")
  )
)

;; From gda-meta-struct.h

;; Original typedef:
;; typedef enum {
;; 	GDA_META_STRUCT_UNKNOWN_OBJECT_ERROR,
;;         GDA_META_STRUCT_DUPLICATE_OBJECT_ERROR,
;;         GDA_META_STRUCT_INCOHERENCE_ERROR,
;; 	GDA_META_STRUCT_XML_ERROR
;; } GdaMetaStructError;

(define-enum-extended MetaStructError
  (in-module "Gda")
  (c-name "GdaMetaStructError")
  (values
    '("unknown-object-error" "GDA_META_STRUCT_UNKNOWN_OBJECT_ERROR" "0")
    '("duplicate-object-error" "GDA_META_STRUCT_DUPLICATE_OBJECT_ERROR" "1")
    '("incoherence-error" "GDA_META_STRUCT_INCOHERENCE_ERROR" "2")
    '("xml-error" "GDA_META_STRUCT_XML_ERROR" "3")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_META_DB_UNKNOWN,
;; 	GDA_META_DB_TABLE,
;; 	GDA_META_DB_VIEW
;; } GdaMetaDbObjectType;

(define-enum-extended MetaDbObjectType
  (in-module "Gda")
  (c-name "GdaMetaDbObjectType")
  (values
    '("unknown" "GDA_META_DB_UNKNOWN" "0")
    '("table" "GDA_META_DB_TABLE" "1")
    '("view" "GDA_META_DB_VIEW" "2")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_META_STRUCT_FEATURE_NONE              = 0,
;; 	GDA_META_STRUCT_FEATURE_FOREIGN_KEYS      = 1 << 0,
;; 	GDA_META_STRUCT_FEATURE_VIEW_DEPENDENCIES = 1 << 1,
;; 
;; 	GDA_META_STRUCT_FEATURE_ALL               = GDA_META_STRUCT_FEATURE_FOREIGN_KEYS |
;; 	                                            GDA_META_STRUCT_FEATURE_VIEW_DEPENDENCIES
;; } GdaMetaStructFeature;

(define-flags-extended MetaStructFeature
  (in-module "Gda")
  (c-name "GdaMetaStructFeature")
  (values
    '("none" "GDA_META_STRUCT_FEATURE_NONE" "0x0")
    '("foreign-keys" "GDA_META_STRUCT_FEATURE_FOREIGN_KEYS" "1 << 0")
    '("view-dependencies" "GDA_META_STRUCT_FEATURE_VIEW_DEPENDENCIES" "1 << 1")
    '("all" "GDA_META_STRUCT_FEATURE_ALL" "0x3")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_META_SORT_ALHAPETICAL,
;; 	GDA_META_SORT_DEPENDENCIES
;; } GdaMetaSortType;

(define-enum-extended MetaSortType
  (in-module "Gda")
  (c-name "GdaMetaSortType")
  (values
    '("alhapetical" "GDA_META_SORT_ALHAPETICAL" "0")
    '("dependencies" "GDA_META_SORT_DEPENDENCIES" "1")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_META_FOREIGN_KEY_UNKNOWN,
;; 	GDA_META_FOREIGN_KEY_NONE,
;; 	GDA_META_FOREIGN_KEY_NO_ACTION,
;; 	GDA_META_FOREIGN_KEY_RESTRICT,
;; 	GDA_META_FOREIGN_KEY_CASCADE,
;; 	GDA_META_FOREIGN_KEY_SET_NULL,
;; 	GDA_META_FOREIGN_KEY_SET_DEFAULT
;; } GdaMetaForeignKeyPolicy;

(define-enum-extended MetaForeignKeyPolicy
  (in-module "Gda")
  (c-name "GdaMetaForeignKeyPolicy")
  (values
    '("unknown" "GDA_META_FOREIGN_KEY_UNKNOWN" "0")
    '("none" "GDA_META_FOREIGN_KEY_NONE" "1")
    '("no-action" "GDA_META_FOREIGN_KEY_NO_ACTION" "2")
    '("restrict" "GDA_META_FOREIGN_KEY_RESTRICT" "3")
    '("cascade" "GDA_META_FOREIGN_KEY_CASCADE" "4")
    '("set-null" "GDA_META_FOREIGN_KEY_SET_NULL" "5")
    '("set-default" "GDA_META_FOREIGN_KEY_SET_DEFAULT" "6")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_META_GRAPH_COLUMNS = 1 << 0
;; } GdaMetaGraphInfo;

(define-flags-extended MetaGraphInfo
  (in-module "Gda")
  (c-name "GdaMetaGraphInfo")
  (values
    '("columns" "GDA_META_GRAPH_COLUMNS" "1 << 0")
  )
)

;; From gda-server-operation.h

;; Original typedef:
;; typedef enum {
;; 	GDA_SERVER_OPERATION_CREATE_DB,
;; 	GDA_SERVER_OPERATION_DROP_DB,
;; 		
;; 	GDA_SERVER_OPERATION_CREATE_TABLE,
;; 	GDA_SERVER_OPERATION_DROP_TABLE,
;; 	GDA_SERVER_OPERATION_RENAME_TABLE,
;; 
;; 	GDA_SERVER_OPERATION_ADD_COLUMN,
;; 	GDA_SERVER_OPERATION_DROP_COLUMN,
;; 
;; 	GDA_SERVER_OPERATION_CREATE_INDEX,
;; 	GDA_SERVER_OPERATION_DROP_INDEX,
;; 
;; 	GDA_SERVER_OPERATION_CREATE_VIEW,
;; 	GDA_SERVER_OPERATION_DROP_VIEW,
;; 
;; 	GDA_SERVER_OPERATION_COMMENT_TABLE,
;; 	GDA_SERVER_OPERATION_COMMENT_COLUMN,
;; 
;; 	GDA_SERVER_OPERATION_CREATE_USER,
;; 	GDA_SERVER_OPERATION_ALTER_USER,
;; 	GDA_SERVER_OPERATION_DROP_USER,
;; 
;; 	GDA_SERVER_OPERATION_LAST
;; } GdaServerOperationType;

(define-enum-extended ServerOperationType
  (in-module "Gda")
  (c-name "GdaServerOperationType")
  (values
    '("create-db" "GDA_SERVER_OPERATION_CREATE_DB" "0")
    '("drop-db" "GDA_SERVER_OPERATION_DROP_DB" "1")
    '("create-table" "GDA_SERVER_OPERATION_CREATE_TABLE" "2")
    '("drop-table" "GDA_SERVER_OPERATION_DROP_TABLE" "3")
    '("rename-table" "GDA_SERVER_OPERATION_RENAME_TABLE" "4")
    '("add-column" "GDA_SERVER_OPERATION_ADD_COLUMN" "5")
    '("drop-column" "GDA_SERVER_OPERATION_DROP_COLUMN" "6")
    '("create-index" "GDA_SERVER_OPERATION_CREATE_INDEX" "7")
    '("drop-index" "GDA_SERVER_OPERATION_DROP_INDEX" "8")
    '("create-view" "GDA_SERVER_OPERATION_CREATE_VIEW" "9")
    '("drop-view" "GDA_SERVER_OPERATION_DROP_VIEW" "10")
    '("comment-table" "GDA_SERVER_OPERATION_COMMENT_TABLE" "11")
    '("comment-column" "GDA_SERVER_OPERATION_COMMENT_COLUMN" "12")
    '("create-user" "GDA_SERVER_OPERATION_CREATE_USER" "13")
    '("alter-user" "GDA_SERVER_OPERATION_ALTER_USER" "14")
    '("drop-user" "GDA_SERVER_OPERATION_DROP_USER" "15")
    '("last" "GDA_SERVER_OPERATION_LAST" "16")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_SERVER_OPERATION_OBJECT_NAME_ERROR,
;; 	GDA_SERVER_OPERATION_INCORRECT_VALUE_ERROR,
;; 	GDA_SERVER_OPERATION_XML_ERROR
;; } GdaServerOperationError;

(define-enum-extended ServerOperationError
  (in-module "Gda")
  (c-name "GdaServerOperationError")
  (values
    '("object-name-error" "GDA_SERVER_OPERATION_OBJECT_NAME_ERROR" "0")
    '("incorrect-value-error" "GDA_SERVER_OPERATION_INCORRECT_VALUE_ERROR" "1")
    '("xml-error" "GDA_SERVER_OPERATION_XML_ERROR" "2")
  )
)

;; Original typedef:
;; typedef enum
;; {
;; 	GDA_SERVER_OPERATION_CREATE_TABLE_NOTHING_FLAG   = 1 << 0,
;; 	GDA_SERVER_OPERATION_CREATE_TABLE_PKEY_FLAG      = 1 << 1,
;; 	GDA_SERVER_OPERATION_CREATE_TABLE_NOT_NULL_FLAG  = 1 << 2,
;; 	GDA_SERVER_OPERATION_CREATE_TABLE_UNIQUE_FLAG    = 1 << 3,
;; 	GDA_SERVER_OPERATION_CREATE_TABLE_AUTOINC_FLAG   = 1 << 4,
;; 	GDA_SERVER_OPERATION_CREATE_TABLE_FKEY_FLAG      = 1 << 5,
;; 	/* Flags combinations */
;; 	GDA_SERVER_OPERATION_CREATE_TABLE_PKEY_AUTOINC_FLAG = GDA_SERVER_OPERATION_CREATE_TABLE_PKEY_FLAG | GDA_SERVER_OPERATION_CREATE_TABLE_AUTOINC_FLAG
;; } GdaServerOperationCreateTableFlag;

(define-flags-extended ServerOperationCreateTableFlag
  (in-module "Gda")
  (c-name "GdaServerOperationCreateTableFlag")
  (values
    '("nothing-flag" "GDA_SERVER_OPERATION_CREATE_TABLE_NOTHING_FLAG" "1 << 0")
    '("pkey-flag" "GDA_SERVER_OPERATION_CREATE_TABLE_PKEY_FLAG" "1 << 1")
    '("not-null-flag" "GDA_SERVER_OPERATION_CREATE_TABLE_NOT_NULL_FLAG" "1 << 2")
    '("unique-flag" "GDA_SERVER_OPERATION_CREATE_TABLE_UNIQUE_FLAG" "1 << 3")
    '("autoinc-flag" "GDA_SERVER_OPERATION_CREATE_TABLE_AUTOINC_FLAG" "1 << 4")
    '("fkey-flag" "GDA_SERVER_OPERATION_CREATE_TABLE_FKEY_FLAG" "1 << 5")
    '("pkey-autoinc-flag" "GDA_SERVER_OPERATION_CREATE_TABLE_PKEY_AUTOINC_FLAG" "0x12")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_SERVER_OPERATION_NODE_PARAMLIST,
;; 	GDA_SERVER_OPERATION_NODE_DATA_MODEL,
;; 	GDA_SERVER_OPERATION_NODE_PARAM,
;; 	GDA_SERVER_OPERATION_NODE_SEQUENCE,
;; 	GDA_SERVER_OPERATION_NODE_SEQUENCE_ITEM,
;; 
;; 	GDA_SERVER_OPERATION_NODE_DATA_MODEL_COLUMN,
;; 	GDA_SERVER_OPERATION_NODE_UNKNOWN
;; } GdaServerOperationNodeType;

(define-enum-extended ServerOperationNodeType
  (in-module "Gda")
  (c-name "GdaServerOperationNodeType")
  (values
    '("paramlist" "GDA_SERVER_OPERATION_NODE_PARAMLIST" "0")
    '("data-model" "GDA_SERVER_OPERATION_NODE_DATA_MODEL" "1")
    '("param" "GDA_SERVER_OPERATION_NODE_PARAM" "2")
    '("sequence" "GDA_SERVER_OPERATION_NODE_SEQUENCE" "3")
    '("sequence-item" "GDA_SERVER_OPERATION_NODE_SEQUENCE_ITEM" "4")
    '("data-model-column" "GDA_SERVER_OPERATION_NODE_DATA_MODEL_COLUMN" "5")
    '("unknown" "GDA_SERVER_OPERATION_NODE_UNKNOWN" "6")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_SERVER_OPERATION_STATUS_OPTIONAL,
;; 	GDA_SERVER_OPERATION_STATUS_REQUIRED,
;; 	GDA_SERVER_OPERATION_STATUS_UNKNOWN
;; } GdaServerOperationNodeStatus;

(define-enum-extended ServerOperationNodeStatus
  (in-module "Gda")
  (c-name "GdaServerOperationNodeStatus")
  (values
    '("optional" "GDA_SERVER_OPERATION_STATUS_OPTIONAL" "0")
    '("required" "GDA_SERVER_OPERATION_STATUS_REQUIRED" "1")
    '("unknown" "GDA_SERVER_OPERATION_STATUS_UNKNOWN" "2")
  )
)

;; From gda-server-provider.h

;; Original typedef:
;; typedef enum
;; {
;;         GDA_SERVER_PROVIDER_METHOD_NON_IMPLEMENTED_ERROR,
;; 	GDA_SERVER_PROVIDER_PREPARE_STMT_ERROR,
;; 	GDA_SERVER_PROVIDER_EMPTY_STMT_ERROR,
;; 	GDA_SERVER_PROVIDER_MISSING_PARAM_ERROR,
;; 	GDA_SERVER_PROVIDER_STATEMENT_EXEC_ERROR,
;; 	GDA_SERVER_PROVIDER_OPERATION_ERROR,
;; 	GDA_SERVER_PROVIDER_INTERNAL_ERROR,
;; 	GDA_SERVER_PROVIDER_BUSY_ERROR,
;; 	GDA_SERVER_PROVIDER_NON_SUPPORTED_ERROR,
;; 	GDA_SERVER_PROVIDER_SERVER_VERSION_ERROR,
;; 	GDA_SERVER_PROVIDER_DATA_ERROR,
;; 	GDA_SERVER_PROVIDER_DEFAULT_VALUE_HANDLING_ERROR,
;; 	GDA_SERVER_PROVIDER_MISUSE_ERROR,
;; 	GDA_SERVER_PROVIDER_FILE_NOT_FOUND_ERROR
;; } GdaServerProviderError;

(define-enum-extended ServerProviderError
  (in-module "Gda")
  (c-name "GdaServerProviderError")
  (values
    '("method-non-implemented-error" "GDA_SERVER_PROVIDER_METHOD_NON_IMPLEMENTED_ERROR" "0")
    '("prepare-stmt-error" "GDA_SERVER_PROVIDER_PREPARE_STMT_ERROR" "1")
    '("empty-stmt-error" "GDA_SERVER_PROVIDER_EMPTY_STMT_ERROR" "2")
    '("missing-param-error" "GDA_SERVER_PROVIDER_MISSING_PARAM_ERROR" "3")
    '("statement-exec-error" "GDA_SERVER_PROVIDER_STATEMENT_EXEC_ERROR" "4")
    '("operation-error" "GDA_SERVER_PROVIDER_OPERATION_ERROR" "5")
    '("internal-error" "GDA_SERVER_PROVIDER_INTERNAL_ERROR" "6")
    '("busy-error" "GDA_SERVER_PROVIDER_BUSY_ERROR" "7")
    '("non-supported-error" "GDA_SERVER_PROVIDER_NON_SUPPORTED_ERROR" "8")
    '("server-version-error" "GDA_SERVER_PROVIDER_SERVER_VERSION_ERROR" "9")
    '("data-error" "GDA_SERVER_PROVIDER_DATA_ERROR" "10")
    '("default-value-handling-error" "GDA_SERVER_PROVIDER_DEFAULT_VALUE_HANDLING_ERROR" "11")
    '("misuse-error" "GDA_SERVER_PROVIDER_MISUSE_ERROR" "12")
    '("file-not-found-error" "GDA_SERVER_PROVIDER_FILE_NOT_FOUND_ERROR" "13")
  )
)

;; From gda-set.h

;; Original typedef:
;; typedef enum
;; {
;; 	GDA_SET_XML_SPEC_ERROR,
;; 	GDA_SET_HOLDER_NOT_FOUND_ERROR,
;; 	GDA_SET_INVALID_ERROR,
;; 	GDA_SET_READ_ONLY_ERROR,
;; 	GDA_SET_IMPLEMENTATION_ERROR
;; } GdaSetError;

(define-enum-extended SetError
  (in-module "Gda")
  (c-name "GdaSetError")
  (values
    '("xml-spec-error" "GDA_SET_XML_SPEC_ERROR" "0")
    '("holder-not-found-error" "GDA_SET_HOLDER_NOT_FOUND_ERROR" "1")
    '("invalid-error" "GDA_SET_INVALID_ERROR" "2")
    '("read-only-error" "GDA_SET_READ_ONLY_ERROR" "3")
    '("implementation-error" "GDA_SET_IMPLEMENTATION_ERROR" "4")
  )
)

;; From gda-sql-builder.h

;; Original typedef:
;; typedef enum {
;; 	GDA_SQL_BUILDER_WRONG_TYPE_ERROR,
;; 	GDA_SQL_BUILDER_MISUSE_ERROR
;; } GdaSqlBuilderError;

(define-enum-extended SqlBuilderError
  (in-module "Gda")
  (c-name "GdaSqlBuilderError")
  (values
    '("wrong-type-error" "GDA_SQL_BUILDER_WRONG_TYPE_ERROR" "0")
    '("misuse-error" "GDA_SQL_BUILDER_MISUSE_ERROR" "1")
  )
)

;; From gda-statement.h

;; Original typedef:
;; typedef enum
;; {
;; 	GDA_STATEMENT_PARSE_ERROR,
;; 	GDA_STATEMENT_SYNTAX_ERROR,
;; 	GDA_STATEMENT_NO_CNC_ERROR,
;; 	GDA_STATEMENT_CNC_CLOSED_ERROR,
;; 	GDA_STATEMENT_EXEC_ERROR,
;; 	GDA_STATEMENT_PARAM_TYPE_ERROR,
;; 	GDA_STATEMENT_PARAM_ERROR
;; } GdaStatementError;

(define-enum-extended StatementError
  (in-module "Gda")
  (c-name "GdaStatementError")
  (values
    '("parse-error" "GDA_STATEMENT_PARSE_ERROR" "0")
    '("syntax-error" "GDA_STATEMENT_SYNTAX_ERROR" "1")
    '("no-cnc-error" "GDA_STATEMENT_NO_CNC_ERROR" "2")
    '("cnc-closed-error" "GDA_STATEMENT_CNC_CLOSED_ERROR" "3")
    '("exec-error" "GDA_STATEMENT_EXEC_ERROR" "4")
    '("param-type-error" "GDA_STATEMENT_PARAM_TYPE_ERROR" "5")
    '("param-error" "GDA_STATEMENT_PARAM_ERROR" "6")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_STATEMENT_MODEL_RANDOM_ACCESS   = 1 << 0,
;; 	GDA_STATEMENT_MODEL_CURSOR_FORWARD  = 1 << 1,
;; 	GDA_STATEMENT_MODEL_CURSOR_BACKWARD = 1 << 2,
;; 	GDA_STATEMENT_MODEL_CURSOR          = GDA_STATEMENT_MODEL_CURSOR_FORWARD | GDA_STATEMENT_MODEL_CURSOR_BACKWARD,
;; 	GDA_STATEMENT_MODEL_ALLOW_NOPARAM   = 1 << 3
;; } GdaStatementModelUsage;

(define-flags-extended StatementModelUsage
  (in-module "Gda")
  (c-name "GdaStatementModelUsage")
  (values
    '("random-access" "GDA_STATEMENT_MODEL_RANDOM_ACCESS" "1 << 0")
    '("cursor-forward" "GDA_STATEMENT_MODEL_CURSOR_FORWARD" "1 << 1")
    '("cursor-backward" "GDA_STATEMENT_MODEL_CURSOR_BACKWARD" "1 << 2")
    '("cursor" "GDA_STATEMENT_MODEL_CURSOR" "0x6")
    '("allow-noparam" "GDA_STATEMENT_MODEL_ALLOW_NOPARAM" "1 << 3")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_STATEMENT_SQL_PARAMS_AS_VALUES   = 0,
;;         GDA_STATEMENT_SQL_PRETTY             = 1 << 0,
;;         GDA_STATEMENT_SQL_PARAMS_LONG        = 1 << 1,
;;         GDA_STATEMENT_SQL_PARAMS_SHORT       = 1 << 2,
;;         GDA_STATEMENT_SQL_PARAMS_AS_COLON    = 1 << 3,
;;         GDA_STATEMENT_SQL_PARAMS_AS_DOLLAR   = 1 << 4,
;;         GDA_STATEMENT_SQL_PARAMS_AS_QMARK    = 1 << 5,
;;         GDA_STATEMENT_SQL_PARAMS_AS_UQMARK   = 1 << 6
;; } GdaStatementSqlFlag;

(define-flags-extended StatementSqlFlag
  (in-module "Gda")
  (c-name "GdaStatementSqlFlag")
  (values
    '("params-as-values" "GDA_STATEMENT_SQL_PARAMS_AS_VALUES" "0x0")
    '("pretty" "GDA_STATEMENT_SQL_PRETTY" "1 << 0")
    '("params-long" "GDA_STATEMENT_SQL_PARAMS_LONG" "1 << 1")
    '("params-short" "GDA_STATEMENT_SQL_PARAMS_SHORT" "1 << 2")
    '("params-as-colon" "GDA_STATEMENT_SQL_PARAMS_AS_COLON" "1 << 3")
    '("params-as-dollar" "GDA_STATEMENT_SQL_PARAMS_AS_DOLLAR" "1 << 4")
    '("params-as-qmark" "GDA_STATEMENT_SQL_PARAMS_AS_QMARK" "1 << 5")
    '("params-as-uqmark" "GDA_STATEMENT_SQL_PARAMS_AS_UQMARK" "1 << 6")
  )
)

;; From gda-transaction-status.h

;; Original typedef:
;; typedef enum {
;; 	GDA_TRANSACTION_STATUS_EVENT_SAVEPOINT,
;; 	GDA_TRANSACTION_STATUS_EVENT_SQL,
;; 	GDA_TRANSACTION_STATUS_EVENT_SUB_TRANSACTION
;; } GdaTransactionStatusEventType;

(define-enum-extended TransactionStatusEventType
  (in-module "Gda")
  (c-name "GdaTransactionStatusEventType")
  (values
    '("savepoint" "GDA_TRANSACTION_STATUS_EVENT_SAVEPOINT" "0")
    '("sql" "GDA_TRANSACTION_STATUS_EVENT_SQL" "1")
    '("sub-transaction" "GDA_TRANSACTION_STATUS_EVENT_SUB_TRANSACTION" "2")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_TRANSACTION_STATUS_STATE_OK,
;; 	GDA_TRANSACTION_STATUS_STATE_FAILED
;; } GdaTransactionStatusState;

(define-enum-extended TransactionStatusState
  (in-module "Gda")
  (c-name "GdaTransactionStatusState")
  (values
    '("ok" "GDA_TRANSACTION_STATUS_STATE_OK" "0")
    '("failed" "GDA_TRANSACTION_STATUS_STATE_FAILED" "1")
  )
)

;; From gda-tree.h

;; Original typedef:
;; typedef enum {
;; 	GDA_TREE_UNKNOWN_ERROR
;; } GdaTreeError;

(define-enum-extended TreeError
  (in-module "Gda")
  (c-name "GdaTreeError")
  (values
    '("unknown-error" "GDA_TREE_UNKNOWN_ERROR" "0")
  )
)

;; From gda-tree-manager.h

;; Original typedef:
;; typedef enum {
;; 	GDA_TREE_MANAGER_UNKNOWN_ERROR
;; } GdaTreeManagerError;

(define-enum-extended TreeManagerError
  (in-module "Gda")
  (c-name "GdaTreeManagerError")
  (values
    '("unknown-error" "GDA_TREE_MANAGER_UNKNOWN_ERROR" "0")
  )
)

;; From gda-tree-node.h

;; Original typedef:
;; typedef enum {
;; 	GDA_TREE_NODE_UNKNOWN_ERROR
;; } GdaTreeNodeError;

(define-enum-extended TreeNodeError
  (in-module "Gda")
  (c-name "GdaTreeNodeError")
  (values
    '("unknown-error" "GDA_TREE_NODE_UNKNOWN_ERROR" "0")
  )
)

;; From gda-xa-transaction.h

;; Original typedef:
;; typedef enum
;; {
;;         GDA_XA_TRANSACTION_ALREADY_REGISTERED_ERROR,
;; 	GDA_XA_TRANSACTION_DTP_NOT_SUPPORTED_ERROR,
;; 	GDA_XA_TRANSACTION_CONNECTION_BRANCH_LENGTH_ERROR
;; } GdaXaTransactionError;

(define-enum-extended XaTransactionError
  (in-module "Gda")
  (c-name "GdaXaTransactionError")
  (values
    '("already-registered-error" "GDA_XA_TRANSACTION_ALREADY_REGISTERED_ERROR" "0")
    '("dtp-not-supported-error" "GDA_XA_TRANSACTION_DTP_NOT_SUPPORTED_ERROR" "1")
    '("connection-branch-length-error" "GDA_XA_TRANSACTION_CONNECTION_BRANCH_LENGTH_ERROR" "2")
  )
)

;; From gda-sql-parser.h

;; Original typedef:
;; typedef enum
;; {
;; 	GDA_SQL_PARSER_SYNTAX_ERROR,
;; 	GDA_SQL_PARSER_OVERFLOW_ERROR,
;; 	GDA_SQL_PARSER_EMPTY_SQL_ERROR
;; } GdaSqlParserError;

(define-enum-extended SqlParserError
  (in-module "Gda")
  (c-name "GdaSqlParserError")
  (values
    '("syntax-error" "GDA_SQL_PARSER_SYNTAX_ERROR" "0")
    '("overflow-error" "GDA_SQL_PARSER_OVERFLOW_ERROR" "1")
    '("empty-sql-error" "GDA_SQL_PARSER_EMPTY_SQL_ERROR" "2")
  )
)

;; Original typedef:
;; typedef enum {
;;         GDA_SQL_PARSER_MODE_PARSE,
;;         GDA_SQL_PARSER_MODE_DELIMIT
;; } GdaSqlParserMode;

(define-enum-extended SqlParserMode
  (in-module "Gda")
  (c-name "GdaSqlParserMode")
  (values
    '("parse" "GDA_SQL_PARSER_MODE_PARSE" "0")
    '("delimit" "GDA_SQL_PARSER_MODE_DELIMIT" "1")
  )
)

;; Original typedef:
;; typedef enum {
;;         GDA_SQL_PARSER_FLAVOUR_STANDARD   = 0,
;;         GDA_SQL_PARSER_FLAVOUR_SQLITE     = 1,
;;         GDA_SQL_PARSER_FLAVOUR_MYSQL      = 2,
;;         GDA_SQL_PARSER_FLAVOUR_ORACLE     = 3,
;;         GDA_SQL_PARSER_FLAVOUR_POSTGRESQL = 4
;; } GdaSqlParserFlavour;

(define-enum-extended SqlParserFlavour
  (in-module "Gda")
  (c-name "GdaSqlParserFlavour")
  (values
    '("standard" "GDA_SQL_PARSER_FLAVOUR_STANDARD" "0")
    '("sqlite" "GDA_SQL_PARSER_FLAVOUR_SQLITE" "1")
    '("mysql" "GDA_SQL_PARSER_FLAVOUR_MYSQL" "2")
    '("oracle" "GDA_SQL_PARSER_FLAVOUR_ORACLE" "3")
    '("postgresql" "GDA_SQL_PARSER_FLAVOUR_POSTGRESQL" "4")
  )
)

;; From gda-statement-struct-compound.h

;; Original typedef:
;; typedef enum {
;; 	GDA_SQL_STATEMENT_COMPOUND_UNION,
;; 	GDA_SQL_STATEMENT_COMPOUND_UNION_ALL,
;; 	GDA_SQL_STATEMENT_COMPOUND_INTERSECT,
;; 	GDA_SQL_STATEMENT_COMPOUND_INTERSECT_ALL,
;; 	GDA_SQL_STATEMENT_COMPOUND_EXCEPT,
;; 	GDA_SQL_STATEMENT_COMPOUND_EXCEPT_ALL
;; } GdaSqlStatementCompoundType;

(define-enum-extended SqlStatementCompoundType
  (in-module "Gda")
  (c-name "GdaSqlStatementCompoundType")
  (values
    '("union" "GDA_SQL_STATEMENT_COMPOUND_UNION" "0")
    '("union-all" "GDA_SQL_STATEMENT_COMPOUND_UNION_ALL" "1")
    '("intersect" "GDA_SQL_STATEMENT_COMPOUND_INTERSECT" "2")
    '("intersect-all" "GDA_SQL_STATEMENT_COMPOUND_INTERSECT_ALL" "3")
    '("except" "GDA_SQL_STATEMENT_COMPOUND_EXCEPT" "4")
    '("except-all" "GDA_SQL_STATEMENT_COMPOUND_EXCEPT_ALL" "5")
  )
)

;; From gda-statement-struct-decl.h

;; Original typedef:
;; typedef enum {
;; 	GDA_SQL_STRUCTURE_CONTENTS_ERROR,
;; 	GDA_SQL_MALFORMED_IDENTIFIER_ERROR,
;; 	GDA_SQL_MISSING_IDENTIFIER_ERROR,
;; 	GDA_SQL_VALIDATION_ERROR
;; } GdaSqlError;

(define-enum-extended SqlError
  (in-module "Gda")
  (c-name "GdaSqlError")
  (values
    '("structure-contents-error" "GDA_SQL_STRUCTURE_CONTENTS_ERROR" "0")
    '("malformed-identifier-error" "GDA_SQL_MALFORMED_IDENTIFIER_ERROR" "1")
    '("missing-identifier-error" "GDA_SQL_MISSING_IDENTIFIER_ERROR" "2")
    '("validation-error" "GDA_SQL_VALIDATION_ERROR" "3")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_SQL_STATEMENT_SELECT,
;; 	GDA_SQL_STATEMENT_INSERT,
;; 	GDA_SQL_STATEMENT_UPDATE,
;; 	GDA_SQL_STATEMENT_DELETE,
;; 	GDA_SQL_STATEMENT_COMPOUND,
;; 
;; 	GDA_SQL_STATEMENT_BEGIN,
;; 	GDA_SQL_STATEMENT_ROLLBACK,
;; 	GDA_SQL_STATEMENT_COMMIT,
;; 
;; 	GDA_SQL_STATEMENT_SAVEPOINT,
;; 	GDA_SQL_STATEMENT_ROLLBACK_SAVEPOINT,
;; 	GDA_SQL_STATEMENT_DELETE_SAVEPOINT,
;; 
;; 	GDA_SQL_STATEMENT_UNKNOWN,
;; 	GDA_SQL_STATEMENT_NONE
;; } GdaSqlStatementType;

(define-enum-extended SqlStatementType
  (in-module "Gda")
  (c-name "GdaSqlStatementType")
  (values
    '("select" "GDA_SQL_STATEMENT_SELECT" "0")
    '("insert" "GDA_SQL_STATEMENT_INSERT" "1")
    '("update" "GDA_SQL_STATEMENT_UPDATE" "2")
    '("delete" "GDA_SQL_STATEMENT_DELETE" "3")
    '("compound" "GDA_SQL_STATEMENT_COMPOUND" "4")
    '("begin" "GDA_SQL_STATEMENT_BEGIN" "5")
    '("rollback" "GDA_SQL_STATEMENT_ROLLBACK" "6")
    '("commit" "GDA_SQL_STATEMENT_COMMIT" "7")
    '("savepoint" "GDA_SQL_STATEMENT_SAVEPOINT" "8")
    '("rollback-savepoint" "GDA_SQL_STATEMENT_ROLLBACK_SAVEPOINT" "9")
    '("delete-savepoint" "GDA_SQL_STATEMENT_DELETE_SAVEPOINT" "10")
    '("unknown" "GDA_SQL_STATEMENT_UNKNOWN" "11")
    '("none" "GDA_SQL_STATEMENT_NONE" "12")
  )
)

;; Original typedef:
;; typedef enum {
;; 	/* complete statements */
;; 	GDA_SQL_ANY_STMT_SELECT = GDA_SQL_STATEMENT_SELECT,
;; 	GDA_SQL_ANY_STMT_INSERT = GDA_SQL_STATEMENT_INSERT,
;; 	GDA_SQL_ANY_STMT_UPDATE = GDA_SQL_STATEMENT_UPDATE,
;; 	GDA_SQL_ANY_STMT_DELETE = GDA_SQL_STATEMENT_DELETE,
;; 	GDA_SQL_ANY_STMT_COMPOUND = GDA_SQL_STATEMENT_COMPOUND,
;; 	GDA_SQL_ANY_STMT_BEGIN = GDA_SQL_STATEMENT_BEGIN,
;; 	GDA_SQL_ANY_STMT_ROLLBACK = GDA_SQL_STATEMENT_ROLLBACK,
;; 	GDA_SQL_ANY_STMT_COMMIT = GDA_SQL_STATEMENT_COMMIT,
;; 	GDA_SQL_ANY_STMT_SAVEPOINT = GDA_SQL_STATEMENT_SAVEPOINT,
;; 	GDA_SQL_ANY_STMT_ROLLBACK_SAVEPOINT = GDA_SQL_STATEMENT_ROLLBACK_SAVEPOINT,
;; 	GDA_SQL_ANY_STMT_DELETE_SAVEPOINT = GDA_SQL_STATEMENT_DELETE_SAVEPOINT,
;; 	GDA_SQL_ANY_STMT_UNKNOWN = GDA_SQL_STATEMENT_UNKNOWN,
;; 	
;; 	/* individual parts */
;; 	GDA_SQL_ANY_EXPR = 500,
;; 	GDA_SQL_ANY_SQL_FIELD,
;; 	GDA_SQL_ANY_SQL_TABLE,
;; 	GDA_SQL_ANY_SQL_FUNCTION,
;; 	GDA_SQL_ANY_SQL_OPERATION,
;; 	GDA_SQL_ANY_SQL_CASE,
;; 	GDA_SQL_ANY_SQL_SELECT_FIELD,
;; 	GDA_SQL_ANY_SQL_SELECT_TARGET,
;; 	GDA_SQL_ANY_SQL_SELECT_JOIN,
;; 	GDA_SQL_ANY_SQL_SELECT_FROM,
;; 	GDA_SQL_ANY_SQL_SELECT_ORDER
;; } GdaSqlAnyPartType;

(define-enum-extended SqlAnyPartType
  (in-module "Gda")
  (c-name "GdaSqlAnyPartType")
  (values
    '("stmt-select" "GDA_SQL_ANY_STMT_SELECT" "0")
    '("stmt-insert" "GDA_SQL_ANY_STMT_INSERT" "1")
    '("stmt-update" "GDA_SQL_ANY_STMT_UPDATE" "2")
    '("stmt-delete" "GDA_SQL_ANY_STMT_DELETE" "3")
    '("stmt-compound" "GDA_SQL_ANY_STMT_COMPOUND" "4")
    '("stmt-begin" "GDA_SQL_ANY_STMT_BEGIN" "5")
    '("stmt-rollback" "GDA_SQL_ANY_STMT_ROLLBACK" "6")
    '("stmt-commit" "GDA_SQL_ANY_STMT_COMMIT" "7")
    '("stmt-savepoint" "GDA_SQL_ANY_STMT_SAVEPOINT" "8")
    '("stmt-rollback-savepoint" "GDA_SQL_ANY_STMT_ROLLBACK_SAVEPOINT" "9")
    '("stmt-delete-savepoint" "GDA_SQL_ANY_STMT_DELETE_SAVEPOINT" "10")
    '("stmt-unknown" "GDA_SQL_ANY_STMT_UNKNOWN" "11")
    '("expr" "GDA_SQL_ANY_EXPR" "500")
    '("sql-field" "GDA_SQL_ANY_SQL_FIELD" "501")
    '("sql-table" "GDA_SQL_ANY_SQL_TABLE" "502")
    '("sql-function" "GDA_SQL_ANY_SQL_FUNCTION" "503")
    '("sql-operation" "GDA_SQL_ANY_SQL_OPERATION" "504")
    '("sql-case" "GDA_SQL_ANY_SQL_CASE" "505")
    '("sql-select-field" "GDA_SQL_ANY_SQL_SELECT_FIELD" "506")
    '("sql-select-target" "GDA_SQL_ANY_SQL_SELECT_TARGET" "507")
    '("sql-select-join" "GDA_SQL_ANY_SQL_SELECT_JOIN" "508")
    '("sql-select-from" "GDA_SQL_ANY_SQL_SELECT_FROM" "509")
    '("sql-select-order" "GDA_SQL_ANY_SQL_SELECT_ORDER" "510")
  )
)

;; From gda-statement-struct-parts.h

;; Original typedef:
;; typedef enum {
;; 	GDA_SQL_OPERATOR_TYPE_AND,
;; 	GDA_SQL_OPERATOR_TYPE_OR,
;; 
;; 	GDA_SQL_OPERATOR_TYPE_EQ,
;; 	GDA_SQL_OPERATOR_TYPE_IS,
;; 	GDA_SQL_OPERATOR_TYPE_LIKE,
;; 	GDA_SQL_OPERATOR_TYPE_BETWEEN,
;; 	GDA_SQL_OPERATOR_TYPE_GT,
;; 	GDA_SQL_OPERATOR_TYPE_LT,
;; 	GDA_SQL_OPERATOR_TYPE_GEQ,
;; 	GDA_SQL_OPERATOR_TYPE_LEQ,
;; 	GDA_SQL_OPERATOR_TYPE_DIFF,
;; 	GDA_SQL_OPERATOR_TYPE_REGEXP,
;; 	GDA_SQL_OPERATOR_TYPE_REGEXP_CI,
;; 	GDA_SQL_OPERATOR_TYPE_NOT_REGEXP,
;; 	GDA_SQL_OPERATOR_TYPE_NOT_REGEXP_CI,
;; 	GDA_SQL_OPERATOR_TYPE_SIMILAR,
;; 	GDA_SQL_OPERATOR_TYPE_ISNULL,
;; 	GDA_SQL_OPERATOR_TYPE_ISNOTNULL,
;; 	GDA_SQL_OPERATOR_TYPE_NOT,
;; 	GDA_SQL_OPERATOR_TYPE_IN,
;; 	GDA_SQL_OPERATOR_TYPE_NOTIN,
;; 
;; 	GDA_SQL_OPERATOR_TYPE_CONCAT,
;; 	GDA_SQL_OPERATOR_TYPE_PLUS,
;; 	GDA_SQL_OPERATOR_TYPE_MINUS,
;; 	GDA_SQL_OPERATOR_TYPE_STAR,
;; 	GDA_SQL_OPERATOR_TYPE_DIV,
;; 	GDA_SQL_OPERATOR_TYPE_REM,
;; 	GDA_SQL_OPERATOR_TYPE_BITAND,
;; 	GDA_SQL_OPERATOR_TYPE_BITOR,
;; 	GDA_SQL_OPERATOR_TYPE_BITNOT,
;; 	GDA_SQL_OPERATOR_TYPE_ILIKE
;; } GdaSqlOperatorType;

(define-enum-extended SqlOperatorType
  (in-module "Gda")
  (c-name "GdaSqlOperatorType")
  (values
    '("and" "GDA_SQL_OPERATOR_TYPE_AND" "0")
    '("or" "GDA_SQL_OPERATOR_TYPE_OR" "1")
    '("eq" "GDA_SQL_OPERATOR_TYPE_EQ" "2")
    '("is" "GDA_SQL_OPERATOR_TYPE_IS" "3")
    '("like" "GDA_SQL_OPERATOR_TYPE_LIKE" "4")
    '("between" "GDA_SQL_OPERATOR_TYPE_BETWEEN" "5")
    '("gt" "GDA_SQL_OPERATOR_TYPE_GT" "6")
    '("lt" "GDA_SQL_OPERATOR_TYPE_LT" "7")
    '("geq" "GDA_SQL_OPERATOR_TYPE_GEQ" "8")
    '("leq" "GDA_SQL_OPERATOR_TYPE_LEQ" "9")
    '("diff" "GDA_SQL_OPERATOR_TYPE_DIFF" "10")
    '("regexp" "GDA_SQL_OPERATOR_TYPE_REGEXP" "11")
    '("regexp-ci" "GDA_SQL_OPERATOR_TYPE_REGEXP_CI" "12")
    '("not-regexp" "GDA_SQL_OPERATOR_TYPE_NOT_REGEXP" "13")
    '("not-regexp-ci" "GDA_SQL_OPERATOR_TYPE_NOT_REGEXP_CI" "14")
    '("similar" "GDA_SQL_OPERATOR_TYPE_SIMILAR" "15")
    '("isnull" "GDA_SQL_OPERATOR_TYPE_ISNULL" "16")
    '("isnotnull" "GDA_SQL_OPERATOR_TYPE_ISNOTNULL" "17")
    '("not" "GDA_SQL_OPERATOR_TYPE_NOT" "18")
    '("in" "GDA_SQL_OPERATOR_TYPE_IN" "19")
    '("notin" "GDA_SQL_OPERATOR_TYPE_NOTIN" "20")
    '("concat" "GDA_SQL_OPERATOR_TYPE_CONCAT" "21")
    '("plus" "GDA_SQL_OPERATOR_TYPE_PLUS" "22")
    '("minus" "GDA_SQL_OPERATOR_TYPE_MINUS" "23")
    '("star" "GDA_SQL_OPERATOR_TYPE_STAR" "24")
    '("div" "GDA_SQL_OPERATOR_TYPE_DIV" "25")
    '("rem" "GDA_SQL_OPERATOR_TYPE_REM" "26")
    '("bitand" "GDA_SQL_OPERATOR_TYPE_BITAND" "27")
    '("bitor" "GDA_SQL_OPERATOR_TYPE_BITOR" "28")
    '("bitnot" "GDA_SQL_OPERATOR_TYPE_BITNOT" "29")
    '("ilike" "GDA_SQL_OPERATOR_TYPE_ILIKE" "30")
  )
)

;; Original typedef:
;; typedef enum {
;; 	GDA_SQL_SELECT_JOIN_CROSS,
;; 	GDA_SQL_SELECT_JOIN_NATURAL,
;; 	GDA_SQL_SELECT_JOIN_INNER,
;; 	GDA_SQL_SELECT_JOIN_LEFT,
;; 	GDA_SQL_SELECT_JOIN_RIGHT,
;; 	GDA_SQL_SELECT_JOIN_FULL
;; } GdaSqlSelectJoinType;

(define-enum-extended SqlSelectJoinType
  (in-module "Gda")
  (c-name "GdaSqlSelectJoinType")
  (values
    '("cross" "GDA_SQL_SELECT_JOIN_CROSS" "0")
    '("natural" "GDA_SQL_SELECT_JOIN_NATURAL" "1")
    '("inner" "GDA_SQL_SELECT_JOIN_INNER" "2")
    '("left" "GDA_SQL_SELECT_JOIN_LEFT" "3")
    '("right" "GDA_SQL_SELECT_JOIN_RIGHT" "4")
    '("full" "GDA_SQL_SELECT_JOIN_FULL" "5")
  )
)

