Bash uses "!" expression in its history substitution command. So it confuses your command with history substitution function and throws an error that it didn't find such a command in its history.
Try temporarily turning off history substitution feature and turning it back on when you're done with your operations involving "!" :
line 1:14 no viable alternative at input '[*].EFFECT!'
line 1:19 token recognition error at: '"'
java.lang.RuntimeException: java.lang.RuntimeException: LexerNoViableAltException('"')
at ca.mcgill.mcb.pcingola.snpSift.lang.LangFactory.compile(LangFactory.java:128)
at ca.mcgill.mcb.pcingola.snpSift.SnpSiftCmdFilter.parseExpression(SnpSiftCmdFilter.java:255)
at ca.mcgill.mcb.pcingola.snpSift.SnpSiftCmdFilter.run(SnpSiftCmdFilter.java:282)
at ca.mcgill.mcb.pcingola.snpSift.SnpSiftCmdFilter.run(SnpSiftCmdFilter.java:268)
at ca.mcgill.mcb.pcingola.snpSift.SnpSift.run(SnpSift.java:360)
at ca.mcgill.mcb.pcingola.snpSift.SnpSift.main(SnpSift.java:69)
Caused by: java.lang.RuntimeException: LexerNoViableAltException('"')
at ca.mcgill.mcb.pcingola.snpSift.lang.LangFactory$1.recover(LangFactory.java:117)
at org.antlr.v4.runtime.Lexer.nextToken(Lexer.java:169)
at org.antlr.v4.runtime.BufferedTokenStream.fetch(BufferedTokenStream.java:187)
at org.antlr.v4.runtime.BufferedTokenStream.sync(BufferedTokenStream.java:170)
at org.antlr.v4.runtime.BufferedTokenStream.consume(BufferedTokenStream.java:154)
at org.antlr.v4.runtime.Parser.consume(Parser.java:588)
at org.antlr.v4.runtime.DefaultErrorStrategy.consumeUntil(DefaultErrorStrategy.java:758)
at org.antlr.v4.runtime.DefaultErrorStrategy.recover(DefaultErrorStrategy.java:191)
at ca.mcgill.mcb.pcingola.snpSift.antlr.SnpSiftParser.expression(SnpSiftParser.java:778)
at ca.mcgill.mcb.pcingola.snpSift.antlr.SnpSiftParser.compilationUnit(SnpSiftParser.java:89)
at ca.mcgill.mcb.pcingola.snpSift.lang.LangFactory.compile(LangFactory.java:125)
... 5 more
Caused by: LexerNoViableAltException('"')
at org.antlr.v4.runtime.atn.LexerATNSimulator.failOrAccept(LexerATNSimulator.java:329)
at org.antlr.v4.runtime.atn.LexerATNSimulator.execATN(LexerATNSimulator.java:250)
at org.antlr.v4.runtime.atn.LexerATNSimulator.match(LexerATNSimulator.java:143)
at org.antlr.v4.runtime.Lexer.nextToken(Lexer.java:165)
... 14 more
I'm having a similar problem (SNPSift - Token Recognition Error). I've tried the suggestions in this thread, but it hasn't worked for me. My error is a result of the "@" being in my ID name.
I was wondering if you could post your final command line so I could try to imitate it and see if it works for me? (I realize you've said "I have used "=" again", but I want to ensure I'm using the "=" correctly like you).
Cheers.
ADD REPLY
• link
updated 22 months ago by
Ram
44k
•
written 9.6 years ago by
anon123
▴
10
1
Entering edit mode
Hi anon123,
"ANN[*].EFFECT != 'synonymous_variant'" is my command. But it is not work efficiently. Then I have translate my data to excel file then extract synonymous variants
instead of
=
, try usinghas
I have tried that as
Swap single quotes and double quotes.
Is it like that
"ANN[*].EFFECT !has "synonymous_variant""
It can not work
Bash uses "!" expression in its history substitution command. So it confuses your command with history substitution function and throws an error that it didn't find such a command in its history.
Try temporarily turning off history substitution feature and turning it back on when you're done with your operations involving "!" :