Way to reverse ordering of an IP ... ? - Mailing list pgsql-sql

From Marc G. Fournier
Subject Way to reverse ordering of an IP ... ?
Date
Msg-id 20060906004355.V13992@ganymede.hub.org
Whole thread Raw
List pgsql-sql
for Reverse DNS purposes, I'd like to reverse an IP ...

ie: 200.46.204.1 would become 1.204.46.200

Is there an easy way of doing this *short* of writing a plpgsql function?

I've checked the docs, and found the substring() function that allows for 
using a regex, which I thought might allow this, but can't seem to figure 
out a proper format for it ;(

If I have to write a function to do it, fine ... just wanted to make sure 
I wasn't missing something first ...

----
Marc G. Fournier           Hub.Org Networking Services (http://www.hub.org)
Email . scrappy@hub.org                              MSN . scrappy@hub.org
Yahoo . yscrappy               Skype: hub.org        ICQ . 7615664


pgsql-sql by date:

Previous
From: "Aaron Bono"
Date:
Subject: Re: Postgres regexp matching failure?
Next
From: Dinesh Tiwari
Date:
Subject: Query regarding to MS reporting services (Grand total problem)