Modify

Opened 7 years ago

Last modified 4 years ago

#3018 assigned defect

Query strings having Syntax Problems

Reported by: ctmurphy Owned by: pacopablo
Priority: normal Component: TaskListPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11

Description (last modified by rjollos)

I've received a couple of different errors that seem to manifest from the SQL string. Both SQL strings appear to be incorrectly structured with values outside of parens and quotes not closing.

SELECT t.id AS id,t.summary AS summary,t.priority AS priority,t.time AS time,t.changetime AS changetime,t.status AS status,t.owner AS owner,t.type AS type,priority.value AS priority_value,action_item.value AS action_item
FROM ticket AS t LEFT OUTER JOIN ticket_custom AS action_item ON (id=action_item.ticket AND action_item.name='action_item')
LEFT OUTER JOIN enum AS priority ON (priority.type='priority' AND priority.name=priority)
WHERE COALESCE(t.status,'') IN (u'accepted',u'assigned',u'new',u'reopened') AND COALESCE(t.owner,'')=u'username' AND COALESCE(t.type,'')=u'task'

SELECT t.id AS id,t.summary AS summary,t.priority AS priority,t.time AS time,t.changetime AS changetime,t.'status AS 'status,priority.value AS priority_value,action_item.value AS action_item FROM ticket AS t
LEFT OUTER JOIN ticket_custom AS action_item ON (id=action_item.ticket AND action_item.name='action_item')
LEFT OUTER JOIN enum AS priority ON (priority.type='priority' AND priority.name=priority)WHERE COALESCE(t.'status,'')!=u"closed'"

Attachments (0)

Change History (3)

comment:1 follow-up: Changed 7 years ago by pacopablo

  • Status changed from new to assigned

Can you please give a little more info? Specifically, [ticket-custom] and [tasklist] sections of trac.ini. Also, what database are you using? Also, versions of trac, genshi, and tasklist plugin.

comment:2 in reply to: ↑ 1 Changed 7 years ago by ctmurphy

Thank you for responding. I'm really anxious to get this working to satisfy the requests the users have made. We are in the early stages of getting Trac integrated and I want to get it set up quickly so I can get that necessary buy in from users.

Here are the versions. There is probably a better way to extract that information, but I'm giving you the .egg name. Let me know if there is a better way.

Trac -11b2 Python - 2.5 mysql - 5.0.45 Genshi-0.5dev_r789-py2.5-linux-i686.egg TaskList-0.1.1-py2.5.egg

[ticket-custom]
action_item = text
action_item.label = Action Item
billable = checkbox
billable.label = Billable?
billable.order = 3
billable.value = 1
blockedby = text
blockedby.label = Blocked By
blocking = text
blocking.label = Blocking
due_close = text
due_close.label = Due Date
due_close.value = MM/DD/YY
estimatedhours = text
estimatedhours.label = Estimated Number of Hours
estimatedhours.order = 1
estimatedhours.value = 0
hours = text
hours.label = Add Hours to Ticket
hours.order = 2
hours.value = 0
restrict_owner = true
testcase_result = select
testcase_result.label = Test Case Result
testcase_result.options = |pass|fail|incomplete
testcase_result.value =
totalhours = text
totalhours.label = Total Hours
totalhours.order = 4
totalhours.value = 0

[tasklist]
default_cols = summary,priority
tasklist_field = action_item

comment:3 Changed 4 years ago by rjollos

  • Description modified (diff)

Add Comment

Modify Ticket

Action
as assigned The owner will remain pacopablo.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.