Search Postgresql Archives

Re: Trying to update a box data type column

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Yonatan Ben-Nes <yonatan@xxxxxxxxxxx> writes:
> I can't figure out how I can update the box column using the values at 
> the nleft & nright columns.

Use the provided constructor functions:

regression=# select box(point(1,2),point(3,4));
     box
-------------
 (3,4),(1,2)
(1 row)

As a general rule, converting something to text and back is not the way
to convert data from one type to another; if it's not a really
outlandish conversion, there'll be a function or cast to help.

			regards, tom lane


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux