Created attachment 141293 [details] test file for view editing Checked with Libo6.0.4 (daily) and LibO6.1 (daily) Open the attached file / tables. Either right click on the single view (vTasksWithEmptyEndDates) or with the view selected choose the menu item 'edit' The pop up menu fails to offer 'Edit in SQL view' and the drop down menu has it grayed out. Select edit for the view and the dialog Table Editor dialog is opened instead of the Query Editor.
Could confirm the table-editor is opened instead of the query-editor if you want to edit a view in Version: 6.1.0.0.alpha0+ Build-ID: dc823f5fa4a5d2eca56297b9045e5962536c00f9 CPU-Threads: 4; BS: Linux 4.4; UI-Render: Standard; VCL: kde4; TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2018-04-10_23:32:35 No possibility to edit the view any more. Only creating a new view will work. Tested with OpenSUSE 42.3 64bit rpm Linux
Hello Drew, Did it work in the past? I've tested in Version: 5.3.0.0.alpha1+ Build ID: 4136757b4e51c4e6f7cb4132c95538a7f831ef2c CPU Threads: 4; OS Version: Linux 4.13; UI Render: default; VCL: gtk3; Layout Engine: new; Locale: ca-ES (ca_ES.UTF-8); Calc: group and the 'Edit in SQL view' option is greyed out...
(In reply to Xisco Faulí from comment #2) > Hello Drew, > Did it work in the past? > > I've tested in > > Version: 5.3.0.0.alpha1+ > Build ID: 4136757b4e51c4e6f7cb4132c95538a7f831ef2c > CPU Threads: 4; OS Version: Linux 4.13; UI Render: default; VCL: gtk3; > Layout Engine: new; > Locale: ca-ES (ca_ES.UTF-8); Calc: group > > and the 'Edit in SQL view' option is greyed out... Didn't work with Firebird since the beginning. Tested also with Firebird in LO 5.2.5.1. (with internal Firebird 2.5). Its the same buggy behavior. Views could never be edited with firebird any more after saving. If you try to create a view through the GUI from a query you get a popup "Couldn't found the tableformat". The view will be created but will only be shown after refreshing the tables. If you try to edit the views every time the tableeditor appears instead of the queryeditor. Remark: Editing of a view of HSQLDB works correct with this versions of LO. All tested with OpenSUSE 42.3 and different LO-Versions (5.2.5.1, 5.3.0, 6.0.3 ...)
Seems impossible to edit a created view with Firebird: https://bugs.documentfoundation.org/show_bug.cgi?id=76072#c6
(In reply to robert from comment #4) > Seems impossible to edit a created view with Firebird: > https://bugs.documentfoundation.org/show_bug.cgi?id=76072#c6 Have tried a little bit more: Tools > SQL CREATE OR ALTER VIEW "viewTest" AS SELECT * FROM "table" WHERE "ID" > 4 Works. A View will be created. But LO will show this view (after refreshing the tables) as table. I could see it is a view, because I change something in "table" and is has been changed also in the view. Now CREATE OR ALTER VIEW "viewTest" AS SELECT * FROM "Leser" WHERE "ID" < 5 Works. The view with the same name could be changed. You could get the code for the view with SELECT RDB$RELATION_NAME, RDB$VIEW_SOURCE FROM RDB$RELATIONS WHERE RDB$VIEW_SOURCE IS NOT NULL So it must be possible to load this code to the GUI-query-editor, change the code and put it back to the database.
With Firebird, the pb comes from here: 1748 Reference< XAlterView > xAsAlterableView; 1749 if ( xViews.is() && xViews->hasByName( _rTableOrViewName ) ) 1750 xAsAlterableView.set( xViews->getByName( _rTableOrViewName ), UNO_QUERY ); 1751 1752 bIsAlterableView = xAsAlterableView.is(); see https://opengrok.libreoffice.org/xref/core/dbaccess/source/ui/app/AppController.cxx#1748 #0 0x00007fffc9b6c96b in dbaui::OApplicationController::impl_isAlterableView_nothrow(rtl::OUString const&) const (this=0x555557c9ed80, _rTableOrViewName="View1") at /home/julien/lo/libreoffice/dbaccess/source/ui/app/AppController.cxx:1752 #1 0x00007fffc9b65f7f in dbaui::OApplicationController::GetState(unsigned short) const (this=0x555557c9ed80, _nId=12317) at /home/julien/lo/libreoffice/dbaccess/source/ui/app/AppController.cxx:773 #2 0x00007fffc9c333a4 in dbaui::OGenericUnoController::ImplBroadcastFeatureState(rtl::OUString const&, com::sun::star::uno::Reference<com::sun::star::frame::XStatusListener> const&, bool) (this=0x555557c9ed80, _rFeature=".uno:DBEditSqlView", xListener=uno::Reference to (framework::MenuBarManager *) 0x5555582bd3d0, _bIgnoreCache=true) at /home/julien/lo/libreoffice/dbaccess/source/ui/browser/genericcontroller.cxx:397 Except in hsqldb, searching xAlterVIew returns nothing for Firebird or other DB types https://opengrok.libreoffice.org/search?project=core&q=XAlterView&defs=&refs=&path=&hist=&type= So it seems it's not possible to edit views in those (Mysql, Postgresql...) or perhaps I missed something?
(In reply to Julien Nabet from comment #6) > With Firebird, the pb comes from here: > 1748 Reference< XAlterView > xAsAlterableView; > 1749 if ( xViews.is() && xViews->hasByName( _rTableOrViewName ) ) > 1750 xAsAlterableView.set( xViews->getByName( > _rTableOrViewName ), UNO_QUERY ); > 1751 > 1752 bIsAlterableView = xAsAlterableView.is(); > see > https://opengrok.libreoffice.org/xref/core/dbaccess/source/ui/app/ > AppController.cxx#1748 > > #0 0x00007fffc9b6c96b in > dbaui::OApplicationController::impl_isAlterableView_nothrow(rtl::OUString > const&) const (this=0x555557c9ed80, _rTableOrViewName="View1") > at > /home/julien/lo/libreoffice/dbaccess/source/ui/app/AppController.cxx:1752 > #1 0x00007fffc9b65f7f in dbaui::OApplicationController::GetState(unsigned > short) const (this=0x555557c9ed80, _nId=12317) > at > /home/julien/lo/libreoffice/dbaccess/source/ui/app/AppController.cxx:773 > #2 0x00007fffc9c333a4 in > dbaui::OGenericUnoController::ImplBroadcastFeatureState(rtl::OUString > const&, > com::sun::star::uno::Reference<com::sun::star::frame::XStatusListener> > const&, bool) (this=0x555557c9ed80, _rFeature=".uno:DBEditSqlView", > xListener=uno::Reference to (framework::MenuBarManager *) 0x5555582bd3d0, > _bIgnoreCache=true) > at > /home/julien/lo/libreoffice/dbaccess/source/ui/browser/genericcontroller.cxx: > 397 > > Except in hsqldb, searching xAlterVIew returns nothing for Firebird or other > DB types > https://opengrok.libreoffice.org/ > search?project=core&q=XAlterView&defs=&refs=&path=&hist=&type= > So it seems it's not possible to edit views in those (Mysql, Postgresql...) > or perhaps I missed something? You mean that LibreOffice (UNO) dbaccess is not setup to do so yet. Firebird (MySQL, Postgress also) engine certainly supports ALTER VIEW (and "CREATE OR REPLACE") command. (Going out on a limb here) it seems there is a chunk of functionality simply never coded for the firebird, or MySQL, or the Postgress drivers. For the external RDMBS it isn't really that big a deal as the DBA tools for those are rather extensive and Base is rather weak with what it supports. But for the embedded engines there is no other choice, it is the Base UI or SQL commands in the SQL window.
one more comment. I'm a bit surprised to hear the MySQL and PostgresSQL connectors don't support this. The SQl2003 standard included a defined the INFORMATION_SCHEMA, which was expanded IIRC in 2005 and 2008. The INFORMATION_SCHEMA would give a standardized access to things such as view definitions. HSQLdb was one of the early adopters of the standard. PostgreSQL, MS SQLServer and MySQL all support it. Firebird 3.0 does not conform to the standard in this respect. I believe the decision was to support the 2003 standard as a baseline. Which meant that for those RDBMS(s) that didn't conform those sdbc drivers would need to recreate the code for access to those artifacts. The MySQL and PostregsSQL should of been able to use the HSQLdb code, for these types of things, almost unchanged. At least I believe that was the plan.
(In reply to Drew Jensen from comment #8) > one more comment. > > I'm a bit surprised to hear the MySQL and PostgresSQL connectors don't > support this. I'm not so affirmative. I just noticed xAlterVIew isn't present in Mysql or PostGreSQL part (according to Opengrok) but I didn't test editing a view on these DBs. About your 2 last comments about missing code, the problem is Base has only 1 core dev (Lionel) + Tamas whereas it's a big part. Indeed, Base has more dependencies than other LO components: - external drivers of DBs - external package for reports (JFreereport) - Java/JNI Moreovover every feature for pivot DB (hsqldb and soon Firebird) should ideally work for other DBs. It's not sot easy, just consider migration part from hsqldb to Firebird. Also some DBs types can only be tested on specific envs (Macab on MacOs) In brief, as long as Base doesn't attract more devs, I think the situation won't evolve a lot. It may explain why some people would like to remove Base from LO. (I don't know if it's still the Tor's opinion, see https://blog.documentfoundation.org/blog/2011/07/21/developer-interview-tor-lillqvist/) Sorry for this long digression.
(In reply to Julien Nabet from comment #9) > (In reply to Drew Jensen from comment #8) > > one more comment. > > > > I'm a bit surprised to hear the MySQL and PostgresSQL connectors don't > > support this. > I'm not so affirmative. I just noticed xAlterVIew isn't present in Mysql or > PostGreSQL part (according to Opengrok) but I didn't test editing a view on > these DBs. > > About your 2 last comments about missing code, the problem is Base has only > 1 core dev (Lionel) + Tamas whereas it's a big part. > Indeed, Base has more dependencies than other LO components: > - external drivers of DBs > - external package for reports (JFreereport) > - Java/JNI > Moreovover every feature for pivot DB (hsqldb and soon Firebird) should > ideally work for other DBs. It's not sot easy, just consider migration part > from hsqldb to Firebird. Also some DBs types can only be tested on specific > envs (Macab on MacOs) > In brief, as long as Base doesn't attract more devs, I think the situation > won't evolve a lot. > It may explain why some people would like to remove Base from LO. (I don't > know if it's still the Tor's opinion, see > https://blog.documentfoundation.org/blog/2011/07/21/developer-interview-tor- > lillqvist/) > > Sorry for this long digression. No problem and thanks for the information. I have one question; What is pivot DB? (just searched for that phrase and I can't find anything on it).
(In reply to Drew Jensen from comment #10) > ... > No problem and thanks for the information. I have one question; What is > pivot DB? (just searched for that phrase and I can't find anything on it). Sorry for the confusion, I meant "by default" DB type in LO.
*** Bug 124262 has been marked as a duplicate of this bug. ***
Should this be changed to a RFE asking to remove the GUI menus offering to edit views when Firebird is the rdbms? It is the only viable solution that I can see.
Sadly. It's frustrating when the functionality gets smaller (compared to previous versions)
Dear Drew Jensen, To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year. There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present. If you have time, please do the following: Test to see if the bug is still present with the latest version of LibreOffice from https://www.libreoffice.org/download/ If the bug is present, please leave a comment that includes the information from Help - About LibreOffice. If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave a comment that includes the information from Help - About LibreOffice. Please DO NOT Update the version field Reply via email (please reply directly on the bug tracker) Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not appropriate in this case) If you want to do more to help you can test to see if your issue is a REGRESSION. To do so: 1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3) from https://downloadarchive.documentfoundation.org/libreoffice/old/ 2. Test your bug 3. Leave a comment with your results. 4a. If the bug was present with 3.3 - set version to 'inherited from OOo'; 4b. If the bug was not present in 3.3 - add 'regression' to keyword Feel free to come ask questions or to say hello in our QA chat: https://kiwiirc.com/nextclient/irc.freenode.net/#libreoffice-qa Thank you for helping us make LibreOffice even better for everyone! Warm Regards, QA Team MassPing-UntouchedBug
Bug is almost there in LO 7.1.1.2 on OpenSUSE 15.2 64bit rpm Linux.
Sorry, I had overlooked this one since I thought it was about automatic migration process from Hsqldb to Firebird. This one should already be fixed with https://cgit.freedesktop.org/libreoffice/core/commit/?id=0adff3f2476f797843fb62d6810de90bfb333e10 used for tdf#126960. Don't hesitate to reopen this tracker if you still reproduce this with next prerelease 7.3.1. *** This bug has been marked as a duplicate of bug 126960 ***