File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed
go/ql/lib/semmle/go/frameworks Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -100,12 +100,28 @@ module SQL {
100100 }
101101 }
102102
103+ /** A string that might identify package `go/bigquery` */
104+ string gobigquery ( ) { result = "cloud.google.com/go/bigquery.Client" }
105+
103106 /** A string that might identify package `go-pg/pg` or a specific version of it. */
104107 private string gopg ( ) { result = package ( "github.com/go-pg/pg" , "" ) }
105108
106109 /** A string that might identify package `go-pg/pg/orm` or a specific version of it. */
107110 private string gopgorm ( ) { result = package ( "github.com/go-pg/pg" , "orm" ) }
108111
112+ /**
113+ * A string argument to an api of `go/bigquery` that is directly interpreted as SQL
114+ * without taking syntactic structure in account
115+ */
116+ class BigQueryString extends Range {
117+ BigQueryString ( ) {
118+ exists ( Function f |
119+ f .hasQualifiedName ( gobigquery ( ) , "Query" ) and
120+ this = f .getACall ( ) .getArgument ( 0 )
121+ )
122+ }
123+ }
124+
109125 /**
110126 * A string argument to an API of `go-pg/pg` that is directly interpreted as SQL without
111127 * taking syntactic structure into account.
You can’t perform that action at this time.
0 commit comments