Toad World® Forums

Code Annotations / Warnings in Editor


#1

Hi,

I’m using Toad 13.0.0.80 and I noticed, that sometimes the Code Annotations Toad makes for Rule 4603 (delivered with Toad by default) are off one line and doubled.
grafik

I only noticed this for Insert and Merge Statements and it seems to depend on the formatting.

I have no Idea what to change to make it work correctly.

Do you have any hints for me?


#2

Hey Claudia,

It looks like the XPath expression for rule 4603 may need a bit of tweaking. I’ll let our parser guy know about this. In the meantime, inside Toad 13.0, you could temporarily edit the XPath expression for that rule to be:

//EXPR[@cat=“concat”] [count(LITERAL[@type=“text”]) = 2] / LITERAL[2], (:lefmost two items, is the most inner concat expr:)
//EXPR[@cat=“concat”] / EXPR[@cat=“concat”] [following-sibling::LITERAL[@type=“text”]] [*[last()][name() = “LITERAL”][@type=“text”]]
/ following-sibling::LITERAL[@type=“text”] (: concat expr where both its last elem and its following sibling are literals:)

When you decide to move to Toad 13.1, after it’s released, that customization will be moved to its own custom user rule. In that case, you’ll need to clone the “Top 20” ruleset, deselect rule 4603 from that new ruleset, and include the new custom Rule ID.

Let us know how that works and if there’s anything else we can do!

-John


#3

Hello John,

thanks for your help. It works fine for my example.
Now one of the triggers in the given test code is not found anymore though.
grafik

Best regards
Claudia