private String getInsertValue(Object value) {

		if (value == null) {
			return null;
		}

		if (value instanceof Date) {
			return "'" + DaoUtils.DATE_FORMATTER.format(value) + "'";
		} else if (value.getClass().isEnum()) {
			return "" + EnumUtils.getId(value) + "";
		} else if (value instanceof String) {
			value = value.toString().replaceAll("'", "''");

			return "'" + value + "'";
		} else {
			// All types of Numbers
			return "" + value.toString() + "";
		}
	}