USE [db_triana]
GO
/****** Object:  UserDefinedFunction [dbo].[FA_FileExists]    Script Date: 2020/02/11 15:14:53 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO

create FUNCTION [dbo].[FA_FileExists](@path varchar(8000))  
RETURNS BIT  
AS  
BEGIN  
     DECLARE @result INT  
     EXEC master.dbo.xp_fileexist @path, @result OUTPUT  
     RETURN cast(@result as bit)  
END
/*
-- To allow advanced options to be changed.
EXEC sp_configure 'show advanced options', 1
GO
-- To update the currently configured value for advanced options.
RECONFIGURE
GO
-- To enable the feature.
EXEC sp_configure 'xp_cmdshell', 1
GO
-- To update the currently configured value for this feature.
RECONFIGURE
GO

*/

