bigcyy commented on PR #3410:
URL: https://github.com/apache/hertzbeat/pull/3410#issuecomment-2921493483

   > > 2. About the cache logic modification:
   > > Previously, if I needed to access the tokens (to extract the original 
SQL/PromQL string), I had to retrieve them from the cache again, which was 
redundant. So I refactored the code: now it first obtains the tokens, then 
generates the parse tree. This improves clarity and avoids repeated cache 
lookups.
   > 
   > how about use `ctx.selectSql().getText()` replace 
`tokens.getText(ctx.selectSql())`
   
   Hi, I tried using ctx.selectSql().getText(), but it doesn't return the full 
SQL string with spaces — I only get something like `select*fromtable`. However, 
when I use tokens.getText(ctx.selectSql()), it correctly returns `select * from 
table`.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscr...@hertzbeat.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@hertzbeat.apache.org
For additional commands, e-mail: notifications-h...@hertzbeat.apache.org

Reply via email to