java.sql.Date如何转换为java.util.Date?
解决方案 »
- java中有文件结束符吗?
- 求教用过JACC的高手
- 求助JTable遇到的奇怪问题
- 请问如何使用Locale类实现对各国家输出格式的更改?
- 请问;怎样用JavaScript语言提取file输入框中文件的后缀?急!
- 怎样找到一个Swing界面中的各个元素在程序中对应的变量?
- 夜深了,送道题给赔我过夜的人们。
- 请问Java怎么编写代码访问一个网址然后在搜索栏自动的输入信息搜索啊
- 用MICROSOFT SQL SERVER 2000的JDBC驱动程序出现错误
- 急!Jbuilder中文显示问题?
- 跪求一个组合算法
- 关于Object-Oriented Design and Patterns的作业题~~高手帮帮忙啊~~
java.sql.Date sqldate = null;
java.util.Date utildate = sqldate;
1楼那样做也行 没实验过 通常取出来的时候to_char过的 要么就是orm工具直接给映射成了util的Date了
/*
* @(#)Date.java 1.33 04/05/18
*
* Copyright 2004 Sun Microsystems, Inc. All rights reserved.
* SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
*/package java.sql;/**
* <P>A thin wrapper around a millisecond value that allows
* JDBC to identify this as an SQL <code>DATE</code> value. A
* milliseconds value represents the number of milliseconds that
* have passed since January 1, 1970 00:00:00.000 GMT.
* <p>
* To conform with the definition of SQL <code>DATE</code>, the
* millisecond values wrapped by a <code>java.sql.Date</code> instance
* must be 'normalized' by setting the
* hours, minutes, seconds, and milliseconds to zero in the particular
* time zone with which the instance is associated.
*/
public class Date extends java.util.Date {
...
...
}顶LS的