1 11 12 package com.nilostep.xlsql.database; 13 14 19 public class xlConstants { 20 21 public static final int ADD = 0; 22 23 public static final int UPDATE = 1; 24 25 public static final int DELETE = 2; 26 27 public static final String NOARGS = "xlSQL: no such argument(s)."; 28 29 30 public static int xlType(int sqlType) { 31 int ret = 0; 32 33 switch (sqlType) { 34 case (-6): 35 case (-5): 36 case (-2): 37 case 2: 38 case 3: 39 case 4: 40 case 5: 41 case 6: 42 case 7: 43 case 8: 44 ret = 1; 45 break; 46 47 case 1: 48 case 12: 49 case 70: 50 ret = 2; 51 break; 52 53 case 91: 54 case 92: 55 case 93: 56 ret = 3; 57 break; 58 59 case -7: 60 case 16: 61 ret = 4; 62 break; 63 64 default: 65 ret = 0; 66 } 67 68 return ret; 69 } 70 } | Popular Tags |