parseExprsWithInt parses one or more sql expressions.
(exprs []string, nakedIntType *types.T)
| 353 | |
| 354 | // parseExprsWithInt parses one or more sql expressions. |
| 355 | func parseExprsWithInt(exprs []string, nakedIntType *types.T) (tree.Exprs, error) { |
| 356 | stmt, err := ParseOneWithInt(fmt.Sprintf("SET ROW (%s)", strings.Join(exprs, ",")), nakedIntType) |
| 357 | if err != nil { |
| 358 | return nil, err |
| 359 | } |
| 360 | set, ok := stmt.AST.(*tree.SetVar) |
| 361 | if !ok { |
| 362 | return nil, errors.AssertionFailedf("expected a SET statement, but found %T", stmt) |
| 363 | } |
| 364 | return set.Values, nil |
| 365 | } |
| 366 | |
| 367 | // ParseExprs parses a comma-delimited sequence of SQL scalar |
| 368 | // expressions. The caller is responsible for ensuring that the input |
no test coverage detected
searching dependent graphs…