Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

QGIS crashes when trying to add ODBC new layer #20807

Closed
qgib opened this issue May 6, 2015 · 10 comments
Closed

QGIS crashes when trying to add ODBC new layer #20807

qgib opened this issue May 6, 2015 · 10 comments
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Crash/Data Corruption Data Provider Related to specific vector, raster or mesh data providers High Priority

Comments

@qgib
Copy link
Contributor

qgib commented May 6, 2015

Author Name: Joan Molinas (Joan Molinas)
Original Redmine Issue: 12701
Affected QGIS version: 2.8.1
Redmine category:data_provider/ogr


QGIS crashes (program closes) when attempting to add a new layer from ODBC Data Base connection.
I try to establish an ODBC connection between a external database Informix and QGIS. The connection test succeeded, but take a lot of time. And when I click to open, QGIS crash and develop me a message "volcado fallido" long time after. Attached file created .dmp.
I try to connect the same data base with eVis plugin and it works properly.

Sorry for my English

@qgib
Copy link
Contributor Author

qgib commented May 6, 2015

Author Name: Giovanni Manghi (@gioman)


Does it happens with previous qgis releases?


  • status_id was changed from Open to Feedback
  • priority_id was changed from Normal to High
  • fixed_version_id removed Version 2.8.1

@qgib
Copy link
Contributor Author

qgib commented May 18, 2015

Author Name: Joan Molinas (Joan Molinas)


I tried it with version 1.8, and it works but it takes very long time.
I've also tried with version 2.4 and does not work either. Exactly the same thing happens with version 2.8

I've also tested with another smaller database (with version 2.8), and it works but also take very long time, 15 minuts more or less.

@qgib
Copy link
Contributor Author

qgib commented May 18, 2015

Author Name: Joan Molinas (Joan Molinas)


And by de eVis plugin opens the list table more or less instantaneously (with two databases).

@qgib
Copy link
Contributor Author

qgib commented Jun 3, 2015

Author Name: Jürgen Fischer (@jef-n)


  • category_id was configured as Data Provider/OGR

@qgib
Copy link
Contributor Author

qgib commented Dec 20, 2015

Author Name: Giovanni Manghi (@gioman)


  • status_id was changed from Feedback to Open

@qgib
Copy link
Contributor Author

qgib commented Mar 7, 2017

Author Name: Giovanni Manghi (@gioman)


If anyway will provide me a way to test odbc connections with real daya I will be happy to test.
I tried with a PostgreSQL OBDC connection, and was slow, but no crashes on 2.18.4.


  • status_id was changed from Open to Feedback

@qgib
Copy link
Contributor Author

qgib commented Apr 29, 2017

Author Name: Giovanni Manghi (@gioman)


Closing for lack of feedback, please reopen if necessary.


  • resolution was changed from to not reproducable
  • status_id was changed from Feedback to Closed

@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! High Priority Data Provider Related to specific vector, raster or mesh data providers Crash/Data Corruption labels May 25, 2019
@qgib qgib closed this as completed May 25, 2019
@rherasm
Copy link

rherasm commented Apr 6, 2020

HI @ll,
I had this same problem:

I was trying a ODBC connection with AWS Presto DB through Simba-Presto x64 driver.
QGIS 3.12 x64
Windows 10 x64 1809

Simba ODBC driver: https://www.simba.com/drivers/presto-odbc-jdbc/?gclid=CjwKCAjwvZv0BRA8EiwAD9T2VUTjxLQYrgQOsI8YT6bduxVaDel2AV9Av8gtExNIIPTZW4gQyf8lQBoCkDMQAvD_BwE

Crash ID: c4598b936d09b7f052a37d8c67c1922646c03994

Stack Trace

