Search
 
SCRIPT & CODE EXAMPLE
 

SQL

make a field auto_increment mysql

ALTER TABLE document MODIFY COLUMN document_id INT auto_increment
Comment

mysql check auto increment value

SELECT AUTO_INCREMENT FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = 'database_name' AND TABLE_NAME = 'table_name';
Comment

mysql set id auto increment

ALTER TABLE users AUTO_INCREMENT=1001;
Comment

update auto increment value in mysql

ALTER TABLE foobar AUTO_INCREMENT=10;
Comment

mysql get auto_increment value

SELECT `AUTO_INCREMENT`
FROM  INFORMATION_SCHEMA.TABLES
WHERE TABLE_SCHEMA = 'DatabaseName'
AND   TABLE_NAME   = 'TableName';
Comment

PREVIOUS NEXT
Code Example
Sql :: sql less than operator 
Sql :: primary key with prefix sql 
Sql :: desc sql 
Sql :: how to compare two columns in sql server 
Sql :: connect mysql 
Sql :: like operator in sql 
Sql :: sqlalchemy _in array sqlite 
Sql :: inner join vs outer join 
Sql :: merge in sql 
Sql :: triggers db 
Sql :: postgres jsonb array push new element 
Sql :: mysql create database 
Sql :: sequelize postgresql schema 
Sql :: round decimal mysql 
Sql :: missing index for constraint error in mysql 
Sql :: SQL Server dynamic pivot unknown number of columns 
Sql :: accessing varchar array from sql 
Sql :: realtime database push multiple values 
Sql :: sqlite referential integrity 
Sql :: sql int +1 
Sql :: how to update date in oracle 
Sql :: mysql wait_timeout 
Sql :: how to get recent added primary key in sql 
Sql :: alter fedora mysql 8.0 user 
Sql :: add plugins to mysql workbench 
Sql :: what alter does in db 
Sql :: sql trigger to call stored procedure with parameters 
Sql :: order records between two cordinates sql 
Sql :: how to add column with custom sequence in postgresql 
Sql :: modify xml in sql server 
ADD CONTENT
Topic
Content
Source link
Name
5+3 =