ParseOne parses a sql statement string, ensuring that it contains only a single statement, and returns that Statement. ParseOne will always interpret the INT and SERIAL types as 64-bit types, since this is used in various internal-execution paths where we might receive bits of SQL from other nodes.
(sql string)
| 234 | // bits of SQL from other nodes. In general, we expect that all |
| 235 | // user-generated SQL has been run through the ParseWithInt() function. |
| 236 | func ParseOne(sql string) (Statement, error) { |
| 237 | var p Parser |
| 238 | return p.parseOneWithDepth(1, sql) |
| 239 | } |
| 240 | |
| 241 | // ParseQualifiedTableName parses a SQL string of the form |
| 242 | // `[ database_name . ] [ schema_name . ] table_name`. |
searching dependent graphs…