memcpy memcpy.asm:135
CPLODBCStatement::Fetch :
DDFRecordIndex::SetClientInfoByIndex :
DDFRecordIndex::SetClientInfoByIndex :
QgsOgrProvider::getOgrGeomType qgsogrprovider.cpp:1045
QgsOgrProvider::loadFields qgsogrprovider.cpp:1091
QgsOgrProvider::setEncoding qgsogrprovider.cpp:1018
QgsOgrProvider::open qgsogrprovider.cpp:4550
QgsOgrProvider::QgsOgrProvider qgsogrprovider.cpp:512
QgsOgrProviderMetadata::createProvider qgsogrprovider.cpp:3462
QgsProviderRegistry::createProvider qgsproviderregistry.cpp:385
QgsVectorLayer::setDataProvider qgsvectorlayer.cpp:1695
QgsVectorLayer::setDataSource qgsvectorlayer.cpp:1602
QgsVectorLayer::QgsVectorLayer qgsvectorlayer.cpp:178
QgisApp::addVectorLayersPrivate qgisapp.cpp:5269
QgisApp::addVectorLayers qgisapp.cpp:5202
QgisApp::qt_static_metacall moc_qgisapp.cpp:1652
QMetaObject::activate :
QgsDataSourceManagerDialog::addVectorLayers moc_qgsdatasourcemanagerdialog.cpp:367
QMetaObject::activate :
QgsAbstractDataSourceWidget::addVectorLayers moc_qgsabstractdatasourcewidget.cpp:304
QgsOgrSourceSelect::addButtonClicked qgsogrsourceselect.cpp:430
QMetaObject::activate :
QAbstractButton::clicked :
QAbstractButton::click :
QAbstractButton::mouseReleaseEvent :
QWidget::event :
QApplicationPrivate::notify_helper :
QApplication::notify :
QgsApplication::notify qgsapplication.cpp:418
QCoreApplication::notifyInternal2 :
QApplicationPrivate::sendMouseEvent :
QSizePolicy::QSizePolicy :
QSizePolicy::QSizePolicy :
QApplicationPrivate::notify_helper :
QApplication::notify :
QgsApplication::notify qgsapplication.cpp:418
QCoreApplication::notifyInternal2 :
QGuiApplicationPrivate::processMouseEvent :
QWindowSystemInterface::sendWindowSystemEvents :
QEventDispatcherWin32::processEvents :
UserCallWinProcCheckWow :
DispatchMessageWorker :
QEventDispatcherWin32::processEvents :
qt_plugin_query_metadata :
QEventLoop::exec :
QDialog::exec :
QgisApp::dataSourceManager qgisapp.cpp:2286
QtPrivate::QFunctorSlotObject,0,QtPrivate::List,void>::impl qobjectdefs_impl.h:421
QMetaObject::activate :
QAction::activate :
QAbstractButton::click :
QAbstractButton::mouseReleaseEvent :
QToolButton::mouseReleaseEvent :
QWidget::event :
QApplicationPrivate::notify_helper :
QApplication::notify :
QgsApplication::notify qgsapplication.cpp:418
QCoreApplication::notifyInternal2 :
QApplicationPrivate::sendMouseEvent :
QSizePolicy::QSizePolicy :
QSizePolicy::QSizePolicy :
QApplicationPrivate::notify_helper :
QApplication::notify :
QgsApplication::notify qgsapplication.cpp:418
QCoreApplication::notifyInternal2 :
QGuiApplicationPrivate::processMouseEvent :
QWindowSystemInterface::sendWindowSystemEvents :
QEventDispatcherWin32::processEvents :
UserCallWinProcCheckWow :
DispatchMessageWorker :
QEventDispatcherWin32::processEvents :
qt_plugin_query_metadata :
QEventLoop::exec :
QCoreApplication::exec :
main main.cpp:1609
BaseThreadInitThunk :
RtlUserThreadStart :

QGIS Info
QGIS Version: 3.12.1-Bucure?ti
QGIS code revision: 121cc00
Compiled against Qt: 5.11.2
Running against Qt: 5.11.2
Compiled against GDAL: 3.0.4
Running against GDAL: 3.0.4

System Info
CPU Type: x86_64
Kernel Type: winnt
Kernel Version: 10.0.17763

@rherasm
Copy link

rherasm commented Apr 6, 2020

Additional information, ODBC driver traces:

gis-bin 3e80-40d8 EXIT SQLAllocStmt with return code 0 (SQL_SUCCESS)
HDBC 0x000001ACE80A2BB0
HSTMT * 0x00000047E1FEDFB8 ( 0x000001ACE25849E0)

qgis-bin 3e80-40d8 ENTER SQLExecDirect
HSTMT 0x000001ACE25849E0
UCHAR * 0x000001ACFB320CB0 [ -3] "SELECT f_table_name, f_geometry_column, geometry_type FROM geometry_columns\ 0"
SDWORD -3

qgis-bin 3e80-40d8 EXIT SQLExecDirect with return code -1 (SQL_ERROR)
HSTMT 0x000001ACE25849E0
UCHAR * 0x000001ACFB320CB0 [ -3] "SELECT f_table_name, f_geometry_column, geometry_type FROM geometry_columns\ 0"
SDWORD -3

	DIAG [S1000] [Simba][Presto] (1060) Presto Query Error: line 1:60: Table hive.schemaName.geometry_columns does not exist (1) (1060) 

qgis-bin 3e80-40d8 ENTER SQLGetDiagRecW
SQLSMALLINT 3 <SQL_HANDLE_STMT>
SQLHANDLE 0x000001ACE25849E0
SQLSMALLINT 1
SQLWCHAR * 0x00000047E1FEDDD0
SQLINTEGER * 0x00000047E1FEDE88
SQLWCHAR * 0x000001ACE254B5E0
SQLSMALLINT 512
SQLSMALLINT * 0x00000047E1FEDE80

