DE-Lib 0.0.36.2__py3-none-any.whl → 0.0.37__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- DE_Lib/DataBase/MsSql.py +2 -2
- DE_Lib/DataBase/OracleDDL.py +1 -1
- DE_Lib/Utils/Generic.py +18 -0
- {de_lib-0.0.36.2.dist-info → de_lib-0.0.37.dist-info}/METADATA +1 -1
- {de_lib-0.0.36.2.dist-info → de_lib-0.0.37.dist-info}/RECORD +8 -8
- {de_lib-0.0.36.2.dist-info → de_lib-0.0.37.dist-info}/WHEEL +1 -1
- {de_lib-0.0.36.2.dist-info → de_lib-0.0.37.dist-info}/licenses/LICENCE +0 -0
- {de_lib-0.0.36.2.dist-info → de_lib-0.0.37.dist-info}/top_level.txt +0 -0
DE_Lib/DataBase/MsSql.py
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
import pymssql as mssql
|
1
|
+
import pymssql as mssql ## biblioteca suportada ate a versao 3.9 ou 3.10 do python
|
2
2
|
|
3
3
|
from DE_Lib.Utils import Generic
|
4
4
|
|
@@ -15,7 +15,7 @@ class MSSQL:
|
|
15
15
|
msg, conn = None, None
|
16
16
|
try:
|
17
17
|
# Efetuando a conexao com a instancia do BANCO
|
18
|
-
|
18
|
+
result = mssql.connect(user=string_connect["username"], password=string_connect["password"], database=string_connect["instance"], server=string_connect["host"])
|
19
19
|
self._connection_is_valid = True
|
20
20
|
self._cnn = result
|
21
21
|
self.__database_error = f"""{json.dumps(string_connect, indent=4).replace(string_connect["password"], "******")}\nConexao bem sucedida!"""
|
DE_Lib/DataBase/OracleDDL.py
CHANGED
DE_Lib/Utils/Generic.py
CHANGED
@@ -5,6 +5,9 @@ import random as rd
|
|
5
5
|
import re
|
6
6
|
import datetime as dt
|
7
7
|
import sys
|
8
|
+
import os
|
9
|
+
|
10
|
+
from docutils.io import error_string
|
8
11
|
|
9
12
|
|
10
13
|
class GENERIC:
|
@@ -263,6 +266,21 @@ class GENERIC:
|
|
263
266
|
result = False
|
264
267
|
finally:
|
265
268
|
return result
|
269
|
+
|
270
|
+
@staticmethod
|
271
|
+
def get_file(filename: str, encoding: str = "utf-8"):
|
272
|
+
msg, result = None, None
|
273
|
+
try:
|
274
|
+
if os.path.exists(filename):
|
275
|
+
fh = open(filename, 'r', encoding=encoding)
|
276
|
+
result = fh.read()
|
277
|
+
except Exception as error:
|
278
|
+
msg = error
|
279
|
+
result = msg
|
280
|
+
finally:
|
281
|
+
return result
|
282
|
+
|
283
|
+
|
266
284
|
# endregion
|
267
285
|
|
268
286
|
|
@@ -5,10 +5,10 @@ DE_Lib/DataBase/Cache.py,sha256=IpTJCVCrtm8Et4U-_AaWoT_2vf7mBqdzYrWDXbpOORE,3171
|
|
5
5
|
DE_Lib/DataBase/Firebird.py,sha256=dXjt3ImVtdiW99NAHcDIzZhGHF_YIyn4RJbM2QR4g7s,1898
|
6
6
|
DE_Lib/DataBase/Informix.py,sha256=jXqPggYu8PjGrqtxMHwlCsqF5rK03olas5yVMH0Ndkw,1559
|
7
7
|
DE_Lib/DataBase/Metadata.py,sha256=j0iJm26Sf0QvsYpN61hfwkllyW2EOA2XoFnSzEo9plE,3274
|
8
|
-
DE_Lib/DataBase/MsSql.py,sha256=
|
8
|
+
DE_Lib/DataBase/MsSql.py,sha256=8_qk1iqdckg0uNgZ1CKvvr7md7tXb844KmUrE-gmKRM,1701
|
9
9
|
DE_Lib/DataBase/MySql.py,sha256=SWLJMaB30EBqaz32xwMBbc3lnemDPpF2kkkf5umlL3k,2534
|
10
10
|
DE_Lib/DataBase/Oracle.py,sha256=n9ub6J6zNX4z62pUWjut3PGxXzLDZQ9jVhZ6eGzFPEw,9704
|
11
|
-
DE_Lib/DataBase/OracleDDL.py,sha256=
|
11
|
+
DE_Lib/DataBase/OracleDDL.py,sha256=8PDTjR52Igtj-FyPQvFUBRjTlXB7crMNB8Xh5LncB_Q,3785
|
12
12
|
DE_Lib/DataBase/Postgres.py,sha256=lMb6sFGvjjuuq4D4k7zzEo7-NtyrC79VITeKQfoDO6U,1667
|
13
13
|
DE_Lib/DataBase/RedShift.py,sha256=ewPi8hxEhfuekBpMl-P1LWgSGfbqPKRpXfjtduCwOKc,1736
|
14
14
|
DE_Lib/DataBase/SQCipher.py,sha256=Bw7nq4tQdhM7ux0INF9PUymsIIjBEwMKcA1Un8orCE8,1625
|
@@ -28,7 +28,7 @@ DE_Lib/Log/Log.py,sha256=NyraX9ZpM7XJN4S4o5nYaFdOTH35EAFP9w7GaTFrflk,18839
|
|
28
28
|
DE_Lib/Log/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
29
29
|
DE_Lib/Utils/Colors.py,sha256=REjcEK2QuhAo7RzRtHtib8EDMf-12TIsZDGJUCfuaTY,5984
|
30
30
|
DE_Lib/Utils/DateUtils.py,sha256=Xl4PIxj66nqj11WAKEzPAc_SGtVzheg97D--jdJEAjc,7818
|
31
|
-
DE_Lib/Utils/Generic.py,sha256=
|
31
|
+
DE_Lib/Utils/Generic.py,sha256=pdrZOfmOEhzUcSnSS9rY6a4-N7jwXbp-tgF6wmIDQ3Q,9633
|
32
32
|
DE_Lib/Utils/Sql.py,sha256=KOEfISWTF4MCydFXlO4z5z-gigU63yH-3eNXK_ss7JI,2646
|
33
33
|
DE_Lib/Utils/System.py,sha256=0ICuCbN9ElNKL6XOd8mtwdiaooN5SRnMwKkMnTd5m_0,3405
|
34
34
|
DE_Lib/Utils/WebHook.py,sha256=dHGP-20z4Q1_FapitEFBiiMlA8fIFlgf9QT4c5pnWfQ,713
|
@@ -42,8 +42,8 @@ DE_Lib/Utils/Cipher/Gcm.py,sha256=fOuCVOyd4sGv389E91yqomujKTtFZu6CyhySrmQKVfY,23
|
|
42
42
|
DE_Lib/Utils/Cipher/Pbkdf2.py,sha256=hRkgf0Fo5hV1gLbWlFGFzhYYUjPEqgpB2R-pPw7N2F8,1210
|
43
43
|
DE_Lib/Utils/Cipher/Rsa.py,sha256=MYG1YsGuq-Q-MoF6pmeMD0TyxMTwt6tuUaLvXcmzQ2k,4126
|
44
44
|
DE_Lib/Utils/Cipher/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
45
|
-
de_lib-0.0.
|
46
|
-
de_lib-0.0.
|
47
|
-
de_lib-0.0.
|
48
|
-
de_lib-0.0.
|
49
|
-
de_lib-0.0.
|
45
|
+
de_lib-0.0.37.dist-info/licenses/LICENCE,sha256=Qv2ilebwoUtMJnRsZwRy729xS5JZQzLauJ0tQzkAkTA,1088
|
46
|
+
de_lib-0.0.37.dist-info/METADATA,sha256=yT178aCbFf2pKrWkUnqKzRoJ8a_MwuJpbvjVpCxYIIA,2287
|
47
|
+
de_lib-0.0.37.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
48
|
+
de_lib-0.0.37.dist-info/top_level.txt,sha256=yI9fdM_jkhCz_sykPZQbfeUbQ1FRMt-xjv9fJ6YZVLE,7
|
49
|
+
de_lib-0.0.37.dist-info/RECORD,,
|
File without changes
|
File without changes
|