pg.ddx.io pgsql-admin@postgresql.org mailing list archive
help / color / mirror / Atom feedthe question about round, truncate
2+ messages / 2 participants
[nested] [flat]
* the question about round, truncate
@ 2010-02-05 07:35 Hyung Joo Lee <procarrie@imrc.kist.re.kr>
2010-02-05 09:41 ` Re: the question about round, truncate Ian Lea <ian.lea@gmail.com>
0 siblings, 1 reply; 2+ messages in thread
From: Hyung Joo Lee @ 2010-02-05 07:35 UTC (permalink / raw)
To: pgsql-admin
Dear all.
I have a question about round, truncate.
I want to fix the data like 3-digit decimal after being rounded on 4-digit decimal.
Ex. Geometryformat('linestring((54.11238742 22.023498293, 35.128937123 94.129837123))',-1);
-------> #######('linestring((54.112 22.023, 35.129 94.130))',-1);
What should I do?
I want to use the round, truncate command.
I'm sorry my English is poor.
Best regards and thanks in advance.
Kevin.
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: the question about round, truncate
2010-02-05 07:35 the question about round, truncate Hyung Joo Lee <procarrie@imrc.kist.re.kr>
@ 2010-02-05 09:41 ` Ian Lea <ian.lea@gmail.com>
0 siblings, 0 replies; 2+ messages in thread
From: Ian Lea @ 2010-02-05 09:41 UTC (permalink / raw)
To: pgsql-admin
test=> select round(54.11238742, 3);
round
--------
54.112
is maybe what you want.
P.S. pgsql-admin list is for postgresql admin questions.
http://www.postgresql.org/community/lists/
--
Ian.
On Fri, Feb 5, 2010 at 7:35 AM, Hyung Joo Lee <procarrie@imrc.kist.re.kr> wrote:
> Dear all.
>
>
>
> I have a question about round, truncate.
>
>
>
> I want to fix the data like 3-digit decimal after being rounded on 4-digit
> decimal.
>
>
>
> Ex. Geometryformat(‘linestring((54.11238742 22.023498293, 35.128937123
> 94.129837123))’,-1);
>
> -------> #######(‘linestring((54.112 22.023, 35.129 94.130))’,-1);
>
>
>
> What should I do?
>
>
>
> I want to use the round, truncate command.
>
>
>
> I’m sorry my English is poor.
>
>
>
>
>
> Best regards and thanks in advance.
>
>
>
> Kevin.
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2010-02-05 09:41 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2010-02-05 07:35 the question about round, truncate Hyung Joo Lee <procarrie@imrc.kist.re.kr>
2010-02-05 09:41 ` Ian Lea <ian.lea@gmail.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox