Skip to content

Commit a670d70

Browse files
query params append fix (#5967)
1 parent 3ff7fdb commit a670d70

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

internal/sql/repository/helper/AppListingRepositoryQueryBuilder.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,8 @@ func (impl AppListingRepositoryQueryBuilder) BuildAppListingQueryLastDeploymentT
174174
func (impl AppListingRepositoryQueryBuilder) GetAppIdsQueryWithPaginationForLastDeployedSearch(appListingFilter AppListingFilter) (string, []interface{}) {
175175
join, queryParams := impl.CommonJoinSubQuery(appListingFilter)
176176
countQuery := " (SELECT count(distinct(a.id)) as count FROM app a " + join + ") AS total_count "
177-
177+
// appending query params for count query as well
178+
queryParams = append(queryParams, queryParams...)
178179
query := "SELECT a.id as app_id,MAX(pco.id) as last_deployed_time, " + countQuery +
179180
` FROM pipeline p
180181
INNER JOIN pipeline_config_override pco ON pco.pipeline_id = p.id and p.deleted=false

0 commit comments

Comments
 (0)