- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for DatabaseTypeName (0.12 sec)
-
migrator/column_type.go
// Common type names include "VARCHAR", "TEXT", "NVARCHAR", "DECIMAL", "BOOL", // "INT", and "BIGINT". func (ct ColumnType) DatabaseTypeName() string { if ct.DataTypeValue.Valid { return ct.DataTypeValue.String } return ct.SQLColumnType.DatabaseTypeName() } // ColumnType returns the database type of the column. like `varchar(16)` func (ct ColumnType) ColumnType() (columnType string, ok bool) {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Thu Mar 24 01:31:58 UTC 2022 - 3.3K bytes - Viewed (0) -
migrator.go
CheckOption string // optional. e.g. `WITH [ CASCADED | LOCAL ] CHECK OPTION` Query *DB // required subquery. } // ColumnType column type interface type ColumnType interface { Name() string DatabaseTypeName() string // varchar ColumnType() (columnType string, ok bool) // varchar(64) PrimaryKey() (isPrimaryKey bool, ok bool) AutoIncrement() (isAutoIncrement bool, ok bool) Length() (length int64, ok bool)
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Oct 30 09:15:49 UTC 2023 - 3.1K bytes - Viewed (0) -
tests/migrate_test.go
AssertEqual(t, nil, err) AssertEqual(t, "varchar", ct.DatabaseTypeName()) ct, err = findColumnType(&ArrayTypeModel{}, "text_array") AssertEqual(t, nil, err) AssertEqual(t, "text[]", ct.DatabaseTypeName()) ct, err = findColumnType(&ArrayTypeModel{}, "nested_text_array") AssertEqual(t, nil, err) AssertEqual(t, "text[]", ct.DatabaseTypeName())
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Mon Mar 18 11:24:16 UTC 2024 - 56.2K bytes - Viewed (0) -
migrator/migrator.go
if field.IgnoreMigration { return nil } // found, smart migrate fullDataType := strings.TrimSpace(strings.ToLower(m.DB.Migrator().FullDataTypeOf(field).SQL)) realDataType := strings.ToLower(columnType.DatabaseTypeName()) var ( alterColumn bool isSameType = fullDataType == realDataType ) if !field.PrimaryKey { // check type if !strings.HasPrefix(fullDataType, realDataType) {
Registered: Sun Nov 03 09:35:10 UTC 2024 - Last Modified: Fri Apr 26 07:15:49 UTC 2024 - 29K bytes - Viewed (0) -
api/go1.8.txt
pkg database/sql/driver, type TxOptions struct, ReadOnly bool pkg database/sql, func Named(string, interface{}) NamedArg pkg database/sql, method (*ColumnType) DatabaseTypeName() string pkg database/sql, method (*ColumnType) DecimalSize() (int64, int64, bool) pkg database/sql, method (*ColumnType) Length() (int64, bool) pkg database/sql, method (*ColumnType) Name() string
Registered: Tue Nov 05 11:13:11 UTC 2024 - Last Modified: Wed Dec 21 05:25:57 UTC 2016 - 16.3K bytes - Viewed (0)