code: public String objectToSql(Object value, Database database) {
          if ((value == null) || "null".equals(value.toString().toLowerCase(Locale.US))) {
              return null;
          } else if (value instanceof DatabaseFunction) {
              return functionToSql((DatabaseFunction) value, database);
          } else if (value instanceof Number) {
              return numberToSql((Number) value, database);
          }
          return otherToSql(value, database);
      }
docs: Returns the value object in a format to include in SQL. Quote if necessary.