1 Reply Latest reply on Aug 30, 2009 2:02 AM by EnTomBet

    SQL autoincrement

    ThaJock1

      I am hoping someone who with expericence using SQLLite with Flex can help me on this.  I can provide more code if needed.

      I have created an SQLLite manager.  With it I created a table with the code below.

      I can insert new rows(insert into tableName(first,last)values('Jack','Black')) without a problem.

      My problem is that it when I select id from tableName, they are all null.  I thought it was suppose to create on automatically.

       

      CREATE TABLE `tableName` (`id` int PRIMATRY KEY AUTOINCRAMENT default NULL,  `first` varchar(50) default NULL,  `last` varchar(50) default NULL,  `address` varchar(100) default NULL, `city` varchar(50) default NULL, `state` varchar(50) default NULL, 'email' varchar(255),'zip' varchar(12), `dob` varchar(30) default NULL,  `employer` varchar(100) default NULL, 'home' varchar(20) default NULL, 'work' varchar(20) default NULL, 'cell' varchar(20) default NULL,`lead_date` varchar(30) default NULL,  `lead_status` varchar(20) default NULL,  `current_insurance` varchar(100) default NULL,  `current_plan` varchar(50) default NULL)

       

      If anyone can tell help me with this one I would greatly appreciate it.