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

torand / FasterSQL / 13591799490

28 Feb 2025 03:59PM UTC coverage: 65.237% (-1.3%) from 66.563%
13591799490

push

github

web-flow
Merge pull request #14 from torand/having-support

feat: supporting the HAVING clause + IS NULL operator now supports an…

214 of 408 branches covered (52.45%)

Branch coverage included in aggregate %.

273 of 389 new or added lines in 69 files covered. (70.18%)

3 existing lines in 3 files now uncovered.

1079 of 1574 relevant lines covered (68.55%)

3.68 hits per line

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

80.0
/src/main/java/io/github/torand/fastersql/projection/ColumnPosition.java
1
package io.github.torand.fastersql.projection;
2

3
import io.github.torand.fastersql.Column;
4
import io.github.torand.fastersql.Context;
5
import io.github.torand.fastersql.Sql;
6
import io.github.torand.fastersql.alias.ColumnAlias;
7
import io.github.torand.fastersql.order.OrderExpression;
8

9
import java.util.stream.Stream;
10

11
import static io.github.torand.fastersql.util.contract.Requires.require;
12

13
/**
14
 * Represents an enumeration of a projection.
15
 */
16
public class ColumnPosition implements Sql, OrderExpression {
17
    private final int position;
18

19
    public ColumnPosition(int position) {
2✔
20
        require(() -> position >= 1, "Position must be 1 or greater");
12!
21
        this.position = position;
3✔
22
    }
1✔
23

24
    // Sql
25

26
    @Override
27
    public String sql(Context context) {
28
        return Integer.toString(position);
4✔
29
    }
30

31
    @Override
32
    public Stream<Object> params(Context context) {
NEW
33
        return Stream.empty();
×
34
    }
35

36
    @Override
37
    public Stream<Column> columnRefs() {
38
        return Stream.empty();
2✔
39
    }
40

41
    @Override
42
    public Stream<ColumnAlias> aliasRefs() {
43
        return Stream.empty();
2✔
44
    }
45
}
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

© 2026 Coveralls, Inc