On Wed, 2006-06-28 at 15:16 -0500, Aaron Bono wrote:
> This should work too:
>
> select
> year_list.year,
> one_list.one_count,
> two_list.two_count
> FROM (
> select years
> from generate_series(2006,2009) as years
> ) year_list
> left outer join (
> select
> date
On Wed, 2006-06-28 at 13:34 -0500, Aaron Bono wrote:
> select
> year_list.year,
> count(one.*),
> count(two.*)
> from (
> select years
> from generate_series(2006,2009) as years
> ) year_list
> left outer join mytable as one on (
> date_part('year', one.date) = year_list.y
Greetings.
I'm having some difficulties with my first use of the generate_series
function.
Situation:
cause| integer
date | timestamp(2) without time zone
cause | date
--++---+
1 | 2006-03-23 15:07:53.63 |
2
gt; 2006-02-16
|> 2006-02-17
|> 2006-02-18
|> 2006-02-19
|> 2006-02-20
|> 2006-02-21
|> 2006-02-22
|> 2006-02-23
|> 2006-02-24
|> 2006-02-25
|> 2006-02-26
|> 2006-02-27
|> 2006-02-28
|> (28 rows)
|>
|> On Monday 20 February 2006 15:3
Hello.
I'm having difficulties on my first incursion through generate_series.
The details:
SELECT DATE_TRUNC('month', timestamp '2006-02-01' )::DATE + s.d AS date,
COUNT (o."04-sms") as totalcause98
FROM generate_series(11,19) AS s(d)
LEFT JOIN netopia o ON (substr(o."26-insertTime",
Hello everyone.
I'm experiencing some doubts regarding a procedure i have (.c compiled
as .so) running as an 'after insert for each row' trigger.
This trigger is supposed to do a simple query, something like
SELECT * FROM table order by id where processed=0 limit 1
It's not the perfect way to get
Hello,
I'm using a TIMESTAMP column with a now() default which (correctly i
assume) uses a '-mm-dd hh:mm:ss' format.
Is it possible to make it something like '-mm-dd hh:mm:ss:cc' ?
(basically, a DATE and a TIME, but with 2 decimal cases on the :cc and
not .c as the TIME format.
Tha
Hello all,
First of all, accept my apologies for what is surely a dumb question,
and yes i have been reading extensively through all the documents, but i
really need to ask this.. :)
I have recently started the migration of a large ex-MySql database to
postgresql, and im still "adapting" to the