04 2015 档案
<s:iterator> 对list操作的一种方法
摘要:显示效果完整代码 1 2 3 4 5 6 7 Insert title here 8 9 10 30 48 49 50 51 52 53 ...
阅读全文
stucts2 基础程序
摘要:参考《Struts2+Hibernate+Spring》index.jsp 1 2 3 4 5 6 Insert title here 7 8 9 10 11 12 13 14 15 View CodeLoginUser....
阅读全文
SQL order by 两个字段排序
摘要:select * from emp;--先按照sal排序,如果sal相同,就按照deptno排序select * from emp order by sal, deptno;--先按照deptno排序,如果deptno相同,就按照sal排序select * from emp order by dep...
阅读全文
SQL isnull函数
摘要:select * from emp;--就算年收入:sal*12+comm,sal为月工资,comm为年薪select ename, sal*12+isnull(comm, 0) from emp;--为什么要使用isnull函数,因为null值不能参加运算select ename, sal*12+...
阅读全文
SQL null值 查询null
摘要:select * from emp;--查询comm为null的员工信息select * from emp where comm is null;--查询comm不为null的员工信息select * from emp where comm is not null;
阅读全文
SQL top order between 一起使用
摘要:select * from emp;--输出工资在[1500,3000]范围之内的工资最高的前5个员工信息select top 5 * from emp where sal between 1500 and 3000 order by sal desc;
阅读全文
SQL order 排序
摘要:select * from emp;--按照工资升序排序select * from emp order by sal;--按照工资降序排序select * from emp order by sal desc;
阅读全文
SQL top查询
摘要:select *from emp;--查询表前5行 员工信息select top 5 * from emp;--查询表前15%行的员工信息select top 15 percent * from emp;
阅读全文
SQL in查询
摘要:--sal为员工工资select * from emp;--查询工资等于1500或3000或5000的用户信息select * from emp where sal in (1500, 3000, 5000);select * from emp where sal = 1500 or sal = 3...
阅读全文
SQL between查询 范围查询
摘要:--sal为员工工资select * from emp;--查询工资在[1500,3000]范围的员工信息select * from emp where sal >= 1500 and sal <= 3000;select * from emp where sal between 1500 and ...
阅读全文
SQL 2008 数据库只读 修改
摘要:先对数据库分离 数据库鼠标右键->任务->分离将UsersDB.mdf UsersDB_log.LDF文件 属性->安全->编辑两个文件的都要更改权限然后在附加数据库 数据库鼠标右键->附加 选择文件路径
阅读全文
java List 简单使用
摘要:Student类class Student{ String name; String pwd; public Student(){} public Student(String name, String pwd){ this.name = name; this.pwd = pwd; } publ...
阅读全文
鼠标右键菜单 删除
摘要:http://zhidao.baidu.com/question/101592007.html?fr=qrl&index=0&qbl=topic_question_0&word=window%20%CA%F3%B1%EA%D3%D2%BC%FC%B2%CB%B5%A5开始 运行 regedit展开 ...
阅读全文
SQL distinct
摘要:select *from emp;select deptno from emp;select distinct deptno from emp;--过滤deptno 重复的数据distinct 对null也会过滤select distinct comm, deptno from emp;--过滤co...
阅读全文
SQL 简单查询语句 select
摘要:select *from emp;//查询emp表内容select ename, job from emp;//从emp表中查询ename和job列select ename, sal from emp;//在表emp中查询ename和sal列select ename, sal*12 from emp...
阅读全文
eclipse jsp 加载服务器tomcat
摘要:1.window->Preferences2.Server->Runtime Environments->Add...3.我安装的是tomcat6.0 所以选择Apache Tomcatv6.0->Next4.选择tomcat安装的路径创建服务器点击new server wizard创建好之后
阅读全文
eclipse 改变字体大小
摘要:1.window->preferences2.General->Apperance->Colors and Fonts->Basic3.选择Text Font->Edit3.选择字体大小我选择字体大小12
阅读全文
SQL 启动服务方法
摘要:(1)windows开始菜单->Microsoft SQL Server 2012->配置工具->配置管理器查看服务(2)win7 将鼠标移到菜单栏->鼠标右键->任务管理器选择服务这是window自带服务在右边任意选中一个,在键盘上输入sq(3)计算机鼠标右键->管理
阅读全文
Servlet 基础认识 使用
摘要:参考书《JSP Web 开发案例教程》在jsp项目中的src文件下面创建HelloServletTest.java,代码如下,注意src的包名,我的包名是zhbit.compackage zhbit.com;import java.io.IOException;import java.io.Prin...
阅读全文
eclipse 导入jdbc4.jar 包
摘要:详细讲解链接http://wenku.baidu.com/link?url=QUhO2rIL2fYRgOUyd1TQPEgbl0jQr156ioxK5fiwSPm_Tset2okpBEJcO1fmzzmJClU5l0XUGBA9rzRMzDIVxaJ2chOTzGc5Yjz3XCeAHfO打开ecl...
阅读全文
eclipse JAVA 类元素 快速添加set和get方法
摘要:鼠标在代码窗口,鼠标右键然后选择如下图然后在下面图中,选择需要个类的元素添加的set和get选择好了点击OK,这样eclipse就自动生成get和set方法
阅读全文
JAVA JDBC连接 SQLServer2012 连接失败 端口号错误
摘要:SQLServer2012的SQL Sever 网络配置 我有4个SQLEXPRESS的协议SQLSERVER2008的协议MSSQLSERVER的协议SQLSERVER2012的协议他们都是实例名,我要用SQLSERVER2012的实例,所以为了能让java能连接,我将下面三个的协议都禁了,只启动...
阅读全文
JAVA JDBC连接 SQLServer2012
摘要:连接数据库的java测试代码 1 import java.sql.*; 2 3 public class ConManager { 4 final static String cfn = "com.microsoft.sqlserver.jdbc.SQLServerDriver"; 5 ...
阅读全文
JDK安装 配置环境变量
摘要:我将JDK安装在D盘中在D盘中新建一个文件 文件名为JAVA运行jdk安装软件 更改jdk安装路径为下一步 等待jdk安装完成安装jre路径 jre路径改为点击下一步 等待jre安装完成注意:安装jdk和jre的文件不能放在用一个文件夹里,否则会出错。环境变量的配置在开始菜单cmd打开cmd配置环境...
阅读全文
jsp eclipse 创建jsp项目
摘要:选择File菜单File->new->Other...选择Dynamic Web Project项目->Next写入项目->Finish在WebContent鼠标右键->New-Other...->JSP file点击Next修改jsp的文件名为index,点击Finish在index.jsp页面写...
阅读全文
SQL Server 身份验证 登陆
摘要:当遇到错误检查SQL是否启动SQL Server (MSSQLSERVER)在打开 SQL Server 配置管理器SQL Server (MSSQLSERVER) 鼠标右键->启动再点击连接 就能连上了
阅读全文