Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

SQL serverÊý¾Ý¼¯³ö´íÇóÖú

Á½ÖÖ´íÎó£º
1.Èç¹ûÎÒÕâÑùÉêÃ÷£ºResultSet rs;´íÎóÌáʾÈçÏ£º

An error occurred at line: 51 in the jsp file: /index.jsp
The local variable rs may not have been initialized
48:        {
49:            out.println("Òì³£!");
50:        }
51:        while(rs.next())
52:        {
53:        %>
54:        <td width="11%" height="20" align="center"> <div align="center">

2.Èç¹ûÎÒÕâÑùÉêÃ÷£ºResultSet rs=null;´íÎóÌáʾÈçÏ£º

org.apache.jasper.JasperException: An exception occurred processing JSP page /index.jsp at line 51

48:        {
49:            out.println("Òì³£!");
50:        }
51:        while(rs.next())
52:        {
53:        %>
54:        <td width="11%" height="20" align="center"> <div align="center">


³öÏÖÕâÖÖÇé¿öÔõô½â¾ö£¿Çó¸ßÊÖ°ï棡±È½Ï¼±,лл~~£¡£¡£¡£¡´úÂëËäÈ»³¤£¬µ«ÊǺܶ඼ûÓбØÒª¿´£¬Ï£ÍûµÃµ½°ïÖú¡£¡£¡£¡£¡£
ÎÊÌâ²¹³ä£¨rs³õʼ»¯ÔÚÏÂÃæ´úÂëÖкìÉ«±êÇ©´¦Ã÷Ã÷³õʼ»¯ÁË


Ïà¹ØÎÊ´ð£º

Á½¸öµ¼¹¹sql serverÊý¾Ý¿â,Êý¾Ýµ¼Èëµ¼³öÎÊÌâ

ÏÖÔÚÓÐÁ½¸öÒì¹¹µÄsql serverÊý¾Ý¿â,ÎÒÏ뽫µÚÒ»¸ö±íÖеÄÊý¾Ýµ¼Èëµ½µÚ¶þ¸ö±íÖÐ,×Ô¼ºÖ¸¶¨µ¼ÈëÊý¾ÝµÄ×Ö¶Î,ÈçºÎµ¼ÈëÊý¾ÝÄØ,´ó¼ÒÌÖÂÛÒ»ÏÂ?
dts¹¤¾ß

µ¼Èëµ¼³ö¹¤¾ß.

DD

¹þ¹þ£¬¹À¼ÆÕâλÊǵØQIOU¶¼Êܲ»Á˵Ä

Ö±½ÓÐ ......

ÇóÒ»SQLÓï¾ä

ÎÒÏÖÔÚÓÐ2¸ö±íTable1£¬Table2¡£¶ÔÓ¦µÄ×ֶΡ¢Êý¾ÝÈçÏ£º

Table1£ºprimary key(a1)
a1(char)      a2(int)
  a            10
  b  & ......

sql Óï¾ä

±íA
¿¨ºÅ         ʱ¼ä
1                 null
2                 null
3 & ......

sqlÈ¡²éѯֵ

ÈçÌ⣺select name from table1
µÃµ½½á¹û£ºname
          СÍõ
          СÕÔ
          СÀî
      ......

Õâ¸öSQLÓï¾äÔõôд

ÓÐÒ»¸ö±í½á¹¹ÈçÏ£º
ÎïÆ·±àÂë  Ê¹ÓôÎÊý  Ãû³Æ  ÊôÐÔ1£¬ÊôÐÔ2.¡£¡£¡£¡£¡£¡£

ÆäÖУ¬Ç°Á½ÏîΪÖ÷¼ü£¨ÎïÆ·±àÂë  Ê¹ÓôÎÊý£©£¬´ÎÊý×î¶àΪ5

ÏÖÔÚÎÒÏë°Ñ ͬһÖÖÎïÆ·µÄ²»Í¬´ÎÊýµÄÊôÐ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