Solved

What is the Logic/Formula for Calculating the "Unit Price" for An Item From the Two Given SQL Server Stored Procedures

Posted on 2011-03-15
1
316 Views
Last Modified: 2012-05-11
Could someone help me figure out what the logic is being used in these two attached stored procedures that calculate the "Unit Price"? I have been tracing back and forth through both of them for hours, and I cannot make heads or tales of what is being computed. If someone could explain to me how the information that is being passed to the stored procedures is used to calculate the "Unit Price", that would be exactly what I cannot figure out on my own. Any help would be greatly appreciated. (Note: As far as I can tell from reading the code, the spsaISOITEM stored procedure calls the spsoGetOrderPrice stored procedure. The end result of knowing this calculation will be a function that will be written in VB . NET 2010. If the stored procedure does need to be callled, please explain how to do this as this SQL code does not make much sense to me after reading through it.) spsaISOITEM.sql  spsoGetOrderPrice.sql
0
Comment
Question by:thenthorn1010
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
1 Comment
 
LVL 35

Accepted Solution

by:
James0628 earned 500 total points
ID: 35146440
I haven't tried to analyze this in detail, but spsaISOITEM executes spsoGetOrderPrice, and then spsoGetOrderPrice executes several other stored procedures.  I think you probably need to look at those.  spsoGetOrderPrice_Standard seems like the place to start.

 spsaISOITEM also gets a UnitPrice column from a function named dbo.fnimCalcItemNetCost, so that might also be worth a look.

 James
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

In this article we will get to know that how can we recover deleted data if it happens accidently. We really can recover deleted rows if we know the time when data is deleted by using the transaction log.
Shadow IT is coming out of the shadows as more businesses are choosing cloud-based applications. It is now a multi-cloud world for most organizations. Simultaneously, most businesses have yet to consolidate with one cloud provider or define an offic…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

749 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question