Skip to content
  • Sam Habiel's avatar
    [#34] VistA Functions: handle SQL NULLs and various fixes · 4e4d4bdc
    Sam Habiel authored
    This MR does several things:
    - All functions that can take a parameter that can be an SQL NULL will
      handle it appropriately; mostly that is just returning SQL NULL back,
      but in `IFNULL` doing the appropriate substitution.
    - A forthcoming Octo version will contain SUBSTRING; so it's now removed
      from here.
    - The functions sql defintion file would only work on a much earlier
      version of Octo that did not enforce the function types. As of commit
      18bce25f541c0d0c0087bb77d691db9b3b25dd15 (Aug 2020), this file
      wouldn't have worked anymore, as that commit made functions fully
      typed. The file is now updated so that all functions are typed
    - `RIGHTY` functions behaved like `LEFTY`; that's now fixed; and code
      has been simplified so that both functions are essentially
      passthroughs to $EXTRACT.
    - `REPLACE` simplified to use pre-existing VistA code.