SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

IF OBJECT_ID('[dbo].[sp_GetJsonForMobileTanarProfil]') IS NOT NULL 
BEGIN
  DROP PROCEDURE [dbo].[sp_GetJsonForMobileTanarProfil]
END
GO

CREATE PROCEDURE [dbo].[sp_GetJsonForMobileTanarProfil]
	@tanarId INT
AS
BEGIN
	SET NOCOUNT ON;	

  SELECT 
      felhasznalo.ID AS                   'id'
      ,felhasznalo.C_NYOMTATASINEV AS     'nev'
      ,'' AS                              'kep'
  FROM T_FELHASZNALO felhasznalo
  WHERE
      felhasznalo.TOROLT = 'F' AND felhasznalo.ID = @tanarId
  FOR JSON PATH

END