Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mysql查询支持将Binary格式转换为HEX展示 #1839

Merged
merged 2 commits into from
Sep 19, 2022

Conversation

hhyo
Copy link
Owner

@hhyo hhyo commented Sep 17, 2022

关联issue: #1766 #1772

查询时可以指定传入参数:binary_as_hex,会将binary数据转换成16进制文本

并没有在数据查询中默认开启,因为有些文本的二进制数据在转换前是可以直接输出文本内容,强制转换后会全部都变成16进制,建议按需自己调整

参考:

@codecov
Copy link

codecov bot commented Sep 17, 2022

Codecov Report

Base: 76.08% // Head: 76.00% // Decreases project coverage by -0.07% ⚠️

Coverage data is based on head (adca1de) compared to base (8cdb232).
Patch coverage: 31.57% of modified lines in pull request are covered.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1839      +/-   ##
==========================================
- Coverage   76.08%   76.00%   -0.08%     
==========================================
  Files          91       91              
  Lines       14195    14208      +13     
==========================================
- Hits        10800    10799       -1     
- Misses       3395     3409      +14     
Impacted Files Coverage Δ
sql/engines/mysql.py 79.57% <27.77%> (-3.01%) ⬇️
sql/engines/models.py 93.00% <100.00%> (+0.07%) ⬆️
sql/views.py 63.45% <0.00%> (-0.67%) ⬇️
sql/engines/goinception.py 64.92% <0.00%> (-0.33%) ⬇️
sql/engines/mssql.py 70.05% <0.00%> (-0.16%) ⬇️
sql/engines/tests.py 99.62% <0.00%> (-0.15%) ⬇️
sql/engines/mongo.py 50.00% <0.00%> (+0.13%) ⬆️
sql/utils/sql_utils.py 63.51% <0.00%> (+0.42%) ⬆️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@hhyo hhyo requested a review from LeoQuote September 19, 2022 10:29
@LeoQuote
Copy link
Collaborator

LeoQuote commented Sep 19, 2022

所以这个pr 只是后端支持, 前端还没有加入口吗? 要不要直接在前端或者 api 处就加个入口? 还是你想后续再做

@hhyo
Copy link
Owner Author

hhyo commented Sep 19, 2022

先不加,毕竟也可以主动查询hex结果,有需要的可以自己在query上面加一下,如果后续做实例options改造可以考虑加入自定义

@hhyo hhyo force-pushed the feature/mysql-binary-as-hex branch from 65de5ad to 5ef43df Compare September 19, 2022 13:40
@hhyo hhyo merged commit 18a1b33 into master Sep 19, 2022
@hhyo hhyo deleted the feature/mysql-binary-as-hex branch September 19, 2022 13:47
nick2wang pushed a commit to nick2wang/Archery that referenced this pull request Nov 8, 2022
* mysql查询支持将Binary格式转换为HEX展示 hhyo#1772

(cherry picked from commit 18a1b33)
@beebird
Copy link

beebird commented Nov 18, 2022

先不加,毕竟也可以主动查询hex结果,有需要的可以自己在query上面加一下,如果后续做实例options改造可以考虑加入自定义

感谢! 就是Docker部署的有点麻烦。。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants