Shigeki Kobayashi created CONNECTORS-511:
--------------------------------------------

             Summary: Crawling MySQL with the latest MySQL JDBC driver fails
                 Key: CONNECTORS-511
                 URL: https://issues.apache.org/jira/browse/CONNECTORS-511
             Project: ManifoldCF
          Issue Type: Task
          Components: JDBC connector
            Reporter: Shigeki Kobayashi


Using "AS" in Select queries in SeedQuery and DataQuery causes error depending 
on MySQL-JDBC drivers' versions.

Env:
- ManifoldCF0.5
- Solr3.6
- MySQL5.5 

Example:

 SeedQuery:SELECT idfield AS $(IDCOLUMN) FROM documenttable

Error Message:
  Bad seed query; doesn't return $(IDCOLUMN) column. Try using quotes around 
$(IDCOLUMN) variable, e.g. "$(IDCOLUMN)".

Cause of Error:
 MySQL JDBC drivers of over version 5.1 seem to have a bug that causes error 
when you use "AS" in Select to put an alias for a column.

Versions of MySQL Connector:
 mysql-connector-java-5.0.8.jar  -> OK
 mysql-connector-java-5.1.18.jar -> No Good (Error)
 mysql-connector-java-5.1.21.jar -> No Good (Error)

Exception:
Using function  (e.g. SELECT sysdate() AS ..) or fixed strings  (e.g. SELECT 
"fixed string" AS ..) followed by "AS" does not cause error.


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


Reply via email to