SQLite Forum

www.sqlite.org/appfunc.html has invalid sample code
Login

www.sqlite.org/appfunc.html has invalid sample code

(1) By Martin Thierer (thierer) on 2020-09-20 12:07:35 [link] [source]

  • Under "2.3.2. The Aggregate Function Callbacks"
  • Under "3. Security Implications"

Both snippets show a "}; hd_resolve_one {0}; hd_puts {" string which doesn't make sense to me and probably got there by accident.

(2) By Simon Slavin (slavin) on 2020-09-21 12:29:00 in reply to 1 [link] [source]

I don't see either of those strings anywhere on that page. In fact my browser can't find the string 'hd' anywhere on that page. Perhaps it has been fixed since you posted.

Can you try another browser ? And if the problem persists, figure out a way to show it to us.

(3) By anonymous on 2020-09-21 13:47:21 in reply to 2 [source]

Perhaps it has been fixed since you posted.

That seems to be the case.

(4) By luelista on 2022-02-17 17:15:22 in reply to 3 [link] [source]

The same problem exists in the Tcl code sample over here:

https://www.sqlite.org/undoredo.html

e.g.

proc freeze {} {
  variable _undo
  if {!}; hd_resolve_one {info exists _undo(freeze)}; hd_puts {} return
  if {$_undo(freeze)>=0} {error "recursive call to ::undo::freeze"}
  set _undo(freeze) }; hd_resolve_one {db one {SELECT coalesce(max(seq),0) FROM undolog}}; hd_puts {
}

(5) By luelista on 2022-02-18 08:35:07 in reply to 4 [link] [source]

Thanks for fixing, and sorry for the double post (I didn't understand the forum is moderated at first)