Also if you where to store a phone number in your db, what column type would you give it. I have used varChar but its all numbers i want to store. Would this suffice.
ThanksHi,
That's four bytes, not four number places. So the range is from -2^31 (-2,147,483,648) through 2^31 - 1 (2,147,483,647). That's a lot of users... :-D
I usually store phone numbers as varchars, whether I include formatting symbols--(, ), -, whatever--or not. That way you don't have to worry about trailing zeroes (or leading ones if you also are using international phone numbers), and formatting for the user interface is way easier. In fact, if you are storing international phone numbers, you probably want to include the symbols as well.
Don
No comments:
Post a Comment