Move lenght to the end of data type for sqlite

Closes #962