google-code-export / sqljet

Automatically exported from code.google.com/p/sqljet
0 stars 1 forks source link

sqlite accepts '$' in identifiers but sqljet does not #116

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
OS: Windows XP sp 3
SQLjet version: 1.0.0.b616

1. Create a sqlite database using the sqlite command line tool, and have a
table named 'my$table' or something else with a '$' in it (not as first
char, this is not accepted by sqlite either)
2. Try to open this database using sqljet database browser
3. There is an exception thrown:

org.tmatesoft.sqljet.core.internal.lang.SqlJetParserException: [line 1:33]
mismatched input '$' expecting ON
    at
org.tmatesoft.sqljet.core.internal.lang.SqlParser.displayRecognitionError(SqlPar
ser.java:265)
    at org.antlr.runtime.BaseRecognizer.reportError(BaseRecognizer.java:186)
    at
org.tmatesoft.sqljet.core.internal.lang.SqlParser.create_index_stmt(SqlParser.ja
va:13137)
    at
org.tmatesoft.sqljet.core.internal.schema.SqlJetSchema.parseIndex(SqlJetSchema.j
ava:249)
    at
org.tmatesoft.sqljet.core.internal.schema.SqlJetSchema.readShema(SqlJetSchema.ja
va:212)
    at
org.tmatesoft.sqljet.core.internal.schema.SqlJetSchema.init(SqlJetSchema.java:11
0)
    at
org.tmatesoft.sqljet.core.internal.schema.SqlJetSchema.<init>(SqlJetSchema.java:
100)
    at org.tmatesoft.sqljet.core.table.SqlJetDb$1.runWithLock(SqlJetDb.java:112)
    at org.tmatesoft.sqljet.core.table.SqlJetDb.runWithLock(SqlJetDb.java:212)
    at org.tmatesoft.sqljet.core.table.SqlJetDb.<init>(SqlJetDb.java:106)
    at org.tmatesoft.sqljet.core.table.SqlJetDb.open(SqlJetDb.java:131)
    at
org.tmatesoft.sqljet.browser.core.schema.SchemaComponent.open(SchemaComponent.ja
va:50)
    at
org.tmatesoft.sqljet.browser.core.BrowserComponentManager.stateChanged(BrowserCo
mponentManager.java:220)
    at
org.tmatesoft.sqljet.browser.core.BrowserComponentManager.open(BrowserComponentM
anager.java:195)
    at
org.tmatesoft.sqljet.browser.core.actions.OpenAction.actionPerformed(OpenAction.
java:68)
    at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
    at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
    at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
    at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
    at javax.swing.AbstractButton.doClick(Unknown Source)
    at javax.swing.plaf.basic.BasicMenuItemUI.doClick(Unknown Source)
    at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(Unknown
Source)
    at java.awt.Component.processMouseEvent(Unknown Source)
    at javax.swing.JComponent.processMouseEvent(Unknown Source)
    at java.awt.Component.processEvent(Unknown Source)
    at java.awt.Container.processEvent(Unknown Source)
    at java.awt.Component.dispatchEventImpl(Unknown Source)
    at java.awt.Container.dispatchEventImpl(Unknown Source)
    at java.awt.Component.dispatchEvent(Unknown Source)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
    at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
    at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
    at java.awt.Container.dispatchEventImpl(Unknown Source)
    at java.awt.Window.dispatchEventImpl(Unknown Source)
    at java.awt.Component.dispatchEvent(Unknown Source)
    at java.awt.EventQueue.dispatchEvent(Unknown Source)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
    at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
    at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
    at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
    at java.awt.EventDispatchThread.run(Unknown Source)
Caused by: MismatchedTokenException(180!=128)
    at
org.tmatesoft.sqljet.core.internal.lang.SqlParser.recoverFromMismatchedToken(Sql
Parser.java:258)
    at org.antlr.runtime.BaseRecognizer.match(BaseRecognizer.java:115)
    at
org.tmatesoft.sqljet.core.internal.lang.SqlParser.create_index_stmt(SqlParser.ja
va:12982)
    ... 39 more

Original issue reported on code.google.com by f...@mcs.be on 19 Nov 2009 at 9:00

GoogleCodeExporter commented 9 years ago

Original comment by sergey.s...@gmail.com on 19 Nov 2009 at 4:27

GoogleCodeExporter commented 9 years ago
Fixed.

Committed revision 759 (trunk).

Should be included into 1.0.1 RC2.

Original comment by sergey.s...@gmail.com on 19 Nov 2009 at 4:39

GoogleCodeExporter commented 9 years ago
Actually will be included in 1.0.1 RC3 :)

Original comment by kit...@gmail.com on 19 Nov 2009 at 11:12