52 Commits

Author SHA1 Message Date
Juergen E. Fischer
c2fb11c8d5 db manager: only alias subqueries on postgres (fixes #13731) 2015-12-02 09:24:25 +01:00
Giuseppe Sucameli
c4dcb7b812 [DbManager] delete layer passed to querybuilder to set sql layer filter (follow f6e31613) 2015-11-30 00:38:06 +01:00
Sebastian Dietrich
f6e3161317 Added a button to set a filter for a query layer. 2015-11-29 13:19:55 +01:00
Sebastian Dietrich
e04d5e4d70 replaced 'LIMIT 0' by 'WHERE 0=1' (fixes #13731) 2015-11-17 21:29:19 +01:00
Juergen E. Fischer
bf64f8d0a0 spelling fixes and indentation update 2015-10-22 21:56:54 +02:00
Giuseppe Sucameli
2a57b17068 DBManager: avoid loading a query as layer with missing fields (fix #11037),
restore combo style and label when multiple unique fields for view are not supported (follow 8e45da9d7e)
2015-10-22 19:23:42 +02:00
Sebastian Dietrich
8e45da9d7e db_manager allows multiple column primary keys only for PostGIS queries, not for SpatiaLite. 2015-10-18 18:10:01 +02:00
Sebastian Dietrich
d8deb8c081 Db_Manager keeps the selected columns for primary key and geometry when running the query or rereading the columns if the selected columns still exist. 2015-10-17 16:43:54 +02:00
Sebastian Dietrich
724a5bda9a Db_Manager now allows to select multiple columnns as the primary key for a query. 2015-10-17 16:15:21 +02:00
Sebastian Dietrich
20283a4dfc Unified the way the column comboboxes are filled when executing the query and when pressing the load columns button. 2015-10-17 02:19:41 +02:00
Juergen E. Fischer
b39055b39c indentation update (now including autopep8) 2015-08-22 14:29:41 +02:00
Nathan Woodrow
5fb52fa1ed Remove query dialog. Replace with tabs 2015-08-17 18:10:59 +10:00
Matthias Kuhn
9fc1b48bf3 Replace str() with unicode() and some PEP 8 2015-08-16 20:58:43 +02:00
Salvatore Larosa
6524080f14 [db manager] Fix #12844 - python error opening SQL Window 2015-06-02 18:48:28 +02:00
Giuseppe Sucameli
08dd620b59 Create a view from the selected query (PR#1999) 2015-05-27 09:59:31 +02:00
Etienne Trimaille
b1dd253fc5 fix selected query (fixes #12429) 2015-05-27 00:56:06 +02:00
Hugo Mercier
e440dee1bd [DBManager] Add a 'create view' button 2015-05-04 17:19:21 +02:00
Hugo Mercier
4876e7a2be [DBManager] Integrate QSpatialite's query builder 2015-05-04 17:19:09 +02:00
Hugo Mercier
d684c8c749 [DBManager] Allow to load a layer without primary key 2015-05-04 17:19:03 +02:00
Hugo Mercier
00618fcabf [DBManager] Allow non-spatial layers 2015-05-04 17:18:24 +02:00
Nathan Woodrow
297a94fc58 Fix formatting of db manager python code 2015-03-21 20:35:29 +10:00
Etienne Trimaille
54ce784d31 add 'way' to geometry column name' 2015-03-18 18:12:33 +02:00
Martin Dobias
c3d9f10cbe Fix #12193 - problem with update of SQL query in DB manager
In the scenario described in the bug report, the selected text was empty,
but editor's hasSelectedText() would still return True
2015-02-20 15:04:46 +07:00
Juergen E. Fischer
2c820bb925 db_manager: use SqlEdit when QgsCodeEditorSQL is unavailable (fixes #12011) 2015-02-02 18:45:27 +01:00
Juergen E. Fischer
956c155e8f fix python pep8 warnings and fix some revealed errors
pep8 --ignore=E111,E128,E201,E202,E203,E211,E221,E222,E225,E226,E227,E231,E241,E261,E265,E272,E302,E303,E501,E701 \
     --exclude="ui_*.py,debian/*,python/ext-libs/*" \
     .
2015-02-01 20:46:47 +01:00
Juergen E. Fischer
bff64fdef9 indentation update 2014-12-30 22:47:09 +01:00
Etienne Trimaille
06c6ca0044 allow execution of the selected text in the SQL window 2014-12-19 16:55:35 +01:00
Salvatore Larosa
2eb0ca343c [codeeditor] set case insensitive for SQL Lexer: followup #1686 2014-12-02 10:18:08 +01:00
Alexander Bruy
ad881089ef case insensitive autocompletion 2014-11-14 18:16:10 +02:00
Alexander Bruy
22619996b5 switch DB Manager's SQL editor to QgsCodeEditorSQL 2014-11-13 17:08:19 +02:00
Nyall Dawson
a9c4136aa9 dbManager - remove more 'Sorry' strings 2014-09-26 07:23:23 +10:00
Nyall
4e3510edec [dbmanager] Try to set sensible default column choice for sql window 2014-09-15 13:08:52 +10:00
Nyall
3bf6f3e472 [dbmanager] Don't trip up when loading a sql layer if sql ends with a ; 2014-09-15 12:28:24 +10:00
Salvatore Larosa
d0bf3dbfe1 [db manager] shows vertical scrollbar as needed and set focus to the query editor after clearing 2014-04-28 10:30:36 +02:00
Juergen E. Fischer
57dd8779ac dbmanager: fix 'load as new layer' (fixes #9548) 2014-02-13 00:00:25 +01:00
Martin Dobias
6b74feed5c [db manager] Also removed completer.py file and its imports 2014-02-11 19:26:44 +07:00
Alexander Bruy
83baa914bd [db manager] use QScintilla for SQL window 2014-02-11 13:10:15 +02:00
Salvatore Larosa
efd84bd022 [dbmanager] set focus to SQL query TextEdit and change to ScrollToPixel the result query area 2013-07-31 23:11:33 +02:00
Salvatore Larosa
9cabd33c0c Fix #8366 2013-07-28 22:44:49 +02:00
Juergen E. Fischer
192e13013b replace foo.replace( QRegExp(regexp), bar) with re.sub(regexp,bar,foo) (fixes #8066) 2013-06-15 22:44:31 +02:00
Juergen E. Fischer
f0c605e0fa dbmanager: add i18n 2013-06-09 18:51:47 +02:00
Giuseppe Sucameli
ae3abccfe3 DBManager: remove empty line from sql editor 2013-06-04 07:33:43 +02:00
Giuseppe Sucameli
80b5a07e55 DBManager: updated to new SIP API 2013-06-04 07:20:54 +02:00
Juergen E. Fischer
ebc8e6c508 indentation update 2013-05-27 08:50:11 +02:00
olivierdalang
6bd1b78b18 [FEATURE] allows to store SQL queries in the DB manager 2013-04-24 16:25:10 +00:00
Alexander Bruy
e742d5e63e fix python plugins after API cleanup 2012-12-24 11:48:08 +02:00
Giuseppe Sucameli
c203990ceb fix #6842 2012-12-10 01:32:31 +01:00
Giuseppe Sucameli
34a16e246c fix #6846 2012-12-10 01:32:31 +01:00
Giuseppe Sucameli
3da32c00d5 do not translate geometry types, change dbmanager translation context names (fix #6837) 2012-12-10 01:32:31 +01:00
Juergen E. Fischer
9721736fd8 remove trailing blanks 2012-12-10 00:12:07 +01:00