String lengths in the SQL backend
donaldcallen at gmail.com
Wed Nov 12 12:11:13 EST 2008
On Wed, Nov 12, 2008 at 11:48 AM, Phil Longstaff <plongstaff at rogers.com> wrote:
> On November 12, 2008 11:22:34 am Donald Allen wrote:
>> Why is mysql an issue? I thought the backend was going to be sqlite3?
>> Perhaps you are doing a generic sql layer, designed to talk any one of
>> many target databases, or the specific target database has changed?
> It uses a library which supports multiple databases. Sqlite3 is the default,
> but mysql and postgresql will also be supported. With not too much extra
> work, other databases could also be supported, but they are not on the list
> for the first release.
Ok, makes sense. Where did the 32 come from? Is that the actual
maximum length of a varchar primary key in mysql? Or was that a number
you just made up as an example?
I ask because I actually do use the account code field to relate
dividends to commodities for use by an external reporting package I
wrote and a few of them are greater than 32 characters. If that field
were limited to 32 characters, I'd work around it -- not a big deal --
but I'd like to be sure that the choice of 32 is not arbitrary. Said
another way, if it is arbitrary, I'd vote for making it
min(max(primary_key_length[i])) where i ranges over the supported
More information about the gnucash-devel