Quick way to get a lot of unit prices

jensmurerjensmurer Member Posts: 3
edited 2017-06-21 in NAV Three Tier
We have to export pricelists in CSV-format multiple times a day. I do so by filtering Item-records and exporting these by a XMLPort. These pricelists contain - unsurprisingly - unit prices. To get the correct unit price per item and customer I have so far found CodeUnit 700 "Sales Price Calc. Mng." which calculates the unit price in Sales Lines in the Client. To do so programatically I have to create a temporary Sales Header, add a temporary Sales Line and pass this to FindSalesLinePrice of Codeunit 7000. This is by FAR to slow for the number of lines I have to create. One pricelistfile takes several minutes and there are nearly a thousand of them.
Is there a quicker way to get to the unit price for a Customer/Item-combination?

To be honest I already pushed the logic to get the Pricelist-receiving customers and their specific item-catalogs into SQL-views/-functions. But this data comes solely from two of our own modules. I don't want to transcribe the NAV-Standard-Codeunit's logic to SQL and have to look after this workaround in the future.

(Sorry for some weird Capitalization, my browser seems to have its own opinion towards that.)
regards

Jens Murer
Sign In or Register to comment.