TIP: Click on subject to list as thread! ANSI
echo: c_plusplus
to: William McBrine
from: Darin McBride
date: 2002-12-30 20:25:16
subject: There`s gotta be an easi

Hello William!

Replying to a message of William McBrine to Jasen Betts:

 WM> Anyway, the big question for me is, why store these numbers as ASCII
 WM> at all? Why not store them as ints (or floats, if necessary), and
 WM> only convert once on input and once on output? That would seem more
 WM> efficient.

Easy - it's coming in from legacy code, or from another subsystem that
doesn't know that these are numerics.  For example, they may be using an
LDAP protocol (guess what I just started using...) where one or more of the
fields is defined (for business reasons) to be integral (employee ID, for
example), but the LDAP protocol doesn't know nor care what the data it
transfers is.

However, Neil, because he is writing for that particular business, knows
that these two fields are always numeric by definition.

There are many more examples that I could give, and way more that I couldn't.

While I would agree - if they are always numerics, the ideal would be to
store them as such, sometimes you don't get to control these details.

Darin
C_PLUSPLUS moderator
dmcbride{at}tower.to.org

---
* Origin: Tanktalus' Tower BBS (1:250/102)
SEEN-BY: 633/267 270
@PATH: 250/102 99 10/345 379/1 633/267

SOURCE: echomail via fidonet.ozzmosis.com

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.