WalkLiteralQuery Handle Literal queries such as "SELECT 1, @var;"
(p *Select)
| 265 | |
| 266 | // WalkLiteralQuery Handle Literal queries such as "SELECT 1, @var;" |
| 267 | func (m *PlannerDefault) WalkLiteralQuery(p *Select) error { |
| 268 | //u.Debugf("WalkLiteralQuery %+v", p.Stmt) |
| 269 | // Must project and possibly where |
| 270 | |
| 271 | if p.Stmt.Where != nil { |
| 272 | u.Warnf("select literal where not implemented") |
| 273 | // the reason this is wrong is that the Source task gets |
| 274 | // added in the WalkProjectionFinal below and the Where would need to be in the |
| 275 | // middle of the Source -> Where -> Projection tasks |
| 276 | } |
| 277 | |
| 278 | err := m.WalkProjectionFinal(p) |
| 279 | |
| 280 | //u.Debugf("m.Ctx: %p m.Ctx.Projection.Proj:%p ", m.Ctx, m.Ctx.Projection.Proj) |
| 281 | if err != nil { |
| 282 | u.Errorf("error projecting literal? %#v", err) |
| 283 | return err |
| 284 | } |
| 285 | return nil |
| 286 | } |
no test coverage detected