When I make it a lexer rule I have other issues with my grammar. These were working before:
Contents of file: C:\OLAP_TO_RELATIONAL\TestINP\bigcond.txt SELECT "[Measures].[Unit Sales]" , "[Store].[Store Name]_PROP_[Store Manager]", "[Store].[Store Name]_PROP_[Store Type]", "[Product].[Product Name]", "[Store].[Store Name]" FROM "Store" WHERE "[Measures].[Unit Sales]" > 10 AND "[Store].[Store Name]_PROP_[Store Type]" = "Supermarket" AND "[Store].[Store Name]_PROP_[Store Sqft]" > 30000 End of file: C:\OLAP_TO_RELATIONAL\TestINP\bigcond.txt line 1:7 no viable alternative at input '"[Measures].[Unit Sales]"' line 2:3 no viable alternative at input '"[Store].[Store Name]_PROP_[Store Manag er]"' line 3:3 no viable alternative at input '"[Store].[Store Name]_PROP_[Store Type] "' line 4:3 no viable alternative at input '"[Product].[Product Name]"' line 5:3 no viable alternative at input '"[Store].[Store Name]"' line 6:5 no viable alternative at input '"Store"' That is why I attempted to use a production rule. I had tried lexer rule first. I have other rules that may start with a double quote but do not allow the same characters as DQTEXT. I am still confused by the resulting tree of my original attempt. (MDX_FUNC " a g g g g g g gggggggggggggggggggggggggx ") was printed by ToStringTree(), but when I loop through all the children hanging off the MDX_FUNC node, I only see 10 children (ie none of the spaces). The Children property must be filtering out the hidden channel. Thanks, For the suggestions -----Original Message----- From: Gavin Lambert [mailto:an...@mirality.co.nz] Sent: Thursday, July 02, 2009 3:52 PM To: Penningroth, Mark; John B. Brodie Cc: antlr-inter...@antlr.org Subject: Re: [antlr-interest] Question about preserving spaces in quoted strings At 07:27 3/07/2009, Penningroth, Mark wrote: >dqcon > : '"' > ( (~'"')=> > ( ('\\')=>'\\'. > | . > ) > )* > '"'; Like you were already told, this should be a lexer rule: DQTEXT : '"' ('\\' . | ~('\\' | '"'))* '"' ; List: http://www.antlr.org/mailman/listinfo/antlr-interest Unsubscribe: http://www.antlr.org/mailman/options/antlr-interest/your-email-address --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "il-antlr-interest" group. To post to this group, send email to il-antlr-interest@googlegroups.com To unsubscribe from this group, send email to il-antlr-interest+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/il-antlr-interest?hl=en -~----------~----~----~----~------~----~------~--~---