qgis-bin 3e80-40d8 EXIT SQLGetDiagRecW with return code 0 (SQL_SUCCESS)
SQLSMALLINT 3 <SQL_HANDLE_STMT>
SQLHANDLE 0x000001ACE25849E0
SQLSMALLINT 1
SQLWCHAR * 0x00000047E1FEDDD0 [ 5] "S1000"
SQLINTEGER * 0x00000047E1FEDE88 (1060)
SQLWCHAR * 0x000001ACE254B5E0 [ 107] "[Simba][Presto] (1060) Presto Query Error: line 1:60: Table hive.schemaName.geometry_columns does not exist (1)"
SQLSMALLINT 512
SQLSMALLINT * 0x00000047E1FEDE80 (107)

qgis-bin 3e80-40d8 ENTER SQLGetDiagRecW
SQLSMALLINT 3 <SQL_HANDLE_STMT>

DIAG [01004] [Simba][ODBC] (10160) Output string data right truncation: string data is too big for the output data buffer and has been truncated. (10160)

@rherasm
Copy link

rherasm commented Apr 16, 2021

Additional information:

xxx.399 ERROR 21836 QueryExecutor::Execute: [Simba][Presto] (1070) Unknown Presto data type: row(timestamp timestamp,zoneid varchar)
xxx.399 ERROR 21836 StatementState::DoExecDirect: [Simba][Presto] (1070) Unknown Presto data type: row(timestamp timestamp,zoneid varchar)
xxx.399 ERROR 21836 StatementStateAllocated::SQLExecDirectW: [Simba][Presto] (1070) Unknown Presto data type: row(timestamp timestamp,zoneid varchar)
xxx.399 ERROR 21836 Statement::SQLExecDirectW: [Simba][Presto] (1070) Unknown Presto data type: row(timestamp timestamp,zoneid varchar)
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: age: CURLVERSION_FOURTH
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: version: 7.48.0
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: version_num: 471040
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: host: x86_64-pc-win32
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_IPV6: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_KERBEROS4: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_SSL: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_LIBZ: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_NTLM: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_GSSNEGOTIATE: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_DEBUG: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_ASYNCHDNS: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_SPNEGO: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_LARGEFILE: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_IDN: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_SSPI: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_CONV: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_CURLDEBUG: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_TLSAUTH_SRP: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_NTLM_WB: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_HTTP2: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_GSSAPI: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_KERBEROS5: ENABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_UNIX_SOCKETS: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: CURL_VERSION_PSL: DISABLED
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: ssl_version: OpenSSL/1.0.2n
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: ssl_version_num: 0
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: libz_version: 1.2.8
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: ares: (null)
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: ares_num: 0
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: libidn: (null)
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: iconv_ver_num: 0
xxx.399 DEBUG 21836 DSCURLUtils::LogCurlVersionInfo: libssh_version: (null)
xxx.399 INFO 21836 Statement::SQLGetStmtAttrW: Attribute: SQL_ATTR_APP_ROW_DESC (10010)
xxx.399 INFO 21836 Statement::SQLGetStmtAttrW: Attribute: SQL_ATTR_APP_PARAM_DESC (10011)
xxx.399 INFO 21836 Statement::SQLGetStmtAttrW: Attribute: SQL_ATTR_IMP_ROW_DESC (10012)
xxx.399 INFO 21836 Statement::SQLGetStmtAttrW: Attribute: SQL_ATTR_IMP_PARAM_DESC (10013)

Apr 16 10:39:05.824 ERROR 21836 QueryExecutor::Execute: [Simba][Presto] (1070) Unknown Presto data type: row(x double,y double,utmzone row(zone integer,north boolean))
Apr 16 10:39:05.824 ERROR 21836 StatementState::DoExecDirect: [Simba][Presto] (1070) Unknown Presto data type: row(x double,y double,utmzone row(zone integer,north boolean))
Apr 16 10:39:05.824 ERROR 21836 StatementStateAllocated::SQLExecDirectW: [Simba][Presto] (1070) Unknown Presto data type: row(x double,y double,utmzone row(zone integer,north boolean))
Apr 16 10:39:05.824 ERROR 21836 Statement::SQLExecDirectW: [Simba][Presto] (1070) Unknown Presto data type: row(x double,y double,utmzone row(zone integer,north boolean))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Crash/Data Corruption Data Provider Related to specific vector, raster or mesh data providers High Priority
Projects
None yet
Development

No branches or pull requests

2 participants