Skip to content

Commit a853534

Browse files
author
Roy
committed
```
fix(database): 修复插件包运行时资源查询中的SQL语句错误 移除了SQL查询语句中多余的"order by code"子句,该子句导致了数据库查询错误。 现在查询语句只包含必要的字段选择和过滤条件,确保了查询的正确执行。 ```
1 parent bd7ae4b commit a853534

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

platform-core/services/database/package.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ func QueryPluginPackages(ctx context.Context, param *models.PluginPackageQueryPa
109109
}
110110

111111
var packageRuntimeResDockers []*models.PluginPackageRuntimeResourcesDocker
112-
err = db.MysqlEngine.Context(ctx).SQL("select plugin_package_id,cpu,memory from plugin_package_runtime_resources_docker where plugin_package_id in ("+idListFilter+") order by code", idListParam...).Find(&packageRuntimeResDockers)
112+
err = db.MysqlEngine.Context(ctx).SQL("select plugin_package_id,cpu,memory from plugin_package_runtime_resources_docker where plugin_package_id in ("+idListFilter+") ", idListParam...).Find(&packageRuntimeResDockers)
113113
if err != nil {
114114
err = exterror.Catch(exterror.New().DatabaseQueryError, err)
115115
return

0 commit comments

Comments
 (0)