[rt-users] TicketSQL question
Bob Goldstein
bobg at uic.edu
Wed Oct 19 01:17:28 EDT 2005
>> I basically want to know, did the requestor
>> send that last Correspond? If he did,
>> and did it 3 days ago, I need to crack some
>> heads. But if we sent the last correspond,
>> the heads can stay healthy.
>
>I don't believe that is possible in raw TicketSQL.
>
>It wouldn't be hard to add a "LastTransaction" concept to TicketSQL,
>but then you have to ask the question: "Do we generalize this? What
>if I want the 2nd to last transaction?" "What if I want the last
>Comment?" And suddenly the world explodes.
>
Boom! I think you're right, but still, what SHOULD
TicketSQL do? How much should it be like SQL?
...(select max(Transaction.date) where Transaction.type='correspond') ...
The 'S' in SQL basically means subqueries, but not in TicketSQL.
I agree that "last Comment" is fair game, but the "2nd to last"
is a lot harder and less useful, so I'm less concerned there.
Let me generalize my question/quandry. I need some reports.
My options are:
1. TicketSQL
2. Real SQL
3. Perl with Objects and DBIx::SB
TicketSQL doesn't have the features, although the fact it works
in a url is very attractive. Real SQL would be great if the
schema docs were ok (am I missing them?) and I could count on
the schema not changing, but the book kinda recommends against
raw sql (I'm talking read-only though). Perl would work, of
course, but that seems so laborious and ad hoc compared to sql
(much as I like perl).
What would you do?
bobg
More information about the rt-users
mailing list