Skip to content
Snippets Groups Projects
  • Matthew Jordan's avatar
    a438a0e6
    res_config_odbc: Fix for nullable integer columns and keyfield existence check in update_odbc. · a438a0e6
    Matthew Jordan authored
    This patch fixes setting nullable integer columns to NULL instead of an empty
    string, which fails for PostgreSQL, for example. The current code is supposed
    to do so, but the check is broken. The patch also allows the first column in
    the list to be a nullable integer.
    
    Also, the check for existence of a mandatory column checked for the first
    column in the list instead of the key field lookup column. This patch fixes
    that issue as well.
    
    Finally, the compatibility option allow_empty_string_in_nontext, which was
    added to previous revisions to allow for some database backends with certain
    schemas to function, has been removed.
    
    Review: https://reviewboard.asterisk.org/r/3335
    
    ASTERISK-23459 #close
    ASTERISK-23351 #close
    
    (closes issue ASTERISK-23459)
    Reported by: zvision
    patches:
      res_config_odbc.diff uploaded by zvision (License 5755)
    
    
    
    git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@411515 65c4cc65-6c06-0410-ace0-fbb531ad65f3
    a438a0e6
    History
    res_config_odbc: Fix for nullable integer columns and keyfield existence check in update_odbc.
    Matthew Jordan authored
    This patch fixes setting nullable integer columns to NULL instead of an empty
    string, which fails for PostgreSQL, for example. The current code is supposed
    to do so, but the check is broken. The patch also allows the first column in
    the list to be a nullable integer.
    
    Also, the check for existence of a mandatory column checked for the first
    column in the list instead of the key field lookup column. This patch fixes
    that issue as well.
    
    Finally, the compatibility option allow_empty_string_in_nontext, which was
    added to previous revisions to allow for some database backends with certain
    schemas to function, has been removed.
    
    Review: https://reviewboard.asterisk.org/r/3335
    
    ASTERISK-23459 #close
    ASTERISK-23351 #close
    
    (closes issue ASTERISK-23459)
    Reported by: zvision
    patches:
      res_config_odbc.diff uploaded by zvision (License 5755)
    
    
    
    git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@411515 65c4cc65-6c06-0410-ace0-fbb531ad65f3