RE: IP Sort
store them in a seperate fieldsuse a list to seperate them [EMAIL PROTECTED] 10/13/00 12:52PM Look into CAST() or CONVERT() I think you can do this using the CAST() function. -Adrian -Original Message- From: Lee Surma [mailto:[EMAIL PROTECTED]] I have a bunch of IP numbers stored in a VarChar field in SQL7. When I sort them, it sorts like text, as it should, with not great results. Is there a quick and easy way to get the IP numbers to sort like a number? -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body. -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.
IP Sort
I have a bunch of IP numbers stored in a VarChar field in SQL7. When I sort them, it sorts like text, as it should, with not great results. Is there a quick and easy way to get the IP numbers to sort like a number? -- _ Lee Surma Public Radio International [EMAIL PROTECTED] 612-330-9223 _ -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebarRstsbodyRsts/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.
Re: IP Sort
Can you change the field type to a numeric or is that the limit of 9?- Original Message - From: Lee Surma [EMAIL PROTECTED] To: CF-Talk [EMAIL PROTECTED] Sent: Friday, October 13, 2000 10:39 AM Subject: IP Sort I have a bunch of IP numbers stored in a VarChar field in SQL7. When I sort them, it sorts like text, as it should, with not great results. Is there a quick and easy way to get the IP numbers to sort like a number? -- _ Lee Surma Public Radio International [EMAIL PROTECTED] 612-330-9223 _ -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=stsbody=sts/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body. -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.
Re: IP Sort
I have a bunch of IP numbers stored in a VarChar field in SQL7. When I sort them, it sorts like text, as it should, with not great results. Is there a quick and easy way to get the IP numbers to sort like a number? Pad out each octet with 0's. 206.168.47.6 = 206.168.047.006. Create another field in the table used just for sorting if you don't want to modify the original field. These should sort correctly. Jim -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.
Re: IP Sort
One xxx.xxx.xxx.xxx per VarChar field, OR xxx.xxx.xxx.xxx,yyy.yyy.yyy.yyy, etc per VarChar field? best, paul At 10:39 AM 10/13/00 -0600, you wrote: I have a bunch of IP numbers stored in a VarChar field in SQL7. When I sort them, it sorts like text, as it should, with not great results. Is there a quick and easy way to get the IP numbers to sort like a number? -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.
RE: IP Sort
Look into CAST() or CONVERT() I think you can do this using the CAST() function. -Adrian -Original Message- From: Lee Surma [mailto:[EMAIL PROTECTED]] I have a bunch of IP numbers stored in a VarChar field in SQL7. When I sort them, it sorts like text, as it should, with not great results. Is there a quick and easy way to get the IP numbers to sort like a number? -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebar=listsbody=lists/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.
Re: IP Sort
On Friday, October 13, 2000, Adrian Cesana [EMAIL PROTECTED] wrote: Look into CAST() or CONVERT() I think you can do this using the CAST() function Thanks!! This works within one class c range Order by { fn convert(right(IPNumber,3),SQL_decimal) } _ Lee Surma Public Radio International [EMAIL PROTECTED] 612-330-9223 _ -- Archives: http://www.mail-archive.com/cf-talk@houseoffusion.com/ To Unsubscribe visit http://www.houseoffusion.com/index.cfm?sidebarRstsbodyRsts/cf_talk or send a message to [EMAIL PROTECTED] with 'unsubscribe' in the body.