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

Scott Marcus marcus at tsstech.com
Wed May 18 13:06:37 CDT 2005


LOL: This type of reasoning will make all of your code "bad practice"
when your applications are run on a 64bit edition of Windows. Better
convert now so that efficiency is there when it happens.

-----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

 




NOTICE:  This electronic mail transmission is for the use of the named individual or entity to which it is directed and may contain information that is privileged or confidential.  If you are not the intended recipient, any disclosure, copying, distribution or use of the contents of any information contained herein is prohibited.  If you have received this electronic mail transmission in error, delete it from your system without copying or forwarding, and notify the sender of the error by replying via email or by calling TSS Technologies at (513) 772-7000, so our address record can be corrected.   

Any information included in this email is provided on an “as is” and “where is” basis, and TSS Technologies makes no representations or warranties of any kind with respect to the completeness or accuracy of the information contained in this email, or with respect to any other matters communicated in this email.  TSS Technologies hereby disclaims any and all express or implied warranties of any kind.  Nothing in this email shall be construed to create any kind of contractual or binding agreement or commitment by or on behalf of TSS Technologies, Inc., the recipient, or any third-parties.



More information about the AccessD mailing list