1.表中有A B C三列,用SQL语句实现:当A列大于B列时选择A列否则选择B列,当B列大于C列时选择B列否则选择C列. select (case when a>b then a else b end),(case when b>c then b else c end) from table; 2.关于Case的解释如下: Case Statement CASE 表达式 WHEN 条件1 THEN 返回值1 WHEN 条件2 THEN 返回值2...WHEN 条件n THEN 返回值nELSE
String sql_gd = "select * from TAX_INFO_GD where ID='"+gdid+"'"; Record gdRecord = Db.findFirst(sql_gd); String sql_sy = "select * from TAX_INFO where ID='"+syid+"'"; Record syRecord = Db.findFirst(sql_sy); String[]