SQLite Forum

Accessing Sqlite3TreeViewSelect
Login

Accessing Sqlite3TreeViewSelect

(1) By curmudgeon on 2022-01-24 15:51:17 [link] [source]

I'm aware I can e.g. place a breakpoint inside sqlite3WalkSelect and then get a tree view of the sql (initially with text cols and later with numbered cols) using the Select* parameter but is there any way you can extract the Select* from the sqlite3_stmt (*Vdbe) (albeit within the amalgamation code) after it's fully prepared?

is there not a case for a TREEVIEW [NUM | TEXT] sql command akin to EXPLAIN?

I'm sure a lot more than me would find it useful to get a breakdown of the sql with every ID replaced with tbl.col. I had hoped that sqlite3_normalized_sql might've one day shown that.

(2) By Larry Brasfield (larrybr) on 2022-01-24 21:13:58 in reply to 1 [link] [source]

is there any way you can extract the Select* from the sqlite3_stmt (*Vdbe) ... after it's fully prepared?

No. The '*' is not incorporated into the VDBE code.

is there not a case for a TREEVIEW [NUM TEXT] sql command akin to EXPLAIN?

I've not seen such a case made. That code is really for internal use by the SQLite developers. It's output is not stable. I would have little hope of prevailing with an argument for publishing that as an interface.

(3) By curmudgeon on 2022-01-25 11:39:28 in reply to 2 [source]

Thanks for the reply Larry.