[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #13 by PICCORO LENZ MCKAY: now this its a confirmed bug: seems the odbc implementation for TDS protocol in gambas does not enabled the advanced cursor.. and uses the default cursor, that does not support subquerys (multiple cursor and moveto cursors) ok, after some research MARS are supported in FreeTDS since version 0.95, its not enabled by default, so the problem here its that the gambas implementatin seems does not enabled the needed features.. PICCORO LENZ MCKAY changed the state of the bug to: Accepted. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #12 by Leonardo SALAZAR: I reproduce the error in debian 7 gambas 3.4.2 the next piece of code always return "-1" Try rs = $conexionodbc.Exec(query) If rs.Available Then ' howmany = rsprices.Count ' Endif get -1 no way to fetch the data in grid -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #11 by PICCORO LENZ MCKAY: hello i tested all the available knowed odbc modules with gambas code, and rs.count only returns a result.count with mysql! again, seems here there are some spected racism.. Quote: SQLRowCount Function Conformance Version Introduced: ODBC 1.0 Standards Compliance: ISO 92 Summary SQLRowCount returns the number of rows affected by an UPDATE, INSERT, or DELETE statement; an SQL_ADD, SQL_UPDATE_BY_BOOKMARK, or SQL_DELETE_BY_BOOKMARK operation in SQLBulkOperations; or an SQL_UPDATE or SQL_DELETE operation in SQLSetPos there's not the case for the rest of odbc typoes, only for mysql, and seems for sqliteodbc are buggy in mayor funtions, but tested agains isql command line and some code with php works.. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #10 by PICCORO LENZ MCKAY: due the result object to make the MoveTo need the count for... as said zxMarce all .MoveXXX methods except .MoveNext SEEMS need a record count from the provider. so there's no way for the DAta event to fill the grid using ODBC and sybase... 1) this kind of information MUST BE in the documentation Benoit 2) the odbc standard does not have that unless a INSERT, UPDATE or DELETE was done Now lest try with the second suggestion .. ODBC does not permit subquerys if a recorset are still open.. all the code will must go to the odbc gambas implementation due by example if i do: select count(codigo) as cuanto from dba.ta_sys_existencias_dinamicas order by cuanto limit 5 offset 0 and in other result i do select * from dba.ta_sys_existencias_dinamicas order by col1 limit 5 offset 0 take in consideration the limit indicate only 5 rows, the odbc does not report the amount , but due strange reasons, the where( rs.available) will iterate over the 5 rows event the count select only return one row! as i said: a) for close this bug the documentation must be updated with methods to fill a grid from odbc b) the respective non_working events and methods must be update in documentation c) there's only 4 modules for DB access, all have good working excepts odbc? seem quite complicated to explain and its not documented in any place in wiki.. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #9 by PICCORO LENZ MCKAY: for close this bug, we need > * or update the gambas wiki documentation (please all languajes) * or provide better handle of the rs.count that perdon me, its very confuse provide such method and no retrieve desired results -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
2017-05-03 22:04 GMT-04:00: > Also, in case you didn't know, Microsoft was one of the leading forces > behind drafting yeah.. i use sybase the original software behind the SQL server and the only way to connect to its odbc (inclusivelly internally always used odbc bridgeds, so then m$ its reasonable to are behind that papers) > But anyway both MS and IBM (at least when I read the docs to make the > Gambas component work again) were kind enough to mark clearly any > deviations or differences from the standard in their ODBC docs. > u are the mantainer and author of the ODBC componet? i used extensivelly the ODBC component and i was thinking that i'm the only used deeply.. tomorrow i'll test again a SP that will retrieve a thousands of rows... (currently i make it with a dummy table, production will retrieve thousands) Lenz McKAY Gerardo (PICCORO) http://qgqlochekone.blogspot.com 2017-05-03 22:09 GMT-04:00 : > Hehe... you're right. But I also cited IBM's ODBC docs for its DB2, and > you can also check Easysoft's excellent C tutorials at > http://www.easysoft.com/developer/languages/c/odbc_tutorial.html. > Speaking about Easysoft, I myself made a command line ODBC tool to connect > with ConnectionStrings and run queries in C with Easysoft's tutorials... > And I absolutely suck at C. That good are those tutorials! > > Also, in case you didn't know, Microsoft was one of the leading forces > behind drafting ODBC, as this quote from Wikipedia says: > > ODBC was originally developed by Microsoft and Progress DataDirect during > the early 1990s, and became the basis for the Call Level Interface (CLI) > standardized by SQL Access Group in the Unix and mainframe field. > > So by using their docs you know that that is the standard. Well, at least > theirs... They suck at Windows (and OS making and privacy respecting in > general), yes, but they sometimes pull nice tricks off their hats like > ODBC. And that is not the only standard they helped draft. > > But anyway both MS and IBM (at least when I read the docs to make the > Gambas component work again) were kind enough to mark clearly any > deviations or differences from the standard in their ODBC docs. > > Hope that helps, > zxMarce. > > On May 3, 2017, 21:20, at 21:20, bugtrac...@gambaswiki.org wrote: > >http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- > > > >Comment #8 by PICCORO LENZ MCKAY: > > > >i noyed u only cited mocosoft papers.. dont know about mocosoft like > >papers.. mocosoft tendts to change everything depends of their > >convenience... > > > > > >odbc its today standardized by SQL Access Group in the Unix and > >mainframe field so please cited a right paper.. not windo/like > > -- > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > ___ > Gambas-user mailing list > Gambas-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/gambas-user > -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
Re: [Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
Hehe... you're right. But I also cited IBM's ODBC docs for its DB2, and you can also check Easysoft's excellent C tutorials at http://www.easysoft.com/developer/languages/c/odbc_tutorial.html. Speaking about Easysoft, I myself made a command line ODBC tool to connect with ConnectionStrings and run queries in C with Easysoft's tutorials... And I absolutely suck at C. That good are those tutorials! Also, in case you didn't know, Microsoft was one of the leading forces behind drafting ODBC, as this quote from Wikipedia says: ODBC was originally developed by Microsoft and Progress DataDirect during the early 1990s, and became the basis for the Call Level Interface (CLI) standardized by SQL Access Group in the Unix and mainframe field. So by using their docs you know that that is the standard. Well, at least theirs... They suck at Windows (and OS making and privacy respecting in general), yes, but they sometimes pull nice tricks off their hats like ODBC. And that is not the only standard they helped draft. But anyway both MS and IBM (at least when I read the docs to make the Gambas component work again) were kind enough to mark clearly any deviations or differences from the standard in their ODBC docs. Hope that helps, zxMarce. On May 3, 2017, 21:20, at 21:20, bugtrac...@gambaswiki.org wrote: >http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- > >Comment #8 by PICCORO LENZ MCKAY: > >i noyed u only cited mocosoft papers.. dont know about mocosoft like >papers.. mocosoft tendts to change everything depends of their >convenience... > > >odbc its today standardized by SQL Access Group in the Unix and >mainframe field so please cited a right paper.. not windo/like -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #8 by PICCORO LENZ MCKAY: i noyed u only cited mocosoft papers.. dont know about mocosoft like papers.. mocosoft tendts to change everything depends of their convenience... odbc its today standardized by SQL Access Group in the Unix and mainframe field so please cited a right paper.. not windo/like -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #7 by PICCORO LENZ MCKAY: marked as working due ODBC specifications said there's no mechanish for count... but needs update documentation wiki! PICCORO LENZ MCKAY changed the state of the bug to: Opened. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #6 by PICCORO LENZ MCKAY: ZXMARGE thanks for the tip, i'm aware of the new features related to connection in recent odbc.. but i not thanking about.. in any case, i posted as a bug due in others languajes like php and java the rows cound are provided.. if this not return count, so the method must documented that -.. the count wiki said "Returns the number of records inside the result." so then now noted that returns "-1" now i understand why "-1"... that must be documented in the odbc wiki count page now here the real problem its that if i try to make a select count, and then a select * toa stored procedure, the odbc seems break or lock.. see it here in bug issue #1102 http://gambaswiki.org/bugtracker/edit?object=BUG.1102=L21haW4- now i know that i must do as u coded: " While (res.Available)" -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- PICCORO LENZ MCKAY changed the state of the bug to: Working. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #5 by zxMarce: Piccoro, Just added an attach with a pretty much generic ODBC component test project. It allows to connect with the new ConnectionString approach (can connect without putting server info in INI files), or the traditional INI file settings. It also allows to run queries on the connected server. There's minimal error catching and also allows to set the GB.Debug flag to get extra ODBC component debug info on the Gambas Console. I used the attach to connect successfully to MSSQL and Firebird: I was reported an error in the internal RowCount function I implemented in the component when using Firebird and it was successfully patched. The app does not use the graphical data connection nor any data-bound controls. As said, it's very basic but does the job. It also helped me to polish some rough edges on my butchering of the Gambas ODBC component. Hope it helps you also, zxMarce. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- zxMarce added an attachment: ODBCTester Public.tar.gz -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #4 by zxMarce: Actually, per practically any available documentation you can check, ODBC doesn't return a row count for SELECT statements. I'll refer you to MSDN, for example (https://docs.microsoft.com/en-us/sql/odbc/reference/syntax/sqlrowcount-function), but you can also check IBM's docs, which say the exact same: Quote: SQLRowCount Function Conformance Version Introduced: ODBC 1.0 Standards Compliance: ISO 92 Summary SQLRowCount returns the number of rows affected by an UPDATE, INSERT, or DELETE statement; an SQL_ADD, SQL_UPDATE_BY_BOOKMARK, or SQL_DELETE_BY_BOOKMARK operation in SQLBulkOperations; or an SQL_UPDATE or SQL_DELETE operation in SQLSetPos So, unless some not-so-easy mechanism is implemented, no ODBC interface will return you a row count for SELECTs. The problem implementing the mechanism is that not all queries return a Result, for example the USE command in MSSQL. A high level ODBC interface would have a ton of things to take into account just to check whether a row count is returnable, necessary or even factible. Add to that difficulty the fact that ODBC is actually not a driver per-se, but a driver manager and the problem only gets worse, because not all drivers implement all calls. In short: You must use Result.Available (boolean) to check whether there are rows or not, and Result.MoveNext to loop records when dealing with ODBC. I did implement a kind of row count for SELECTs, but it works or not depending on the underlying database driver (the one managed by ODBC), so you cannot rely on it. One last thing: You can use a Connection String to connect to a database, if you know how to create it with your database driver of choice. Fill the Connection.Host property with the connection string instead of flling it with the Host Name and you're set. I connected to MSSQL and MySQL just changing the Connection String. Almost forget: Regarding PHP, Java, etc, if anyone can tell me what to look at to get the infamous row count they claim they get with ODBC SELECTs, I'll appreciate it. Maybe I can add it to Gambas' ODBC. Regards, zxMarce. zxMarce changed the state of the bug to: NeedsInfo. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #3 by PICCORO LENZ MCKAY: preparing a project for that its quite tedius, and its obviusly.. i notes that only the "mysql" module are well knowed.. the rest have some bugs always.. i reported some time ago piece of correctiions for postgres part.. i'll try to upload a project in two or 3 days, but wheantime please some one revise the code.. i'm hurry "again" due now i must use odbc and not have scape this time.. the info required that in their machines u must configured a odbc driver so event i upload a project must relly on their odbc connections.. so the "needsinfo" state are relative... PICCORO LENZ MCKAY changed the state of the bug to: Opened. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #2 by Tobias BOEGE: >If rs.Available Then ' <--- Here we have -1 !!! Result.Available is a Boolean. It is expected that its numerical value is -1 (meaning True). >howmany = rsprices.Count ' < psst ¡always get here -1! no care the query, >if there are a SP always -2 Is "rsprices" related in any way to the "rs" object you stored the query result in? I have never used ODBC but the people who know about it will likely want a project that reproduces the bug, a sample database and possibly any configuration files that ODBC might require (no idea). Tobias BOEGE changed the state of the bug to: NeedsInfo. -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- Comment #1 by PICCORO LENZ MCKAY: NOTE: using a freetds odbc bridge with sybase.. in php retrieve correct roms and in java so i dischard NOTE2: same with postgres but using odbc -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user
[Gambas-user] [Gambas Bug Tracker] Bug #1100: ODBC driver super buggy 1: rs.count return always negative and only one event in lasted
http://gambaswiki.org/bugtracker/edit?object=BUG.1100=L21haW4- PICCORO LENZ MCKAY reported a new bug. Summary --- ODBC driver super buggy 1: rs.count return always negative and only one event in lasted Type : Bug Priority : High Gambas version : 3.9 Product : ODBC driver Description --- some time ago i tried and found many bugs, but not reported due i using older linux.. but today i tested in linuxmint, winbuntu, stupibuntu, debian lasted, and fedora and with gambas versions from 3.1.1 to lasted (specifically 3.1.1, 3.4.2 and 3.9.X and trunk) the next piece of code always return "-1" Try rs = $conexionodbc.Exec(queryprices) If rs.Available Then ' <--- Here we have -1 !!! ' BUG 2 Max from resulset in ODBC are negative! howmany = rsprices.Count ' < psst ¡always get here -1! no care the query, if there are a SP always -2 Endif System information -- [System] Gambas=3.9.1 OperatingSystem=Linux Kernel=3.2.0-0.bpo.4-686-pae Architecture=x86 Distribution=debian 6.1 Desktop= Theme=VenenuX Language=es_VE.UTF-8 Memory=1695M [Libraries] Cairo=libcairo.so.2.11000.2 Curl=libcurl.so.4.2.0 DBus=libdbus-1.so.3.4.0 GStreamer=libgstreamer-0.10.so.0.27.0 GTK+2=libgtk-x11-2.0.so.0.2000.1 Poppler=libpoppler.so.5.0.0 QT4=libQtCore.so.4.7.4 SDL=libSDL-1.2.so.0.11.4 SQLite=libsqlite3.so.0.8.6 [Environment] DBUS_SESSION_BUS_ADDRESS=unix:abstract=/tmp/dbus-SDLMZFhfxe,guid=e84bee4349323ab2fdd0e833000d3724 DESKTOP_SESSION=openbox DISPLAY=:0.0 GB_GUI=gb.qt4 GDMSESSION=openbox GDM_LANG=es_VE.UTF-8 GDM_XSERVER_LOCATION=local GNOME_KEYRING_CONTROL=/tmp/keyring-F6Av2Z GNOME_KEYRING_PID=28945 HOME= LANG=es_VE.UTF-8 LOGNAME= PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games:/.rvm/bin PWD= SHELL=/bin/bash SSH_AGENT_PID=28992 SSH_AUTH_SOCK=/tmp/ssh-MIgmw28954/agent.28954 TZ=:/etc/localtime USER= USERNAME= WINDOWPATH=7:8:8:8:8 XAUTHORITY=/.Xauthority XDG_DATA_DIRS=/usr/local/share/:/usr/share/:/usr/share/gdm/ XDG_SESSION_COOKIE=b7d14e28769c4139a06b6f99000c-1493388004.744958-1810097376 -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Gambas-user mailing list Gambas-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/gambas-user