GNOME Bugzilla – Bug 335295
execSQL misbehaviour
Last modified: 2018-05-22 13:14:17 UTC
Please describe the problem: Using Gnumeric 1.6.1 from the SUSE supplimentary distribution, along with gnome-database-properties 1.3.91 and Postgres 8.0.3. Also tested with mySQL 4.1.13 with similar results. Steps to reproduce: 1. Set up a postgres data source in gnome-database-properties 2. Enter array forumula =execSQL("Postgres Test","fishy","fishfish","select addr1,addr2 from eg_pod limit 6"). 3. Use the awful syntax inherited from Excel to execute this: ctrl-shift-enter. 4. Observe that just two rows and one column of valid data are returned. The rest of the cells get '0'. Actual results: Partial data. Expected results: All the data. Does this happen every time? Yes. Other information: Note that it seems to ignore the first three parameters (source, login and password). And libgda asks me for the password two more times before the data is returned.
See also http://www.obviously.com/tech_tips/Loading%20SQL%20Data%20into%20Gnumeric.html
Testing with gnumeric and libgda CVS (1.7.3 and 1.9.104) and the sqlite provider, I get all the rows. Username and password in the execSQL statement seems to be ignored, I'm prompted for them.
Beyond this: I'd love a way to return results without needing to know the number of columns and rows in advance. I'd love a simple "enter some sql" box, that returns the proper number of rows (with headers).
Reconfirmed with Gnumeric 1.6.3 from SUSE (current release). =execSQL("ezsched","postgres","","select * from route") 1 0 0 0 2 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
Retested with MySQL 5.0.26. Bug still present: =execSQL("mtest","root","fishfish","select * from CCS_TERMS") 1 0 2 0 0 0 0 0 Oddly if I mess with this enough something happens and data is returned. But I can't repeat that part (getting the data). The "would split an array" thing is annoying too.
libgda is 1.3.91 in this case (SUSE 10.2).
*** Bug 172213 has been marked as a duplicate of this bug. ***
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/gnumeric/issues/50.