I need to change column type from tinyInt(used as bool) to Varchar, without loosing data. I have found many answers on stack-overflow but all of them ...
I need to change column type from tinyInt(used as bool) to Varchar, without loosing data. I have found many answers on stack-overflow but all of them ...
Given this setup create type myenum_one as enum('foo', 'bar', 'baz'); create table mytable ( myvalue myenum_one ); alter table mytable add constr ...
I have a column that I made as HH:MM:SS in Excel, but when I moved it to Bigquery, it kept the format but changed to string. I need to change it back ...
I am new to DB design and have created my tables in Postgres. However, I need to change the datatype of one of my tables from date to integer'. Howeve ...
Besides the obvious possible data loss, when altering the size from varchar(MAX) to varchar(255), are there any side effects? Like: table-lock? ...
unable to execute the script, please assist how can I add maximum length to already existed column for an int data type. ...
I can't figure out why I can't change a column's data type from TEXT to INT. Here is the script I'm using. Error 1366: Incorrect integer value: '' ...
I need to change the type of a column from varchar(255) to uuid. I am using: ALTER TABLE table_name ALTER COLUMN col TYPE UUID USING col::UUID; ...
I have a primary key column in my SQL table in PostgreSQL named "id". It is a "bigseries" column. I want to convert the column to a "UUID" column. It ...
I have a table import.hugo (import is schema) and I need to change all columns data type from text to numeric. The table already has data, so to alter ...
I have a table matches with a column deleted_date which is of type date, so its values look like 2020-12-30 right now. I want to change the type of th ...
I have column in table book... named as status... i want to set default 1... but, i tried DEFAULT 1, ALTER TABLE book MODIFY status DEFAULT 1 and i i ...
I have 62 tables that were set up as system-versioned/temporal tables except the start and end time columns were set up as datetime2(0) as shown below ...
I am trying to change the column size from 100 to 150 varchar data type using following query: Getting the following error: SQL Error [42601]: ...
I'm working with PostgreSQL. I have to set the NOT NULL property on a column that exists in all the tables of my database. I know how to set in one ta ...
I would be eternaly grateful if somebody could help me a bit. I am totally new to Postrgresql 10 I had a large file millions of lines 73 columns, I co ...
I use EF code first approach and altering database by package manager console Trying to change column invoiceno Datetime to long Add-migration "mess ...
I am altering the column datatype for a table with around 100 Million records using the below query: ALTER TABLE dbo.TARGETTABLE ALTER COLUMN XXX_DAT ...
In "Code First" EF approach, I've changed the type of a property: Before: After: And then I executed (Package Manager Console): Which create ...
For the CsvCruncher project, I am loading a CSV file into HSQLDB. At the time of creating the table and loading, I don't know anything about the co ...