DBA Data[Home] [Help]

APPS.CCT_QDE_PUB dependencies on CCT_QDE_AGENT

Line 30: update cct_qde_agent_queues set count = p_count

26: --|| ' p_count = ' || p_count);
27:
28: l_item_type := CCT_MEDIA_TYPES_PUB.GET_UWQ_MEDIA_TYPE_ID(p_item_type);
29:
30: update cct_qde_agent_queues set count = p_count
31: where agent_id = p_agent_id
32: and item_type = l_item_type
33: and ((p_classification is null and classification is null) or (p_classification is not null
34: and classification = p_classification)) ;

Line 48: insert into cct_qde_agent_queues

44: end if;
45:
46: EXCEPTION
47: WHEN ENTRY_NOT_FOUND THEN
48: insert into cct_qde_agent_queues
49: ( agent_queue_id, agent_id, item_type, classification, count,
50: created_by, creation_date,
51: last_updated_by, last_update_date, last_update_login
52: )

Line 55: cct_qde_agent_queues_s1.nextval, p_agent_id, l_item_type, p_classification, p_count,

51: last_updated_by, last_update_date, last_update_login
52: )
53: values
54: (
55: cct_qde_agent_queues_s1.nextval, p_agent_id, l_item_type, p_classification, p_count,
56: 1, sysdate, 1, sysdate, 1
57: );
58: IF FND_API.To_Boolean( p_commit ) THEN
59: COMMIT WORK;

Line 290: from cct_qde_agent_vw

286: -- check if agent is available to process media item.
287:
288: declare cursor r1 is
289: select agent_id, raw_agent_index, item_type, classification
290: from cct_qde_agent_vw
291: where (item_type = p_item_type)
292: and ((classification is null) or (classification is not null
293: and classification = p_classification))
294: and (is_get_work = 1)

Line 310: from cct_qde_agent

306: --dbms_output.put_line('UPDATE_ROUTE_RESULT: pre lock agent');
307: begin
308:
309: select agent_id into l_agent_id
310: from cct_qde_agent
311: where agent_id = r1_rec.agent_id and is_get_work = 1
312: for update nowait;
313: --dbms_output.put_line('UPDATE_ROUTE_RESULT: post lock agent');
314: exception

Line 351: update cct_qde_agent

347:
348:
349: delete from cct_qde_data where item_id = p_item_id;
350:
351: update cct_qde_agent
352: set is_get_work = 0, item_type = null, classification = null
353: where agent_id = r1_rec.agent_id;
354:
355: -- TODO Handle what happens if dequeue returns failure.

Line 508: select raw_agent_index into l_raw_agent_index from cct_qde_agent

504:
505:
506: --dbms_output.put_line('GET_NEXT_ITEM: pre select raw_agent_id');
507:
508: select raw_agent_index into l_raw_agent_index from cct_qde_agent
509: where agent_id = p_agent_id ;
510:
511: update cct_qde_agent
512: set is_get_work = 1, item_type = p_item_type,

Line 511: update cct_qde_agent

507:
508: select raw_agent_index into l_raw_agent_index from cct_qde_agent
509: where agent_id = p_agent_id ;
510:
511: update cct_qde_agent
512: set is_get_work = 1, item_type = p_item_type,
513: classification = p_classification,
514: gw_req_time = sysdate
515: where agent_id = p_agent_id;

Line 548: select agent_id into l_agent_id from cct_qde_agent

544: end;
545: end if; */
546: --dbms_output.put_line('GET_NEXT_ITEM: pre select route result');
547: begin
548: select agent_id into l_agent_id from cct_qde_agent
549: where agent_id = p_agent_id
550: for update nowait;
551: exception
552: when NO_DATA_FOUND then

Line 582: update cct_qde_agent

578: select item_kvp into x_kvp from cct_qde_data
579: where item_id = r1_rec.item_id;
580: delete from cct_qde_data where item_id = r1_rec.item_id;
581:
582: update cct_qde_agent
583: set is_get_work = 0, item_type = null, classification = null
584: where agent_id = p_agent_id;
585:
586: -- TODO Handle what happens if dequeue returns failure.

Line 722: select raw_agent_index into l_raw_agent_index from cct_qde_agent

718: x_msg_data := null;
719:
720: -- API body
721: --dbms_output.put_line('UPDATE_AGENT_QUEUES: pre select raw_agent_id');
722: select raw_agent_index into l_raw_agent_index from cct_qde_agent
723: where agent_id = p_agent_id;
724: --dbms_output.put_line('UPDATE_AGENT_QUEUES: post select raw_agent_id');
725: --- $$$$
726: -- if sql%notfound then raise AGENT_NOT_FOUND;

Line 818: from cct_qde_agent_queues

814:
815:
816: declare cursor r2 is
817: select agent_queue_id , classification
818: from cct_qde_agent_queues
819: where (item_type = CCT_MEDIA_TYPES_PUB.GET_UWQ_MEDIA_TYPE_ID(p_item_type))
820: and classification is not null
821: and agent_id = p_agent_id ;
822: begin

Line 843: delete from cct_qde_agent_queues

839: if l_found = 'false'
840: then
841: begin
842: --dbms_output.put_line('Deleting classification' || r2_rec.classification);
843: delete from cct_qde_agent_queues
844: where agent_queue_id = r2_rec.agent_queue_id;
845: IF FND_API.To_Boolean( p_commit ) THEN
846: COMMIT WORK;
847: END IF;

Line 923: lock table cct_qde_agent_global_lock in exclusive mode;

919: l_hex_agent_index varchar2(2000);
920: BEGIN
921: --dbms_output.put_line('CREATE_AGENT_INDEX:'
922: --|| ' agent_id = ' || p_agent_id);
923: lock table cct_qde_agent_global_lock in exclusive mode;
924: select max(agent_index) into l_max_agent_index
925: from cct_qde_agent;
926: if (l_max_agent_index is null) then
927: l_max_agent_index := -1;

Line 925: from cct_qde_agent;

921: --dbms_output.put_line('CREATE_AGENT_INDEX:'
922: --|| ' agent_id = ' || p_agent_id);
923: lock table cct_qde_agent_global_lock in exclusive mode;
924: select max(agent_index) into l_max_agent_index
925: from cct_qde_agent;
926: if (l_max_agent_index is null) then
927: l_max_agent_index := -1;
928: end if;
929: x_agent_index := l_max_agent_index + 1;

Line 935: insert into cct_qde_agent

931: l_hex_agent_index := CCT_HEX_UTIL_PUB.dec_to_hex(x_agent_index);
932: --dbms_output.put_line('l_hex_agent_index := '||l_hex_agent_index );
933: x_raw_agent_index := hextoraw(l_hex_agent_index);
934: --dbms_output.put_line('x_raw_agent_index :=' || x_raw_agent_index);
935: insert into cct_qde_agent
936: ( agent_id, agent_index, raw_agent_index,
937: created_by, creation_date,
938: last_updated_by, last_update_date, last_update_login
939: )

Line 998: into x_agent_index, x_raw_agent_index from cct_qde_agent

994: x_msg_count := 0;
995: x_msg_data := null;
996:
997: select agent_index, raw_agent_index
998: into x_agent_index, x_raw_agent_index from cct_qde_agent
999: where agent_id = p_agent_id;
1000: IF FND_API.To_Boolean( p_commit ) THEN
1001: COMMIT WORK;
1002: END IF;