Use NEWID() inside function in SQL Server
In SQL Server, if we use the NEWID() function inside an user-defined function, it throws an error as “Invalid use of side-effecting or time-dependent operator in ‘newid()’ within a function.” For any reason, if we need to use the NEWID() function inside an user-defined function, we need to do some work around. In this post, […]