保存进度!
This commit is contained in:
		
							
								
								
									
										23
									
								
								code/db/pkg/Telsaler_twr_pkg.pck
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										23
									
								
								code/db/pkg/Telsaler_twr_pkg.pck
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,23 @@
 | 
			
		||||
create or replace package Telsaler_twr_pkg is
 | 
			
		||||
 | 
			
		||||
  -- Author  : KANE
 | 
			
		||||
  -- Created : 2023/11/26 18:19:22
 | 
			
		||||
  -- Purpose : TWRϵͳ<CFB5><CDB3><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ص<EFBFBD>pkg
 | 
			
		||||
  
 | 
			
		||||
  procedure <20><><EFBFBD><EFBFBD>TWR<57><52><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϯԱ<CFAF><D4B1><EFBFBD><EFBFBD>;
 | 
			
		||||
 | 
			
		||||
end Telsaler_twr_pkg;
 | 
			
		||||
/
 | 
			
		||||
create or replace package body Telsaler_twr_pkg is
 | 
			
		||||
 | 
			
		||||
  procedure <20><><EFBFBD><EFBFBD>TWR<57><52><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϯԱ<CFAF><D4B1><EFBFBD><EFBFBD>
 | 
			
		||||
  is
 | 
			
		||||
  begin
 | 
			
		||||
    execute immediate 'truncate table twr_telsaler';
 | 
			
		||||
  end;
 | 
			
		||||
 | 
			
		||||
begin
 | 
			
		||||
  -- Initialization
 | 
			
		||||
  null;
 | 
			
		||||
end Telsaler_twr_pkg;
 | 
			
		||||
/
 | 
			
		||||
@@ -154,20 +154,26 @@ CREATE OR REPLACE PACKAGE BODY TELSALE_ARCHIEVEMENT_PKG IS
 | 
			
		||||
    BEGIN
 | 
			
		||||
        --<2D><>ѯ<EFBFBD><D1AF>ϯ<EFBFBD><CFAF><EFBFBD>ƣ<EFBFBD><C6A3>Ͳ<EFBFBD><CDB2><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƣ<EFBFBD><C6A3><EFBFBD>֤<EFBFBD><D6A4><EFBFBD><EFBFBD>
 | 
			
		||||
        BEGIN
 | 
			
		||||
            SELECT zx.saler_name,
 | 
			
		||||
            /*SELECT zx.saler_name,
 | 
			
		||||
                  bm.department_name
 | 
			
		||||
             INTO l_caller_name,
 | 
			
		||||
                  l_department_name
 | 
			
		||||
             FROM tele_saler      zx,
 | 
			
		||||
                  tele_saler_team team,
 | 
			
		||||
                  idst0.bm_t      bm
 | 
			
		||||
            WHERE zx.saler_code = a_caller_code
 | 
			
		||||
              AND zx.team_code = team.team_code
 | 
			
		||||
              AND team.department_code = bm.department_code;*/
 | 
			
		||||
            SELECT ry.<2E><>Ա<EFBFBD><D4B1><EFBFBD><EFBFBD>,
 | 
			
		||||
                   bm.department_name
 | 
			
		||||
              INTO l_caller_name,
 | 
			
		||||
                   l_department_name
 | 
			
		||||
              FROM tele_saler      zx,
 | 
			
		||||
                   tele_saler_team team,
 | 
			
		||||
                   idst0.bm_t      bm
 | 
			
		||||
             WHERE zx.saler_code = a_caller_code
 | 
			
		||||
               AND zx.team_code = team.team_code
 | 
			
		||||
               AND team.department_code = bm.department_code;
 | 
			
		||||
            /* SELECT saler_name
 | 
			
		||||
             INTO l_caller_name
 | 
			
		||||
             FROM tele_saler
 | 
			
		||||
            WHERE saler_code = a_caller_code;*/
 | 
			
		||||
              FROM twr_telsaler      ry,
 | 
			
		||||
                   twr_telsaler_team team,
 | 
			
		||||
                   idst0.bm_t        bm
 | 
			
		||||
             WHERE ry.<2E>Ŷ<EFBFBD><C5B6><EFBFBD><EFBFBD><EFBFBD> = team.team_name
 | 
			
		||||
               AND team.department_code = bm.department_code
 | 
			
		||||
               AND ry.<2E><>Ա<EFBFBD><D4B1><EFBFBD><EFBFBD> = a_caller_code;
 | 
			
		||||
        EXCEPTION
 | 
			
		||||
            -- <20><><EFBFBD><EFBFBD>û<EFBFBD>в<EFBFBD>ѯ<EFBFBD><D1AF><EFBFBD><EFBFBD>ϯ<EFBFBD><CFAF><EFBFBD>ƣ<EFBFBD>˵<EFBFBD><CBB5><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>׳<EFBFBD><D7B3>쳣
 | 
			
		||||
            WHEN no_data_found THEN
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										17
									
								
								code/db/twr_常用.sql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										17
									
								
								code/db/twr_常用.sql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,17 @@
 | 
			
		||||
select *
 | 
			
		||||
from twr_telsaler_team;
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
SELECT ry.<EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,
 | 
			
		||||
       ry.<EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD><EFBFBD>,
 | 
			
		||||
       team.team_code,
 | 
			
		||||
       team.team_name,
 | 
			
		||||
       bm.department_code,
 | 
			
		||||
       bm.department_name
 | 
			
		||||
  FROM twr_telsaler      ry,
 | 
			
		||||
       twr_telsaler_team team,
 | 
			
		||||
       idst0.bm_t        bm
 | 
			
		||||
 WHERE ry.<EFBFBD>Ŷ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> = team.team_name
 | 
			
		||||
   AND team.department_code = bm.department_code
 | 
			
		||||
   AND (ry.<EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD><EFBFBD> = '<EFBFBD><EFBFBD>С<EFBFBD><EFBFBD>' OR ry.<EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD><EFBFBD> = '<EFBFBD><EFBFBD>С<EFBFBD><EFBFBD>');
 | 
			
		||||
@@ -1,5 +1,5 @@
 | 
			
		||||
drop table telsaler;
 | 
			
		||||
create table telsaler
 | 
			
		||||
drop table twr_telsaler;
 | 
			
		||||
create table twr_telsaler
 | 
			
		||||
(
 | 
			
		||||
       <EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD><EFBFBD> varchar2(40),
 | 
			
		||||
<EFBFBD><EFBFBD>Ա<EFBFBD><EFBFBD><EFBFBD><EFBFBD>  varchar2(40),
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										7
									
								
								code/db/建表/TWr坐席团队.sql
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										7
									
								
								code/db/建表/TWr坐席团队.sql
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,7 @@
 | 
			
		||||
drop table twr_telsaler_team;
 | 
			
		||||
create table twr_telsaler_team
 | 
			
		||||
(
 | 
			
		||||
       team_name varchar2(40) not null,
 | 
			
		||||
       team_code varchar2(20),
 | 
			
		||||
       department_code varchar2(6) not null
 | 
			
		||||
);
 | 
			
		||||
		Reference in New Issue
	
	Block a user