The Artima Developer Community
Sponsored Link

Legacy Java Answers Forum
January 2001



This page contains an archived post to the Java Answers Forum made prior to February 25, 2002. If you wish to participate in discussions, please visit the new Artima Forums.


Java int and access Long Integer

Posted by Kishori Sharan on January 09, 2001 at 12:08 PM

When you set the data type of Number for a column in a table then you can set its field size to byte, Integer, Long Integer etc. The Long Integer in access takes 4 bytes and that is what Java int takes. So Java int is compatible with Long Integer in access ( I mean takes exactly same value ) . If you are declaring your table field as Long Integer in access then you can use Java int without any fear of getting truncated values. In access Integer takes only two bytes and it is not safe you if wtire from Java int to access Integer.However, opposite is OK.


  • ok ok programmer June 19, 2001 at 4:06 PM (0)

Sponsored Links

Copyright © 1996-2009 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use - Advertise with Us