Q
Problem solve Get help with specific problems with your technologies, process and projects.

Packaging procedures with two schemas

My database has two schemas containing procedures and functions. According to good coding practices, these should be packaged up. My question is which schema to put them in?

I have a question regarding packages and procedures. My database has two schemas containing procedures and functions. According to good coding practices, these should be packaged up. My question is which schema to put them in? It really wasn't necessary for these to be in one of the schemas over the other, but that's the way it is right now. The procedures (some) reference tables in either or both of the schemas. What guidelines could you provide as to setting up the development (programmer's) environment where schemas are concerned and where the various objects should reside?
The first question that came to my mind is why are you using two schemas? If you have objects in SchemaA and objects in SchemaB, and those objects are constantly referencing the other schema, then doesn't it makes sense to put all of these in one schema, not two? It makes sense to me to use one schema. Of course, I could be missing a key factor which leads to two schemas.

Now to directly answer your question. With the information you have provided, it does not make any difference which schema you place your package in. One schema is going to have to reference objects in the other with schema-dot notation. Knowing that, does it make a difference to you? If not, then flip a coin to decide.

Dig Deeper on Oracle database design and architecture

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.

-ADS BY GOOGLE

SearchDataManagement

SearchBusinessAnalytics

SearchSAP

SearchSQLServer

TheServerSide.com

SearchDataCenter

SearchContentManagement

SearchHRSoftware

Close