Author Topic: Task attened user  (Read 2540 times)

Se7en

  • Newbie
  • *
  • Posts: 11
    • View Profile
    • Email
Task attened user
« on: July 30, 2010, 09:57:43 am »
hi,

i need a table name includes task's name and attended user id or user name like this..

og_projects_task table has title and others but i cant find user..

i need and sql query just listed workspace name,tasks title in that workspaces and task's users list..

thanks,
regards,

cabeza

  • Administrator
  • Hero Member
  • *****
  • Posts: 1004
    • View Profile
    • Feng Office
Re: Task attened user
« Reply #1 on: July 30, 2010, 10:00:29 am »
It is "assigned_to_user_id" on og_projects_task table

Se7en

  • Newbie
  • *
  • Posts: 11
    • View Profile
    • Email
Re: Task attened user
« Reply #2 on: July 30, 2010, 10:04:50 am »
thanks for quick reply.. and one question again..

in that table.. where is that task's workspace id ?

cabeza

  • Administrator
  • Hero Member
  • *****
  • Posts: 1004
    • View Profile
    • Feng Office
Re: Task attened user
« Reply #3 on: July 30, 2010, 10:25:04 am »
It's not. The link is defined in og_workspace_objects

Se7en

  • Newbie
  • *
  • Posts: 11
    • View Profile
    • Email
Re: Task attened user
« Reply #4 on: July 30, 2010, 10:37:34 am »
og_projects_tasks  ' id field is equal og_workspace_objects 's object_id field?

and object_manager is "ProjectTasks" 

i write a query

Code: [Select]
SELECT
og_users.username,
og_project_tasks.title,
og_projects.name
FROM
og_project_tasks
Inner Join og_users ON og_project_tasks.assigned_to_user_id = og_users.id
Inner Join og_workspace_objects ON og_project_tasks.id = og_workspace_objects.workspace_id
Inner Join og_projects ON og_workspace_objects.workspace_id = og_projects.id
WHERE
og_workspace_objects.object_manager =  'ProjectTasks'

but it wasnt get list correctly..

thanks,regards

cabeza

  • Administrator
  • Hero Member
  • *****
  • Posts: 1004
    • View Profile
    • Feng Office
Re: Task attened user
« Reply #5 on: July 30, 2010, 03:07:04 pm »
og_projects_tasks  ' id field is equal og_workspace_objects 's object_id field?

and object_manager is "ProjectTasks" 

Yes