Project and Portfolio Management Practitioners Forum
cancel

Linking Time Sheet Notes with Time Sheet Id

Highlighted
saiskt
Respected Contributor.

Linking Time Sheet Notes with Time Sheet Id

Hi Could any one help me in linking the Time sheet Notes with that particular Time Sheet.

I am trying the below 2 queries but its not working properly. Please help.

Query 1

SELECT ttm.time_sheet_id,itg.note_text FROM itg_notes itg,knta_users ku,tm_time_sheets ttm
WHERE itg.last_updated_by (+) = ku.user_id AND ttm.resource_id = ku.user_id AND itg.note_type = 'TS'

Query 2

SELECT ttm.time_sheet_id,itg.note_text FROM itg_notes itg,tm_time_sheets ttm
WHERE itg.last_update_date (+)= ttm.last_update_date AND itg.note_type = 'TS'
3 REPLIES
Mahen M
Acclaimed Contributor.

Re: Linking Time Sheet Notes with Time Sheet Id

I hope note text is of CLOB format, You have to convert it to varchar format.

I hope your issue is you cannot see the note_text

Regards,
Mahendran M
HimaPV
Regular Contributor.

Re: Linking Time Sheet Notes with Time Sheet Id

Try this query

SELECT ttm.time_sheet_id,itg.note_text FROM itg_notes itg,knta_users ku,tm_time_sheets ttm
WHERE ttm.resource_id = ku.user_id
and ku.user_id=ttm.resource_id AND itg.note_type = 'TS'
and ttm.time_sheet_id=itg.OWNER_ID
Sevilay
Honored Contributor.

Re: Linking Time Sheet Notes with Time Sheet Id

Hi Saiskt,

i modified the last query very little :

SELECT ttm.description,tsl.time_sheet_line_id,tsl.time_sheet_line_seq,to_char(itg.note_text)
FROM itg_notes itg,
knta_users ku,
tm_time_sheets ttm ,
tm_time_sheet_lines tsl
WHERE ttm.resource_id = ku.user_id
and ku.user_id=ttm.resource_id
and itg.note_type = 'TS'
and ttm.time_sheet_id = itg.OWNER_ID
and ttm.time_sheet_id = tsl.time_sheet_id