select b.inventlocationid, itemid, a.availphysical, a.postedqty, a.postedvalue / case when a.postedqty = 0 then 1 else a.postedqty end as cost_avg_mj from inventsum a join inventdim b on b.inventdimid = a.inventdimid and b.dataareaid = a.dataareaid where a.itemid like 'S-%' and a.availphysical <> 0
Microsoft AX 2012, X++, C#, SQL server, SSRS, Java, JavaFX, Oracle, PL/SQL, Delphi - codes examples, step-by-step tutorials, experiences.
Tuesday, November 28, 2017
SQL SERVER, ORACLE - How use conditional logic in select, case statement
Prevention zero divide error:
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment