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

bad sql grammar #572

Open
patrickzurek opened this issue Oct 13, 2016 · 3 comments
Open

bad sql grammar #572

patrickzurek opened this issue Oct 13, 2016 · 3 comments

Comments

@patrickzurek
Copy link

JIRA issue created by: banderson
Originally opened: 2011-08-17 01:55 PM

Issue body:
(nt)

@patrickzurek
Copy link
Author

JIRA Coment by user: banderson
JIRA Timestamp: 2011-08-17 01:57 PM

Comment body:

full log file here:
http://www.extensiblecatalog.org/doc/MST/support/ahmed_MST_General_log.txt

26 Jul 2011 09:00:59,349 xc.mst.scheduling.WorkerThread:93 ERROR [Thread-16] -
org.springframework.jdbc.BadSqlGrammarException: PreparedStatementCallback; bad SQL grammar [ select straight_join r.record_id, r.oai_datestamp, r.format_id, r.status, r.type, r.prev_status , x.xml, max(u.date_updated) as date_updated from xc_testting2.record_updates u force index (idx_record_updates_record_id), xc_testting2.records r , xc_testting2.records_xml x where r.record_id = x.record_id and (r.record_id > ? or ? is null) and r.record_id = u.record_id and (u.date_updated >= ? or ? is null) and u.date_updated <= ? and status in ('A','D') group by u.record_id order by u.record_id limit 1000]; nested exception is com.mysql.jdbc.exceptions.MySQLSyntaxErrorException: Key 'idx_record_updates_record_id' doesn't exist in table 'u'
at org.springframework.jdbc.support.SQLStateSQLExceptionTranslator.doTranslate(SQLStateSQLExceptionTranslator.java:98)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:72)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
at org.springframework.jdbc.support.AbstractFallbackSQLExceptionTranslator.translate(AbstractFallbackSQLExceptionTranslator.java:80)
at org.springframework.jdbc.core.JdbcTemplate.execute(JdbcTemplate.java:602)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:636)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:665)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:673)
at org.springframework.jdbc.core.JdbcTemplate.query(JdbcTemplate.java:713)
at xc.mst.repo.RepositoryDAO.getRecords(RepositoryDAO.java:1112)
at xc.mst.repo.RepositoryDAO.getRecordsWSets(RepositoryDAO.java:1436)

@patrickzurek
Copy link
Author

JIRA Coment by user: banderson
JIRA Timestamp: 2011-08-19 08:12 PM

Comment body:

I don't know how to reproduce this, so I don't think it should go in 1.0. I'm not sure we even do anything in 1.1. It might be a thing of waiting until someone reports an actual user error. Or we could try to do a fix with just this info, but it's kind of like working in the dark.

@patrickzurek
Copy link
Author

JIRA Coment by user: jbrand
JIRA Timestamp: 2011-08-22 06:40 PM

Comment body:

Extra clarification: this was just one of the issues seen in the general log, not something directly reported as a problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant