Skip to content

Commit

Permalink
Alphanumeric Column Names.
Browse files Browse the repository at this point in the history
  • Loading branch information
Randall Nagy committed Jun 5, 2024
1 parent cdd2ca7 commit 026b03b
Show file tree
Hide file tree
Showing 8 changed files with 12 additions and 6 deletions.
4 changes: 2 additions & 2 deletions PyDAO_9000.egg-info/PKG-INFO
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Metadata-Version: 2.1
Name: PyDAO_9000
Version: 1.2.8
Name: PyDAO-9000
Version: 1.4.0
Summary: 'All-In-One File' SQL Code Generator
Author-email: Randall Nagy <[email protected]>
Project-URL: Homepage, https://github.com/soft9000/PyDAO
Expand Down
12 changes: 9 additions & 3 deletions SqltDAO/CodeGen01/Normalizers.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,15 @@ def NormCol(name):
if ord(name[0]) == 65279:
name = eval(name[1:])
name = str(name).strip()
for bad in (' ', '\\', '/', ':', ';'):
name = name.replace(bad, '_')
return name
if name[0].isnumeric():
name = 'z' + name
result = ''
for ss in range(len(name)):
if name[ss].isalnum():
result += name[ss]
elif name[ss] == '_':
result += name[ss]
return result.rstrip('_')

@staticmethod
def NormCols(fields):
Expand Down
Binary file removed dist/PyDAO_9000-1.2.8-py3-none-any.whl
Binary file not shown.
Binary file not shown.
Binary file removed dist/pydao_9000-1.2.7.tar.gz
Binary file not shown.
Binary file removed dist/pydao_9000-1.2.8.tar.gz
Binary file not shown.
Binary file added dist/pydao_9000-1.4.0.tar.gz
Binary file not shown.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[project]
name = "PyDAO-9000"
version = "1.3.0"
version = "1.4.0"
authors = [
{ name="Randall Nagy", email="[email protected]" },
]
Expand Down

0 comments on commit 026b03b

Please sign in to comment.