Project

General

Profile

Feature #2683

Updated by Muhammad Bintar 8 months ago

dear tim developer mohon support nya untuk pembuatan query untuk generate personal working schedule. 

 ini contoh dari asuransi bintang 

 DECLARE @toinsertmd125 TABLE 
         ( 
		  [landscape] VARCHAR(20) 
            ,[emp_id] VARCHAR(20) 
            ,[start_date] VARCHAR(20) 
            ,[end_date] VARCHAR(20) 
            ,[day_type] VARCHAR(20) 
            ,[ph_id] VARCHAR(20) 
            ,[user_change] VARCHAR(50) 
            ,[last_change] VARCHAR(50) 
            ,[created_by] VARCHAR(50) 
            ,[created_date] VARCHAR(50) 
         ) 
	 insert into @toinsertmd125 
 select md25.landscape, md25.emp_id, cal.datespecified, cal.datespecified,cal.day_type,cal.ph_id, 'system' ,    FORMAT(getdate(),'yyyyMMddHHmmss'), 'system',FORMAT(getdate(),'yyyyMMddHHmmss') from hr_md_emp_md0025 md25 
 left join hr_tm_workschedule_calender cal on md25.ws_type = cal.workschedule_type  
               and cal.year= '2024' 
 where md25.ws_type = 'OVT' and md25.start_date = '20240101' 
 --SELECT * FROM @toinsertmd125 
 INSERT INTO    dbo.hr_md_emp_md0125  
 SELECT DISTINCT    landscape,[emp_id],[start_date],[end_date],[day_type],[ph_id],[user_change],[last_change],[created_by],[created_date] FROM @toinsertmd125 



 remote.minovais.com:61120 
 database sql server 
 remote.minovais.com, 1445 1452 

Back