⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 jmxx.java

📁 这个是我们做土地局的一个项目。感觉不错。欢迎下载
💻 JAVA
字号:
package huayi.gg.jmXX;
import java.sql.*;
import java.util.*;

public class jmXX{
public jmXX(){}
public int getHY(String YGBH){
  int i=0;
  try{
   huayi.gg.dbConn.dbConn myConn=new huayi.gg.dbConn.dbConn();
   String BHT=YGBH;
   GregorianCalendar gcalendara1=new GregorianCalendar();
   String date=null;
   String yue=null;
   String ri=null;
   if ((gcalendara1.get(gcalendara1.MONTH)+1)<10){ yue="0"+(gcalendara1.get(gcalendara1.MONTH)+1); }
   else{ yue=""+(gcalendara1.get(gcalendara1.MONTH)+1); }
   if ((gcalendara1.get(gcalendara1.DATE))<10){ ri="0"+(gcalendara1.get(gcalendara1.DATE)); }
   else{ ri=""+(gcalendara1.get(gcalendara1.DATE)); }
    date=gcalendara1.get(gcalendara1.YEAR)+"-"+yue+"-"+ri;
   String sql="select BH,ZZRY from V_NB_HYCJ where SYRQ ='"+date+"'";
   ResultSet rs = myConn.executeQuery(sql);
   if(rs.next()){
   String BH=rs.getString("BH");
   String ZZRY=rs.getString("ZZRY");
    String sqlT="select YGBH from T_CHRY where HYBH='"+BH+"' and ZT<>'1'";
    ResultSet rsT = myConn.executeQuery(sqlT);
    while(rsT.next()){
    String YGBHT=rsT.getString("YGBH");
    if(YGBHT.compareTo(BHT)==0){ i++; }
   
   if(ZZRY.compareTo(BHT)==0){ i++; }
    }
   }
   myConn.close();
     }catch(Exception e){System.out.print(e.toString());return -1;} 	
   //return i;
   return i;
  }
public int getGW(String YGBH)
  {
  int j=0;
  try{
   huayi.gg.dbConn.dbConn myConn=new huayi.gg.dbConn.dbConn();
   String BHT=YGBH;
   //查找没有处理的文件,此处为存储过程调用在数据库T_TEMPGW 表中
   myConn.executeGWSP(BHT);
   String sqlcountQS="select count(*) 'QScount' from T_TEMPGW ";
   ResultSet rscountQS = myConn.executeQuery(sqlcountQS);
   if(rscountQS.next()){
   j=Integer.parseInt(rscountQS.getString("QScount"));
    }
   myConn.close();
     }catch(Exception e){System.out.print(e.toString());} 	
     return j;
  }
  
  
  public int getRWQS(String YGBH)
  {
  int j=0;
  try{
   huayi.gg.dbConn.dbConn myConn=new huayi.gg.dbConn.dbConn();
   String BHT=YGBH;
   //查找没有处理的文件,此处为存储过程调用在数据库T_TEMPGW 表中
   //myConn.executeGWSP(BHT);
   String sqlcountQS="select count(*) 'QScount' from V_RWQSCX where BQSRBZ='0' and BQSR='"+YGBH+"'";
   ResultSet rscountQS = myConn.executeQuery(sqlcountQS);
   if(rscountQS.next()){
   j=Integer.parseInt(rscountQS.getString("QScount"));
    }
   myConn.close();
     }catch(Exception e){System.out.print(e.toString());} 	
     return j;
  }
  
  public int getRWXD(String YGBH)
  {
  int j=0;
  try{
   huayi.gg.dbConn.dbConn myConn=new huayi.gg.dbConn.dbConn();
   String BHT=YGBH;
   //查找没有处理的文件,此处为存储过程调用在数据库T_TEMPGW 表中
   //myConn.executeGWSP(BHT);
   String sqlcountQS="select count(*) 'QScount' from V_RWXDCX where BXDRBZ='0' and BXDR='"+YGBH+"'";
   ResultSet rscountQS = myConn.executeQuery(sqlcountQS);
   if(rscountQS.next()){
   j=Integer.parseInt(rscountQS.getString("QScount"));
    }
   myConn.close();
     }catch(Exception e){System.out.print(e.toString());} 	
     return j;
  }
  
  public int getRWJS(String YGBH)
  {
  int j=0;
  try{
   huayi.gg.dbConn.dbConn myConn=new huayi.gg.dbConn.dbConn();
   String BHT=YGBH;
   //查找没有处理的文件,此处为存储过程调用在数据库T_TEMPGW 表中
   //myConn.executeGWSP(BHT);
   String sqlcountQS="select count(*) 'QScount' from V_RWJSCX where BJSRBZ='0' and XDR='"+YGBH+"'";
   ResultSet rscountQS = myConn.executeQuery(sqlcountQS);
   if(rscountQS.next()){
   j=Integer.parseInt(rscountQS.getString("QScount"));
    }
   myConn.close();
     }catch(Exception e){System.out.print(e.toString());} 	
     return j;
  }
  
  
  public int getRWFK(String YGBH)
  {
  int j=0,i=0,k=0,m=0;
  try{
   huayi.gg.dbConn.dbConn myConn=new huayi.gg.dbConn.dbConn();
   String BHT=YGBH;
   //查找没有处理的文件,此处为存储过程调用在数据库T_TEMPGW 表中
   //myConn.executeGWSP(BHT);
   String sqlcountQS="select count(*) 'QScount' from V_RWJSCX where WCBZ='1' and XDR='"+YGBH+"'";
   ResultSet rscountQS = myConn.executeQuery(sqlcountQS);
   if(rscountQS.next()){
   j=Integer.parseInt(rscountQS.getString("QScount"));
    }
   myConn.close();
     }catch(Exception e){System.out.print(e.toString());} 	
    // return j;
  
  
  try{
   huayi.gg.dbConn.dbConn myConn1=new huayi.gg.dbConn.dbConn();
   //String BHT=YGBH;
   //查找没有处理的文件,此处为存储过程调用在数据库T_TEMPGW 表中
   //myConn.executeGWSP(BHT);
   String sqlcountQS1="select count(*) 'QScount' from V_RWQSCX where (QSRBZ='1' or QSRBZ='0')and GTZT='1' and QSR='"+YGBH+"'";
   ResultSet rscountQS1 = myConn1.executeQuery(sqlcountQS1);
   if(rscountQS1.next()){
   i=Integer.parseInt(rscountQS1.getString("QScount"));
    }
   myConn1.close();
     }catch(Exception e){System.out.print(e.toString());} 	
    // return j;
    
    try{
   huayi.gg.dbConn.dbConn myConn2=new huayi.gg.dbConn.dbConn();
   //String BHT=YGBH;
   //查找没有处理的文件,此处为存储过程调用在数据库T_TEMPGW 表中
   //myConn.executeGWSP(BHT);
   String sqlcountQS2="select count(*) 'QScount' from V_RWXDCX where (XDRBZ='1' or XDRBZ='0')and GTBZ='1' and XDR='"+YGBH+"'";
   ResultSet rscountQS2 = myConn2.executeQuery(sqlcountQS2);
   if(rscountQS2.next()){
   k=Integer.parseInt(rscountQS2.getString("QScount"));
    }
   myConn2.close();
     }catch(Exception e){System.out.print(e.toString());}
     
     m=j+i+k; 	
    return m;
  }
  public int getRW(String YGBH){
  	int rw=0;
  	rw=getRWQS(YGBH)+getRWXD(YGBH)+getRWJS(YGBH)+getRWFK(YGBH);
  	return rw;
  	
}
  
}


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -