RE: how to tell who the caller of a procedure is
Date: Wed, 30 Jan 2008 12:33:49 -0500
I suggest "Structured Design (Fundamentals of a Discipline of Computer Program and Systems Design)" by Edward Yourdon and Larry L. Constantine, preferably the second edition, 1978, by Yourdon Press. Page 197 in particular talks about why sequential cohesion is almost always a bad idea.
As a fallback position, I suggest you use a number or a code as an argument, rather than the caller's name, so that next week when the fifth calling function appears, which happens to need to do exactly what the third one does, you can call the procedure with a "3" rather than having to update the procedure to do what "3" does with yet another calling function name.
Unless you're writing a profiler or an error exit traceback report, it is very unlikely you really want to know your caller's name, and even then it seems unlikely you would want to use the name as a process control.
Are you talking about a PL/SQL procedure?
From: oracle-l-bounce_at_freelists.org [mailto:oracle-l-bounce_at_freelists.org] On Behalf Of Oxnard Montalvo
Sent: Wednesday, January 30, 2008 12:02 PM To: Post to FreeList Oracle-L
Subject: how to tell who the caller of a procedure is
Oracle ver 10.2.0.3.0
I have a procedure which is called from one of four functions. Other than simply passing the name in as a varchar is there a way to have the procedure known the name. In my procedure I have one of four things to do based on who the calling function is.
http://www.freelists.org/webpage/oracle-l Received on Wed Jan 30 2008 - 11:33:49 CST