mirror of
https://github.com/bitwarden/server.git
synced 2024-12-10 15:13:29 +01:00
22 lines
463 B
MySQL
22 lines
463 B
MySQL
|
IF OBJECT_ID('[dbo].[OrganizationUser_ReadByMinimumRole]') IS NOT NULL
|
|||
|
BEGIN
|
|||
|
DROP PROCEDURE [dbo].[OrganizationUser_ReadByMinimumRole]
|
|||
|
END
|
|||
|
GO
|
|||
|
|
|||
|
CREATE PROCEDURE [dbo].[OrganizationUser_ReadByMinimumRole]
|
|||
|
@OrganizationId UNIQUEIDENTIFIER,
|
|||
|
@MinRole TINYINT
|
|||
|
AS
|
|||
|
BEGIN
|
|||
|
SET NOCOUNT ON
|
|||
|
|
|||
|
SELECT
|
|||
|
*
|
|||
|
FROM
|
|||
|
[dbo].[OrganizationUserUserDetailsView]
|
|||
|
WHERE
|
|||
|
OrganizationId = @OrganizationId
|
|||
|
AND [Type] <= @MinRole
|
|||
|
END
|