Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tinyint, smallint, mediumint cannot be autoincrement #14102

DestinyMKas opened this issue May 20, 2019 · 1 comment


Copy link

commented May 20, 2019

I have mysql table where autoincrement column is smallint type.

CREATE TABLE `attribute` (
  `id` smallint(5) unsigned NOT NULL AUTO_INCREMENT,
  `image` int(10) unsigned DEFAULT NULL,
  `sort` smallint(5) unsigned NOT NULL,
  `price` decimal(9,2) NOT NULL,
  `limit` tinyint(3) unsigned NOT NULL,
  PRIMARY KEY (`id`)
$attribute = Attribute::find();

throws an exception Column type cannot be auto-increment


phalcon => enabled
Author => Phalcon Team and contributors
Version => 4.0.0-alpha.3
Build Date => May 20 2019 19:19:33
Powered by Zephir => Version 0.11.11-b661a58

Linux => Fedora 30
Build from source

10.3.12-MariaDB-log - MariaDB Server

PHP 7.3.5 (cli) (built: Apr 30 2019 08:37:17) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.3.5, Copyright (c) 1998-2018 Zend Technologies
with Zend OPcache v7.3.5, Copyright (c) 1999-2018, by Zend Technologies
with Xdebug v2.7.2, Copyright (c) 2002-2019, by Derick Rethans

@niden niden added this to To do in 4.0 Release via automation May 20, 2019

@niden niden added the Bug - Low label May 20, 2019

@niden niden referenced this issue May 20, 2019


T14102 int autoincrement #14103

3 of 5 tasks complete

@niden niden moved this from To do to In progress in 4.0 Release May 20, 2019


This comment has been minimized.

Copy link

commented May 20, 2019

Resolved in #14102

@niden niden closed this May 20, 2019

4.0 Release automation moved this from In progress to Done May 20, 2019

@niden niden added the 4.0 label Jun 21, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants
You can’t perform that action at this time.