codefori / vscode-db2i

Db2 for IBM i Tools for VS Code
MIT License
46 stars 25 forks source link

DB2 for i : Generate SQL #115

Open HenryMiller opened 1 year ago

HenryMiller commented 1 year ago

Hi, I have a SQL function created via IBM ACS.

I tried to use "generate SQL" from DB2 for I , but the generated code has a space for variable names which include a § character.

Generating SQL from ACS works fine.

image

⚠️ REMOVE THIS LINE AND ANY SENSITIVE INFORMATION BELOW! ⚠️

Context Version
Code for IBM i version 2.1.1
Visual Studio Code version 1.81.1
Operating System darwin_arm64
Active extensions ``` Code Coverage for IBM i (code-coverage-ibmi): 0.1.7 Code Runner (code-runner): 0.12.0 Code for IBM i Walkthroughs (vscode-ibmi-walkthroughs): 0.3.1 Db2 for IBM i (vscode-db2i): 0.4.1 Emmet (emmet): 1.0.0 Extension Authoring (extension-editing): 1.0.0 Git (git): 1.0.0 Git Base (git-base): 1.0.0 GitHub (github): 0.0.1 GitHub Authentication (github-authentication): 0.0.2 GitLens — Git supercharged (gitlens): 14.2.1 IBM i Notebooks (vscode-ibmi-notebooks): 0.0.6 JSON Language Features (json-language-features): 1.0.0 Jira and Bitbucket (Atlassian Labs) (atlascode): 3.0.5 Live Server (LiveServer): 5.7.9 Merge Conflict (merge-conflict): 1.0.0 Microsoft Account (microsoft-authentication): 0.0.1 NPM support for VS Code (npm): 1.0.1 Node Debug Auto-attach (debug-auto-launch): 1.0.0 Overtype (overtype): 0.5.0 RPGLE (vscode-rpgle): 0.21.3 TypeScript and JavaScript Language Features (typescript-language-features): 1.0.0 YAML (vscode-yaml): 1.14.0 ```

Remote system |Setting|Value| |-|-| |IBM i OS|V7R4M0| |Tech Refresh|7| |CCSID|1144| |SQL|Enabled |Source dates|Disabled ### Enabled features |/QOpenSys/pkgs/bin|/usr/bin|/QSYS.lib/ILEDITOR.lib|/QSYS.LIB|/QIBM/ProdData/IBMiDebugService/bin| |-|-|-|-|-| |bash|attr|GENCMDXML.PGM|QZDFMDB2.PGM|startDebugService.sh| |chsh|iconv|GETNEWLIBL.PGM||| |ls|setccsid|||| |md5sum|tar|||| |sort||||| |stat||||| |tn5250|||||
Shell env ```bash BUILDLIB=S CURLIB=S HOME=/home/ LIBLS= LOGIN= LOGNAME= MAIL=/var/spool/mail/ OLDPWD=/home/ PATH=/QOpenSys/usr/bin:/usr/ccs/bin:/QOpenSys/usr/bin/X11:/usr/sbin:.:/usr/bin PWD=/home/ SHELL=/QOpenSys/pkgs/bin/bash SHLVL=1 SSH_CLIENT= SSH_CONNECTION= TZ=-1,M3.5.0,M10.5.0 USER= USERNAME= _=/QOpenSys/usr/bin/env ```
Variants ```json { "american": "#@$", "local": "£§$" } ```
Errors
worksofliam commented 1 year ago

Can we have the original source to try recreate this?

HenryMiller commented 1 year ago

Hi Barry,

I attach it test.txt If you try to generate SQL for the table itself (gmichielin.testtable) , you get the same issue.

Best regards, GM