开发者

SQL proc diagram generating software of a program flow [closed]

开发者 https://www.devze.com 2022-12-18 18:43 出处:网络
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.

We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.

Closed 7 years ago.

Improve this question

I have a couple of very long procs in Oracle 2000+ lines with lots of calls. And I'd like to generate program flow Diagram (algorithm) for better understanding of the process for further refactoring.

It's not the code I wrote so I don't know the logic enough.

What would you advise to do in this case? I tried to d开发者_运维百科raw a text-like flow but it takes lots of time and still hard to cover all the logic for understanding.

The best approach I see would be flow chart generated from SQL proc with links to "jump" between code and chart.

UPDATE: Found couple of software doing the same:

  1. ClearSQL - makes CRUD diagrams, call map, and flow chart.

  2. Quest SQL Navigator Expert (using it now): it has Outline (makes code flow with ability to collapse-expand blocks of code - really cool one!), Code Explorer (enumerates all func, params with links ti SQL text - just in interface) features


There is a product, Code Visual to Flowchart, which can take code in various languages and do something like what you're describing. Unfortunately though Oracle doesn't appear to be in the list of supported languages, but Microsoft TSQL is; maybe you could at least translate your proc from Oracle into MS and use this to roughly visualize your proc's flow.

Failing that burnall's suggestion sounds like the best way to go, essentially divide and conquer.


I doubt that such tool, even if it exists could help better understanding. I think, time of big flow-charts is over.
I would advice to understand logic with step-by-step refactoring:
iteratively extract parts of procedure to smaller procedures and add tests.

0

精彩评论

暂无评论...
验证码 换一张
取 消