Here you can find the source of getSQLParameterSubstring(String value, int type)
public static String getSQLParameterSubstring(String value, int type)
//package com.java2s; import java.sql.Types; public class Main { public static String getSQLParameterSubstring(String value, int type) { if (isNumericType(type)) { return value; } else {//from w w w. j ava2 s .c om return "'" + value + "'"; } } public static boolean isNumericType(int type) { return Types.BIGINT == type || Types.DECIMAL == type || Types.INTEGER == type || Types.NUMERIC == type || Types.SMALLINT == type || Types.TINYINT == type; } }