2013/9/17 Stipe Tolj <[email protected]>:
> Am 17.09.2013 16:54, schrieb Willy Mularto:
>
>> Thanks for your review. The other approach is to override the sms_type
>> value during the INSERT.
>
>
> yep, most DBMSs allow setting "default values", in case the INSERT statement
> does not insert a specific value for the field. That was my idea. It's
> cleaner, and leaves the value injection to the DB layer.

for MySQL I use this:

`sms_type` tinyint(1) DEFAULT '2'

would be good to alter CREATE TABLE statements for each DBMS and also
change bigint(20) where its not needed to reduce size of the tables.

>
>
> Stipe
>
> --
> -------------------------------------------------------------------
> Kölner Landstrasse 419
> 40589 Düsseldorf, NRW, Germany
>
> tolj.org system architecture      Kannel Software Foundation (KSF)
> http://www.tolj.org/              http://www.kannel.org/
>
> mailto:st_{at}_tolj.org           mailto:stolj_{at}_kannel.org
> -------------------------------------------------------------------
>

Reply via email to