SELECT name, physical_name
FROM sys.master_files
WHERE database_id = DB_ID('GrpInsurance');
GO
 

USE master;
GO
ALTER DATABASE GrpInsurance
MODIFY FILE
(
    NAME = GrpInsurance_Log,
    FILENAME = N'D:\Database\GrpInsurance_log.ldf'
);
GO
 


USE master
GO
ALTER DATABASE YourDatabaseName
SET OFFLINE WITH ROLLBACK IMMEDIATE
GO


USE master
GO
ALTER DATABASE YourDatabaseName
SET ONLINE
GO