最简单的单表学生信息查询:
创建一张表,存学号,姓名,年龄
create table t_student (sno number(3),sname varchar2(10),sage number(3))
插入记录:
insert into t_student (sno,sname,sage) values (1,'张三',21)
insert into t_student (sno,sname,sage) values (2,'李四',23)
commit
查询年龄小于22岁的:
select * from t_student where sage <22
查询学号为2号的:
select * from t_student where sno = 2
查询姓张的:
select * from t_student where sname like '张%'
这样应该差不多了。
利用管道机制,先设置路径,然后再设置一些命令,下面有个列子,希望你能看懂set classpath=%JAVA_HOME%\bin%JAVA_HOME%\lib\dt.jar%JAVA_HOME%\lib\tools.jarC:\oracle\ora92\binC:\Program Files\Oracle\jre\1.1.8\bin%SystemRoot%\system32%SystemRoot%%SystemRoot%\System32\WbemC:\jakarta-tomcat-5.0.28\common\lib\log4j-1.2.8.jarC:\jakarta-tomcat-5.0.28\common\lib\classes12.jar
javac tclsend.java
java tclsend
欢迎分享,转载请注明来源:内存溢出
评论列表(0条)