Integers vs. Long Integers Was: RE: [AccessD] Global Variable

John W. Colby jwcolby at colbyconsulting.com
Wed May 18 12:30:41 CDT 2005


Not true

John W. Colby
www.ColbyConsulting.com 

Contribute your unused CPU cycles to a good cause:
http://folding.stanford.edu/

-----Original Message-----
From: accessd-bounces at databaseadvisors.com
[mailto:accessd-bounces at databaseadvisors.com] On Behalf Of DWUTKA at marlow.com
Sent: Wednesday, May 18, 2005 1:17 PM
To: accessd at databaseadvisors.com
Subject: Integers vs. Long Integers Was: RE: [AccessD] Global Variable


An integer is a 16 bit variable.  Which means, on a 32 bit system (which
includes almost anything running Windows), for the processor to use that 16
bit variable, it first converts it into a 32 bit variable.  Then it does
what it needs to do, then converts it back to a 16 bit variable.

A long integer is a 32 bit variable.  So it doesn't need to be converted.
That means, for every 'transaction' between an integer and a long integer,
the integer is going to take longer (3 steps instead of 1)

Drew



-----Original Message-----
From: Susan Harkins [mailto:ssharkins at bellsouth.net]
Sent: Wednesday, May 18, 2005 10:24 AM
To: 'Access Developers discussion and problem solving'
Subject: RE: [AccessD] Global Variable


 However, Integers, while they may be misused, even if they are used
correctly, they are still bad practice, because they are 16 bit variables.  

========Why is that bad? If it saves you the trouble of writing code that
does exactly what the data type does -- reject an inappropriate value? Why
would you bother? What is bad about using the data type for its said
purpose, regardless of its size?

Susan H. 

-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com
-- 
AccessD mailing list
AccessD at databaseadvisors.com
http://databaseadvisors.com/mailman/listinfo/accessd
Website: http://www.databaseadvisors.com






More information about the AccessD mailing list