View CRM-ReCreate-AuditBase-Partitioning.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Change DB | |
use [org_MSCRM] | |
-- 1. PartitionCreate | |
-- Drop any existing partition function and scheme | |
IF EXISTS (SELECT * FROM sys.partition_schemes WHERE name = N'AuditPScheme') | |
BEGIN | |
print 'Dropping Partition Scheme AuditPScheme' | |
DROP PARTITION SCHEME [AuditPScheme] |
View POA-transfer.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Based on http://support2.microsoft.com/kb/2664150 | |
-- Change DB | |
use [test_MSCRM] | |
BEGIN TRY | |
IF EXISTS (SELECT * FROM sys.sysobjects | |
WHERE id = object_id(N'[dbo].[PrincipalObjectAccess_New]') | |
AND ObjectProperty(id, N'IsUserTable') = 1) | |
RAISERROR ('ERROR: PrincipalObjectAccess_New already exists!!!', 16,-1); |
View gist:860331
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# -*- coding: utf-8 -*- | |
import os | |
import sys | |
import zipfile | |
filename = 'list.txt' | |
archname = 'desktop.zip' | |
outdir = os.path.curdir | |
inputset = set() |