mirror of
https://gitee.com/johng/gf
synced 2026-06-06 02:25:47 +08:00
110e3fbf16bfe3475dc711b2592a21e2617d548c
## Summary - Add wildcard pattern support (`*` and `?`) for `tables` configuration - Fix `tablesEx` wildcard to use exact match (`^$`) for consistency - Add warning when exact table name does not exist - Add unit tests and integration tests for MySQL and PostgreSQL ## Changes | Configuration | Before | After | |---------------|--------|-------| | `tables: "user_*"` | Not supported | Matches tables starting with "user_" | | `tables: "*"` | Not supported | Matches all tables | | `tablesEx: "user_*"` | Partial match | Exact match (consistent with tables) | ## Features - `*` matches any characters (e.g., `user_*` matches `user_info`, `user_log`) - `?` matches single character (e.g., `user_???` matches `user_log` but not `user_info`) - Mixed patterns and exact names supported (e.g., `tables: "user_*,config"`) - Non-existent exact table names are skipped with warning message ## Test plan - [x] Unit tests for `containsWildcard`, `patternToRegex`, `filterTablesByPatterns` (11 cases) - [x] Integration tests for MySQL (5 cases) - [x] Integration tests for PostgreSQL (1 case with tables + tablesEx) - [x] Standard SQL syntax for cross-database compatibility Closes #4629 --------- Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
refract(gerror): add ITextArgs interface and its implements, mainly for i18n that needs text and args separately (#4597)
fix(util/gconv): fix incompatable converting to nil pointer target from older version implement (#4224)
fix(contrib/drivers): resolve field duplication issue when same table/column names exist across different MySQL/MariaDB databases (#4577)
English | 简体中文
A powerful framework for faster, easier, and more efficient project development.
Installation
go get -u github.com/gogf/gf/v2
Documentation
- Official Site: https://goframe.org
- Official Site(en): https://goframe.org/en
- 国内镜像: https://goframe.org.cn
- Mirror Site: Github Pages
- Mirror Site: Offline Docs
- GoDoc API: https://pkg.go.dev/github.com/gogf/gf/v2
- Doc Source: https://github.com/gogf/gf-site
Contributors
💖 Thanks to all the contributors who made GoFrame possible 💖
License
GoFrame is licensed under the MIT License, 100% free and open-source, forever.
Languages
GO
100%
