Getting Routines/Procedures name

Answered

I'm using the new DasUtil and DatabaseSystem with a custom plugin, I'm initializing a TextFieldWithAutoCompletion and I want all the Store Procedures names to be initialized into it,
I was working in previous Intellij with the old database infrastructure which totally changed.

Can't seem to find an easy way to get all the store procedures names, can you give some code example
showing the proper way to do so?

0
4 comments

Hi!

Something like the following will do:

databaseSystem.getModel().traverser()
.expand(o -> o instanceof DasNamespace)
.filter(DasRoutine.class)
.map(o -> o.getName())
.toSet()
1

Thanks, works beautifully!

0

I've Installed the latest Intellij 2017.2.5 build and the code doesn't return the DasRoutine names as previously.

The .expand method doesn't return any value with the given condition, can you tell me how to change

the code elegantly so it works as before?

0

It works as before for me.

Please place a breakpoint in the "expand" lambda and see what's there.

If it is not hit then some more debugging is due.

 

0

Please sign in to leave a comment.