PDA

View Full Version : storing IP address as what type?


loonatik
04-15-2003, 10:53 PM
when a user hits submit, his ip address is also inserted into the db. but whichever type (double, decimal, etc) i use, it always truncates the ip address. do i use text type or is there a better solution? thanks.

Spookster
04-15-2003, 11:15 PM
You will probably want to use VARCHAR. Also make sure you set the size of the field large enough to handle all the characters in the IP address.