Stock Re-order Report SQL error

Hello,

    We are trying to implement a stock control system.   We have created a stock location, and entered various products at that location.  However, when I try to run the "stock re-order report", I get the following error:

 

Failed to generate report: Error executing SQL statement for : stock reorder report

 

Not sure what is going wrong.  Any suggestions welcomed.

 

Cahir

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.

Re: Stock Re-order Report SQL error

You're could be seeing the problem outlined here: http://www.openvpms.org/forum/1.7-alpha-failure-running-stock-reorder-re...

Try running the latest version from: http://www.openvpms.org/customisation/stock-reorder-report

-Tim

Re: Stock Re-order Report SQL error

Cahir - I have just had a play with the standard (in the 1.7B2 distribution) report.  Mine works happily.  It is attached.

One way to get more info is to use a text editor to grab the SQL code from the report and run this manually. If this is not easy for you yell and I will generate it for you - but first try the attached jrxml.

Regards, Tim G

AttachmentSize
stock reorder report.jrxml 28.87 KB

Re: Stock Re-order Report SQL error

Cheers Tim.  The new jrxml got rid of the SQL error.

 

However, the report always comes out with blank pages.  I have ticked "enable stock control" under practice location.  I created a test product and ticked "always order", and entered an amount under the "critical amount", so not sure what is happening.

 

If you can give me pointers on grabbing the SQL code I will do that to try to reach the bottom of this.

Cahir

Re: Stock Re-order Report SQL error

Cahir - I am willing to bet that your problem is preferencial suppliers.

a) in the CSH text for the Suppliers|Orders screen it says:

Generate Orders - run the Generate Order process to generate the orders - this will bring up a confirmation window to allow you to specify the supplier and stock location. See here for help if you are not generating the orders you expect.

b) the above 'here' link goes to http://www.openvpms.org/documentation/csh/1.7/product/tabs#supplier which says:

Generating Orders
Note that the system's 'Generate Orders' function will only generate orders for a product that has low stock if:

  • the product has a supplier specified and the supplier's Preferred box is checked
  • the Package Size set for the preferred supplier is greater than zero
  • the Ideal and Critical quantities must be greater than zero

Now the logic used by both the 'Generate Orders' function and the Stock Re-order report is the same.

Hence I am willing to bet that your problem was exactly the same as mine when I tried to duplicate your problem - blank output because none of the products had a preferred supplier set. [This is intentional in my case because we don't want ordering to occur until we specifically turn it on for specific products by setting the supplier as preferred. ie we are going to bring the system live with stock control running but we don't want to initially change how the was stuff is ordered - ie totally manually.]

If/when I get around to tarting up the stock reorder report I will put in a notice saying the above that gets printed if nothing gets printed.

Regards, Tim G

Re: Stock Re-order Report SQL error

Tim - once again you were correct.  I had not set the "preferred supplier" or package size under the "supplier tab" in the product listing.  Thank you for your help.  A warning screen would definitely help, as I had not thought to touch on the preferred supplier tab, just the stock locations tab.

Cahir

Syndicate content