From 8bc8242ad90556404e42c31d7b45b37e24665cda Mon Sep 17 00:00:00 2001 From: deepakrai9185720 Date: Fri, 4 Nov 2022 17:40:27 +0530 Subject: [PATCH] Changed query to accept user input in parameterized query --- warehouse/warehouse.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/warehouse/warehouse.go b/warehouse/warehouse.go index d0e7271547..3395403e81 100644 --- a/warehouse/warehouse.go +++ b/warehouse/warehouse.go @@ -1836,7 +1836,7 @@ func getPendingStagingFileCount(sourceOrDestId string, isSourceId bool) (fileCou lastStagingFileID, sourceOrDestColumn, ) - err = dbHandle.QueryRow(sourceOrDestId, sourceOrDestId).Scan(&fileCount) + err = dbHandle.QueryRow(sqlStatement, sourceOrDestId).Scan(&fileCount) if err != nil && err != sql.ErrNoRows { err = fmt.Errorf("query: %s run failed with Error : %w", sqlStatement, err) return