Question : In ORDBMS databases I have seen that complex types can be used: create type name as( …) And […]
Tag: ddl
Replication and table locks during alter table
Question : Recently we have noticed that a number of our Rails migrations end up deadlocking / freezing our app+DB […]
Drop primary key without dropping an index
Question : Is it possible to drop primary key constraint on a table without dropping the index? I have a […]
Rollback group of DDL statements
Question : Working in SQL Server 2008 R2, I am trying to rollback a set of DDL statements as a […]
lock-ddl-per-table option not working as expected in Xtrabackup
Question : I’ve recently been getting the following errors on some of my Percona XtraBackup backups: InnoDB: An optimized (without […]
Migrate foreign key type from char to binary – ways to deal with the fallout?
Question : I am in the process of slimming down a database that has been using char/varchar fields where binary/varbinary […]
Is there anything a table-level constraint declaration can do that a column-level one can not do?
Question : Had an exam today. One question disturbed me: What can a table-level constraint do that a column-level constraint […]
Making a domain conditional on other values in the table
Question : How can I define or change a domain based on another attribute value? F.e. domain for salary is […]
Advantages to column constraints over table constraints
Question : Is there any advantages whatsoever, other than style to writing this, CREATE TABLE foo ( a int PRIMARY […]
Online schema changes for cloudsql DB
Question : I’m new to cloudsql for mysql. I have a table with trigger. I need to do some ddl […]