Re: Possible bug in "select"
Kevin Rosenberg <kevin-HJRc7zDS/[email protected]> Fri, 23 Dec 2005 03:13:49 -0700
| Newsgroups | gmane.lisp.clsql.devel |
|---|---|
| Message-ID | <[email protected]> |
Asbjørn Bjørnstad wrote: > CL-USER 38 > (clsql:select 'foo-bar :where [= [foo-bar id] 1]) > with expression "SELECT foo_bar.id FROM foo_bar,foo_bar WHERE ((foo_bar.id = 1))": Yes, I'd call that a bug. As a workaround, using (clsql:select 'foo-bar :where [= [id] 1]) give the expected results. > I've tracked it down to the way duplicates is removed in #'find-all: > 'foo-bar "becomes": > (slot-value (clsql:sql-expression :table (clsql:view-table (clsql::find-class 'foo-bar))) 'clsql-sys:name) > which equals FOO_BAR > > [foo-bar] "becomes": > (slot-value [foo-bar] 'clsql-sys:name) > which equals FOO-BAR Thanks for tracking this down. I have an idea how to fix this. Thanks for the report, Kevin