You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At SQL Server we can create a function that can be linked to a table, then we just retrieve that column name to get computed values.
With a function like this
CREATE FUNCTION [dbo].[ufn_AlbumCount] (@ArtistId int)
RETURNS smallintASBEGIN
DECLARE @AlbumCount int;
SELECT @AlbumCount =COUNT(AlbumId)
FROM Albums
WHERE ArtistId = @ArtistId;
RETURN @AlbumCount;
END;
GO
At SQL Server we can create a function that can be linked to a table, then we just retrieve that column name to get computed values.
With a function like this
We add this function to the ref table
Then we just list the table that will give us the native fields plus a computed column
The text was updated successfully, but these errors were encountered: