mySQLDBCtrlAPI 0.1.1__py3-none-any.whl → 1.2510.22__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.

Potentially problematic release.


This version of mySQLDBCtrlAPI might be problematic. Click here for more details.

@@ -0,0 +1,4 @@
1
+ from .mySQLDBCtrl import CLASS_MailSender
2
+
3
+ __all__ = ["CLASS_mySQLDBCtrl"
4
+ ]
@@ -136,6 +136,22 @@ class CLASS_mySQLDBCtrl:
136
136
  # 傳回: obj_Query
137
137
  # ----------------------------------------------------------------------
138
138
  def CUF_DB_OpenSQL(self, Pobj_Connection, Pms_SQL):
139
+ Pobj_Connection.commit();
140
+ # ------------------------------------------------------------
141
+ obj_Query = Pobj_Connection.cursor();
142
+ # ------------------------------------------------------------
143
+ obj_Query.execute(self.CUF_str_big5(Pms_SQL));
144
+ # ------------------------------------------------------------
145
+ Pobj_Connection.commit();
146
+ # ------------------------------------------------------------
147
+ self.CVmi_qryRECCNT = self.CUF_DB_RecordCount(obj_Query);
148
+ # ------------------------------------------------------------
149
+ if(self.CVmi_qryRECCNT > 0):
150
+ self.CUF_DB_Next(obj_Query);
151
+ # ------------------------------------------------------------
152
+ return(obj_Query);
153
+ # ----------------------------------------------------------------------
154
+ def CUF_DB_OpenSQL_utf8(self, Pobj_Connection, Pms_SQL):
139
155
  Pobj_Connection.commit();
140
156
  # ------------------------------------------------------------
141
157
  obj_Query = Pobj_Connection.cursor();
@@ -146,6 +162,9 @@ class CLASS_mySQLDBCtrl:
146
162
  # ------------------------------------------------------------
147
163
  self.CVmi_qryRECCNT = self.CUF_DB_RecordCount(obj_Query);
148
164
  # ------------------------------------------------------------
165
+ if(self.CVmi_qryRECCNT > 0):
166
+ self.CUF_DB_Next(obj_Query);
167
+ # ------------------------------------------------------------
149
168
  return(obj_Query);
150
169
 
151
170
 
@@ -158,6 +177,9 @@ class CLASS_mySQLDBCtrl:
158
177
  self.CVmi_qryRECCNT = self.CVmi_qryRECCNT - 1;
159
178
  # ------------------------------------------------------------
160
179
  return(Pobj_Query.fetchone());
180
+ # ----------------------------------------------------------------------
181
+ def CUF_DB_Next(self, Pobj_Query):
182
+ self.CUF_DB_FETCH(Pobj_Query);
161
183
 
162
184
 
163
185
  # ----------------------------------------------------------------------
@@ -166,6 +188,15 @@ class CLASS_mySQLDBCtrl:
166
188
  # 傳回: obj_Field
167
189
  # ----------------------------------------------------------------------
168
190
  def CUF_DB_ExecSQL(self, Pobj_Connection, Pms_SQL):
191
+ obj_Query = Pobj_Connection.cursor();
192
+ # ------------------------------------------------------------
193
+ obj_Query.execute(self.CUF_str_big5(Pms_SQL));
194
+ # ------------------------------------------------------------
195
+ Pobj_Connection.commit();
196
+ # ------------------------------------------------------------
197
+ return(obj_Query);
198
+ # ----------------------------------------------------------------------
199
+ def CUF_DB_ExecSQL_utf8(self, Pobj_Connection, Pms_SQL):
169
200
  obj_Query = Pobj_Connection.cursor();
170
201
  # ------------------------------------------------------------
171
202
  obj_Query.execute(Pms_SQL);
@@ -211,6 +242,25 @@ class CLASS_mySQLDBCtrl:
211
242
  return(self.CUF_DB_Eof(Pobj_Query));
212
243
 
213
244
 
245
+ # ----------------------------------------------------------------------
246
+ # 功能: 轉換字串編碼 (big5 -> utf-8)
247
+ # 傳入:
248
+ # 傳回: true: Eof
249
+ # Robj_DataSet: 資料集
250
+ # ----------------------------------------------------------------------
251
+ def CUF_str_utf8(self, Pobj_DataSet):
252
+ return(str(Pobj_DataSet).encode("latin1").decode("big5"));
253
+
254
+ # ----------------------------------------------------------------------
255
+ # 功能: 轉換字串編碼 (utf-8 -> big5)
256
+ # 傳入:
257
+ # 傳回: true: Eof
258
+ # Robj_DataSet: 資料集
259
+ # ----------------------------------------------------------------------
260
+ def CUF_str_big5(self, Pobj_DataSet):
261
+ return(str(Pobj_DataSet).encode("big5").decode("latin1"));
262
+
263
+
214
264
  # ----------------------------------------------------------------------
215
265
  # 功能: 讀取 BLOB Field
216
266
  # 傳入:
@@ -0,0 +1,46 @@
1
+ Metadata-Version: 2.4
2
+ Name: mySQLDBCtrlAPI
3
+ Version: 1.2510.22
4
+ Summary: mySQLDBCtrlAPI Python package
5
+ Author-email: James Lin <tylin123@ms27.hinet.net>
6
+ License: Copyright (c) 2025 James Lin
7
+
8
+ All rights reserved.
9
+
10
+ Permission is granted for **personal, educational, or non-commercial use only**.
11
+ You **may NOT**:
12
+
13
+ 1. Sell or otherwise commercially exploit this software or any part of it.
14
+ 2. Reproduce, distribute, or sublicense this software for commercial purposes.
15
+ 3. Modify or create derivative works for commercial purposes without explicit written permission from the copyright holder.
16
+
17
+ You **may**:
18
+
19
+ - Use the software for personal learning, research, or internal company evaluation (non-commercial).
20
+ - Share the software with attribution to the original author, as long as it is not for commercial gain.
21
+
22
+ **Disclaimer:**
23
+ This software is provided "AS IS", without any warranty of any kind, either expressed or implied,
24
+ including but not limited to the warranties of merchantability, fitness for a particular purpose, or non-infringement.
25
+ In no event shall the author be liable for any claim, damages, or other liability arising from, out of, or in connection with the software or its use.
26
+
27
+ Project-URL: Homepage, https://mis.gotech.biz
28
+ Description-Content-Type: text/markdown
29
+ License-File: LICENSE
30
+ Requires-Dist: pymysql
31
+ Dynamic: license-file
32
+
33
+ #mySQLDBCtrlAPI
34
+
35
+ ## History of version
36
+ Version 1.2510.22: 2025/10/22<BR>
37
+ 1.Add string decode method (translage utf8 charset -> utf-8)
38
+ 2.Add Eof() procedure
39
+ 3.Fixed CUF_DB_ExecSQL() and CUF_DB_OpenSQL() bugs.
40
+
41
+
42
+ Version 0.1.2: 2025/10/09<BR>
43
+ Add string decode method (translage big5 charset -> utf-8)
44
+
45
+ Version 0.1.1: 2025/09/19<BR>
46
+ Fixed some bugs.
@@ -0,0 +1,7 @@
1
+ mySQLDBCtrlAPI/__init__.py,sha256=Bxl2jLU8CE2sp59PnCB9LMyOVBlP6dLNf43xKQbRhMM,100
2
+ mySQLDBCtrlAPI/mySQLDBCtrl.py,sha256=eK9HYIVq22c5lYn8iQ-aGBGjop0d1Atg_ZcCo_MpffQ,22288
3
+ mysqldbctrlapi-1.2510.22.dist-info/licenses/LICENSE,sha256=bTN6shImvjBn0VScA1LIqy7LH3B_O6XZieGPnoT4Gxk,1054
4
+ mysqldbctrlapi-1.2510.22.dist-info/METADATA,sha256=eIE7adMLs2stfOhJ3KT-nrdjRPsPNtgzNmSLBuJnNs0,1903
5
+ mysqldbctrlapi-1.2510.22.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
6
+ mysqldbctrlapi-1.2510.22.dist-info/top_level.txt,sha256=onworg8ic7UQRjmAT-NpGAJFJb4X9hU1rOlYUCD_gng,15
7
+ mysqldbctrlapi-1.2510.22.dist-info/RECORD,,
@@ -0,0 +1,20 @@
1
+ Copyright (c) 2025 James Lin
2
+
3
+ All rights reserved.
4
+
5
+ Permission is granted for **personal, educational, or non-commercial use only**.
6
+ You **may NOT**:
7
+
8
+ 1. Sell or otherwise commercially exploit this software or any part of it.
9
+ 2. Reproduce, distribute, or sublicense this software for commercial purposes.
10
+ 3. Modify or create derivative works for commercial purposes without explicit written permission from the copyright holder.
11
+
12
+ You **may**:
13
+
14
+ - Use the software for personal learning, research, or internal company evaluation (non-commercial).
15
+ - Share the software with attribution to the original author, as long as it is not for commercial gain.
16
+
17
+ **Disclaimer:**
18
+ This software is provided "AS IS", without any warranty of any kind, either expressed or implied,
19
+ including but not limited to the warranties of merchantability, fitness for a particular purpose, or non-infringement.
20
+ In no event shall the author be liable for any claim, damages, or other liability arising from, out of, or in connection with the software or its use.
@@ -1,14 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: mySQLDBCtrlAPI
3
- Version: 0.1.1
4
- Summary: mySQLDBCtrlAPI Python package
5
- Author-email: James Lin <tylin123@ms27.hinet.net>
6
- Project-URL: Homepage, https://mis.gotech.biz
7
- Description-Content-Type: text/markdown
8
- Requires-Dist: pymysql
9
-
10
- #mySQLDBCtrlAPI
11
-
12
- ## History of version
13
- Version 0.1.1: 2025/09/19<BR>
14
- Fixed some bugs.
@@ -1,6 +0,0 @@
1
- mySQLDBCtrlAPI/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
- mySQLDBCtrlAPI/mySQLDBCtrl.py,sha256=Ol-mVh3aqFDtsJ1AgUxKNQZyaHeeuTpYtceHVf7LueQ,19792
3
- mysqldbctrlapi-0.1.1.dist-info/METADATA,sha256=gDvbLf0yhcga8_K7y62g34STumNPXxqbVbbA4xyvLkc,357
4
- mysqldbctrlapi-0.1.1.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
5
- mysqldbctrlapi-0.1.1.dist-info/top_level.txt,sha256=onworg8ic7UQRjmAT-NpGAJFJb4X9hU1rOlYUCD_gng,15
6
- mysqldbctrlapi-0.1.1.dist-info/RECORD,,