Re: How do I create a box from fields in a table? - Mailing list pgsql-general

From Rob Richardson
Subject Re: How do I create a box from fields in a table?
Date
Msg-id 67D108EDFAD3C148A593E6ED7DCB4BBDC3FB69A4@RADCONWIN2K8PDC.radcon.local
Whole thread Raw
In response to Re: How do I create a box from fields in a table?  (Merlin Moncure <mmoncure@gmail.com>)
Responses Re: How do I create a box from fields in a table?
List pgsql-general
Thank you for your reply.

In my opinion, that is ugly to the point of uselessness.  I think I would rather just use simple integer arithmetic.
Itwill be easier for others to understand. 

RobR

-----Original Message-----
From: Merlin Moncure [mailto:mmoncure@gmail.com]
Sent: Thursday, October 17, 2013 5:58 PM
To: Rob Richardson
Cc: pgsql-general@postgresql.org
Subject: Re: [GENERAL] How do I create a box from fields in a table?

you have to construct the string.  this is somewhat baroque by modern postgres standards but should work:

select tran_car_identification, format('((%s, 1), (2, 3))', location)::box from transfer_car;

merlin


pgsql-general by date:

Previous
From: Vincent Veyron
Date:
Subject: Re: Help function to sort string
Next
From: akp geek
Date:
Subject: Re: Need some help on Performance 9.0.4