java´æ´¢¹ý³ÌµÄ´´½¨Óëµ÷ÓÃ
create or replace procedure updateProject is
begin
update project p set p.total_intend_gather =
(select sum(ig.gather_sum) from intend_gather ig where ig.project_number=p.project_number);
update project p set p.total_actual_gather =
(select sum(ag.gahter_sum) from actual_gather ag where ag.project_number=p.project_number);
update project p set p.total_invoice=
(select sum(invoice.invoice_sum) from invoice invoice
where invoice.intend_id in
(select ig.intend_id from intend_gather ig where ig.project_number=p.project_number));
end updateProject;
Session session = this.getSession();
Transaction tx =null;
try {
tx = session.beginTransaction();
Connection con = session.connection();
String procedure = "{call updateproject() }";
CallableStatement cstmt = con.prepareCall(procedure);
cstmt.executeUpdate();
tx.commit();
} catch (Exception e) {
tx.rollback();
}
Ïà¹ØÎĵµ£º
²âÊÔ»·¾³£ºwin2000+jdk1.4+jb2006
import java.io.*;
import java.util.Enumeration;
//import java.util.zip.*;
import org.apache.tools.zip.*;
public class Test {
//½âѹÎļþ
public static void extZipFileList(String zipFileName, String extPlace) {
try {
  ......
×÷ÕߣºÐûÕ×Åô
------------------------------------------------------------------------------------------------------------------------------------------
¹¤×÷µÚÒ»²½£ºÊìϤMyEclipseµÄ»·¾³ÒÔ¼°Ö÷Òª¹¦ÄÜ¡£
¹¤×÷µÚ¶þ²½£º½¨Á¢Êý¾Ý¿âÁ¬½Ó
Êý¾Ý¿â£ºMySQL
1¡¢MySQLµÄÅäÖÃÓëÎÊÌâ½â¾ö
Ïê¼ûÎ ......
ÏÖÔÚUrlRewriter¼¼ÊõÓÐÁ½¸ö¼¼Êõƽ̨µÄ£¬Ò»¸ö¾ÍÊÇÔÚJava·½ÏòµÄ£¬ÁíÒ»¸ö¾ÍÊÇ.NET·½ÏòµÄ¡£Õâ´ÎÊÇJava·½ÏòµÄÓ¦Óá£
Ê×ÏÈÈÃÎÒÃÇÁ˽âËüµÄ¹¤×÷ÔÀí£¬Ëµ°×ÁËËü¾ÍÊÇÒ»¸ö¼òµ¥µÄ¹ýÂËÆ÷£¨Filter£©£¬¿´¿´Ô´ÂëÄã¾Í»áºÜ¿ìµÄÃ÷°×£¬Ëü¾ÍÊÇͨ¹ýÎÒÃÇÔÚjspÖг£ÓõÄÁ½¸ö·½·¨ÊµÏÖµÄforward(),sendRedirect().
ÏÂÃæÎÒÃǾͿìËÙµÄΪÄãµÄÍøÕ¾´î½¨U ......
System.out.println(2|0); //0010 0000 =>0010 = 2
System.out.println(2|1); //0010 0001 =>0011 = 3
System.out.println(3|2); //0011 0010 =>0011 = 3
System.out.println(3&2); //0011 0010 =>0010 = 2
/*
ÔÚjavaÖÐ0´ú±í¼Ù, 1´ú±íÕæ
00011|0010 ´ÓÓÒµ½×ó±È½Ï0|1 = 1, 1|0 = ......