Commit f8c5460f392f8a3f0534c9872ebf035ce2c0040b
1 parent
d17af4b1
Exists in
main
Adiciondo job para atualizar automaticamente dados do sistema comercial. Colocad…
…o para não mostrar erro para o usuário quando a divisão da cota do no der zero
Showing
4 changed files
with
70 additions
and
3 deletions
Show diff stats
db/SqlServer/jobs/jobAtualizaTabelasSistemaComercial.sql
0 → 100644
@@ -0,0 +1,67 @@ | @@ -0,0 +1,67 @@ | ||
1 | +USE [msdb] | ||
2 | +GO | ||
3 | + | ||
4 | +/****** Object: Job [jobAtualizaTabelasSistemaComercial] Script Date: 02/24/2022 23:51:46 ******/ | ||
5 | +BEGIN TRANSACTION | ||
6 | +DECLARE @ReturnCode INT | ||
7 | +SELECT @ReturnCode = 0 | ||
8 | +/****** Object: JobCategory [[Uncategorized (Local)]]] Script Date: 02/24/2022 23:51:46 ******/ | ||
9 | +IF NOT EXISTS (SELECT name FROM msdb.dbo.syscategories WHERE name=N'[Uncategorized (Local)]' AND category_class=1) | ||
10 | +BEGIN | ||
11 | +EXEC @ReturnCode = msdb.dbo.sp_add_category @class=N'JOB', @type=N'LOCAL', @name=N'[Uncategorized (Local)]' | ||
12 | +IF (@@ERROR <> 0 OR @ReturnCode <> 0) GOTO QuitWithRollback | ||
13 | + | ||
14 | +END | ||
15 | + | ||
16 | +DECLARE @jobId BINARY(16) | ||
17 | +EXEC @ReturnCode = msdb.dbo.sp_add_job @job_name=N'jobAtualizaTabelasSistemaComercial', | ||
18 | + @enabled=1, | ||
19 | + @notify_level_eventlog=0, | ||
20 | + @notify_level_email=0, | ||
21 | + @notify_level_netsend=0, | ||
22 | + @notify_level_page=0, | ||
23 | + @delete_level=0, | ||
24 | + @description=N'No description available.', | ||
25 | + @category_name=N'[Uncategorized (Local)]', | ||
26 | + @owner_login_name=N'sa', @job_id = @jobId OUTPUT | ||
27 | +IF (@@ERROR <> 0 OR @ReturnCode <> 0) GOTO QuitWithRollback | ||
28 | +/****** Object: Step [atualizarTodasTabelas] Script Date: 02/24/2022 23:51:46 ******/ | ||
29 | +EXEC @ReturnCode = msdb.dbo.sp_add_jobstep @job_id=@jobId, @step_name=N'atualizarTodasTabelas', | ||
30 | + @step_id=1, | ||
31 | + @cmdexec_success_code=0, | ||
32 | + @on_success_action=1, | ||
33 | + @on_success_step_id=0, | ||
34 | + @on_fail_action=2, | ||
35 | + @on_fail_step_id=0, | ||
36 | + @retry_attempts=0, | ||
37 | + @retry_interval=0, | ||
38 | + @os_run_priority=0, @subsystem=N'TSQL', | ||
39 | + @command=N'exec dbo.atualizaTabelasSistemaComercial', | ||
40 | + @database_name=N'geosan', | ||
41 | + @flags=0 | ||
42 | +IF (@@ERROR <> 0 OR @ReturnCode <> 0) GOTO QuitWithRollback | ||
43 | +EXEC @ReturnCode = msdb.dbo.sp_update_job @job_id = @jobId, @start_step_id = 1 | ||
44 | +IF (@@ERROR <> 0 OR @ReturnCode <> 0) GOTO QuitWithRollback | ||
45 | +EXEC @ReturnCode = msdb.dbo.sp_add_jobschedule @job_id=@jobId, @name=N'Final expediente', | ||
46 | + @enabled=1, | ||
47 | + @freq_type=8, | ||
48 | + @freq_interval=62, | ||
49 | + @freq_subday_type=1, | ||
50 | + @freq_subday_interval=0, | ||
51 | + @freq_relative_interval=0, | ||
52 | + @freq_recurrence_factor=1, | ||
53 | + @active_start_date=20220225, | ||
54 | + @active_end_date=99991231, | ||
55 | + @active_start_time=10000, | ||
56 | + @active_end_time=235959, | ||
57 | + @schedule_uid=N'2cf5b330-de94-4dbc-9071-e23bbccc9bd7' | ||
58 | +IF (@@ERROR <> 0 OR @ReturnCode <> 0) GOTO QuitWithRollback | ||
59 | +EXEC @ReturnCode = msdb.dbo.sp_add_jobserver @job_id = @jobId, @server_name = N'(local)' | ||
60 | +IF (@@ERROR <> 0 OR @ReturnCode <> 0) GOTO QuitWithRollback | ||
61 | +COMMIT TRANSACTION | ||
62 | +GOTO EndSave | ||
63 | +QuitWithRollback: | ||
64 | + IF (@@TRANCOUNT > 0) ROLLBACK TRANSACTION | ||
65 | +EndSave: | ||
66 | + | ||
67 | +GO | ||
0 | \ No newline at end of file | 68 | \ No newline at end of file |
install/GeraSetupGeoSan/Codigo Gerador Instalador Geosan com TerraComponents.iss
trunk/Modules/Global.bas
@@ -201,7 +201,7 @@ Public Sub Main() | @@ -201,7 +201,7 @@ Public Sub Main() | ||
201 | End If | 201 | End If |
202 | 'Configura a versão atual do GeoSan | 202 | 'Configura a versão atual do GeoSan |
203 | Versao_Geo = App.Major & "." & App.Minor & "." & App.Revision | 203 | Versao_Geo = App.Major & "." & App.Minor & "." & App.Revision |
204 | - Versao_Geo = "08.02.00" | 204 | + Versao_Geo = "08.02.01" |
205 | glo.diretorioGeoSan = App.path 'salva globalmente o caminho onde encontra-se o GeoSan.exe | 205 | glo.diretorioGeoSan = App.path 'salva globalmente o caminho onde encontra-se o GeoSan.exe |
206 | SaveLoadGlobalData glo.diretorioGeoSan + "/controles/variaveisGlobais.txt", True 'salva em um arquivo todas as variáveis globais para poderem ser acessadas por outras aplicações | 206 | SaveLoadGlobalData glo.diretorioGeoSan + "/controles/variaveisGlobais.txt", True 'salva em um arquivo todas as variáveis globais para poderem ser acessadas por outras aplicações |
207 | connn = "" | 207 | connn = "" |
trunk/classes/CIntBilinear.cls
@@ -50,7 +50,7 @@ Trata_Erro: | @@ -50,7 +50,7 @@ Trata_Erro: | ||
50 | If Err.Number = 0 Or Err.Number = 20 Then | 50 | If Err.Number = 0 Or Err.Number = 20 Then |
51 | Resume Next | 51 | Resume Next |
52 | Else | 52 | Else |
53 | - ErroUsuario.Registra "CIntBilinear", "CalcInterpolacao - divisão por zero no MDT", CStr(Err.Number), CStr(Err.Description), True, glo.enviaEmails | 53 | + ErroUsuario.Registra "CIntBilinear", "CalcInterpolacao - divisão por zero no MDT", CStr(Err.Number), CStr(Err.Description), False, glo.enviaEmails |
54 | End If | 54 | End If |
55 | End Function | 55 | End Function |
56 | 56 |