• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

lightningnetwork / lnd / 16313565012

16 Jul 2025 07:46AM UTC coverage: 67.205% (-0.1%) from 67.321%
16313565012

Pull #10081

github

web-flow
Merge bf32adb8a into 9059a4e7b
Pull Request #10081: graph/db: use `/*SLICE:<field_name>*/` to optimise various graph queries

0 of 379 new or added lines in 4 files covered. (0.0%)

99 existing lines in 24 files now uncovered.

135374 of 201433 relevant lines covered (67.21%)

21718.6 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/sqldb/sqlc/db_custom.go
1
package sqlc
2

3
import "fmt"
4

5
// makeQueryParams generates a string of query parameters for a SQL query. It is
6
// meant to replace the `?` placeholders in a SQL query with numbered parameters
7
// like `$1`, `$2`, etc. This is required for the sqlc /*SLICE:<field_name>*/
8
// workaround. See scripts/gen_sqlc_docker.sh for more details.
NEW
9
func makeQueryParams(numTotalArgs, numListArgs int) string {
×
NEW
10
        diff := numTotalArgs - numListArgs
×
NEW
11
        result := ""
×
NEW
12
        for i := diff + 1; i <= numTotalArgs; i++ {
×
NEW
13
                if i == numTotalArgs {
×
NEW
14
                        result += fmt.Sprintf("$%d", i)
×
NEW
15

×
NEW
16
                        continue
×
17
                }
NEW
18
                result += fmt.Sprintf("$%d,", i)
×
19
        }
NEW
20
        return result
×
21
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc