Toad World® Forums

Is there a way to limit "search" in editor to a specific section?

Is it possible in any way to search for a text, that occurs between two lines, two bookmarks, within a procedure, or similar?

for instance, when you need to find all "to_char" in a procedure of 2500 lines, in a package of 9800 lines.

I can see your use case being pretty helpful on occasion. Toad currently doesn't have the ability to conduct searches given line/bookmark boundaries as you describe. If you don't mind entering this suggestion in our Idea Pond, that would be super.

Toad does have, however, a few search options that might get you a little closer to your end goal. Snap below shows options that allow you to confine a search to a highlighted section of text (e.g. between two of your bookmarks, for example) or from your cursor location as a starting point.

1 Like

Hey Gary, THAT is a super functionality! :slight_smile:

Thanks for the reply. I am aware of the suggestions, and use them frequently. But as you know, as soon as you hit “next”, the text is no longer selected and upon the next “next “, you might be out of the boundaries or the scope intended.

You are correct, and even if you performed a Find-All within your selection to list all found items within your selection, yeah, your bounded selection is lost if you need to conduct another search within those bounds.

Please define an entry for this use case in the Toad/Oracle Idea Pond, and guarantee you'll get a few user votes... :slight_smile:

Thanks. I have added a tag, and my (1) vote. Is more required to have this posted in Idea Pond?

Have you tried the sys view called all_source

Yes I know this view, but it's not very handy while editing code in Editor.

One could, I suppose, extract a portion of the code into the editor having selected by line numbers. But making changes to code and then compiling it, require that the entire package is present. Line numbers might be altered as soon as the code is changed, which means the entire cumbersome operation is repeated.