SplitMultiSQL splits statement into a slice of the single SQL.
(engine storepb.Engine, statement string)
| 130 | |
| 131 | // SplitMultiSQL splits statement into a slice of the single SQL. |
| 132 | func SplitMultiSQL(engine storepb.Engine, statement string) ([]Statement, error) { |
| 133 | f, ok := splitters[engine] |
| 134 | if !ok { |
| 135 | return nil, errors.Errorf("engine %s is not supported", engine) |
| 136 | } |
| 137 | return f(statement) |
| 138 | } |
| 139 | |
| 140 | // RegisterCompleteFunc registers the completion function for the engine. |
| 141 | func RegisterCompleteFunc(engine storepb.Engine, f CompletionFunc) { |