From 77c5da96d1dbf12500e92f8f26a65145c3a2c3f1 Mon Sep 17 00:00:00 2001 From: Trowbridge Date: Fri, 9 Nov 2018 12:37:19 -0500 Subject: [PATCH 1/6] move user file --- postgres/user.sql | 39 +++++++++++++++++++++++++++++++++++++++ user.sql | 37 ------------------------------------- 2 files changed, 39 insertions(+), 37 deletions(-) create mode 100644 postgres/user.sql delete mode 100644 user.sql diff --git a/postgres/user.sql b/postgres/user.sql new file mode 100644 index 0000000..4576f71 --- /dev/null +++ b/postgres/user.sql @@ -0,0 +1,39 @@ +DROP USER IF EXISTS report; + +SET password_encryption = 'scram-sha-256'; + +CREATE ROLE report WITH + LOGIN + NOSUPERUSER + NOCREATEDB + NOCREATEROLE + INHERIT + NOREPLICATION + CONNECTION LIMIT -1 + PASSWORD 'report'; + +--------------------grant-------------------------------------------------- + +GRANT USAGE ON SCHEMA lgdat TO report; + +GRANT SELECT /*, UPDATE, INSERT, DELETE*/ ON ALL TABLES IN SCHEMA lgdat TO report; + +GRANT USAGE ON ALL SEQUENCES IN SCHEMA lgdat TO report; + +ALTER DEFAULT PRIVILEGES IN SCHEMA lgdat GRANT SELECT/*, UPDATE, INSERT, DELETE*/ ON TABLES TO report; + +ALTER DEFAULT PRIVILEGES IN SCHEMA lgdat GRANT USAGE ON SEQUENCES TO report; + +---------------------------revoke--------------------------------------- + +REVOKE USAGE ON SCHEMA lgdat FROM report; + +REVOKE USAGE ON SCHEMA lgdat FROM report; + +REVOKE SELECT , UPDATE, INSERT, DELETE ON ALL TABLES IN SCHEMA lgdat FROM report; + +REVOKE USAGE ON ALL SEQUENCES IN SCHEMA lgdat FROM report; + +ALTER DEFAULT PRIVILEGES IN SCHEMA lgdat REVOKE SELECT, UPDATE, INSERT, DELETE ON TABLES FROM report; + +ALTER DEFAULT PRIVILEGES IN SCHEMA lgdat REVOKE USAGE ON SEQUENCES FROM report; \ No newline at end of file diff --git a/user.sql b/user.sql deleted file mode 100644 index e43a361..0000000 --- a/user.sql +++ /dev/null @@ -1,37 +0,0 @@ -DROP USER IF EXISTS salesreader; - -CREATE ROLE salesreader WITH - LOGIN - NOSUPERUSER - NOCREATEDB - NOCREATEROLE - INHERIT - NOREPLICATION - CONNECTION LIMIT -1 - ENCRYPTED PASSWORD 'md5b66677418e59ca921c20ff40534685a7'; - ---------------------grant-------------------------------------------------- - -GRANT USAGE ON SCHEMA rlarp TO salesreader; - -GRANT SELECT /*, UPDATE, INSERT, DELETE*/ ON ALL TABLES IN SCHEMA rlarp TO salesreader; - -GRANT USAGE ON ALL SEQUENCES IN SCHEMA rlarp TO salesreader; - -ALTER DEFAULT PRIVILEGES IN SCHEMA rlarp GRANT SELECT/*, UPDATE, INSERT, DELETE*/ ON TABLES TO salesreader; - -ALTER DEFAULT PRIVILEGES IN SCHEMA rlarp GRANT USAGE ON SEQUENCES TO salesreader; - ----------------------------revoke--------------------------------------- - -REVOKE USAGE ON SCHEMA tps FROM salesreader; - -REVOKE USAGE ON SCHEMA rlarp FROM salesreader; - -REVOKE SELECT /*, UPDATE, INSERT, DELETE*/ ON ALL TABLES IN SCHEMA rlarp FROM salesreader; - -REVOKE USAGE ON ALL SEQUENCES IN SCHEMA rlarp FROM salesreader; - -ALTER DEFAULT PRIVILEGES IN SCHEMA rlarp REVOKE SELECT/*, UPDATE, INSERT, DELETE*/ ON TABLES FROM salesreader; - -ALTER DEFAULT PRIVILEGES IN SCHEMA rlarp REVOKE USAGE ON SEQUENCES FROM salesreader; \ No newline at end of file From 4e3fc33354e8b0c421cbc21cbe00311fc5f47572 Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Wed, 14 Nov 2018 08:20:02 -0500 Subject: [PATCH 2/6] strat CMS menu notes --- cms.md | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 cms.md diff --git a/cms.md b/cms.md new file mode 100644 index 0000000..5a06119 --- /dev/null +++ b/cms.md @@ -0,0 +1,3 @@ +PDMN24-1 Production Reporting +IVMN02-4 Maint Part/Plant +IVMN14-7 Costing Sheet \ No newline at end of file From b8351a5fc4e2f7433cd3eed4fbedddbbdde8c28f Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Wed, 14 Nov 2018 11:41:59 -0500 Subject: [PATCH 3/6] sql server error handling approach idea --- sql_server/error_handling.sql | 33 +++++++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 sql_server/error_handling.sql diff --git a/sql_server/error_handling.sql b/sql_server/error_handling.sql new file mode 100644 index 0000000..778cae4 --- /dev/null +++ b/sql_server/error_handling.sql @@ -0,0 +1,33 @@ +CREATE PROC RLARP.TEST AS + +BEGIN + PRINT 'Hi'; --non-erroring statement + create table #temp(x varchar(255)); --create a permanent object to call outside block after error + insert into #temp select 1/0; + insert into #temp select 'hi'; --fill it after error + --select * from #temp; --select it after error + PRINT ERROR_MESSAGE(); --error message is gone + +END; + +begin transaction x +declare @e int; +DECLARE @em varchar(max); +begin try + EXEC RLARP.TEST; +end TRY +begin CATCH + select @e = ERROR_NUMBER(), @em = ERROR_MESSAGE(); + if @e <> 0 + BEGIN + rollback transaction x; + print @em; + END + if @e = 0 + BEGIN + commit transaction x; + print 'ok'; + end +end catch + +SELECT * FROM #temp \ No newline at end of file From 8525992a59ad85be4bb5a10d7f8aff0cde226a60 Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Wed, 21 Nov 2018 08:23:43 -0500 Subject: [PATCH 4/6] lose swap file --- .tmux.md.swp | Bin 12288 -> 0 bytes 1 file changed, 0 insertions(+), 0 deletions(-) delete mode 100644 .tmux.md.swp diff --git a/.tmux.md.swp b/.tmux.md.swp deleted file mode 100644 index 57d60d9761d60c0e8669870a1eaa83e35f6fd04b..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 12288 zcmeI2J!=#}7{{O3C%zRDt1%)dN3!Qd6N@vL#7596oJ~No*`4zSXJ43^%bsbh1ko>H zWn-y+0xSIlehNQ=_}{%fj72a-3IqRvAM^6e^UUyrEtcK=?$bw4)V-Cipj{Ao{r1D| z+QJq2H77E(S_f}Zz22*%$F|L#!OpS4BY`N(LzF}Vubq#Y;?ct*8D}~VKFW)reH60s zWF0AIjo@DaQLWAF^DgEep$+yV7@J-|i- zG(ZD1Km#;D12jMbG(ZD1@LwCK|I=1+2yrq}%RzP3{n;!O%4_dUk*lsW+pI^_8XxKa z*1e=yNOhCk?v>?#HfgtdkqY^V({a$MGI?55sBCo->O)IcWMz=#&z4+Q?Y5JgGA)Qh zwu7^stxkW_xuV)YIfvUHYMEg8!dR=yIM;HBSr$)BhESB5yctYG{Xw}A^&jhDsIz@# z0%X-mUY6>G(wflB)xNexB{%+FbmsXeoaDySlCrlQtm|y;sTd*-4CHu~6j>JMslp%j V?xnh!#MbImg^`9PJv5VB@*DX~wx<99 From 8748ef264cf74a4b44b02d171209fc0529e3ef26 Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Wed, 21 Nov 2018 09:06:09 -0500 Subject: [PATCH 5/6] cms menus --- cms.md | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cms.md b/cms.md index 5a06119..d90f1d4 100644 --- a/cms.md +++ b/cms.md @@ -1,3 +1,5 @@ -PDMN24-1 Production Reporting +PDMN24-1 Maintain Product Structure IVMN02-4 Maint Part/Plant -IVMN14-7 Costing Sheet \ No newline at end of file +IVMN14-7 Costing Sheet +PDMN31-1 WO Production Reporting +PDMN06 Maintain WO \ No newline at end of file From c1a40198c47c0e7f65a93bb4227e7664fa9378b1 Mon Sep 17 00:00:00 2001 From: Paul Trowbridge Date: Wed, 28 Nov 2018 09:03:33 -0500 Subject: [PATCH 6/6] list of default things to install --- install_list.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 install_list.md diff --git a/install_list.md b/install_list.md new file mode 100644 index 0000000..b67b3af --- /dev/null +++ b/install_list.md @@ -0,0 +1,18 @@ +dbeaver +vs code +bash +vundle + +npgsql +pspg +postgresql apt repo +pgadmin +windows postgres + +nodejs + + +power bi +ms data gateway +excel add-in +