RE: [Trac] How to write report SQL to group by day

2006-03-31 Thread ECKHART.CURT
Thanks for the response, but I'm having a little trouble with
(formatting system may vary).  Where is the documentation on how to
format query output fields in Trac Sqlite?  I can't find it anywhere.  I
tried several DB formatting syntaxes but it always returned Unknown
function.

Pointers anyone? TIA.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Jani Tiainen
Sent: Thursday, March 30, 2006 3:15 AM
To: trac@lists.edgewall.com
Subject: Re: [Trac] How to write report SQL to group by day

ECKHART.CURT kirjoitti:
 Hi folks,
 
 I'm trying to write a TRAC report, and I'm stumped by a little thing.
 
 I'm closing out a project which we've controlled using TRAC and I need
 to begin monitoring items closed out each day.
 
 I tried a clause:
 
 time AS __group__ 
 
 in the hopes of getting each day's tickets grouped by day.  I didn't
 really expect it to work and it didn't.
 
 How could I write a report SQL to get groups of one per day?

You need to format that time value to return suitable group, like 
formating it only for DD-MM- format or similiar...

so you output something like

to_char(time, 'DD-MM-') AS __group__

(formating system may vary)

Otherwise you just get grouped by all tickets entered at spesific, exact

moment.

-- 

Jani Tiainen
___
Trac mailing list
Trac@lists.edgewall.com
http://lists.edgewall.com/mailman/listinfo/trac
___
Trac mailing list
Trac@lists.edgewall.com
http://lists.edgewall.com/mailman/listinfo/trac


Re: [Trac] How to write report SQL to group by day

2006-03-30 Thread Jani Tiainen

ECKHART.CURT kirjoitti:

Hi folks,

I'm trying to write a TRAC report, and I'm stumped by a little thing.

I'm closing out a project which we've controlled using TRAC and I need
to begin monitoring items closed out each day.

I tried a clause:

time AS __group__ 


in the hopes of getting each day's tickets grouped by day.  I didn't
really expect it to work and it didn't.

How could I write a report SQL to get groups of one per day?


You need to format that time value to return suitable group, like 
formating it only for DD-MM- format or similiar...


so you output something like

to_char(time, 'DD-MM-') AS __group__

(formating system may vary)

Otherwise you just get grouped by all tickets entered at spesific, exact 
moment.


--

Jani Tiainen
___
Trac mailing list
Trac@lists.edgewall.com
http://lists.edgewall.com/mailman/listinfo/trac


[Trac] How to write report SQL to group by day

2006-03-29 Thread ECKHART.CURT
Hi folks,

I'm trying to write a TRAC report, and I'm stumped by a little thing.

I'm closing out a project which we've controlled using TRAC and I need
to begin monitoring items closed out each day.

I tried a clause:

time AS __group__ 

in the hopes of getting each day's tickets grouped by day.  I didn't
really expect it to work and it didn't.

How could I write a report SQL to get groups of one per day?

Here's the SQL that I'm trying to modify:

SELECT p.value AS __color__,
   id AS ticket, summary, component, milestone, owner, severity, time AS
created,
   changetime AS _changetime, description AS _description,
   reporter AS _reporter
  FROM ticket t,enum p
  WHERE status = 'closed'
AND p.name=t.priority AND p.type='priority'
  ORDER BY time desc, p.value, severity


Thanks in advance,

Curt Eckhart

The Florida Legislature

Office of Legislative Information Technology Services

Office : (850) 488-5340

 
A successful tool is one that was used to do something undreamt of by
its author. - Stephen C. Johnson
___
Trac mailing list
Trac@lists.edgewall.com
http://lists.edgewall.com/mailman/listinfo/trac