Multi-statement Table Valued Function vs Inline Table Valued Function

A few examples to show, just incase: Inline Table Valued CREATE FUNCTION MyNS.GetUnshippedOrders() RETURNS TABLE AS RETURN SELECT a.SaleId, a.CustomerID, b.Qty FROM Sales.Sales a INNER JOIN Sales.SaleDetail b ON a.SaleId = b.SaleId INNER JOIN Production.Product c ON b.ProductID = c.ProductID WHERE a.ShipDate IS NULL GO Multi Statement Table Valued CREATE FUNCTION MyNS.GetLastShipped(@CustomerID INT) RETURNS @CustomerOrder … Read more

How is “=default” different from “{}” for default constructor and destructor?

I originally posted this as a question only about destructors, but now I’m adding consideration of the default constructor. Here’s the original question: If I want to give my class a destructor that is virtual, but is otherwise the same as what the compiler would generate, I can use =default: class Widget { public: virtual … Read more