diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 76aae6130d..c31aa775e5 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -2,7 +2,7 @@ # the repo. Unless a later match takes precedence, # @global-owner1 and @global-owner2 will be requested for # review when someone opens a pull request. -* @devinleighsmith @jdtoombs @asanchezr @rpbcg @FuriousLlama @rafaelponcedeleon @stairaku +* @devinleighsmith @asanchezr @FuriousLlama @stairaku @Maheshbabu28 # Order is important; the last matching pattern takes the most # precedence. When someone opens a pull request that only diff --git a/Makefile b/Makefile index 26abc51204..17eca16787 100644 --- a/Makefile +++ b/Makefile @@ -185,7 +185,11 @@ start-infra: ## Starts infrastructure containers (e.g. keycloak, database, geose @echo "$(P) Starting up infrastructure containers..." @"$(MAKE)" start n="keycloak database geoserver" -start up: ## Runs the local containers (n=service name) +start: ## Starts the local containers (n=service name) + @echo "$(P) Starting client and server containers..." + @docker-compose start $(n) + +up: ## Runs the local containers (n=service name) @echo "$(P) Running client and server..." @docker-compose up -d --no-recreate $(n) diff --git a/auth/keycloak/Dockerfile b/auth/keycloak/Dockerfile index 010b10e4ee..71a90ab025 100644 --- a/auth/keycloak/Dockerfile +++ b/auth/keycloak/Dockerfile @@ -1,7 +1,7 @@ # >docker build -t keycloak . # >docker run --env-file=../../.env -d keycloak # https://hub.docker.com/r/jboss/keycloak/ -FROM jboss/keycloak:11.0.0 +FROM jboss/keycloak:16.1.1 EXPOSE 8080 diff --git a/backend/Pims.sln b/backend/Pims.sln index c51c92af96..b2365f8c86 100644 --- a/backend/Pims.sln +++ b/backend/Pims.sln @@ -58,7 +58,9 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Pims.Geocoder", "geocoder\P EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Pims.Ltsa", "ltsa\Pims.Ltsa.csproj", "{1ED5DF03-7784-44EC-B02B-516167210CCF}" EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Pims.Dal.Mock.Test", "tests\unit\mockdal\Pims.Dal.Mock.Test.csproj", "{2C31E92C-9C95-45FF-9F95-928C2962F37D}" +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Pims.Dal.Mock.Test", "tests\unit\mockdal\Pims.Dal.Mock.Test.csproj", "{2C31E92C-9C95-45FF-9F95-928C2962F37D}" +EndProject +Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Pims.Av", "clamav\Pims.Av.csproj", "{16C06BDA-112F-4D04-82FF-0BBE45072372}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution @@ -214,6 +216,18 @@ Global {2C31E92C-9C95-45FF-9F95-928C2962F37D}.Release|x64.Build.0 = Release|Any CPU {2C31E92C-9C95-45FF-9F95-928C2962F37D}.Release|x86.ActiveCfg = Release|Any CPU {2C31E92C-9C95-45FF-9F95-928C2962F37D}.Release|x86.Build.0 = Release|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Debug|Any CPU.Build.0 = Debug|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Debug|x64.ActiveCfg = Debug|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Debug|x64.Build.0 = Debug|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Debug|x86.ActiveCfg = Debug|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Debug|x86.Build.0 = Debug|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Release|Any CPU.ActiveCfg = Release|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Release|Any CPU.Build.0 = Release|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Release|x64.ActiveCfg = Release|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Release|x64.Build.0 = Release|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Release|x86.ActiveCfg = Release|Any CPU + {16C06BDA-112F-4D04-82FF-0BBE45072372}.Release|x86.Build.0 = Release|Any CPU EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE @@ -232,6 +246,7 @@ Global {BF7450E8-B3C5-46FB-BEC1-C5FC1C5964DC} = {5237F8A4-67F5-4751-B8B2-B93A06791480} {1ED5DF03-7784-44EC-B02B-516167210CCF} = {5237F8A4-67F5-4751-B8B2-B93A06791480} {2C31E92C-9C95-45FF-9F95-928C2962F37D} = {3D70B211-74A8-484C-9B86-B0A2835C71E7} + {16C06BDA-112F-4D04-82FF-0BBE45072372} = {5237F8A4-67F5-4751-B8B2-B93A06791480} EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {3433C5DD-DC49-4A96-A1AE-90C1A1EBA87C} diff --git a/backend/api/Areas/Notes/Controllers/NoteController.cs b/backend/api/Areas/Notes/Controllers/NoteController.cs index c81bfeeed1..893e545945 100644 --- a/backend/api/Areas/Notes/Controllers/NoteController.cs +++ b/backend/api/Areas/Notes/Controllers/NoteController.cs @@ -1,4 +1,5 @@ +using System.Collections.Generic; using MapsterMapper; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Http; @@ -8,7 +9,6 @@ using Pims.Api.Policies; using Pims.Api.Services; using Pims.Dal.Security; -using System.Collections.Generic; using Swashbuckle.AspNetCore.Annotations; namespace Pims.Api.Areas.Notes.Controllers @@ -64,12 +64,12 @@ public IActionResult AddNote(NoteType type, [FromBody] EntityNoteModel noteModel } /// - /// Get the notes for the specified type and entity id. + /// Gets a collection of notes for the specified type and owner id. /// /// Used to identify note type. /// Used to identify note's parent entity. /// - [HttpGet("{type}/{entityId}")] + [HttpGet("{type}/owner/{entityId:long}")] [Produces("application/json")] [HasPermission(Permissions.NoteView)] [ProducesResponseType(typeof(IEnumerable), 200)] @@ -81,18 +81,53 @@ public IActionResult GetNotes(NoteType type, long entityId) return new JsonResult(mappedNotes); } + /// + /// Retrieves the note with the specified id. + /// + /// Used to identify note type. + /// Used to identify the note. + /// + [HttpGet("{type}/{noteId:long}")] + [Produces("application/json")] + [HasPermission(Permissions.NoteView)] + [ProducesResponseType(typeof(NoteModel), 200)] + [SwaggerOperation(Tags = new[] { "note" })] + public IActionResult GetNoteById(NoteType type, long noteId) + { + var note = _noteService.GetById(noteId); + return new JsonResult(note); + } + + /// + /// Updates the note with the specified id. + /// + /// Used to identify note type. + /// Used to identify the note. + /// The updated note values. + /// + [HttpPut("{type}/{noteId:long}")] + [Produces("application/json")] + [HasPermission(Permissions.NoteEdit)] + [ProducesResponseType(typeof(NoteModel), 200)] + [SwaggerOperation(Tags = new[] { "note" })] + public IActionResult UpdateNote(NoteType type, long noteId, [FromBody] NoteModel noteModel) + { + var updatedNote = _noteService.Update(noteModel); + return new JsonResult(updatedNote); + } + /// /// Deletes the note for the specified type. /// /// Used to identify note type. /// Used to identify the note and delete it. /// - [HttpDelete("{type}/{noteId}")] + [HttpDelete("{type}/{noteId:long}")] [Produces("application/json")] [HasPermission(Permissions.NoteDelete)] [ProducesResponseType(typeof(bool), 200)] [SwaggerOperation(Tags = new[] { "note" })] - public IActionResult DeleteNote(NoteType type, int noteId) + public IActionResult DeleteNote(NoteType type, long noteId) { _noteService.DeleteNote(type, noteId); return new JsonResult(true); diff --git a/backend/api/Areas/Property/Controllers/PropertyController.cs b/backend/api/Areas/Property/Controllers/PropertyController.cs index 87ab2bc7c4..3cd0de7606 100644 --- a/backend/api/Areas/Property/Controllers/PropertyController.cs +++ b/backend/api/Areas/Property/Controllers/PropertyController.cs @@ -78,17 +78,17 @@ public IActionResult GetProperty(int id) } /// - /// Get the property associations for the specified unique 'pid'. + /// Get the property associations for the specified unique 'id'. /// /// - [HttpGet("{pid}/associations")] + [HttpGet("{id}/associations")] [HasPermission(Permissions.PropertyView)] [Produces("application/json")] [ProducesResponseType(typeof(PropertyAssociationModel), 200)] [SwaggerOperation(Tags = new[] { "property" })] - public IActionResult GetPropertyAssociationsWithPid(string pid) + public IActionResult GetPropertyAssociationsWithId(long id) { - var property = _pimsRepository.Property.GetAssociations(pid); + var property = _pimsRepository.Property.GetAssociations(id); return new JsonResult(_mapper.Map(property)); } @@ -96,17 +96,17 @@ public IActionResult GetPropertyAssociationsWithPid(string pid) #region Concept Endpoints /// - /// Get the property for the specified unique 'pid'. + /// Get the property for the specified unique 'id'. /// /// - [HttpGet("concept/{pid}")] + [HttpGet("concept/{id}")] [HasPermission(Permissions.PropertyView)] [Produces("application/json")] [ProducesResponseType(typeof(IEnumerable), 200)] [SwaggerOperation(Tags = new[] { "property" })] - public IActionResult GetConceptPropertyWithPid(string pid) + public IActionResult GetConceptPropertyWithId(long id) { - var property = _pimsService.PropertyService.GetByPid(pid); + var property = _pimsService.PropertyService.GetById(id); return new JsonResult(_mapper.Map(property)); } @@ -114,7 +114,7 @@ public IActionResult GetConceptPropertyWithPid(string pid) /// Update the specified property, and attached properties. /// /// - [HttpPut("concept/{pid}")] + [HttpPut("concept/{id}")] [HasPermission(Permissions.PropertyEdit)] [Produces("application/json")] [ProducesResponseType(typeof(Pims.Api.Models.Concepts.PropertyModel), 200)] diff --git a/backend/api/Areas/Tools/Controllers/GeocoderController.cs b/backend/api/Areas/Tools/Controllers/GeocoderController.cs index 2de58b5cf5..94bf4f4c93 100644 --- a/backend/api/Areas/Tools/Controllers/GeocoderController.cs +++ b/backend/api/Areas/Tools/Controllers/GeocoderController.cs @@ -87,7 +87,7 @@ public async Task FindPidsAsync(Guid siteId) /// /// Make a request to Data BC Geocoder for the property that is the closest to the given lat/lng point. /// - /// The lat/lng of the desired property. + /// The lat/lng of the desired property in the format 'lng,lat'. /// A single address match. [HttpGet("nearest")] [Produces("application/json")] diff --git a/backend/api/Controllers/DocumentController.cs b/backend/api/Controllers/DocumentController.cs index b2c30d52ae..bc449f24b3 100644 --- a/backend/api/Controllers/DocumentController.cs +++ b/backend/api/Controllers/DocumentController.cs @@ -1,4 +1,4 @@ -using System.Threading.Tasks; +using MapsterMapper; using Microsoft.AspNetCore.Authorization; using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Mvc; @@ -11,6 +11,9 @@ using Pims.Dal.Entities; using Pims.Dal.Security; using Swashbuckle.AspNetCore.Annotations; +using System.Collections.Generic; +using System.Threading.Tasks; +using Concepts = Pims.Api.Models.Concepts; namespace Pims.Api.Controllers { @@ -27,6 +30,7 @@ public class DocumentController : ControllerBase #region Variables private readonly IDocumentService _documentService; private readonly IDocumentSyncService _documentSyncService; + private readonly IMapper _mapper; #endregion #region Constructors @@ -35,10 +39,12 @@ public class DocumentController : ControllerBase /// /// /// - public DocumentController(IDocumentService documentService, IDocumentSyncService documentSyncService) + /// + public DocumentController(IDocumentService documentService, IDocumentSyncService documentSyncService, IMapper mapper) { _documentService = documentService; _documentSyncService = documentSyncService; + _mapper = mapper; } #endregion @@ -91,9 +97,9 @@ public IActionResult DownloadFile(int documentId, int fileId) [HasPermission(Permissions.PropertyAdd)] [ProducesResponseType(typeof(ExternalResult), 200)] [SwaggerOperation(Tags = new[] { "documents" })] - public IActionResult UploadDocument([FromForm] int documentType, [FromForm] IFormFile file) + public async Task UploadDocument([FromForm] int documentType, [FromForm] IFormFile file) { - var result = _documentService.UploadDocument(documentType, file); + var result = await _documentService.UploadDocumentAsync(documentType, file); return new JsonResult(result); } @@ -136,6 +142,22 @@ public async Task SyncDocumentTypes() return new JsonResult(result); } + /// + /// Get the document types. + /// + /// + [HttpGet("document-types")] + [HasPermission(Permissions.DocumentView)] + [Produces("application/json")] + [ProducesResponseType(typeof(List), 200)] + [SwaggerOperation(Tags = new[] { "document-types" })] + public IActionResult GetDocumentTypeItems() + { + var documentTypes = _documentService.GetPimsDocumentTypes(); + var mappedDocumentTypes = _mapper.Map>(documentTypes); + return new JsonResult(mappedDocumentTypes); + } + #endregion } } diff --git a/backend/api/Controllers/LookupController.cs b/backend/api/Controllers/LookupController.cs index 490ea07b18..ade3ec0aea 100644 --- a/backend/api/Controllers/LookupController.cs +++ b/backend/api/Controllers/LookupController.cs @@ -113,6 +113,7 @@ public IActionResult GetAll() var volumeUnitTypes = _mapper.Map(_pimsService.Lookup.GetPropertyVolumeUnitTypes()); var propertyVolumetricTypes = _mapper.Map(_pimsService.Lookup.GetPropertyVolumetricTypes()); var pphStatusType = _mapper.Map(_pimsService.Lookup.GetPPHStatusType()); + var documentStatusTypes = _mapper.Map(_pimsService.Lookup.GetDocumentStatusTypes()); var codes = new List(); codes.AddRange(areaUnitTypes); @@ -151,7 +152,8 @@ public IActionResult GetAll() codes.AddRange(volumeUnitTypes); codes.AddRange(propertyVolumetricTypes); codes.AddRange(pphStatusType); - + codes.AddRange(documentStatusTypes); + return new JsonResult(codes); } #endregion diff --git a/backend/api/Helpers/Middleware/ErrorHandlingMiddleware.cs b/backend/api/Helpers/Middleware/ErrorHandlingMiddleware.cs index 2e78396a9b..2fe349de45 100644 --- a/backend/api/Helpers/Middleware/ErrorHandlingMiddleware.cs +++ b/backend/api/Helpers/Middleware/ErrorHandlingMiddleware.cs @@ -182,6 +182,13 @@ private async Task HandleExceptionAsync(HttpContext context, Exception ex) _logger.LogError(ex, "Ltsa unhandled exception."); } + else if (ex is AvException) + { + code = HttpStatusCode.BadRequest; + message = ex.Message; + + _logger.LogError(ex, "clamav unhandled exception."); + } else if (ex is HttpClientRequestException || ex is ProxyRequestException) { var exception = ex as HttpClientRequestException; diff --git a/backend/api/Models/Concepts/Document/DocumentMap.cs b/backend/api/Models/Concepts/Document/DocumentMap.cs new file mode 100644 index 0000000000..81f3de949e --- /dev/null +++ b/backend/api/Models/Concepts/Document/DocumentMap.cs @@ -0,0 +1,19 @@ +using Mapster; +using Entity = Pims.Dal.Entities; + +namespace Pims.Api.Models.Concepts.Document +{ + public class DocumentMap : IRegister + { + public void Register(TypeAdapterConfig config) + { + config.NewConfig() + .PreserveReference(true) + .Map(dest => dest.Id, src => src.DocumentId) + .Map(dest => dest.DocumentType, src => src.DocumentType) + .Map(dest => dest.DocumentStatusTypeCode, src => src.DocumentStatusTypeCodeNavigation) + .Map(dest => dest.FileName, src => src.FileName) + .Map(dest => dest.RowVersion, src => src.ConcurrencyControlNumber); + } + } +} diff --git a/backend/api/Models/Concepts/Document/DocumentModel.cs b/backend/api/Models/Concepts/Document/DocumentModel.cs new file mode 100644 index 0000000000..ec8a4c68fd --- /dev/null +++ b/backend/api/Models/Concepts/Document/DocumentModel.cs @@ -0,0 +1,33 @@ + +namespace Pims.Api.Models.Concepts +{ + /// + /// DocumentModel class, provides a model to represent document associated to entities. + /// + public class DocumentModel : BaseAppModel + { + + #region Properties + + /// + /// get/set - Document Id. + /// + public int Id { get; set; } + + /// + /// get/set - Document Type. + /// + public DocumentTypeModel DocumentType { get; set; } + + /// + /// get/set - The document status type. + /// + public TypeModel DocumentStatusTypeCode { get; set; } + + /// + /// get/set - Document/File Name. + /// + public string FileName { get; set; } + #endregion + } +} diff --git a/backend/api/Models/Concepts/Document/DocumentTypeMap.cs b/backend/api/Models/Concepts/Document/DocumentTypeMap.cs new file mode 100644 index 0000000000..72b71fad6a --- /dev/null +++ b/backend/api/Models/Concepts/Document/DocumentTypeMap.cs @@ -0,0 +1,17 @@ +using Mapster; +using Entity = Pims.Dal.Entities; + +namespace Pims.Api.Models.Concepts.Document +{ + public class DocumentTypeMap : IRegister + { + public void Register(TypeAdapterConfig config) + { + config.NewConfig() + .PreserveReference(true) + .Map(dest => dest.Id, src => src.DocumentTypeId) + .Map(dest => dest.DocumentType, src => src.DocumentType) + .Inherits(); + } + } +} diff --git a/backend/api/Models/Concepts/Document/DocumentTypeModel.cs b/backend/api/Models/Concepts/Document/DocumentTypeModel.cs new file mode 100644 index 0000000000..1c27eedc85 --- /dev/null +++ b/backend/api/Models/Concepts/Document/DocumentTypeModel.cs @@ -0,0 +1,24 @@ + +namespace Pims.Api.Models.Concepts +{ + /// + /// DocumentTypeModel class, provides a model to represent document associated to entities. + /// + public class DocumentTypeModel : BaseAppModel + { + + #region Properties + + /// + /// get/set - Document Type Id. + /// + public int Id { get; set; } + + /// + /// get/set - Document Type. + /// + public string DocumentType { get; set; } + + #endregion + } +} diff --git a/backend/api/Models/Concepts/Note/NoteMap.cs b/backend/api/Models/Concepts/Note/NoteMap.cs index d0a4e79325..3152f3c2f2 100644 --- a/backend/api/Models/Concepts/Note/NoteMap.cs +++ b/backend/api/Models/Concepts/Note/NoteMap.cs @@ -11,7 +11,6 @@ public void Register(TypeAdapterConfig config) .PreserveReference(true) .Map(dest => dest.Id, src => src.Id) .Map(dest => dest.Note, src => src.NoteTxt) - .Map(dest => dest.RowVersion, src => src.ConcurrencyControlNumber) .Inherits(); config.NewConfig() diff --git a/backend/api/Pims.Api.csproj b/backend/api/Pims.Api.csproj index 900e76978e..03d80855f5 100644 --- a/backend/api/Pims.Api.csproj +++ b/backend/api/Pims.Api.csproj @@ -2,8 +2,8 @@ 0ef6255f-9ea0-49ec-8c65-c172304b4926 - 1.1.0-31.23 - 1.1.0.31 + 2.1.0-32.25 + 2.1.0.32 true 16BC0468-78F6-4C91-87DA-7403C919E646 @@ -49,6 +49,7 @@ + diff --git a/backend/api/Program.cs b/backend/api/Program.cs index a2556bfb80..e4b960cb6d 100644 --- a/backend/api/Program.cs +++ b/backend/api/Program.cs @@ -66,6 +66,8 @@ static IWebHostBuilder CreateWebHostBuilder(ProgramOptions options) config.AddJsonFile($"geocoder.{env}.json", optional: true, reloadOnChange: true); config.AddJsonFile("ltsa.json", optional: false, reloadOnChange: true); config.AddJsonFile($"ltsa.{env}.json", optional: true, reloadOnChange: true); + config.AddJsonFile("av.json", optional: false, reloadOnChange: true); + config.AddJsonFile($"av.{env}.json", optional: true, reloadOnChange: true); config.AddEnvironmentVariables(); config.AddCommandLine(args); }) diff --git a/backend/api/Services/DocumentService.cs b/backend/api/Services/DocumentService.cs index 143b66f55d..6bd0b014ea 100644 --- a/backend/api/Services/DocumentService.cs +++ b/backend/api/Services/DocumentService.cs @@ -1,9 +1,13 @@ +using System.Collections.Generic; using System.Threading.Tasks; using Microsoft.AspNetCore.Http; using Pims.Api.Models; using Pims.Api.Models.Mayan; using Pims.Api.Models.Mayan.Document; using Pims.Api.Repositories.Mayan; +using Pims.Dal.Entities; +using Pims.Dal.Repositories; +using Pims.Av; namespace Pims.Api.Services { @@ -13,10 +17,15 @@ namespace Pims.Api.Services public class DocumentService : IDocumentService { private readonly IEdmsDocumentRepository documentRepository; + private readonly IDocumentTypeRepository documentTypeRepository; + + private readonly IAvService avService; - public DocumentService(IEdmsDocumentRepository documentRepository) + public DocumentService(IEdmsDocumentRepository documentRepository, IDocumentTypeRepository documentTypeRepository, IAvService avService) { this.documentRepository = documentRepository; + this.documentTypeRepository = documentTypeRepository; + this.avService = avService; } public ExternalResult> GetDocumentTypes(string ordering = "", int? page = null, int? pageSize = null) @@ -40,11 +49,17 @@ public ExternalResult DownloadFile(int documentId, int fileId) return task.Result; } - public ExternalResult UploadDocument(int documentType, IFormFile fileRaw) + public async Task> UploadDocumentAsync(int documentType, IFormFile fileRaw) { + await this.avService.ScanAsync(fileRaw); Task> task = documentRepository.UploadDocumentAsync(documentType, fileRaw); task.Wait(); return task.Result; } + + public IEnumerable GetPimsDocumentTypes() + { + return documentTypeRepository.GetAll(); + } } } diff --git a/backend/api/Services/IDocumentService.cs b/backend/api/Services/IDocumentService.cs index cb8231f665..672f178ce8 100644 --- a/backend/api/Services/IDocumentService.cs +++ b/backend/api/Services/IDocumentService.cs @@ -1,7 +1,10 @@ +using System.Threading.Tasks; using Microsoft.AspNetCore.Http; using Pims.Api.Models; using Pims.Api.Models.Mayan; using Pims.Api.Models.Mayan.Document; +using Pims.Dal.Entities; +using System.Collections.Generic; namespace Pims.Api.Services { @@ -16,6 +19,8 @@ public interface IDocumentService ExternalResult DownloadFile(int documentId, int fileId); - ExternalResult UploadDocument(int documentType, IFormFile fileRaw); + Task> UploadDocumentAsync(int documentType, IFormFile fileRaw); + + IEnumerable GetPimsDocumentTypes(); } } diff --git a/backend/api/Services/INoteService.cs b/backend/api/Services/INoteService.cs index 24b6aa39df..f32cf8c704 100644 --- a/backend/api/Services/INoteService.cs +++ b/backend/api/Services/INoteService.cs @@ -7,9 +7,10 @@ namespace Pims.Api.Services { public interface INoteService { + NoteModel GetById(long id); EntityNoteModel Add(NoteType type, EntityNoteModel model); - - void DeleteNote(NoteType type, int noteId); + NoteModel Update(NoteModel model); + void DeleteNote(NoteType type, long noteId); IEnumerable GetNotes(NoteType type, long entityId); } } diff --git a/backend/api/Services/NoteService.cs b/backend/api/Services/NoteService.cs index 46fd3f3b55..25c3332071 100644 --- a/backend/api/Services/NoteService.cs +++ b/backend/api/Services/NoteService.cs @@ -1,6 +1,7 @@ using System.Collections.Generic; using System.Security.Claims; using MapsterMapper; +using Microsoft.EntityFrameworkCore; using Microsoft.Extensions.Logging; using Pims.Api.Constants; using Pims.Api.Models.Concepts; @@ -33,8 +34,20 @@ public NoteService(ClaimsPrincipal user, ILogger logger, IMapper ma _entityNoteRepository = entityNoteRepository; } + public NoteModel GetById(long id) + { + this.Logger.LogInformation("Getting note with id {id}", id); + this.User.ThrowIfNotAuthorized(Permissions.NoteView); + + var pimsEntity = _noteRepository.GetById(id); + var noteModel = _mapper.Map(pimsEntity); + + return noteModel; + } + public EntityNoteModel Add(NoteType type, EntityNoteModel model) { + this.Logger.LogInformation("Adding note with type {type} and model {model}", type, model); model.ThrowIfNull(nameof(model)); this.User.ThrowIfNotAuthorized(Permissions.NoteAdd); @@ -56,14 +69,31 @@ public EntityNoteModel Add(NoteType type, EntityNoteModel model) return result; } + public NoteModel Update(NoteModel model) + { + this.Logger.LogInformation("Updating note with id {id}", model.Id); + + model.ThrowIfNull(nameof(model)); + this.User.ThrowIfNotAuthorized(Permissions.NoteEdit); + ValidateVersion(model.Id, model.RowVersion); + + var pimsEntity = _mapper.Map(model); + var newNote = _noteRepository.Update(pimsEntity); + _noteRepository.CommitTransaction(); + + this.Logger.LogInformation("Note with id {id} update successfully", model.Id); + return GetById(newNote.Id); + } /// /// Find and delete the note /// /// Note type to determine the type of note to delete. /// Note id to identify the note to delete - public void DeleteNote(NoteType type, int noteId) + public void DeleteNote(NoteType type, long noteId) { + this.Logger.LogInformation("Deleting note with type {type} and id {noteId}", type, noteId); + switch (type) { case NoteType.Activity: @@ -86,6 +116,8 @@ public void DeleteNote(NoteType type, int noteId) /// public IEnumerable GetNotes(NoteType type, long entityId) { + this.Logger.LogInformation("Getting all notes with type {type} and parent id {entityId}", type, entityId); + switch (type) { case NoteType.Activity: @@ -95,5 +127,14 @@ public IEnumerable GetNotes(NoteType type, long entityId) return new List(); } } + + private void ValidateVersion(long noteId, long noteVersion) + { + long currentRowVersion = _noteRepository.GetRowVersion(noteId); + if (currentRowVersion != noteVersion) + { + throw new DbUpdateConcurrencyException("You are working with an older version of this note, please refresh the application and retry."); + } + } } } diff --git a/backend/api/Startup.cs b/backend/api/Startup.cs index ba979fd038..f72db45010 100644 --- a/backend/api/Startup.cs +++ b/backend/api/Startup.cs @@ -45,8 +45,10 @@ using Pims.Dal.Keycloak; using Pims.Geocoder; using Pims.Ltsa; +using Pims.Av; using Prometheus; using Swashbuckle.AspNetCore.SwaggerGen; +using nClam; namespace Pims.Api { @@ -218,6 +220,7 @@ public void ConfigureServices(IServiceCollection services) services.AddPimsKeycloakService(); services.AddGeocoderService(this.Configuration.GetSection("Geocoder")); // TODO: Determine if a default value could be used instead. services.AddLtsaService(this.Configuration.GetSection("Ltsa")); + services.AddClamAvService(this.Configuration.GetSection("Av")); services.AddSingleton(); services.AddTransient(); services.AddHttpContextAccessor(); diff --git a/backend/api/av.Local.json b/backend/api/av.Local.json new file mode 100644 index 0000000000..319be7a199 --- /dev/null +++ b/backend/api/av.Local.json @@ -0,0 +1,5 @@ +{ + "Av": { + "DisableScan": "true" + } +} diff --git a/backend/api/av.json b/backend/api/av.json new file mode 100644 index 0000000000..c37763f824 --- /dev/null +++ b/backend/api/av.json @@ -0,0 +1,6 @@ +{ + "Av": { + "DisableScan": "false", + "Port": 3310 + } +} diff --git a/backend/clamav/ClamAvService.cs b/backend/clamav/ClamAvService.cs new file mode 100644 index 0000000000..a0072d8fbe --- /dev/null +++ b/backend/clamav/ClamAvService.cs @@ -0,0 +1,97 @@ +using System.IO; +using System.Threading.Tasks; +using Microsoft.AspNetCore.Http; +using Microsoft.Extensions.Logging; +using Microsoft.Extensions.Options; +using nClam; +using Pims.Av.Configuration; +using Pims.Core.Exceptions; + +namespace Pims.Av +{ + /// + /// ClamAvService class, provides a service for integration with a running ClamAv Service and performing scans. + /// + public class ClamAvService : IAvService + { + private readonly ILogger _logger; + + #region Constructors + + /// + /// Creates a new instance of a ClamAvService, initializes with specified arguments. + /// + /// + /// + /// + public ClamAvService(IOptions options, IClamClient client, ILogger logger) + { + this.Options = options.Value; + this.Client = client; + this.Client.Port = this.Options.Port; + this.Client.Server = this.Options.HostUri; + this._logger = logger; + } + #endregion + + #region Properties + public ClamAvOptions Options { get; } + protected IClamClient Client { get; } + #endregion + + #region Methods + + /// + /// Scan the passed file, throw exceptions if the scan fails, or returns a positive result. + /// + /// + /// + public async Task ScanAsync(IFormFile file) + { + if (this.Options.DisableScan) + { + this._logger.LogInformation("ClamAV scan disabled"); + return; + } + using var ms = new MemoryStream(); + file.OpenReadStream().CopyTo(ms); + byte[] fileBytes = ms.ToArray(); + + await ScanAsync(fileBytes); + } + + /// + /// Scan the passed file, throw exceptions if the scan fails, or returns a positive result. + /// + /// + /// + public async Task ScanAsync(byte[] fileData) + { + if (this.Options.DisableScan) + { + this._logger.LogInformation("ClamAV scan disabled"); + return; + } + this._logger.LogInformation("ClamAV scan start"); + var scanResult = await this.Client.SendAndScanFileAsync(fileData); + + switch (scanResult.Result) + { + case ClamScanResults.Unknown: + this._logger.LogError("ClamAV scan failed", scanResult); + throw new AvException("Virus scan failed with unknown response. If you continue to see this error, please contact your site administrator."); + case ClamScanResults.Clean: + this._logger.LogDebug("ClamAV scan was clean", scanResult); + break; + case ClamScanResults.VirusDetected: + this._logger.LogWarning("ClamAV scan possible threat", scanResult); + throw new AvException($"Virus scan failed, one or more threats found. If you are confident this file is safe, please contact your site administrator."); + case ClamScanResults.Error: + this._logger.LogError("ClamAV scan returned an error", scanResult); + throw new AvException($"Virus scan failed with error: {scanResult.RawResult}. If you continue to see this error, please contact your site administrator."); + } + this._logger.LogInformation("ClamAV scan end"); + } + #endregion + } +} diff --git a/backend/clamav/Configuration/ClamAvOptions.cs b/backend/clamav/Configuration/ClamAvOptions.cs new file mode 100644 index 0000000000..5cb48ebe43 --- /dev/null +++ b/backend/clamav/Configuration/ClamAvOptions.cs @@ -0,0 +1,27 @@ +namespace Pims.Av.Configuration +{ + /// + /// ClamAvOptions class, provides a way to configure Clam AV. + /// + public class ClamAvOptions + { + public const string DEFAULTURI = "localhost"; + #region Properties + + /// + /// get/set - The URI to the ClamAV API service. + /// + public string HostUri { get; set; } = DEFAULTURI; + + /// + /// get/set - the ClamAV port. + /// + public int Port { get; set; } = 3310; + + /// + /// get/set - Whether or not the av scan should be skipped. + /// + public bool DisableScan { get; set; } = false; + #endregion + } +} diff --git a/backend/clamav/Exceptions/AvException.cs b/backend/clamav/Exceptions/AvException.cs new file mode 100644 index 0000000000..2b1bdf1f09 --- /dev/null +++ b/backend/clamav/Exceptions/AvException.cs @@ -0,0 +1,39 @@ +using System; +using System.Runtime.Serialization; + +namespace Pims.Core.Exceptions +{ + /// + /// ClamAvException class, provides a way to express HTTP request exceptions that occur. + /// + [Serializable] + public class AvException : Exception + { + + #region Constructors + public AvException() + { + } + + /// + /// Creates a new instance of an ClamAvException class, initializes it with the specified arguments. + /// + /// + /// + public AvException(string message) + : base(message) + { + } + + public AvException(string message, Exception innerException) + : base(message, innerException) + { + } + + protected AvException(SerializationInfo serializationInfo, StreamingContext streamingContext) + : base(serializationInfo, streamingContext) + { + } + #endregion + } +} diff --git a/backend/clamav/Extensions/ServiceCollectionExtensions.cs b/backend/clamav/Extensions/ServiceCollectionExtensions.cs new file mode 100644 index 0000000000..0df51620f9 --- /dev/null +++ b/backend/clamav/Extensions/ServiceCollectionExtensions.cs @@ -0,0 +1,29 @@ +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.DependencyInjection; +using nClam; +using Pims.Av.Configuration; + +namespace Pims.Av +{ + /// + /// ServiceCollectionExtensions static class, provides extension methods for ServiceCollection objects. + /// + public static class ServiceCollectionExtensions + { + /// + /// Add the AddClamAvService to the dependency injection service collection. + /// + /// + /// + /// + public static IServiceCollection AddClamAvService(this IServiceCollection services, IConfigurationSection section) + { + + + return services + .Configure(section) + .AddSingleton() + .AddSingleton(x => new ClamClient(ClamAvOptions.DEFAULTURI)); + } + } +} diff --git a/backend/clamav/IAvService.cs b/backend/clamav/IAvService.cs new file mode 100644 index 0000000000..00440eac55 --- /dev/null +++ b/backend/clamav/IAvService.cs @@ -0,0 +1,11 @@ +using System.Threading.Tasks; +using Microsoft.AspNetCore.Http; + +namespace Pims.Av +{ + public interface IAvService + { + public Task ScanAsync(IFormFile file); + public Task ScanAsync(byte[] fileData); + } +} diff --git a/backend/clamav/Pims.Av.csproj b/backend/clamav/Pims.Av.csproj new file mode 100644 index 0000000000..305ae49150 --- /dev/null +++ b/backend/clamav/Pims.Av.csproj @@ -0,0 +1,14 @@ + + + + Library + 1.0.0.0 + 1.0.0.0 + + + + + + + + diff --git a/backend/dal/Repositories/ContactRepository.cs b/backend/dal/Repositories/ContactRepository.cs index 3aa8ace656..c91a612f8c 100644 --- a/backend/dal/Repositories/ContactRepository.cs +++ b/backend/dal/Repositories/ContactRepository.cs @@ -111,45 +111,35 @@ private IEnumerable GetFilteredContacts(ContactFilter filter, { filter.ThrowIfNull(nameof(filter)); - var query = from c in this.Context.PimsContactMgrVws - join o in this.Context.PimsOrganizations - on c.Organization equals o into contactOrganization - from co in contactOrganization.DefaultIfEmpty() - join po in this.Context.PimsPersonOrganizations - on co equals po.Organization into contactPersonOrganization - from copo in contactPersonOrganization.DefaultIfEmpty() - join p in this.Context.PimsPeople - on new { person = copo != null ? copo.Person : null } equals new { person = p } into contactPersonOrganizationPerson - from copop in contactPersonOrganizationPerson.DefaultIfEmpty() - select new { Contact = c, Organization = co, PersonOrganization = copo, Person = copop }; + var query = Context.PimsContactMgrVws.AsNoTracking(); if (!string.IsNullOrWhiteSpace(filter.Municipality)) { - query = query.Where(c => c.Contact.MunicipalityName != null && c.Contact.MunicipalityName.Contains(filter.Municipality)); + query = query.Where(c => c.MunicipalityName.Contains(filter.Municipality)); } var summary = filter.Summary?.Trim() ?? string.Empty; if (filter.SearchBy == "persons") { - query = query.Where(c => c.Contact.PersonId != null && c.Contact.Id.StartsWith("P")); + query = query.Where(c => c.PersonId != null && c.Id.StartsWith("P")); string[] nameParts = summary.Split(' '); if (!string.IsNullOrWhiteSpace(summary)) { foreach (string namePart in nameParts) { - query = query.Where(c => (c.Contact.FirstName != null && c.Contact.FirstName.Contains(namePart)) || - (c.Contact.Surname != null && c.Contact.Surname.Contains(namePart)) || - (c.Contact.MiddleNames != null && c.Contact.MiddleNames.Contains(namePart))); + query = query.Where(c => (c.FirstName != null && c.FirstName.Contains(namePart)) || + (c.Surname != null && c.Surname.Contains(namePart)) || + (c.MiddleNames != null && c.MiddleNames.Contains(namePart))); } } } else if (filter.SearchBy == "organizations") { - query = query.Where(c => c.Contact.OrganizationId != null && c.Contact.Id.StartsWith("O")); + query = query.Where(c => c.OrganizationId != null && c.Id.StartsWith("O")); if (!string.IsNullOrWhiteSpace(summary)) { - query = query.Where(c => c.Contact.Summary != null && c.Contact.Summary.Contains(summary)); + query = query.Where(c => c.Summary != null && c.Summary.Contains(summary)); } } else @@ -159,17 +149,17 @@ from copop in contactPersonOrganizationPerson.DefaultIfEmpty() { foreach (string namePart in nameParts) { - query = query.Where(c => (c.Contact.FirstName != null && c.Contact.FirstName.Contains(namePart)) || - (c.Contact.Surname != null && c.Contact.Surname.Contains(namePart)) || - (c.Contact.MiddleNames != null && c.Contact.MiddleNames.Contains(namePart)) || - (c.Contact.OrganizationName != null && c.Contact.OrganizationName.Contains(summary))); + query = query.Where(c => (c.FirstName != null && c.FirstName.Contains(namePart)) || + (c.Surname != null && c.Surname.Contains(namePart)) || + (c.MiddleNames != null && c.MiddleNames.Contains(namePart)) || + (c.OrganizationName != null && c.OrganizationName.Contains(summary))); } } } if (filter.ActiveContactsOnly) { - query = query.Where(c => !c.Contact.IsDisabled); + query = query.Where(c => !c.IsDisabled); } if (filter.Sort?.Any() == true) @@ -178,39 +168,86 @@ from copop in contactPersonOrganizationPerson.DefaultIfEmpty() var direction = filter.Sort.FirstOrDefault()?.Split(" ")?.LastOrDefault(); if (field == "Surname") { - query = direction == "asc" ? query.OrderBy(c => c.Contact.Surname) : query.OrderByDescending(c => c.Contact.Surname); + query = direction == "asc" ? query.OrderBy(c => c.Surname) : query.OrderByDescending(c => c.Surname); } else if (field == "FirstName") { - query = direction == "asc" ? query.OrderBy(c => c.Contact.FirstName) : query.OrderByDescending(c => c.Contact.FirstName); + query = direction == "asc" ? query.OrderBy(c => c.FirstName) : query.OrderByDescending(c => c.FirstName); } else if (field == "OrganizationName") { - query = direction == "asc" ? query.OrderBy(c => c.Contact.OrganizationName) : query.OrderByDescending(c => c.Contact.OrganizationName); + query = direction == "asc" ? query.OrderBy(c => c.OrganizationName) : query.OrderByDescending(c => c.OrganizationName); } else if (field == "MunicipalityName") { - query = direction == "asc" ? query.OrderBy(c => c.Contact.MunicipalityName) : query.OrderByDescending(c => c.Contact.MunicipalityName); + query = direction == "asc" ? query.OrderBy(c => c.MunicipalityName) : query.OrderByDescending(c => c.MunicipalityName); } else { - query = direction == "asc" ? query.OrderBy(c => c.Contact.Summary) : query.OrderByDescending(c => c.Contact.Summary); + query = direction == "asc" ? query.OrderBy(c => c.Summary) : query.OrderByDescending(c => c.Summary); } } else { - query = query.OrderBy(c => c.Contact.Summary); + query = query.OrderBy(c => c.Summary); } var skip = (filter.Page - 1) * filter.Quantity; totalItems = query.Count(); - var contactsWithOrganizations = query - .Skip(skip) + var contacts = query.Skip(skip) .Take(filter.Quantity) .ToArray(); + // Unable to use includes on PersonOrganization as scaffolded views in EF are keyless entities. + var joinOrganizationQuery = from c in this.Context.PimsContactMgrVws + where contacts.Select(c => c.Id).Contains(c.Id) + join o in this.Context.PimsOrganizations + on c.Organization equals o into contactOrganization + from co in contactOrganization.DefaultIfEmpty() + join po in this.Context.PimsPersonOrganizations + on co equals po.Organization into contactPersonOrganization + from copo in contactPersonOrganization.DefaultIfEmpty() + join p in this.Context.PimsPeople + on new { person = copo != null ? copo.Person : null } equals new { person = p } into contactPersonOrganizationPerson + from copop in contactPersonOrganizationPerson.DefaultIfEmpty() + select new { Contact = c, Organization = co, PersonOrganization = copo }; + + // TODO refactor this into a shared method. + if (filter.Sort?.Any() == true) + { + var field = filter.Sort.FirstOrDefault()?.Split(" ")?.FirstOrDefault(); + var direction = filter.Sort.FirstOrDefault()?.Split(" ")?.LastOrDefault(); + if (field == "Surname") + { + joinOrganizationQuery = direction == "asc" ? joinOrganizationQuery.OrderBy(c => c.Contact.Surname) : joinOrganizationQuery.OrderByDescending(c => c.Contact.Surname); + } + else if (field == "FirstName") + { + joinOrganizationQuery = direction == "asc" ? joinOrganizationQuery.OrderBy(c => c.Contact.FirstName) : joinOrganizationQuery.OrderByDescending(c => c.Contact.FirstName); + } + else if (field == "OrganizationName") + { + joinOrganizationQuery = direction == "asc" ? joinOrganizationQuery.OrderBy(c => c.Contact.OrganizationName) : joinOrganizationQuery.OrderByDescending(c => c.Contact.OrganizationName); + } + else if (field == "MunicipalityName") + { + joinOrganizationQuery = direction == "asc" ? joinOrganizationQuery.OrderBy(c => c.Contact.MunicipalityName) : joinOrganizationQuery.OrderByDescending(c => c.Contact.MunicipalityName); + } + else + { + joinOrganizationQuery = direction == "asc" ? joinOrganizationQuery.OrderBy(c => c.Contact.Summary) : joinOrganizationQuery.OrderByDescending(c => c.Contact.Summary); + } + } + else + { + joinOrganizationQuery = joinOrganizationQuery.OrderBy(c => c.Contact.Summary); + } + + var contactsWithOrganizations = joinOrganizationQuery.ToArray(); + + // The joinOrganizationQuery returns a cartesion product, this creates a unique list of contacts with attached Organization and list of PersonOrganizations. return contactsWithOrganizations.GroupBy(copop => copop.Contact.Id).Select(contactGroup => { PimsContactMgrVw contact = contactGroup.FirstOrDefault().Contact; PimsOrganization organization = contactGroup.FirstOrDefault().Organization; @@ -220,7 +257,6 @@ from copop in contactPersonOrganizationPerson.DefaultIfEmpty() .Where(copop => copop.Contact.Id == contactGroup.Key && copop.PersonOrganization != null) .Select(copop => { - copop.PersonOrganization.Person = copop.Person; return copop.PersonOrganization; }); diff --git a/backend/dal/Repositories/Interfaces/ILookupService.cs b/backend/dal/Repositories/Interfaces/ILookupService.cs index 29b7edb1f8..64cf5e22ac 100644 --- a/backend/dal/Repositories/Interfaces/ILookupService.cs +++ b/backend/dal/Repositories/Interfaces/ILookupService.cs @@ -46,6 +46,8 @@ public interface ILookupService : IRepository IEnumerable GetPropertyAdjacentLandTypes(); IEnumerable GetPropertyVolumetricTypes(); IEnumerable GetPPHStatusType(); + IEnumerable GetDocumentStatusTypes(); + IEnumerable GetDocumentTypes(); } } diff --git a/backend/dal/Repositories/Interfaces/INoteRepository.cs b/backend/dal/Repositories/Interfaces/INoteRepository.cs index 8e3759a52f..b0715a40ad 100644 --- a/backend/dal/Repositories/Interfaces/INoteRepository.cs +++ b/backend/dal/Repositories/Interfaces/INoteRepository.cs @@ -5,12 +5,12 @@ namespace Pims.Dal.Repositories { public interface INoteRepository : IRepository { + PimsNote GetById(long id); PimsNote Add(PimsNote note); + PimsNote Update(PimsNote note); long GetRowVersion(long id); int Count(); - IEnumerable GetActivityNotes(long entityId); - - void DeleteActivityNotes(int noteId); + void DeleteActivityNotes(long noteId); } } diff --git a/backend/dal/Repositories/Interfaces/IPropertyRepository.cs b/backend/dal/Repositories/Interfaces/IPropertyRepository.cs index 420b987eaf..89f131df56 100644 --- a/backend/dal/Repositories/Interfaces/IPropertyRepository.cs +++ b/backend/dal/Repositories/Interfaces/IPropertyRepository.cs @@ -15,7 +15,7 @@ public interface IPropertyRepository : IRepository PimsProperty Get(long id); PimsProperty GetByPid(string pid); PimsProperty GetByPid(int pid); - PimsProperty GetAssociations(string pid); + PimsProperty GetAssociations(long id); PimsProperty Update(PimsProperty property); void Delete(PimsProperty property); } diff --git a/backend/dal/Repositories/LookupService.cs b/backend/dal/Repositories/LookupService.cs index d5ed4c66f9..71080f2394 100644 --- a/backend/dal/Repositories/LookupService.cs +++ b/backend/dal/Repositories/LookupService.cs @@ -245,6 +245,14 @@ public IEnumerable GetPPHStatusType() { return this.Context.PimsPphStatusTypes.AsNoTracking().OrderBy(r => r.DisplayOrder).ToArray(); } + public IEnumerable GetDocumentStatusTypes() + { + return this.Context.PimsDocumentStatusTypes.AsNoTracking().ToArray(); + } + public IEnumerable GetDocumentTypes() + { + return this.Context.PimsDocumentTyps.AsNoTracking().ToArray(); + } #endregion } } diff --git a/backend/dal/Repositories/NoteRepository.cs b/backend/dal/Repositories/NoteRepository.cs index 579f8e9607..6b7e8f0ef1 100644 --- a/backend/dal/Repositories/NoteRepository.cs +++ b/backend/dal/Repositories/NoteRepository.cs @@ -29,6 +29,17 @@ public NoteRepository(PimsContext dbContext, ClaimsPrincipal user, IPimsReposito #region Methods + /// + /// Retrieves the note with the specified id. + /// + /// + /// + public PimsNote GetById(long id) + { + return this.Context.PimsNotes.AsNoTracking() + .FirstOrDefault(x => x.NoteId == id) ?? throw new KeyNotFoundException(); + } + /// /// Adds the specified note to the datasource /// @@ -41,6 +52,24 @@ public PimsNote Add(PimsNote note) return note; } + /// + /// Updates the specified note. + /// + /// + /// + public PimsNote Update(PimsNote note) + { + note.ThrowIfNull(nameof(note)); + + var existingNote = this.Context.PimsNotes + .FirstOrDefault(x => x.NoteId == note.Id) ?? throw new KeyNotFoundException(); + + // update main entity - PimsNote + this.Context.Entry(existingNote).CurrentValues.SetValues(note); + + return existingNote; + } + /// /// Retrieves the row version of the note with the specified id. /// @@ -65,7 +94,7 @@ public IEnumerable GetActivityNotes(long entityId) .Where(x => x.ActivityInstanceId == entityId && x.IsDisabled == false).Select(x => x.Note).ToList(); } - public void DeleteActivityNotes(int noteId) + public void DeleteActivityNotes(long noteId) { var activityNotes = this.Context.PimsActivityInstanceNotes.Where(x => x.NoteId == noteId).ToList(); if (activityNotes.Any()) diff --git a/backend/dal/Repositories/PropertyRepository.cs b/backend/dal/Repositories/PropertyRepository.cs index 17358c3484..68fa5e8de4 100644 --- a/backend/dal/Repositories/PropertyRepository.cs +++ b/backend/dal/Repositories/PropertyRepository.cs @@ -193,14 +193,12 @@ public PimsProperty GetByPid(int pid) } /// - /// Get the property for the specified PID value. + /// Get the property for the specified id value. /// - /// + /// /// - public PimsProperty GetAssociations(string pid) + public PimsProperty GetAssociations(long id) { - int parsedPid = pid.ConvertPID(); - PimsProperty property = this.Context.PimsProperties .Include(p => p.PimsPropertyLeases) .ThenInclude(pl => pl.Lease) @@ -208,7 +206,7 @@ public PimsProperty GetAssociations(string pid) .Include(p => p.PimsPropertyResearchFiles) .ThenInclude(pr => pr.ResearchFile) .ThenInclude(r => r.ResearchFileStatusTypeCodeNavigation) - .FirstOrDefault(p => p.Pid == parsedPid); + .FirstOrDefault(p => p.PropertyId == id); return property; } diff --git a/backend/dal/Repositories/ResearchFilePropertyRepository.cs b/backend/dal/Repositories/ResearchFilePropertyRepository.cs index 1e1d022200..34ae64b77e 100644 --- a/backend/dal/Repositories/ResearchFilePropertyRepository.cs +++ b/backend/dal/Repositories/ResearchFilePropertyRepository.cs @@ -34,6 +34,7 @@ public List GetByResearchFileId(long researchFileId) return Context.PimsPropertyResearchFiles .Where(x => x.ResearchFileId == researchFileId) .Include(rp => rp.Property) + .Include(rp => rp.PimsPrfPropResearchPurposeTypes) .AsNoTracking() .ToList(); } @@ -66,6 +67,9 @@ public void Delete(PimsPropertyResearchFile propertyResearchFile) Context.Entry(propertyResearchFile.Property).State = EntityState.Unchanged; } + // Delete any Property research purpose type associations + propertyResearchFile.PimsPrfPropResearchPurposeTypes.ForEach(purposeType => Context.PimsPrfPropResearchPurposeTypes.Remove(purposeType)); + Context.PimsPropertyResearchFiles.Remove(propertyResearchFile); } diff --git a/backend/dal/Security/Permissions.cs b/backend/dal/Security/Permissions.cs index d3404abbfe..d77fbaa6d9 100644 --- a/backend/dal/Security/Permissions.cs +++ b/backend/dal/Security/Permissions.cs @@ -95,5 +95,9 @@ public enum Permissions [Display(GroupName = "note", Name = "note-delete", Description = "Can delete existing notes.")] NoteDelete = 30, + + + [Display(GroupName = "document", Name = "document-view", Description = "Can view documents.")] + DocumentView = 31, } } diff --git a/backend/entities/Partials/DocumentType.cs b/backend/entities/Partials/DocumentType.cs new file mode 100644 index 0000000000..c0d41f6531 --- /dev/null +++ b/backend/entities/Partials/DocumentType.cs @@ -0,0 +1,15 @@ +using System.ComponentModel.DataAnnotations.Schema; + +namespace Pims.Dal.Entities +{ + /// + /// PimsDocument class, provides an entity for the datamodel to manage notes. + /// + public partial class PimsDocumentTyp : IdentityBaseAppEntity, IBaseAppEntity + { + #region Properties + [NotMapped] + public override long Id { get => this.DocumentTypeId; set => this.DocumentTypeId = value; } + #endregion + } +} diff --git a/backend/entities/Partials/PimsDocumentStatusType.cs b/backend/entities/Partials/PimsDocumentStatusType.cs new file mode 100644 index 0000000000..3ac0e3a09a --- /dev/null +++ b/backend/entities/Partials/PimsDocumentStatusType.cs @@ -0,0 +1,28 @@ +using System.ComponentModel.DataAnnotations.Schema; +namespace Pims.Dal.Entities +{ + /// + /// PimsVolumetricType class, provides an entity for the datamodel to manage a list of volumetric types. + /// + public partial class PimsDocumentStatusType : ITypeEntity + { + #region Properties + /// + /// get/set - Primary key to identify volumetric type. + /// + [NotMapped] + public string Id { get => DocumentStatusTypeCode; set => DocumentStatusTypeCode = value; } + #endregion + + #region Constructors + /// + /// Create a new instance of a PimsVolumetricType class. + /// + /// + public PimsDocumentStatusType(string id) : this() + { + Id = id; + } + #endregion + } +} diff --git a/backend/entities/PimsBaseContext.cs b/backend/entities/PimsBaseContext.cs index 851cd33717..76e72e0308 100644 --- a/backend/entities/PimsBaseContext.cs +++ b/backend/entities/PimsBaseContext.cs @@ -68,12 +68,28 @@ public PimsBaseContext(DbContextOptions options) public virtual DbSet PimsAccessRequestOrganizations { get; set; } public virtual DbSet PimsAccessRequestOrganizationHists { get; set; } public virtual DbSet PimsAccessRequestStatusTypes { get; set; } + public virtual DbSet PimsAcqFlPersonProfileTypes { get; set; } + public virtual DbSet PimsAcqPhysFileStatusTypes { get; set; } + public virtual DbSet PimsAcquisitionActivityInstances { get; set; } + public virtual DbSet PimsAcquisitionActivityInstanceHists { get; set; } + public virtual DbSet PimsAcquisitionFiles { get; set; } + public virtual DbSet PimsAcquisitionFileHists { get; set; } + public virtual DbSet PimsAcquisitionFilePeople { get; set; } + public virtual DbSet PimsAcquisitionFilePersonHists { get; set; } + public virtual DbSet PimsAcquisitionFileStatusTypes { get; set; } + public virtual DbSet PimsAcquisitionFundingTypes { get; set; } + public virtual DbSet PimsAcquisitionOwners { get; set; } + public virtual DbSet PimsAcquisitionOwnerHists { get; set; } + public virtual DbSet PimsAcquisitionTypes { get; set; } public virtual DbSet PimsActivityInstances { get; set; } public virtual DbSet PimsActivityInstanceDocuments { get; set; } public virtual DbSet PimsActivityInstanceDocumentHists { get; set; } public virtual DbSet PimsActivityInstanceHists { get; set; } public virtual DbSet PimsActivityInstanceNotes { get; set; } public virtual DbSet PimsActivityInstanceNoteHists { get; set; } + public virtual DbSet PimsActivityTemplates { get; set; } + public virtual DbSet PimsActivityTemplateHists { get; set; } + public virtual DbSet PimsActivityTemplateTypes { get; set; } public virtual DbSet PimsAddresses { get; set; } public virtual DbSet PimsAddressHists { get; set; } public virtual DbSet PimsAddressUsageTypes { get; set; } @@ -95,6 +111,7 @@ public PimsBaseContext(DbContextOptions options) public virtual DbSet PimsInsurances { get; set; } public virtual DbSet PimsInsuranceHists { get; set; } public virtual DbSet PimsInsuranceTypes { get; set; } + public virtual DbSet PimsLandSurveyorTypes { get; set; } public virtual DbSet PimsLeases { get; set; } public virtual DbSet PimsLeaseCategoryTypes { get; set; } public virtual DbSet PimsLeaseHists { get; set; } @@ -139,6 +156,8 @@ public PimsBaseContext(DbContextOptions options) public virtual DbSet PimsPropPropTenureTypes { get; set; } public virtual DbSet PimsPropResearchPurposeTypes { get; set; } public virtual DbSet PimsProperties { get; set; } + public virtual DbSet PimsPropertyAcquisitionFiles { get; set; } + public virtual DbSet PimsPropertyAcquisitionFileHists { get; set; } public virtual DbSet PimsPropertyAdjacentLandTypes { get; set; } public virtual DbSet PimsPropertyAnomalyTypes { get; set; } public virtual DbSet PimsPropertyBoundaryVws { get; set; } @@ -195,6 +214,7 @@ public PimsBaseContext(DbContextOptions options) public virtual DbSet PimsStaticVariables { get; set; } public virtual DbSet PimsStaticVariableHists { get; set; } public virtual DbSet PimsSurplusDeclarationTypes { get; set; } + public virtual DbSet PimsSurveyPlanTypes { get; set; } public virtual DbSet PimsTenants { get; set; } public virtual DbSet PimsUsers { get; set; } public virtual DbSet PimsUserHists { get; set; } @@ -1825,6 +1845,402 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) entity.Property(e => e.IsDisabled).HasDefaultValueSql("(CONVERT([bit],(0)))"); }); + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcqFlPersonProfileTypeCode) + .HasName("AQFPPT_PK"); + + entity.HasComment("Codified values for the acquistion file staff profile (role)."); + + entity.Property(e => e.AcqFlPersonProfileTypeCode).HasComment("Code value for the acquistion file staff profile (role)."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.Description).HasComment("Description of the acquistion file staff profile (role)."); + + entity.Property(e => e.DisplayOrder).HasComment("Designates a preferred presentation order of the code descriptions."); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the code value is inactive."); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcqPhysFileStatusTypeCode) + .HasName("ACQPFS_PK"); + + entity.HasComment("Codified values for the acquistion physical file status type."); + + entity.Property(e => e.AcqPhysFileStatusTypeCode).HasComment("Code value for the acquistion physical file status type."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.Description).HasComment("Description of the acquistion physical file status type."); + + entity.Property(e => e.DisplayOrder).HasComment("Designates a preferred presentation order of the code descriptions."); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the code value is inactive."); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionActivityInstanceId) + .HasName("ACQAIN_PK"); + + entity.Property(e => e.AcquisitionActivityInstanceId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ])"); + + entity.Property(e => e.AppCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppCreateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppLastUpdateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the relationship is active."); + + entity.HasOne(d => d.AcquisitionFile) + .WithMany(p => p.PimsAcquisitionActivityInstances) + .HasForeignKey(d => d.AcquisitionFileId) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("PIM_ACQNFL_PIM_ACQAIN_FK"); + + entity.HasOne(d => d.ActivityInstance) + .WithMany(p => p.PimsAcquisitionActivityInstances) + .HasForeignKey(d => d.ActivityInstanceId) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("PIM_ACTINS_PIM_ACQAIN_FK"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionActivityInstanceHistId) + .HasName("PIMS_ACQAIN_H_PK"); + + entity.Property(e => e.AcquisitionActivityInstanceHistId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ])"); + + entity.Property(e => e.EffectiveDateHist).HasDefaultValueSql("(getutcdate())"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionFileId) + .HasName("ACQNFL_PK"); + + entity.HasComment("Entity containing information regarding an acquisition file."); + + entity.Property(e => e.AcquisitionFileId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACQUISITION_FILE_ID_SEQ])"); + + entity.Property(e => e.AppCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppCreateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppLastUpdateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AssignedDate) + .HasDefaultValueSql("(getutcdate())") + .HasComment("Date of file assignment."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.CpsProductCode).HasComment("CPS product code."); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DeliveryDate).HasComment("Date of file delivery."); + + entity.Property(e => e.FileName).HasComment("Descriptive name given to the acquisition file."); + + entity.Property(e => e.FileNumber).HasComment("File number assigned to the acquisition file."); + + entity.Property(e => e.FundingOther).HasComment("Description of other funding type."); + + entity.Property(e => e.MinistryProjectName).HasComment("Ministry project name."); + + entity.Property(e => e.MinistryProjectNumber).HasComment("Ministry project number."); + + entity.Property(e => e.RegionCode) + .HasDefaultValueSql("((-1))") + .HasComment("Region responsible for oversight of the acquisition."); + + entity.HasOne(d => d.AcqPhysFileStatusTypeCodeNavigation) + .WithMany(p => p.PimsAcquisitionFiles) + .HasForeignKey(d => d.AcqPhysFileStatusTypeCode) + .HasConstraintName("PIM_ACQPFS_PIM_ACQNFL_FK"); + + entity.HasOne(d => d.AcquisitionFileStatusTypeCodeNavigation) + .WithMany(p => p.PimsAcquisitionFiles) + .HasForeignKey(d => d.AcquisitionFileStatusTypeCode) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("PIM_ACQFST_PIM_ACQNFL_FK"); + + entity.HasOne(d => d.AcquisitionFundingTypeCodeNavigation) + .WithMany(p => p.PimsAcquisitionFiles) + .HasForeignKey(d => d.AcquisitionFundingTypeCode) + .HasConstraintName("PIM_ACQFTY_PIM_ACQNFL_FK"); + + entity.HasOne(d => d.AcquisitionTypeCodeNavigation) + .WithMany(p => p.PimsAcquisitionFiles) + .HasForeignKey(d => d.AcquisitionTypeCode) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("PIM_ACQTYP_PIM_ACQNFL_FK"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionFileHistId) + .HasName("PIMS_ACQNFL_H_PK"); + + entity.Property(e => e.AcquisitionFileHistId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACQUISITION_FILE_H_ID_SEQ])"); + + entity.Property(e => e.EffectiveDateHist).HasDefaultValueSql("(getutcdate())"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionFilePersonId) + .HasName("ACQPER_PK"); + + entity.HasComment("Table to associate an acquisition file to a person."); + + entity.Property(e => e.AcquisitionFilePersonId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACQUISITION_FILE_PERSON_ID_SEQ])"); + + entity.Property(e => e.AppCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppCreateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppLastUpdateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the relationship is active."); + + entity.HasOne(d => d.AcqFlPersonProfileTypeCodeNavigation) + .WithMany(p => p.PimsAcquisitionFilePeople) + .HasForeignKey(d => d.AcqFlPersonProfileTypeCode) + .HasConstraintName("PIM_AQFPPT_PIM_ACQPER_FK"); + + entity.HasOne(d => d.AcquisitionFile) + .WithMany(p => p.PimsAcquisitionFilePeople) + .HasForeignKey(d => d.AcquisitionFileId) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("PIM_ACQNFL_PIM_ACQPER_FK"); + + entity.HasOne(d => d.Person) + .WithMany(p => p.PimsAcquisitionFilePeople) + .HasForeignKey(d => d.PersonId) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("PIM_PERSON_PIM_ACQPER_FK"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionFilePersonHistId) + .HasName("PIMS_ACQPER_H_PK"); + + entity.Property(e => e.AcquisitionFilePersonHistId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ])"); + + entity.Property(e => e.EffectiveDateHist).HasDefaultValueSql("(getutcdate())"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionFileStatusTypeCode) + .HasName("ACQFST_PK"); + + entity.HasComment("Codified values for the acquistion file status."); + + entity.Property(e => e.AcquisitionFileStatusTypeCode).HasComment("Code value for the acquistion file status."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.Description).HasComment("Description of the acquistion file status."); + + entity.Property(e => e.DisplayOrder).HasComment("Designates a preferred presentation order of the code descriptions."); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the code value is inactive."); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionFundingTypeCode) + .HasName("ACQFTY_PK"); + + entity.HasComment("Codified values for the acquistion funding type."); + + entity.Property(e => e.AcquisitionFundingTypeCode).HasComment("Code value for the acquistion funding type."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.Description).HasComment("Description of the acquistion funding type."); + + entity.Property(e => e.DisplayOrder).HasComment("Designates a preferred presentation order of the code descriptions."); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the code value is inactive."); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionOwnerId) + .HasName("ACQOWN_PK"); + + entity.HasComment("Entity containing information regarding an acquisition file."); + + entity.Property(e => e.AcquisitionOwnerId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACQUISITION_OWNER_ID_SEQ])"); + + entity.Property(e => e.AppCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppCreateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppLastUpdateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.OwnerName) + .HasDefaultValueSql("('')") + .HasComment("Name of the owner."); + + entity.HasOne(d => d.AcquisitionFile) + .WithMany(p => p.PimsAcquisitionOwners) + .HasForeignKey(d => d.AcquisitionFileId) + .HasConstraintName("PIM_ACQNFL_PIM_ACQOWN_FK"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionOwnerHistId) + .HasName("PIMS_ACQOWN_H_PK"); + + entity.Property(e => e.AcquisitionOwnerHistId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACQUISITION_OWNER_H_ID_SEQ])"); + + entity.Property(e => e.EffectiveDateHist).HasDefaultValueSql("(getutcdate())"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.AcquisitionTypeCode) + .HasName("ACQTYP_PK"); + + entity.HasComment("Codified values for the acquistion type."); + + entity.Property(e => e.AcquisitionTypeCode).HasComment("Code value for the acquistion type."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.Description).HasComment("Description of the acquistion type."); + + entity.Property(e => e.DisplayOrder).HasComment("Designates a preferred presentation order of the code descriptions."); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the code value is inactive."); + }); + modelBuilder.Entity(entity => { entity.HasKey(e => e.ActivityInstanceId) @@ -1834,6 +2250,10 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) entity.Property(e => e.ActivityInstanceId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACTIVITY_INSTANCE_ID_SEQ])"); + entity.Property(e => e.ActivityDataJson) + .HasDefaultValueSql("('')") + .HasComment("JSON structure containing data specific to an activity instance."); + entity.Property(e => e.AppCreateTimestamp).HasDefaultValueSql("(getutcdate())"); entity.Property(e => e.AppCreateUserDirectory).HasDefaultValueSql("(user_name())"); @@ -1855,6 +2275,11 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.HasOne(d => d.ActivityTemplate) + .WithMany(p => p.PimsActivityInstances) + .HasForeignKey(d => d.ActivityTemplateId) + .HasConstraintName("PIM_ACTTMP_PIM_ACTINS_FK"); }); modelBuilder.Entity(entity => @@ -1980,6 +2405,83 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) entity.Property(e => e.EffectiveDateHist).HasDefaultValueSql("(getutcdate())"); }); + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.ActivityTemplateId) + .HasName("ACTTMP_PK"); + + entity.Property(e => e.ActivityTemplateId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACTIVITY_TEMPLATE_ID_SEQ])"); + + entity.Property(e => e.ActivityTemplateJson) + .HasDefaultValueSql("('')") + .HasComment("JSON structure desribing how to construct the activity UI."); + + entity.Property(e => e.AppCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppCreateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppLastUpdateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.HasOne(d => d.ActivityTemplateTypeCodeNavigation) + .WithMany(p => p.PimsActivityTemplates) + .HasForeignKey(d => d.ActivityTemplateTypeCode) + .HasConstraintName("PIM_ACTTTY_PIM_ACTTMP_FK"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.ActivityTemplateHistId) + .HasName("PIMS_ACTTMP_H_PK"); + + entity.Property(e => e.ActivityTemplateHistId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ])"); + + entity.Property(e => e.EffectiveDateHist).HasDefaultValueSql("(getutcdate())"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.ActivityTemplateTypeCode) + .HasName("ACTTTY_PK"); + + entity.HasComment("Codified values for the activity type."); + + entity.Property(e => e.ActivityTemplateTypeCode).HasComment("Code value for the activity type."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.Description).HasComment("Description of the activity type."); + + entity.Property(e => e.DisplayOrder).HasComment("Designates a preferred presentation order of the code descriptions."); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the code value is inactive."); + }); + modelBuilder.Entity(entity => { entity.HasKey(e => e.AddressId) @@ -2488,6 +2990,34 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) entity.Property(e => e.IsDisabled).HasDefaultValueSql("(CONVERT([bit],(0)))"); }); + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.LandSurveyorTypeCode) + .HasName("LNSRVT_PK"); + + entity.HasComment("Codified values for the land surveyor type. This is an unassociated table that is used in the UI to populate JSON attributes."); + + entity.Property(e => e.LandSurveyorTypeCode).HasComment("Code value for the land surveyor type."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.Description).HasComment("Description of the land surveyor type."); + + entity.Property(e => e.DisplayOrder).HasComment("Designates a preferred presentation order of the code descriptions."); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the code value is inactive."); + }); + modelBuilder.Entity(entity => { entity.HasKey(e => e.LeaseId) @@ -3937,6 +4467,64 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) .HasConstraintName("PIM_PRVOLT_PIM_PRPRTY_FK"); }); + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.PropertyAcquisitionFileId) + .HasName("PRACQF_PK"); + + entity.HasComment("Associates a property with an acquisition file."); + + entity.Property(e => e.PropertyAcquisitionFileId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ])"); + + entity.Property(e => e.AppCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppCreateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.AppLastUpdateUserDirectory).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.AppLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the relationship is active."); + + entity.HasOne(d => d.AcquisitionFile) + .WithMany(p => p.PimsPropertyAcquisitionFiles) + .HasForeignKey(d => d.AcquisitionFileId) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("PIM_ACQNFL_PIM_PRACQF_FK"); + + entity.HasOne(d => d.Property) + .WithMany(p => p.PimsPropertyAcquisitionFiles) + .HasForeignKey(d => d.PropertyId) + .OnDelete(DeleteBehavior.ClientSetNull) + .HasConstraintName("PIM_PRPRTY_PIM_PRACQF_FK"); + }); + + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.PropertyAcquisitionFileHistId) + .HasName("PIMS_PRACQF_H_PK"); + + entity.Property(e => e.PropertyAcquisitionFileHistId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ])"); + + entity.Property(e => e.EffectiveDateHist).HasDefaultValueSql("(getutcdate())"); + }); + modelBuilder.Entity(entity => { entity.HasKey(e => e.PropertyAdjacentLandTypeCode) @@ -4317,6 +4905,8 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) entity.HasKey(e => e.PropertyResearchFileId) .HasName("PRSCRC_PK"); + entity.HasComment("Associates a property with a research file."); + entity.Property(e => e.PropertyResearchFileId).HasDefaultValueSql("(NEXT VALUE FOR [PIMS_PROPERTY_RESEARCH_FILE_ID_SEQ])"); entity.Property(e => e.AppCreateTimestamp).HasDefaultValueSql("(getutcdate())"); @@ -5337,6 +5927,34 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) .HasComment("Indicates that the code value is disabled"); }); + modelBuilder.Entity(entity => + { + entity.HasKey(e => e.SurveyPlanTypeCode) + .HasName("SRVPLT_PK"); + + entity.HasComment("Codified values for the survey plan type. This is an unassociated table that is used in the UI to populate JSON attributes."); + + entity.Property(e => e.SurveyPlanTypeCode).HasComment("Code value for the survey plan type."); + + entity.Property(e => e.ConcurrencyControlNumber).HasDefaultValueSql("((1))"); + + entity.Property(e => e.DbCreateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbCreateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.DbLastUpdateTimestamp).HasDefaultValueSql("(getutcdate())"); + + entity.Property(e => e.DbLastUpdateUserid).HasDefaultValueSql("(user_name())"); + + entity.Property(e => e.Description).HasComment("Description of the survey plan type."); + + entity.Property(e => e.DisplayOrder).HasComment("Designates a preferred presentation order of the code descriptions."); + + entity.Property(e => e.IsDisabled) + .HasDefaultValueSql("(CONVERT([bit],(0)))") + .HasComment("Indicates if the code value is inactive."); + }); + modelBuilder.Entity(entity => { entity.HasKey(e => e.TenantId) @@ -5617,6 +6235,46 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) .HasMin(1) .HasMax(2147483647); + modelBuilder.HasSequence("PIMS_ACQUISITION_ACTIVITY_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_FILE_H_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_FILE_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_FILE_NUMBER_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_FILE_PERSON_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_OWNER_H_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACQUISITION_OWNER_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + modelBuilder.HasSequence("PIMS_ACTIVITY_H_ID_SEQ") .HasMin(1) .HasMax(2147483647); @@ -5665,6 +6323,14 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) .HasMin(1) .HasMax(2147483647); + modelBuilder.HasSequence("PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_ACTIVITY_TEMPLATE_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + modelBuilder.HasSequence("PIMS_ADDRESS_H_ID_SEQ") .HasMin(1) .HasMax(2147483647); @@ -5909,6 +6575,14 @@ protected override void OnModelCreating(ModelBuilder modelBuilder) .HasMin(1) .HasMax(2147483647); + modelBuilder.HasSequence("PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + + modelBuilder.HasSequence("PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ") + .HasMin(1) + .HasMax(2147483647); + modelBuilder.HasSequence("PIMS_PROPERTY_ACTIVITY_H_ID_SEQ") .HasMin(1) .HasMax(2147483647); diff --git a/backend/entities/ef/PimsAcqFlPersonProfileType.cs b/backend/entities/ef/PimsAcqFlPersonProfileType.cs new file mode 100644 index 0000000000..9cd055b4e2 --- /dev/null +++ b/backend/entities/ef/PimsAcqFlPersonProfileType.cs @@ -0,0 +1,50 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQ_FL_PERSON_PROFILE_TYPE")] + public partial class PimsAcqFlPersonProfileType + { + public PimsAcqFlPersonProfileType() + { + PimsAcquisitionFilePeople = new HashSet(); + } + + [Key] + [Column("ACQ_FL_PERSON_PROFILE_TYPE_CODE")] + [StringLength(20)] + public string AcqFlPersonProfileTypeCode { get; set; } + [Required] + [Column("DESCRIPTION")] + [StringLength(200)] + public string Description { get; set; } + [Required] + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("DISPLAY_ORDER")] + public int? DisplayOrder { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [InverseProperty(nameof(PimsAcquisitionFilePerson.AcqFlPersonProfileTypeCodeNavigation))] + public virtual ICollection PimsAcquisitionFilePeople { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcqPhysFileStatusType.cs b/backend/entities/ef/PimsAcqPhysFileStatusType.cs new file mode 100644 index 0000000000..c22db117f7 --- /dev/null +++ b/backend/entities/ef/PimsAcqPhysFileStatusType.cs @@ -0,0 +1,50 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQ_PHYS_FILE_STATUS_TYPE")] + public partial class PimsAcqPhysFileStatusType + { + public PimsAcqPhysFileStatusType() + { + PimsAcquisitionFiles = new HashSet(); + } + + [Key] + [Column("ACQ_PHYS_FILE_STATUS_TYPE_CODE")] + [StringLength(20)] + public string AcqPhysFileStatusTypeCode { get; set; } + [Required] + [Column("DESCRIPTION")] + [StringLength(200)] + public string Description { get; set; } + [Required] + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("DISPLAY_ORDER")] + public int? DisplayOrder { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [InverseProperty(nameof(PimsAcquisitionFile.AcqPhysFileStatusTypeCodeNavigation))] + public virtual ICollection PimsAcquisitionFiles { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionActivityInstance.cs b/backend/entities/ef/PimsAcquisitionActivityInstance.cs new file mode 100644 index 0000000000..da908f9c32 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionActivityInstance.cs @@ -0,0 +1,71 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_ACTIVITY_INSTANCE")] + [Index(nameof(AcquisitionFileId), Name = "ACQAIN_ACQUISITION_FILE_ID_IDX")] + [Index(nameof(ActivityInstanceId), Name = "ACQAIN_ACTIVITY_INSTANCE_ID_IDX")] + public partial class PimsAcquisitionActivityInstance + { + [Key] + [Column("ACQUISITION_ACTIVITY_INSTANCE_ID")] + public long AcquisitionActivityInstanceId { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long AcquisitionFileId { get; set; } + [Column("ACTIVITY_INSTANCE_ID")] + public long ActivityInstanceId { get; set; } + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [ForeignKey(nameof(AcquisitionFileId))] + [InverseProperty(nameof(PimsAcquisitionFile.PimsAcquisitionActivityInstances))] + public virtual PimsAcquisitionFile AcquisitionFile { get; set; } + [ForeignKey(nameof(ActivityInstanceId))] + [InverseProperty(nameof(PimsActivityInstance.PimsAcquisitionActivityInstances))] + public virtual PimsActivityInstance ActivityInstance { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionActivityInstanceHist.cs b/backend/entities/ef/PimsAcquisitionActivityInstanceHist.cs new file mode 100644 index 0000000000..723f39eea0 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionActivityInstanceHist.cs @@ -0,0 +1,69 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST")] + [Index(nameof(AcquisitionActivityInstanceHistId), nameof(EndDateHist), Name = "PIMS_ACQAIN_H_UK", IsUnique = true)] + public partial class PimsAcquisitionActivityInstanceHist + { + [Key] + [Column("_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID")] + public long AcquisitionActivityInstanceHistId { get; set; } + [Column("EFFECTIVE_DATE_HIST", TypeName = "datetime")] + public DateTime EffectiveDateHist { get; set; } + [Column("END_DATE_HIST", TypeName = "datetime")] + public DateTime? EndDateHist { get; set; } + [Column("ACQUISITION_ACTIVITY_INSTANCE_ID")] + public long AcquisitionActivityInstanceId { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long AcquisitionFileId { get; set; } + [Column("ACTIVITY_INSTANCE_ID")] + public long ActivityInstanceId { get; set; } + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionFile.cs b/backend/entities/ef/PimsAcquisitionFile.cs new file mode 100644 index 0000000000..af3b29b971 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionFile.cs @@ -0,0 +1,128 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_FILE")] + [Index(nameof(AcquisitionFileStatusTypeCode), Name = "ACQNFL_ACQUISITION_FILE_STATUS_TYPE_CODE_IDX")] + [Index(nameof(AcquisitionFundingTypeCode), Name = "ACQNFL_ACQUISITION_FUNDING_TYPE_CODE_IDX")] + [Index(nameof(AcquisitionTypeCode), Name = "ACQNFL_ACQUISITION_TYPE_CODE_IDX")] + [Index(nameof(AcqPhysFileStatusTypeCode), Name = "ACQNFL_ACQ_PHYS_FILE_STATUS_TYPE_CODE_IDX")] + public partial class PimsAcquisitionFile + { + public PimsAcquisitionFile() + { + PimsAcquisitionActivityInstances = new HashSet(); + PimsAcquisitionFilePeople = new HashSet(); + PimsAcquisitionOwners = new HashSet(); + PimsPropertyAcquisitionFiles = new HashSet(); + } + + [Key] + [Column("ACQUISITION_FILE_ID")] + public long AcquisitionFileId { get; set; } + [Required] + [Column("ACQUISITION_FILE_STATUS_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionFileStatusTypeCode { get; set; } + [Required] + [Column("ACQUISITION_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionTypeCode { get; set; } + [Column("ACQUISITION_FUNDING_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionFundingTypeCode { get; set; } + [Column("ACQ_PHYS_FILE_STATUS_TYPE_CODE")] + [StringLength(20)] + public string AcqPhysFileStatusTypeCode { get; set; } + [Column("MINISTRY_PROJECT_NUMBER")] + [StringLength(20)] + public string MinistryProjectNumber { get; set; } + [Column("MINISTRY_PROJECT_NAME")] + [StringLength(100)] + public string MinistryProjectName { get; set; } + [Column("CPS_PRODUCT_CODE")] + [StringLength(12)] + public string CpsProductCode { get; set; } + [Required] + [Column("FILE_NAME")] + [StringLength(500)] + public string FileName { get; set; } + [Column("FILE_NUMBER")] + [StringLength(18)] + public string FileNumber { get; set; } + [Column("REGION_CODE")] + public short RegionCode { get; set; } + [Column("FUNDING_OTHER")] + [StringLength(200)] + public string FundingOther { get; set; } + [Column("ASSIGNED_DATE", TypeName = "datetime")] + public DateTime? AssignedDate { get; set; } + [Column("DELIVERY_DATE", TypeName = "datetime")] + public DateTime? DeliveryDate { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [ForeignKey(nameof(AcqPhysFileStatusTypeCode))] + [InverseProperty(nameof(PimsAcqPhysFileStatusType.PimsAcquisitionFiles))] + public virtual PimsAcqPhysFileStatusType AcqPhysFileStatusTypeCodeNavigation { get; set; } + [ForeignKey(nameof(AcquisitionFileStatusTypeCode))] + [InverseProperty(nameof(PimsAcquisitionFileStatusType.PimsAcquisitionFiles))] + public virtual PimsAcquisitionFileStatusType AcquisitionFileStatusTypeCodeNavigation { get; set; } + [ForeignKey(nameof(AcquisitionFundingTypeCode))] + [InverseProperty(nameof(PimsAcquisitionFundingType.PimsAcquisitionFiles))] + public virtual PimsAcquisitionFundingType AcquisitionFundingTypeCodeNavigation { get; set; } + [ForeignKey(nameof(AcquisitionTypeCode))] + [InverseProperty(nameof(PimsAcquisitionType.PimsAcquisitionFiles))] + public virtual PimsAcquisitionType AcquisitionTypeCodeNavigation { get; set; } + [InverseProperty(nameof(PimsAcquisitionActivityInstance.AcquisitionFile))] + public virtual ICollection PimsAcquisitionActivityInstances { get; set; } + [InverseProperty(nameof(PimsAcquisitionFilePerson.AcquisitionFile))] + public virtual ICollection PimsAcquisitionFilePeople { get; set; } + [InverseProperty(nameof(PimsAcquisitionOwner.AcquisitionFile))] + public virtual ICollection PimsAcquisitionOwners { get; set; } + [InverseProperty(nameof(PimsPropertyAcquisitionFile.AcquisitionFile))] + public virtual ICollection PimsPropertyAcquisitionFiles { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionFileHist.cs b/backend/entities/ef/PimsAcquisitionFileHist.cs new file mode 100644 index 0000000000..15d8ea6649 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionFileHist.cs @@ -0,0 +1,102 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_FILE_HIST")] + [Index(nameof(AcquisitionFileHistId), nameof(EndDateHist), Name = "PIMS_ACQNFL_H_UK", IsUnique = true)] + public partial class PimsAcquisitionFileHist + { + [Key] + [Column("_ACQUISITION_FILE_HIST_ID")] + public long AcquisitionFileHistId { get; set; } + [Column("EFFECTIVE_DATE_HIST", TypeName = "datetime")] + public DateTime EffectiveDateHist { get; set; } + [Column("END_DATE_HIST", TypeName = "datetime")] + public DateTime? EndDateHist { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long AcquisitionFileId { get; set; } + [Required] + [Column("ACQUISITION_FILE_STATUS_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionFileStatusTypeCode { get; set; } + [Required] + [Column("ACQUISITION_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionTypeCode { get; set; } + [Column("ACQUISITION_FUNDING_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionFundingTypeCode { get; set; } + [Column("ACQ_PHYS_FILE_STATUS_TYPE_CODE")] + [StringLength(20)] + public string AcqPhysFileStatusTypeCode { get; set; } + [Column("MINISTRY_PROJECT_NUMBER")] + [StringLength(20)] + public string MinistryProjectNumber { get; set; } + [Column("MINISTRY_PROJECT_NAME")] + [StringLength(100)] + public string MinistryProjectName { get; set; } + [Column("CPS_PRODUCT_CODE")] + [StringLength(12)] + public string CpsProductCode { get; set; } + [Required] + [Column("FILE_NAME")] + [StringLength(500)] + public string FileName { get; set; } + [Column("FILE_NUMBER")] + [StringLength(18)] + public string FileNumber { get; set; } + [Column("REGION_CODE")] + public short RegionCode { get; set; } + [Column("FUNDING_OTHER")] + [StringLength(200)] + public string FundingOther { get; set; } + [Column("ASSIGNED_DATE", TypeName = "datetime")] + public DateTime? AssignedDate { get; set; } + [Column("DELIVERY_DATE", TypeName = "datetime")] + public DateTime? DeliveryDate { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionFilePerson.cs b/backend/entities/ef/PimsAcquisitionFilePerson.cs new file mode 100644 index 0000000000..77d5050963 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionFilePerson.cs @@ -0,0 +1,79 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_FILE_PERSON")] + [Index(nameof(AcquisitionFileId), Name = "ACQPER_ACQUISITION_FILE_ID_IDX")] + [Index(nameof(AcqFlPersonProfileTypeCode), Name = "ACQPER_ACQ_FL_PERSON_PROFILE_TYPE_CODE_IDX")] + [Index(nameof(PersonId), Name = "ACQPER_PERSON_ID_IDX")] + [Index(nameof(AcqFlPersonProfileTypeCode), nameof(PersonId), nameof(AcquisitionFileId), Name = "ACQPER_PERSON_PROFILE_TUC", IsUnique = true)] + public partial class PimsAcquisitionFilePerson + { + [Key] + [Column("ACQUISITION_FILE_PERSON_ID")] + public long AcquisitionFilePersonId { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long AcquisitionFileId { get; set; } + [Column("PERSON_ID")] + public long PersonId { get; set; } + [Column("ACQ_FL_PERSON_PROFILE_TYPE_CODE")] + [StringLength(20)] + public string AcqFlPersonProfileTypeCode { get; set; } + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [ForeignKey(nameof(AcqFlPersonProfileTypeCode))] + [InverseProperty(nameof(PimsAcqFlPersonProfileType.PimsAcquisitionFilePeople))] + public virtual PimsAcqFlPersonProfileType AcqFlPersonProfileTypeCodeNavigation { get; set; } + [ForeignKey(nameof(AcquisitionFileId))] + [InverseProperty(nameof(PimsAcquisitionFile.PimsAcquisitionFilePeople))] + public virtual PimsAcquisitionFile AcquisitionFile { get; set; } + [ForeignKey(nameof(PersonId))] + [InverseProperty(nameof(PimsPerson.PimsAcquisitionFilePeople))] + public virtual PimsPerson Person { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionFilePersonHist.cs b/backend/entities/ef/PimsAcquisitionFilePersonHist.cs new file mode 100644 index 0000000000..55d6ac35d6 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionFilePersonHist.cs @@ -0,0 +1,72 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_FILE_PERSON_HIST")] + [Index(nameof(AcquisitionFilePersonHistId), nameof(EndDateHist), Name = "PIMS_ACQPER_H_UK", IsUnique = true)] + public partial class PimsAcquisitionFilePersonHist + { + [Key] + [Column("_ACQUISITION_FILE_PERSON_HIST_ID")] + public long AcquisitionFilePersonHistId { get; set; } + [Column("EFFECTIVE_DATE_HIST", TypeName = "datetime")] + public DateTime EffectiveDateHist { get; set; } + [Column("END_DATE_HIST", TypeName = "datetime")] + public DateTime? EndDateHist { get; set; } + [Column("ACQUISITION_FILE_PERSON_ID")] + public long AcquisitionFilePersonId { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long AcquisitionFileId { get; set; } + [Column("PERSON_ID")] + public long PersonId { get; set; } + [Column("ACQ_FL_PERSON_PROFILE_TYPE_CODE")] + [StringLength(20)] + public string AcqFlPersonProfileTypeCode { get; set; } + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionFileStatusType.cs b/backend/entities/ef/PimsAcquisitionFileStatusType.cs new file mode 100644 index 0000000000..ce2c4a3d0e --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionFileStatusType.cs @@ -0,0 +1,50 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_FILE_STATUS_TYPE")] + public partial class PimsAcquisitionFileStatusType + { + public PimsAcquisitionFileStatusType() + { + PimsAcquisitionFiles = new HashSet(); + } + + [Key] + [Column("ACQUISITION_FILE_STATUS_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionFileStatusTypeCode { get; set; } + [Required] + [Column("DESCRIPTION")] + [StringLength(200)] + public string Description { get; set; } + [Required] + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("DISPLAY_ORDER")] + public int? DisplayOrder { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [InverseProperty(nameof(PimsAcquisitionFile.AcquisitionFileStatusTypeCodeNavigation))] + public virtual ICollection PimsAcquisitionFiles { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionFundingType.cs b/backend/entities/ef/PimsAcquisitionFundingType.cs new file mode 100644 index 0000000000..d549d1d97c --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionFundingType.cs @@ -0,0 +1,50 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_FUNDING_TYPE")] + public partial class PimsAcquisitionFundingType + { + public PimsAcquisitionFundingType() + { + PimsAcquisitionFiles = new HashSet(); + } + + [Key] + [Column("ACQUISITION_FUNDING_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionFundingTypeCode { get; set; } + [Required] + [Column("DESCRIPTION")] + [StringLength(200)] + public string Description { get; set; } + [Required] + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("DISPLAY_ORDER")] + public int? DisplayOrder { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [InverseProperty(nameof(PimsAcquisitionFile.AcquisitionFundingTypeCodeNavigation))] + public virtual ICollection PimsAcquisitionFiles { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionOwner.cs b/backend/entities/ef/PimsAcquisitionOwner.cs new file mode 100644 index 0000000000..d10c54e5b3 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionOwner.cs @@ -0,0 +1,67 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_OWNER")] + [Index(nameof(AcquisitionFileId), Name = "ACQOWN_ACQUISITION_FILE_ID_IDX")] + public partial class PimsAcquisitionOwner + { + [Key] + [Column("ACQUISITION_OWNER_ID")] + public long AcquisitionOwnerId { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long? AcquisitionFileId { get; set; } + [Required] + [Column("OWNER_NAME")] + [StringLength(300)] + public string OwnerName { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [ForeignKey(nameof(AcquisitionFileId))] + [InverseProperty(nameof(PimsAcquisitionFile.PimsAcquisitionOwners))] + public virtual PimsAcquisitionFile AcquisitionFile { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionOwnerHist.cs b/backend/entities/ef/PimsAcquisitionOwnerHist.cs new file mode 100644 index 0000000000..73970faef3 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionOwnerHist.cs @@ -0,0 +1,69 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_OWNER_HIST")] + [Index(nameof(AcquisitionOwnerHistId), nameof(EndDateHist), Name = "PIMS_ACQOWN_H_UK", IsUnique = true)] + public partial class PimsAcquisitionOwnerHist + { + [Key] + [Column("_ACQUISITION_OWNER_HIST_ID")] + public long AcquisitionOwnerHistId { get; set; } + [Column("EFFECTIVE_DATE_HIST", TypeName = "datetime")] + public DateTime EffectiveDateHist { get; set; } + [Column("END_DATE_HIST", TypeName = "datetime")] + public DateTime? EndDateHist { get; set; } + [Column("ACQUISITION_OWNER_ID")] + public long AcquisitionOwnerId { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long? AcquisitionFileId { get; set; } + [Required] + [Column("OWNER_NAME")] + [StringLength(300)] + public string OwnerName { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + } +} diff --git a/backend/entities/ef/PimsAcquisitionType.cs b/backend/entities/ef/PimsAcquisitionType.cs new file mode 100644 index 0000000000..4a2079e7e9 --- /dev/null +++ b/backend/entities/ef/PimsAcquisitionType.cs @@ -0,0 +1,50 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACQUISITION_TYPE")] + public partial class PimsAcquisitionType + { + public PimsAcquisitionType() + { + PimsAcquisitionFiles = new HashSet(); + } + + [Key] + [Column("ACQUISITION_TYPE_CODE")] + [StringLength(20)] + public string AcquisitionTypeCode { get; set; } + [Required] + [Column("DESCRIPTION")] + [StringLength(200)] + public string Description { get; set; } + [Required] + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("DISPLAY_ORDER")] + public int? DisplayOrder { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [InverseProperty(nameof(PimsAcquisitionFile.AcquisitionTypeCodeNavigation))] + public virtual ICollection PimsAcquisitionFiles { get; set; } + } +} diff --git a/backend/entities/ef/PimsActivityInstance.cs b/backend/entities/ef/PimsActivityInstance.cs index 736c95f1ce..f81cec9c11 100644 --- a/backend/entities/ef/PimsActivityInstance.cs +++ b/backend/entities/ef/PimsActivityInstance.cs @@ -9,10 +9,12 @@ namespace Pims.Dal.Entities { [Table("PIMS_ACTIVITY_INSTANCE")] + [Index(nameof(ActivityTemplateId), Name = "ACTINS_ACTIVITY_TEMPLATE_ID_IDX")] public partial class PimsActivityInstance { public PimsActivityInstance() { + PimsAcquisitionActivityInstances = new HashSet(); PimsActivityInstanceDocuments = new HashSet(); PimsActivityInstanceNotes = new HashSet(); } @@ -20,6 +22,11 @@ public PimsActivityInstance() [Key] [Column("ACTIVITY_INSTANCE_ID")] public long ActivityInstanceId { get; set; } + [Column("ACTIVITY_TEMPLATE_ID")] + public long? ActivityTemplateId { get; set; } + [Required] + [Column("ACTIVITY_DATA_JSON")] + public string ActivityDataJson { get; set; } [Column("CONCURRENCY_CONTROL_NUMBER")] public long ConcurrencyControlNumber { get; set; } [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] @@ -59,6 +66,11 @@ public PimsActivityInstance() [StringLength(30)] public string DbLastUpdateUserid { get; set; } + [ForeignKey(nameof(ActivityTemplateId))] + [InverseProperty(nameof(PimsActivityTemplate.PimsActivityInstances))] + public virtual PimsActivityTemplate ActivityTemplate { get; set; } + [InverseProperty(nameof(PimsAcquisitionActivityInstance.ActivityInstance))] + public virtual ICollection PimsAcquisitionActivityInstances { get; set; } [InverseProperty(nameof(PimsActivityInstanceDocument.ActivityInstance))] public virtual ICollection PimsActivityInstanceDocuments { get; set; } [InverseProperty(nameof(PimsActivityInstanceNote.ActivityInstance))] diff --git a/backend/entities/ef/PimsActivityInstanceHist.cs b/backend/entities/ef/PimsActivityInstanceHist.cs index 19b2478f8a..8893a97c4b 100644 --- a/backend/entities/ef/PimsActivityInstanceHist.cs +++ b/backend/entities/ef/PimsActivityInstanceHist.cs @@ -21,6 +21,8 @@ public partial class PimsActivityInstanceHist public DateTime? EndDateHist { get; set; } [Column("ACTIVITY_INSTANCE_ID")] public long ActivityInstanceId { get; set; } + [Column("ACTIVITY_TEMPLATE_ID")] + public long? ActivityTemplateId { get; set; } [Column("CONCURRENCY_CONTROL_NUMBER")] public long ConcurrencyControlNumber { get; set; } [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] diff --git a/backend/entities/ef/PimsActivityTemplate.cs b/backend/entities/ef/PimsActivityTemplate.cs new file mode 100644 index 0000000000..9646502906 --- /dev/null +++ b/backend/entities/ef/PimsActivityTemplate.cs @@ -0,0 +1,74 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACTIVITY_TEMPLATE")] + [Index(nameof(ActivityTemplateTypeCode), Name = "ACTTMP_ACTIVITY_TEMPLATE_TYPE_CODE_IDX")] + public partial class PimsActivityTemplate + { + public PimsActivityTemplate() + { + PimsActivityInstances = new HashSet(); + } + + [Key] + [Column("ACTIVITY_TEMPLATE_ID")] + public long ActivityTemplateId { get; set; } + [Column("ACTIVITY_TEMPLATE_TYPE_CODE")] + [StringLength(20)] + public string ActivityTemplateTypeCode { get; set; } + [Required] + [Column("ACTIVITY_TEMPLATE_JSON")] + public string ActivityTemplateJson { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [ForeignKey(nameof(ActivityTemplateTypeCode))] + [InverseProperty(nameof(PimsActivityTemplateType.PimsActivityTemplates))] + public virtual PimsActivityTemplateType ActivityTemplateTypeCodeNavigation { get; set; } + [InverseProperty(nameof(PimsActivityInstance.ActivityTemplate))] + public virtual ICollection PimsActivityInstances { get; set; } + } +} diff --git a/backend/entities/ef/PimsActivityTemplateHist.cs b/backend/entities/ef/PimsActivityTemplateHist.cs new file mode 100644 index 0000000000..6958a1edda --- /dev/null +++ b/backend/entities/ef/PimsActivityTemplateHist.cs @@ -0,0 +1,66 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACTIVITY_TEMPLATE_HIST")] + [Index(nameof(ActivityTemplateHistId), nameof(EndDateHist), Name = "PIMS_ACTTMP_H_UK", IsUnique = true)] + public partial class PimsActivityTemplateHist + { + [Key] + [Column("_ACTIVITY_TEMPLATE_HIST_ID")] + public long ActivityTemplateHistId { get; set; } + [Column("EFFECTIVE_DATE_HIST", TypeName = "datetime")] + public DateTime EffectiveDateHist { get; set; } + [Column("END_DATE_HIST", TypeName = "datetime")] + public DateTime? EndDateHist { get; set; } + [Column("ACTIVITY_TEMPLATE_ID")] + public long ActivityTemplateId { get; set; } + [Column("ACTIVITY_TEMPLATE_TYPE_CODE")] + [StringLength(20)] + public string ActivityTemplateTypeCode { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + } +} diff --git a/backend/entities/ef/PimsActivityTemplateType.cs b/backend/entities/ef/PimsActivityTemplateType.cs new file mode 100644 index 0000000000..8d0a69f78b --- /dev/null +++ b/backend/entities/ef/PimsActivityTemplateType.cs @@ -0,0 +1,50 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_ACTIVITY_TEMPLATE_TYPE")] + public partial class PimsActivityTemplateType + { + public PimsActivityTemplateType() + { + PimsActivityTemplates = new HashSet(); + } + + [Key] + [Column("ACTIVITY_TEMPLATE_TYPE_CODE")] + [StringLength(20)] + public string ActivityTemplateTypeCode { get; set; } + [Required] + [Column("DESCRIPTION")] + [StringLength(200)] + public string Description { get; set; } + [Required] + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("DISPLAY_ORDER")] + public int? DisplayOrder { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [InverseProperty(nameof(PimsActivityTemplate.ActivityTemplateTypeCodeNavigation))] + public virtual ICollection PimsActivityTemplates { get; set; } + } +} diff --git a/backend/entities/ef/PimsLandSurveyorType.cs b/backend/entities/ef/PimsLandSurveyorType.cs new file mode 100644 index 0000000000..46b3ccb845 --- /dev/null +++ b/backend/entities/ef/PimsLandSurveyorType.cs @@ -0,0 +1,42 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_LAND_SURVEYOR_TYPE")] + public partial class PimsLandSurveyorType + { + [Key] + [Column("LAND_SURVEYOR_TYPE_CODE")] + [StringLength(20)] + public string LandSurveyorTypeCode { get; set; } + [Required] + [Column("DESCRIPTION")] + [StringLength(200)] + public string Description { get; set; } + [Required] + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("DISPLAY_ORDER")] + public int? DisplayOrder { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + } +} diff --git a/backend/entities/ef/PimsPerson.cs b/backend/entities/ef/PimsPerson.cs index 6913c588dc..a2c546708b 100644 --- a/backend/entities/ef/PimsPerson.cs +++ b/backend/entities/ef/PimsPerson.cs @@ -13,6 +13,7 @@ public partial class PimsPerson { public PimsPerson() { + PimsAcquisitionFilePeople = new HashSet(); PimsContactMethods = new HashSet(); PimsLeaseTenantPeople = new HashSet(); PimsLeaseTenantPrimaryContacts = new HashSet(); @@ -97,6 +98,8 @@ public PimsPerson() [StringLength(30)] public string DbLastUpdateUserid { get; set; } + [InverseProperty(nameof(PimsAcquisitionFilePerson.Person))] + public virtual ICollection PimsAcquisitionFilePeople { get; set; } [InverseProperty(nameof(PimsContactMethod.Person))] public virtual ICollection PimsContactMethods { get; set; } [InverseProperty(nameof(PimsLeaseTenant.Person))] diff --git a/backend/entities/ef/PimsProperty.cs b/backend/entities/ef/PimsProperty.cs index 26a6d6699b..36c7199b87 100644 --- a/backend/entities/ef/PimsProperty.cs +++ b/backend/entities/ef/PimsProperty.cs @@ -32,6 +32,7 @@ public PimsProperty() PimsPropPropAnomalyTypes = new HashSet(); PimsPropPropRoadTypes = new HashSet(); PimsPropPropTenureTypes = new HashSet(); + PimsPropertyAcquisitionFiles = new HashSet(); PimsPropertyEvaluations = new HashSet(); PimsPropertyLeases = new HashSet(); PimsPropertyOrganizations = new HashSet(); @@ -245,6 +246,8 @@ public PimsProperty() public virtual ICollection PimsPropPropRoadTypes { get; set; } [InverseProperty(nameof(PimsPropPropTenureType.Property))] public virtual ICollection PimsPropPropTenureTypes { get; set; } + [InverseProperty(nameof(PimsPropertyAcquisitionFile.Property))] + public virtual ICollection PimsPropertyAcquisitionFiles { get; set; } [InverseProperty(nameof(PimsPropertyEvaluation.Property))] public virtual ICollection PimsPropertyEvaluations { get; set; } [InverseProperty(nameof(PimsPropertyLease.Property))] diff --git a/backend/entities/ef/PimsPropertyAcquisitionFile.cs b/backend/entities/ef/PimsPropertyAcquisitionFile.cs new file mode 100644 index 0000000000..c167521047 --- /dev/null +++ b/backend/entities/ef/PimsPropertyAcquisitionFile.cs @@ -0,0 +1,71 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_PROPERTY_ACQUISITION_FILE")] + [Index(nameof(AcquisitionFileId), Name = "PRACQF_ACQUISITION_FILE_ID_IDX")] + [Index(nameof(PropertyId), Name = "PRACQF_PROPERTY_ID_IDX")] + public partial class PimsPropertyAcquisitionFile + { + [Key] + [Column("PROPERTY_ACQUISITION_FILE_ID")] + public long PropertyAcquisitionFileId { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long AcquisitionFileId { get; set; } + [Column("PROPERTY_ID")] + public long PropertyId { get; set; } + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + + [ForeignKey(nameof(AcquisitionFileId))] + [InverseProperty(nameof(PimsAcquisitionFile.PimsPropertyAcquisitionFiles))] + public virtual PimsAcquisitionFile AcquisitionFile { get; set; } + [ForeignKey(nameof(PropertyId))] + [InverseProperty(nameof(PimsProperty.PimsPropertyAcquisitionFiles))] + public virtual PimsProperty Property { get; set; } + } +} diff --git a/backend/entities/ef/PimsPropertyAcquisitionFileHist.cs b/backend/entities/ef/PimsPropertyAcquisitionFileHist.cs new file mode 100644 index 0000000000..031f89c86a --- /dev/null +++ b/backend/entities/ef/PimsPropertyAcquisitionFileHist.cs @@ -0,0 +1,69 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_PROPERTY_ACQUISITION_FILE_HIST")] + [Index(nameof(PropertyAcquisitionFileHistId), nameof(EndDateHist), Name = "PIMS_PRACQF_H_UK", IsUnique = true)] + public partial class PimsPropertyAcquisitionFileHist + { + [Key] + [Column("_PROPERTY_ACQUISITION_FILE_HIST_ID")] + public long PropertyAcquisitionFileHistId { get; set; } + [Column("EFFECTIVE_DATE_HIST", TypeName = "datetime")] + public DateTime EffectiveDateHist { get; set; } + [Column("END_DATE_HIST", TypeName = "datetime")] + public DateTime? EndDateHist { get; set; } + [Column("PROPERTY_ACQUISITION_FILE_ID")] + public long PropertyAcquisitionFileId { get; set; } + [Column("ACQUISITION_FILE_ID")] + public long AcquisitionFileId { get; set; } + [Column("PROPERTY_ID")] + public long PropertyId { get; set; } + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("APP_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppCreateTimestamp { get; set; } + [Required] + [Column("APP_CREATE_USERID")] + [StringLength(30)] + public string AppCreateUserid { get; set; } + [Column("APP_CREATE_USER_GUID")] + public Guid? AppCreateUserGuid { get; set; } + [Required] + [Column("APP_CREATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppCreateUserDirectory { get; set; } + [Column("APP_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime AppLastUpdateTimestamp { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USERID")] + [StringLength(30)] + public string AppLastUpdateUserid { get; set; } + [Column("APP_LAST_UPDATE_USER_GUID")] + public Guid? AppLastUpdateUserGuid { get; set; } + [Required] + [Column("APP_LAST_UPDATE_USER_DIRECTORY")] + [StringLength(30)] + public string AppLastUpdateUserDirectory { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + } +} diff --git a/backend/entities/ef/PimsSurveyPlanType.cs b/backend/entities/ef/PimsSurveyPlanType.cs new file mode 100644 index 0000000000..142c645c57 --- /dev/null +++ b/backend/entities/ef/PimsSurveyPlanType.cs @@ -0,0 +1,42 @@ +using System; +using System.Collections.Generic; +using System.ComponentModel.DataAnnotations; +using System.ComponentModel.DataAnnotations.Schema; +using Microsoft.EntityFrameworkCore; + +#nullable disable + +namespace Pims.Dal.Entities +{ + [Table("PIMS_SURVEY_PLAN_TYPE")] + public partial class PimsSurveyPlanType + { + [Key] + [Column("SURVEY_PLAN_TYPE_CODE")] + [StringLength(20)] + public string SurveyPlanTypeCode { get; set; } + [Required] + [Column("DESCRIPTION")] + [StringLength(200)] + public string Description { get; set; } + [Required] + [Column("IS_DISABLED")] + public bool? IsDisabled { get; set; } + [Column("DISPLAY_ORDER")] + public int? DisplayOrder { get; set; } + [Column("CONCURRENCY_CONTROL_NUMBER")] + public long ConcurrencyControlNumber { get; set; } + [Column("DB_CREATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbCreateTimestamp { get; set; } + [Required] + [Column("DB_CREATE_USERID")] + [StringLength(30)] + public string DbCreateUserid { get; set; } + [Column("DB_LAST_UPDATE_TIMESTAMP", TypeName = "datetime")] + public DateTime DbLastUpdateTimestamp { get; set; } + [Required] + [Column("DB_LAST_UPDATE_USERID")] + [StringLength(30)] + public string DbLastUpdateUserid { get; set; } + } +} diff --git a/backend/geocoder/Extensions/ServiceCollectionExtensions.cs b/backend/geocoder/Extensions/ServiceCollectionExtensions.cs index d66ed30830..cf7c441ab8 100644 --- a/backend/geocoder/Extensions/ServiceCollectionExtensions.cs +++ b/backend/geocoder/Extensions/ServiceCollectionExtensions.cs @@ -19,7 +19,7 @@ public static IServiceCollection AddGeocoderService(this IServiceCollection serv { return services .Configure(section) - .AddScoped() + .AddSingleton() .AddScoped(); } } diff --git a/backend/geocoder/Parameters/NearestParameters.cs b/backend/geocoder/Parameters/NearestParameters.cs index dbd117d200..012230fe4e 100644 --- a/backend/geocoder/Parameters/NearestParameters.cs +++ b/backend/geocoder/Parameters/NearestParameters.cs @@ -7,6 +7,7 @@ public class NearestParameters : BaseParameters { /// /// get/set - The point (x,y) from which the nearby sites will be identified. The coordinates must be specified in the same SRS as given by the 'outputSRS' parameter. + /// example": "-122.377,50.121". /// public string Point { get; set; } /// diff --git a/backend/ltsa/LtsaService.cs b/backend/ltsa/LtsaService.cs index 96129c2c04..abd85d9574 100644 --- a/backend/ltsa/LtsaService.cs +++ b/backend/ltsa/LtsaService.cs @@ -101,6 +101,7 @@ private async Task>> SendOrderAsync(string { var orderProcessingPolicy = Policy .HandleResult>>(result => IsResponseMissingJsonAndProcessing(result)) + .Or() .WaitAndRetryAsync(Options.MaxRetries, retryAttempt => TimeSpan.FromSeconds(Math.Pow(2, retryAttempt))); try @@ -121,6 +122,11 @@ private async Task>> SendOrderAsync(string Error error = await GetLtsaError(ex, url); throw new LtsaException(ex, this.Client, error); } + catch (JsonException ex) + { + this._logger.LogError("Failed to process LTSA json: ", ex); + throw new LtsaException(ex.Message, HttpStatusCode.InternalServerError); + } } private static bool IsResponseMissingJsonAndProcessing(OrderWrapper> response) where T : IFieldedData @@ -140,7 +146,8 @@ private async Task GetLtsaError(HttpClientRequestException ex, string url } catch (JsonException) { - error = new Error(new List() { ex.Message }); + _logger.LogError(ex, $"Failed to deserialize error from remote host: ${errorContent}"); + error = new Error(new List() { ex.Message, "LTSA returned an invalid response. Please refresh your page to try again." }); } _logger.LogError(ex, $"Failed to send/receive request: ${url}"); } @@ -159,7 +166,7 @@ private async Task RefreshAccessTokenAsync() { try { - var refreshToken = _token.RefreshToken; + var refreshToken = _token?.RefreshToken; _token = null; // remove any existing token details so that the authpolicy will fetch a new token if this auth request fails. var response = await _authPolicy.ExecuteAsync(async () => await this.Client.PostJsonAsync(this.Options.AuthUrl.AppendToURL(this.Options.RefreshEndpoint), new { refreshToken })); var tokens = JsonSerializer.Deserialize(await response.Content.ReadAsStringAsync(), _jsonSerializerOptions); diff --git a/backend/tests/core/Entities/ActivityHelper.cs b/backend/tests/core/Entities/ActivityHelper.cs new file mode 100644 index 0000000000..6b4f45fb9a --- /dev/null +++ b/backend/tests/core/Entities/ActivityHelper.cs @@ -0,0 +1,41 @@ +using System; +using Pims.Dal; +using Entity = Pims.Dal.Entities; + +namespace Pims.Core.Test +{ + /// + /// EntityHelper static class, provides helper methods to create test entities. + /// + public static partial class EntityHelper + { + /// + /// Create a new instance of Activity. + /// + /// + /// + public static Entity.PimsActivityInstance CreateActivity(long id = 0, Entity.PimsNote note = null) + { + var activity = new Entity.PimsActivityInstance() + { + ActivityInstanceId = id, + AppCreateTimestamp = DateTime.Now, + AppCreateUserid = "admin", + AppCreateUserDirectory = "", + AppLastUpdateUserDirectory = "", + AppLastUpdateUserid = "", + DbCreateUserid = "", + DbLastUpdateUserid = "", + ConcurrencyControlNumber = 1 + }; + + if (note != null) + { + activity.PimsActivityInstanceNotes.Add(new Entity.PimsActivityInstanceNote() { ActivityInstance = activity, Note = note }); + } + + return activity; + } + } +} + diff --git a/backend/tests/core/Entities/NoteHelper.cs b/backend/tests/core/Entities/NoteHelper.cs new file mode 100644 index 0000000000..8489b74c6d --- /dev/null +++ b/backend/tests/core/Entities/NoteHelper.cs @@ -0,0 +1,65 @@ +using System; +using Pims.Dal; +using Entity = Pims.Dal.Entities; + +namespace Pims.Core.Test +{ + /// + /// EntityHelper static class, provides helper methods to create test entities. + /// + public static partial class EntityHelper + { + /// + /// Create a new instance of ActivityNote. + /// + /// + /// + /// + /// + public static Entity.PimsActivityInstanceNote CreateActivityNote(Entity.PimsActivityInstance activity = null, Entity.PimsNote note = null) + { + note ??= EntityHelper.CreateNote("Test Note"); + activity ??= EntityHelper.CreateActivity(1); + + return new Entity.PimsActivityInstanceNote() + { + Note = note, + ActivityInstance = activity, + AppCreateTimestamp = DateTime.Now, + AppCreateUserid = "admin", + AppCreateUserDirectory = "", + AppLastUpdateUserDirectory = "", + AppLastUpdateUserid = "", + DbCreateUserid = "", + DbLastUpdateUserid = "", + IsDisabled = false, + ConcurrencyControlNumber = 1 + }; + } + + /// + /// Create a new instance of a Note. + /// + /// + /// + /// + /// + /// + public static Entity.PimsNote CreateNote(string note) + { + return new Entity.PimsNote() + { + NoteTxt = note, + AppCreateTimestamp = DateTime.Now, + AppCreateUserid = "admin", + AppCreateUserDirectory = "", + AppLastUpdateUserDirectory = "", + AppLastUpdateUserid = "", + DbCreateUserid = "", + DbLastUpdateUserid = "", + ConcurrencyControlNumber = 1 + }; + } + } +} + diff --git a/backend/tests/core/TestHelper.cs b/backend/tests/core/TestHelper.cs index 00c6b024e4..149c334778 100644 --- a/backend/tests/core/TestHelper.cs +++ b/backend/tests/core/TestHelper.cs @@ -1,5 +1,6 @@ using Mapster; using MapsterMapper; +using Microsoft.AspNetCore.Http; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Options; using Moq; @@ -8,6 +9,7 @@ using System; using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; +using System.IO; using System.Linq; using System.Reflection; using System.Text.Json; @@ -216,6 +218,21 @@ public T CreateInstance() { return (T)ActivatorUtilities.CreateInstance(Provider, typeof(T)); } + + public IFormFile GetFormFile(string text) + { + //Setup mock file using a memory stream + var fileName = "test.pdf"; + var stream = new MemoryStream(); + var writer = new StreamWriter(stream); + writer.Write(text); + writer.Flush(); + stream.Position = 0; + + //create FormFile with desired data + IFormFile file = new FormFile(stream, 0, stream.Length, "id_from_form", fileName); + return file; + } #endregion } } diff --git a/backend/tests/unit/api/Controllers/Note/NoteControllerTest.cs b/backend/tests/unit/api/Controllers/Note/NoteControllerTest.cs index f2b16298ec..a3de647849 100644 --- a/backend/tests/unit/api/Controllers/Note/NoteControllerTest.cs +++ b/backend/tests/unit/api/Controllers/Note/NoteControllerTest.cs @@ -1,26 +1,26 @@ +using System; +using System.Collections.Generic; +using System.Diagnostics.CodeAnalysis; +using FluentAssertions; using MapsterMapper; using Microsoft.AspNetCore.Http; using Microsoft.AspNetCore.Mvc; using Moq; +using Pims.Api.Areas.Notes.Controllers; using Pims.Api.Constants; using Pims.Api.Helpers.Exceptions; using Pims.Api.Models.Concepts; +using Pims.Api.Services; using Pims.Core.Test; using Pims.Dal; +using Pims.Dal.Entities; using Pims.Dal.Entities.Models; using Pims.Dal.Exceptions; using Pims.Dal.Security; using Pims.Dal.Services; -using System; -using System.Collections.Generic; -using System.Diagnostics.CodeAnalysis; using Xunit; using Entity = Pims.Dal.Entities; using SModel = Pims.Api.Areas.Notes; -using FluentAssertions; -using Pims.Api.Areas.Notes.Controllers; -using Pims.Dal.Entities; -using Pims.Api.Services; namespace Pims.Api.Test.Controllers.Note { @@ -37,7 +37,36 @@ public class NoteControllerTest #region Tests #region GetNotes /// - /// Make a successful request that includes the research filter. + /// Make a successful request to add a note to a parent entity. + /// + [Fact] + public void AddNote_Success() + { + // Arrange + var helper = new TestHelper(); + var controller = helper.CreateController(Permissions.NoteAdd); + + var service = helper.GetService>(); + var mapper = helper.GetService(); + + var note = EntityHelper.CreateActivityNote(); + var noteModel = mapper.Map(note); + + service.Setup(m => m.Add(It.IsAny(), It.IsAny())).Returns(noteModel); + + // Act + var result = controller.AddNote(Constants.NoteType.Activity, noteModel); + + // Assert + var actionResult = Assert.IsType(result); + var actualResult = Assert.IsType(actionResult.Value); + var expectedResult = mapper.Map(note); + expectedResult.Should().BeEquivalentTo(actualResult); + service.Verify(m => m.Add(It.IsAny(), It.IsAny()), Times.Once()); + } + + /// + /// Make a successful request to get all notes for a given parent entity. /// [Fact] public void GetNotes_All_Success() @@ -46,16 +75,7 @@ public void GetNotes_All_Success() var helper = new TestHelper(); var controller = helper.CreateController(Permissions.NoteView); - var notes = new[] { new PimsNote() { - NoteId = 1, - NoteTxt = "Note 1", - AppCreateTimestamp = DateTime.Now, - AppCreateUserid = "admin" - }, new PimsNote() { - NoteId = 1, - NoteTxt = "Note 1", - AppCreateTimestamp = DateTime.Now, - AppCreateUserid = "admin" } }; + var notes = new[] { EntityHelper.CreateNote("Note 1"), EntityHelper.CreateNote("Note 2") }; var service = helper.GetService>(); var mapper = helper.GetService(); @@ -83,7 +103,7 @@ public void Delete_Note_All_Success() var service = helper.GetService>(); var mapper = helper.GetService(); - service.Setup(m => m.DeleteNote(It.IsAny(), It.IsAny())); + service.Setup(m => m.DeleteNote(It.IsAny(), It.IsAny())); // Act var result = controller.DeleteNote(Constants.NoteType.Activity, 1); @@ -91,7 +111,7 @@ public void Delete_Note_All_Success() // Assert var actionResult = Assert.IsType(result); Assert.Equal(true, actionResult.Value); - service.Verify(m => m.DeleteNote(It.IsAny(), It.IsAny()), Times.Once()); + service.Verify(m => m.DeleteNote(It.IsAny(), It.IsAny()), Times.Once()); } #endregion #endregion diff --git a/backend/tests/unit/api/Controllers/Property/PropertyControllerTest.cs b/backend/tests/unit/api/Controllers/Property/PropertyControllerTest.cs index 74323556cd..cbf3c1e658 100644 --- a/backend/tests/unit/api/Controllers/Property/PropertyControllerTest.cs +++ b/backend/tests/unit/api/Controllers/Property/PropertyControllerTest.cs @@ -22,7 +22,7 @@ public class PropertyControllerTest /// Make a successful request to fetch property by PID. /// [Fact] - public void GetConceptPropertyByPid_Success() + public void GetConceptPropertyById_Success() { // Arrange var pid = 12345; @@ -33,17 +33,17 @@ public void GetConceptPropertyByPid_Success() var service = helper.GetService>(); var mapper = helper.GetService(); - service.Setup(m => m.PropertyService.GetByPid(It.IsAny())).Returns(property); + service.Setup(m => m.PropertyService.GetById(It.IsAny())).Returns(property); // Act - var result = controller.GetConceptPropertyWithPid(pid.ToString()); + var result = controller.GetConceptPropertyWithId(property.Id); // Assert var actionResult = Assert.IsType(result); var actualResult = Assert.IsType(actionResult.Value); var expectedResult = mapper.Map(property); expectedResult.Should().BeEquivalentTo(actualResult); - service.Verify(m => m.PropertyService.GetByPid(It.IsAny()), Times.Once()); + service.Verify(m => m.PropertyService.GetById(It.IsAny()), Times.Once()); } #endregion #region Update diff --git a/backend/tests/unit/api/Routes/Notes/NoteControllerTest.cs b/backend/tests/unit/api/Routes/Notes/NoteControllerTest.cs new file mode 100644 index 0000000000..889db2ce5f --- /dev/null +++ b/backend/tests/unit/api/Routes/Notes/NoteControllerTest.cs @@ -0,0 +1,83 @@ +using Pims.Api.Areas.Notes.Controllers; +using Pims.Api.Constants; +using Pims.Api.Models.Concepts; +using Pims.Core.Extensions; +using Pims.Core.Test; +using Pims.Dal.Security; +using System.Diagnostics.CodeAnalysis; +using Xunit; + +namespace Pims.Api.Test.Routes +{ + /// + /// NoteControllerTest class, provides a way to test endpoint routes. + /// + [Trait("category", "unit")] + [Trait("category", "api")] + [Trait("group", "note")] + [Trait("group", "route")] + [ExcludeFromCodeCoverage] + public class NoteControllerTest + { + + #region Constructors + public NoteControllerTest() + { + } + #endregion + + #region Tests + [Fact] + public void Controller_Route() + { + // Arrange + // Act + // Assert + var type = typeof(NoteController); + type.HasAuthorize(); + type.HasArea("notes"); + type.HasRoute("[area]"); + type.HasRoute("v{version:apiVersion}/[area]"); + } + + [Fact] + public void AddNote_Route() + { + // Arrange + var endpoint = typeof(NoteController).FindMethod(nameof(NoteController.AddNote), typeof(NoteType), typeof(EntityNoteModel)); + + // Act + // Assert + Assert.NotNull(endpoint); + endpoint.HasPost("{type}"); + endpoint.HasPermissions(Permissions.NoteAdd); + } + + [Fact] + public void GetNotes_Route() + { + // Arrange + var endpoint = typeof(NoteController).FindMethod(nameof(NoteController.GetNotes), typeof(NoteType), typeof(long)); + + // Act + // Assert + Assert.NotNull(endpoint); + endpoint.HasGet("{type}/owner/{entityId:long}"); + endpoint.HasPermissions(Permissions.NoteView); + } + + [Fact] + public void DeleteNote_Route() + { + // Arrange + var endpoint = typeof(NoteController).FindMethod(nameof(NoteController.DeleteNote), typeof(NoteType), typeof(long)); + + // Act + // Assert + Assert.NotNull(endpoint); + endpoint.HasDelete("{type}/{noteId:long}"); + endpoint.HasPermissions(Permissions.NoteDelete); + } + #endregion + } +} diff --git a/backend/tests/unit/api/Routes/Property/PropertyControllerTest.cs b/backend/tests/unit/api/Routes/Property/PropertyControllerTest.cs index 482965e526..d573537684 100644 --- a/backend/tests/unit/api/Routes/Property/PropertyControllerTest.cs +++ b/backend/tests/unit/api/Routes/Property/PropertyControllerTest.cs @@ -40,15 +40,15 @@ public void Controller_Route() } [Fact] - public void GetConceptPropertyWithPid_Route() + public void GetConceptPropertyWithId_Route() { // Arrange - var endpoint = typeof(PropertyController).FindMethod(nameof(PropertyController.GetConceptPropertyWithPid), typeof(string)); + var endpoint = typeof(PropertyController).FindMethod(nameof(PropertyController.GetConceptPropertyWithId), typeof(long)); // Act // Assert Assert.NotNull(endpoint); - endpoint.HasGet("concept/{pid}"); + endpoint.HasGet("concept/{id}"); endpoint.HasPermissions(Permissions.PropertyView); } @@ -61,7 +61,7 @@ public void UpdateConceptProperty_Route() // Act // Assert Assert.NotNull(endpoint); - endpoint.HasPut("concept/{pid}"); + endpoint.HasPut("concept/{id}"); endpoint.HasPermissions(Permissions.PropertyEdit); } #endregion diff --git a/backend/tests/unit/dal/Libraries/Av/AvServiceCollectionTest.cs b/backend/tests/unit/dal/Libraries/Av/AvServiceCollectionTest.cs new file mode 100644 index 0000000000..cc4fdd839a --- /dev/null +++ b/backend/tests/unit/dal/Libraries/Av/AvServiceCollectionTest.cs @@ -0,0 +1,80 @@ +using FluentAssertions; +using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Logging; +using Microsoft.Extensions.Options; +using Moq; +using Pims.Av; +using Pims.Av.Configuration; +using Pims.Core.Http; +using Pims.Core.Test; +using System.Diagnostics.CodeAnalysis; +using System.IdentityModel.Tokens.Jwt; +using System.IO; +using System.Net.Http; +using System.Text; +using System.Text.Json; +using Xunit; + +namespace Pims.Dal.Test.Libraries.Av +{ + [Trait("category", "unit")] + [Trait("category", "av")] + [Trait("group", "notification")] + [ExcludeFromCodeCoverage] + public class AvServiceCollectionTest + { + public IConfiguration Configuration { get; } + + #region Tests + #region AvServiceCollection + [Fact] + public void AvServiceCollection_Success() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + helper.AddSingleton(user); + + var builder = new ConfigurationBuilder(); + var options = new ClamAvOptions() + { + DisableScan = true, + HostUri = "testuri", + Port = 1234 + }; + var avJson = JsonSerializer.Serialize(new { Av = options }); + IConfigurationRoot avConfig; + using (var io = new MemoryStream(Encoding.UTF8.GetBytes(avJson))) + { + builder.AddJsonStream(io); + avConfig = builder.Build(); + } + + var mockClientFactory = new Mock(); + var mockIOptionsMonitor = new Mock>(); + var mockIlogger = new Mock>(); + var mockIAvService = new Mock>(); + + helper.AddSingleton(mockClientFactory.Object); + helper.AddSingleton(mockIOptionsMonitor.Object); + helper.AddSingleton(mockIlogger.Object); + helper.AddSingleton(mockIAvService.Object); + + // Act + _ = helper.Services.AddClamAvService(section: avConfig.GetSection("Av")); + + var avOptions = helper.GetService>(); + var avService = helper.GetService(); + + // Assert + Assert.NotNull(avService); + Assert.NotNull(avOptions); + + avOptions.Value.DisableScan.Should().Be(options.DisableScan); + avOptions.Value.HostUri.Should().Be(options.HostUri); + avOptions.Value.Port.Should().Be(options.Port); + } + #endregion + #endregion + } +} diff --git a/backend/tests/unit/dal/Libraries/Av/ClamAvServiceTest.cs b/backend/tests/unit/dal/Libraries/Av/ClamAvServiceTest.cs new file mode 100644 index 0000000000..aeb02347ca --- /dev/null +++ b/backend/tests/unit/dal/Libraries/Av/ClamAvServiceTest.cs @@ -0,0 +1,244 @@ +using FluentAssertions; +using Microsoft.AspNetCore.Http; +using Microsoft.Extensions.Options; +using Moq; +using nClam; +using Pims.Av; +using Pims.Av.Configuration; +using Pims.Core.Exceptions; +using Pims.Core.Test; +using System; +using System.Collections.Generic; +using System.Diagnostics.CodeAnalysis; +using System.Linq; +using System.Text; +using System.Threading.Tasks; +using Xunit; + +namespace Pims.Dal.Test.Libraries.Av +{ + [Trait("category", "unit")] + [Trait("category", "av")] + [Trait("group", "notification")] + [ExcludeFromCodeCoverage] + public class ClamAvServiceTest + { + #region Tests + [Fact] + public async void Scan_Negative() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions()); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult("ok"); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + await service.ScanAsync(new byte[] { 1, 2, 3 }); + + // Verify + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Once); + } + + [Fact] + public async void Scan_Skip() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions() { DisableScan = true }); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult("ok"); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + await service.ScanAsync(new byte[] { 1, 2, 3 }); + + // Verify + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Never); + } + + [Fact] + public async void Scan_Positive() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions() { }); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult("found"); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + var exception = await Assert.ThrowsAsync(async () => await service.ScanAsync(new byte[] { 1, 2, 3 })); + + // Verify + exception.Message.Should().Contain("threats found"); + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Once); + } + + [Fact] + public async void Scan_Error() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions() {}); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult("error"); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + var exception = await Assert.ThrowsAsync(async () => await service.ScanAsync(new byte[] { 1, 2, 3 })); + + // Verify + exception.Message.Should().Contain("error"); + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Once); + } + + [Fact] + public async void Scan_Unknown() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions() { }); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult(""); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + var exception = await Assert.ThrowsAsync(async () => await service.ScanAsync(new byte[] { 1, 2, 3 })); + + // Verify + exception.Message.Should().Contain("unknown"); + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Once); + } + + [Fact] + public async void Scan_File_Negative() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions()); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult("ok"); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + await service.ScanAsync(helper.GetFormFile("")); + + // Verify + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Once); + } + + [Fact] + public async void Scan_File_Skip() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions() { DisableScan = true }); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult("ok"); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + await service.ScanAsync(helper.GetFormFile("")); + + // Verify + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Never); + } + + [Fact] + public async void Scan_File_Positive() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions() { }); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult("found"); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + var exception = await Assert.ThrowsAsync(async () => await service.ScanAsync(helper.GetFormFile(""))); + + // Verify + exception.Message.Should().Contain("threats found"); + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Once); + } + + [Fact] + public async void Scan_File_Error() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions() { }); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult("error"); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + var exception = await Assert.ThrowsAsync(async () => await service.ScanAsync(helper.GetFormFile(""))); + + // Verify + exception.Message.Should().Contain("error"); + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Once); + } + + [Fact] + public async void Scan_File_Unknown() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + var options = Options.Create(new ClamAvOptions() { }); + var service = helper.Create(options, user); + + var client = helper.GetService>(); + var scanResult = new ClamScanResult(""); + client.Setup(_ => _.SendAndScanFileAsync(It.IsAny())).ReturnsAsync(scanResult); + + // Execute + var exception = await Assert.ThrowsAsync(async () => await service.ScanAsync(helper.GetFormFile(""))); + + // Verify + exception.Message.Should().Contain("unknown"); + client.Verify(_ => _.SendAndScanFileAsync(It.IsAny()), Times.Once); + } + #endregion + } +} diff --git a/backend/tests/unit/dal/Repositories/NoteRepositoryTest.cs b/backend/tests/unit/dal/Repositories/NoteRepositoryTest.cs new file mode 100644 index 0000000000..7d037039b8 --- /dev/null +++ b/backend/tests/unit/dal/Repositories/NoteRepositoryTest.cs @@ -0,0 +1,70 @@ +using System; +using System.Diagnostics.CodeAnalysis; +using FluentAssertions; +using Pims.Core.Test; +using Pims.Dal.Entities; +using Pims.Dal.Repositories; +using Pims.Dal.Security; +using Xunit; + +namespace Pims.Dal.Test.Services +{ + [Trait("category", "unit")] + [Trait("category", "dal")] + [Trait("group", "note")] + [ExcludeFromCodeCoverage] + public class NoteRepositoryTest + { + #region Constructors + public NoteRepositoryTest() { } + #endregion + + #region Tests + + #region Add Note + [Fact] + public void Add_Success() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(Permissions.NoteAdd); + + var activity = EntityHelper.CreateActivity(); + activity.ActivityInstanceId = 1; + + var context = helper.CreatePimsContext(user, true).AddAndSaveChanges(activity); + var repository = helper.CreateRepository(user); + + var activityNote = EntityHelper.CreateActivityNote(activity); + + // Act + var result = repository.Add(activityNote); + + // Assert + result.Should().NotBeNull(); + result.Should().BeAssignableTo(); + result.Note.NoteTxt.Should().Be("Test Note"); + result.ActivityInstance.ActivityInstanceId.Should().Be(1); + } + + [Fact] + public void Add_ThrowIfNull() + { + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(Permissions.NoteAdd); + helper.CreatePimsContext(user, true); + + var repository = helper.CreateRepository(user); + + // Act + Action act = () => repository.Add(null); + + // Assert + act.Should().Throw(); + } + + #endregion + + #endregion + } +} diff --git a/backend/tests/unit/dal/Repositories/ResearchFilePropertyRepositoryTest.cs b/backend/tests/unit/dal/Repositories/ResearchFilePropertyRepositoryTest.cs new file mode 100644 index 0000000000..7fd1a39872 --- /dev/null +++ b/backend/tests/unit/dal/Repositories/ResearchFilePropertyRepositoryTest.cs @@ -0,0 +1,54 @@ +using System; +using System.Collections.Generic; +using System.Diagnostics.CodeAnalysis; +using System.Linq; +using FluentAssertions; +using Pims.Core.Test; +using Pims.Dal.Entities; +using Pims.Dal.Entities.Models; +using Pims.Dal.Exceptions; +using Pims.Dal.Repositories; +using Pims.Dal.Security; +using Xunit; +using Entity = Pims.Dal.Entities; + +namespace Pims.Dal.Test.Services +{ + [Trait("category", "unit")] + [Trait("category", "dal")] + [Trait("group", "research")] + [ExcludeFromCodeCoverage] + public class ResearchFilePropertyRepositoryTest + { + #region Data + #endregion + + #region Tests + #region Delete + [Fact] + public void Delete_PropertyResearchFile() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(Permissions.ResearchFileView); + var pimsPropertyResearchFile = new PimsPropertyResearchFile() { Property = new PimsProperty() { RegionCode = 1 } }; + pimsPropertyResearchFile.PimsPrfPropResearchPurposeTypes = new List() { new PimsPrfPropResearchPurposeType() { } }; + + var context = helper.CreatePimsContext(user, true); + context.AddAndSaveChanges(pimsPropertyResearchFile); + + var repository = helper.CreateRepository(user); + + // Act + repository.Delete(pimsPropertyResearchFile); + + // Assert + var result = repository.GetByResearchFileId(pimsPropertyResearchFile.Id); + result.Should().BeEmpty(); + } + + #endregion + + #endregion + } +} diff --git a/backend/tests/unit/dal/Services/DocumentServiceTest.cs b/backend/tests/unit/dal/Services/DocumentServiceTest.cs new file mode 100644 index 0000000000..a6c420b197 --- /dev/null +++ b/backend/tests/unit/dal/Services/DocumentServiceTest.cs @@ -0,0 +1,52 @@ +using System.Diagnostics.CodeAnalysis; +using Microsoft.AspNetCore.Http; +using Moq; +using Pims.Api.Repositories.Mayan; +using Pims.Api.Services; +using Pims.Av; +using Pims.Core.Test; +using Pims.Dal.Entities.Models; +using Pims.Dal.Exceptions; +using Pims.Dal.Repositories; +using Pims.Dal.Security; +using Pims.Dal.Services; +using Xunit; + +namespace Pims.Dal.Test.Services +{ + [Trait("category", "unit")] + [Trait("category", "dal")] + [Trait("group", "document")] + [ExcludeFromCodeCoverage] + public class DocumentServiceTest + { + + #region Tests + #region UploadDocument + [Fact] + public void UploadDocument_VirusScan() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + + helper.CreatePimsContext(user, true); + + var service = helper.Create(); + var documentRepository = helper.GetService>(); + documentRepository.Setup(x => x.UploadDocumentAsync(It.IsAny(), It.IsAny())); + var avService = helper.GetService>(); + avService.Setup(x => x.ScanAsync(It.IsAny())); + + // Act + var updatedLease = service.UploadDocumentAsync(1, helper.GetFormFile("")); + + // Assert + documentRepository.Verify(x => x.UploadDocumentAsync(It.IsAny(), It.IsAny()), Times.Once); + avService.Verify(x => x.ScanAsync(It.IsAny()), Times.Once); + } + + #endregion + #endregion + } +} diff --git a/backend/tests/unit/dal/Services/NoteServiceTest.cs b/backend/tests/unit/dal/Services/NoteServiceTest.cs new file mode 100644 index 0000000000..c02344e462 --- /dev/null +++ b/backend/tests/unit/dal/Services/NoteServiceTest.cs @@ -0,0 +1,74 @@ +using System; +using System.Diagnostics.CodeAnalysis; +using FluentAssertions; +using MapsterMapper; +using Moq; +using Pims.Api.Constants; +using Pims.Api.Models.Concepts; +using Pims.Api.Services; +using Pims.Core.Test; +using Pims.Dal.Entities; +using Pims.Dal.Exceptions; +using Pims.Dal.Repositories; +using Pims.Dal.Security; +using Xunit; + +namespace Pims.Dal.Test.Services +{ + [Trait("category", "unit")] + [Trait("category", "dal")] + [Trait("group", "note")] + [ExcludeFromCodeCoverage] + public class NoteServiceTest + { + #region Tests + #region Add + [Fact] + public void Add_Success() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(Permissions.NoteAdd); + var service = helper.Create(user); + + var mapper = helper.GetService(); + var activityNote = EntityHelper.CreateActivityNote(); + var noteModel = mapper.Map(activityNote); + + var repository = helper.GetService>(); + repository.Setup(x => x.Add(It.IsAny())).Returns(activityNote); + + // Act + var result = service.Add(NoteType.Activity, noteModel); + + // Assert + repository.Verify(x => x.Add(It.IsAny()), Times.Once); + } + + [Fact] + public void Add_NoPermission() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(); + var service = helper.Create(user); + + var mapper = helper.GetService(); + var activityNote = EntityHelper.CreateActivityNote(); + var noteModel = mapper.Map(activityNote); + + var repository = helper.GetService>(); + repository.Setup(x => x.Add(It.IsAny())).Returns(activityNote); + + // Act + Action act = () => service.Add(NoteType.Activity, noteModel); + + // Assert + act.Should().Throw(); + repository.Verify(x => x.Add(It.IsAny()), Times.Never); + } + + #endregion + #endregion + } +} diff --git a/backend/tests/unit/dal/Services/ResearchServiceTest.cs b/backend/tests/unit/dal/Services/ResearchServiceTest.cs index 5758c1c5b7..d7a68fc3ac 100644 --- a/backend/tests/unit/dal/Services/ResearchServiceTest.cs +++ b/backend/tests/unit/dal/Services/ResearchServiceTest.cs @@ -1,6 +1,9 @@ +using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; +using System.Linq; using Moq; using Pims.Core.Test; +using Pims.Dal.Entities; using Pims.Dal.Entities.Models; using Pims.Dal.Exceptions; using Pims.Dal.Repositories; @@ -58,8 +61,41 @@ public void GetPage_NoPermission() Assert.Throws(() => service.GetPage(new ResearchFilter())); researchRepository.Verify(x => x.GetPage(It.IsAny()), Times.Never); } - - #endregion + #endregion + + #region UpdateProperties + [Fact] + public void UpdateProperties_Delete() + { + // Arrange + var helper = new TestHelper(); + var user = PrincipalHelper.CreateForPermission(Permissions.ResearchFileEdit); + + var researchFile = EntityHelper.CreateResearchFile(1); + var pimsPropertyResearchFile = new PimsPropertyResearchFile() { Property = new PimsProperty() { RegionCode = 1 } }; + pimsPropertyResearchFile.PimsPrfPropResearchPurposeTypes = new List() { new PimsPrfPropResearchPurposeType() { } }; + researchFile.PimsPropertyResearchFiles.Add(pimsPropertyResearchFile); + helper.CreatePimsContext(user, true).AddAndSaveChanges(researchFile); + + var service = helper.Create(); + var researchRepository = helper.GetService>(); + researchRepository.Setup(x => x.GetPage(It.IsAny())); + researchRepository.Setup(x => x.GetRowVersion(It.IsAny())).Returns(2); + var researchFilePropertyRepository = helper.GetService>(); + researchFilePropertyRepository.Setup(x => x.Delete(It.IsAny())); + researchFilePropertyRepository.Setup(x => x.GetByResearchFileId(It.IsAny())).Returns(researchFile.PimsPropertyResearchFiles.ToList()); + + // Act + researchFile.PimsPropertyResearchFiles.Clear(); + var updatedLease = service.UpdateProperties(researchFile); + + // Assert + researchFilePropertyRepository.Verify(x => x.GetByResearchFileId(It.IsAny()), Times.Once); + researchFilePropertyRepository.Verify(x => x.Delete(It.IsAny()), Times.Once); + + #endregion + #endregion + } } } diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/01_PSP_PIMS_S32_00_Alter_Down.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/01_PSP_PIMS_S32_00_Alter_Down.sql new file mode 100644 index 0000000000..ce77a3cd5f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/01_PSP_PIMS_S32_00_Alter_Down.sql @@ -0,0 +1,1222 @@ +-- Script generated by Aqua Data Studio Schema Synchronization for MS SQL Server 2016 on Wed Jul 06 16:16:15 PDT 2022 +-- Execute this script on: +-- PSP_PIMS_S32_00/dbo - This database/schema will be modified +-- to synchronize it with MS SQL Server 2016: +-- PSP_PIMS_S31_01/dbo + +-- We recommend backing up the database prior to executing the script. + +SET XACT_ABORT ON +GO +SET TRANSACTION ISOLATION LEVEL SERIALIZABLE +GO +BEGIN TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_SRVPLT_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_SRVPLT_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_SRVPLT_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_SRVPLT_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_SRVPLT_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_SRVPLT_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTTMP_A_S_IUD_TR +PRINT N'Drop trigger dbo.PIMS_ACTTMP_A_S_IUD_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTTMP_A_S_IUD_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACQNFL_PIM_PRACQF_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACQNFL_PIM_PRACQF_FK' +GO +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] + DROP CONSTRAINT IF EXISTS [PIM_ACQNFL_PIM_PRACQF_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_PRPRTY_PIM_PRACQF_FK +PRINT N'Drop foreign key constraint dbo.PIM_PRPRTY_PIM_PRACQF_FK' +GO +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] + DROP CONSTRAINT IF EXISTS [PIM_PRPRTY_PIM_PRACQF_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACQNFL_PIM_ACQPER_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACQNFL_PIM_ACQPER_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + DROP CONSTRAINT IF EXISTS [PIM_ACQNFL_PIM_ACQPER_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_AQFPPT_PIM_ACQPER_FK +PRINT N'Drop foreign key constraint dbo.PIM_AQFPPT_PIM_ACQPER_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + DROP CONSTRAINT IF EXISTS [PIM_AQFPPT_PIM_ACQPER_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_PERSON_PIM_ACQPER_FK +PRINT N'Drop foreign key constraint dbo.PIM_PERSON_PIM_ACQPER_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + DROP CONSTRAINT IF EXISTS [PIM_PERSON_PIM_ACQPER_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACQNFL_PIM_ACQOWN_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACQNFL_PIM_ACQOWN_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] + DROP CONSTRAINT IF EXISTS [PIM_ACQNFL_PIM_ACQOWN_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACQNFL_PIM_ACQAIN_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACQNFL_PIM_ACQAIN_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] + DROP CONSTRAINT IF EXISTS [PIM_ACQNFL_PIM_ACQAIN_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACTINS_PIM_ACQAIN_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACTINS_PIM_ACQAIN_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] + DROP CONSTRAINT IF EXISTS [PIM_ACTINS_PIM_ACQAIN_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACQFTY_PIM_ACQNFL_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACQFTY_PIM_ACQNFL_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + DROP CONSTRAINT IF EXISTS [PIM_ACQFTY_PIM_ACQNFL_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACQTYP_PIM_ACQNFL_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACQTYP_PIM_ACQNFL_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + DROP CONSTRAINT IF EXISTS [PIM_ACQTYP_PIM_ACQNFL_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACQFST_PIM_ACQNFL_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACQFST_PIM_ACQNFL_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + DROP CONSTRAINT IF EXISTS [PIM_ACQFST_PIM_ACQNFL_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACQPFS_PIM_ACQNFL_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACQPFS_PIM_ACQNFL_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + DROP CONSTRAINT IF EXISTS [PIM_ACQPFS_PIM_ACQNFL_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACTTMP_PIM_ACTINS_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACTTMP_PIM_ACTINS_FK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] + DROP CONSTRAINT IF EXISTS [PIM_ACTTMP_PIM_ACTINS_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop foreign key constraint dbo.PIM_ACTTTY_PIM_ACTTMP_FK +PRINT N'Drop foreign key constraint dbo.PIM_ACTTTY_PIM_ACTTMP_FK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] + DROP CONSTRAINT IF EXISTS [PIM_ACTTTY_PIM_ACTTMP_FK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACTTMP_ACTIVITY_TEMPLATE_TYPE_CODE_IDX +PRINT N'Drop index dbo.ACTTMP_ACTIVITY_TEMPLATE_TYPE_CODE_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACTIVITY_TEMPLATE].[ACTTMP_ACTIVITY_TEMPLATE_TYPE_CODE_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_LNSRVT_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_LNSRVT_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_LNSRVT_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_LNSRVT_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_LNSRVT_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_LNSRVT_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_PRACQF_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_PRACQF_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_PRACQF_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_PRACQF_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_PRACQF_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_PRACQF_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_PRACQF_A_S_IUD_TR +PRINT N'Drop trigger dbo.PIMS_PRACQF_A_S_IUD_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_PRACQF_A_S_IUD_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.PRACQF_PROPERTY_ID_IDX +PRINT N'Drop index dbo.PRACQF_PROPERTY_ID_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_PROPERTY_ACQUISITION_FILE].[PRACQF_PROPERTY_ID_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.PRACQF_ACQUISITION_FILE_ID_IDX +PRINT N'Drop index dbo.PRACQF_ACQUISITION_FILE_ID_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_PROPERTY_ACQUISITION_FILE].[PRACQF_ACQUISITION_FILE_ID_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQNFL_A_S_IUD_TR +PRINT N'Drop trigger dbo.PIMS_ACQNFL_A_S_IUD_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQNFL_A_S_IUD_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQNFL_ACQUISITION_TYPE_CODE_IDX +PRINT N'Drop index dbo.ACQNFL_ACQUISITION_TYPE_CODE_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_FILE].[ACQNFL_ACQUISITION_TYPE_CODE_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQNFL_ACQUISITION_FUNDING_TYPE_CODE_IDX +PRINT N'Drop index dbo.ACQNFL_ACQUISITION_FUNDING_TYPE_CODE_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_FILE].[ACQNFL_ACQUISITION_FUNDING_TYPE_CODE_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQNFL_ACQUISITION_FILE_STATUS_TYPE_CODE_IDX +PRINT N'Drop index dbo.ACQNFL_ACQUISITION_FILE_STATUS_TYPE_CODE_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_FILE].[ACQNFL_ACQUISITION_FILE_STATUS_TYPE_CODE_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQNFL_ACQ_PHYS_FILE_STATUS_TYPE_CODE_IDX +PRINT N'Drop index dbo.ACQNFL_ACQ_PHYS_FILE_STATUS_TYPE_CODE_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_FILE].[ACQNFL_ACQ_PHYS_FILE_STATUS_TYPE_CODE_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQOWN_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACQOWN_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQOWN_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQOWN_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACQOWN_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQOWN_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQPER_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACQPER_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQPER_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQPER_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACQPER_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQPER_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQPER_A_S_IUD_TR +PRINT N'Drop trigger dbo.PIMS_ACQPER_A_S_IUD_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQPER_A_S_IUD_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQPER_PERSON_ID_IDX +PRINT N'Drop index dbo.ACQPER_PERSON_ID_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_PERSON].[ACQPER_PERSON_ID_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQPER_ACQUISITION_FILE_ID_IDX +PRINT N'Drop index dbo.ACQPER_ACQUISITION_FILE_ID_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_PERSON].[ACQPER_ACQUISITION_FILE_ID_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQPER_ACQ_FL_PERSON_PROFILE_TYPE_CODE_IDX +PRINT N'Drop index dbo.ACQPER_ACQ_FL_PERSON_PROFILE_TYPE_CODE_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_PERSON].[ACQPER_ACQ_FL_PERSON_PROFILE_TYPE_CODE_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_AQFPPT_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_AQFPPT_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_AQFPPT_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_AQFPPT_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_AQFPPT_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_AQFPPT_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQOWN_A_S_IUD_TR +PRINT N'Drop trigger dbo.PIMS_ACQOWN_A_S_IUD_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQOWN_A_S_IUD_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQOWN_ACQUISITION_FILE_ID_IDX +PRINT N'Drop index dbo.ACQOWN_ACQUISITION_FILE_ID_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_OWNER].[ACQOWN_ACQUISITION_FILE_ID_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQAIN_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACQAIN_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQAIN_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQAIN_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACQAIN_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQAIN_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQAIN_A_S_IUD_TR +PRINT N'Drop trigger dbo.PIMS_ACQAIN_A_S_IUD_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQAIN_A_S_IUD_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQAIN_ACTIVITY_INSTANCE_ID_IDX +PRINT N'Drop index dbo.ACQAIN_ACTIVITY_INSTANCE_ID_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE].[ACQAIN_ACTIVITY_INSTANCE_ID_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACQAIN_ACQUISITION_FILE_ID_IDX +PRINT N'Drop index dbo.ACQAIN_ACQUISITION_FILE_ID_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE].[ACQAIN_ACQUISITION_FILE_ID_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQNFL_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACQNFL_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQNFL_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQNFL_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACQNFL_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQNFL_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQFTY_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACQFTY_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQFTY_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQFTY_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACQFTY_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQFTY_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQPFS_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACQPFS_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQPFS_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQPFS_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACQPFS_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQPFS_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQTYP_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACQTYP_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQTYP_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQTYP_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACQTYP_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQTYP_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQFST_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACQFST_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQFST_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACQFST_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACQFST_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACQFST_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTINS_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACTINS_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTINS_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTINS_A_S_IUD_TR +PRINT N'Drop trigger dbo.PIMS_ACTINS_A_S_IUD_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTINS_A_S_IUD_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop index dbo.ACTINS_ACTIVITY_TEMPLATE_ID_IDX +PRINT N'Drop index dbo.ACTINS_ACTIVITY_TEMPLATE_ID_IDX' +GO +DROP INDEX IF EXISTS [dbo].[PIMS_ACTIVITY_INSTANCE].[ACTINS_ACTIVITY_TEMPLATE_ID_IDX] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTINS_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACTINS_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTINS_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTTMP_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACTTMP_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTTMP_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTTMP_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACTTMP_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTTMP_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTTTY_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACTTTY_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTTTY_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTTTY_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACTTTY_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTTTY_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.SRVPLT_PK +PRINT N'Drop primary key constraint dbo.SRVPLT_PK' +GO +ALTER TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] + DROP CONSTRAINT IF EXISTS [SRVPLT_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop unique constraint dbo.PIMS_ACTTMP_H_UK +PRINT N'Drop unique constraint dbo.PIMS_ACTTMP_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACTTMP_H_UK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.PIMS_ACTTMP_H_PK +PRINT N'Drop primary key constraint dbo.PIMS_ACTTMP_H_PK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACTTMP_H_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.LNSRVT_PK +PRINT N'Drop primary key constraint dbo.LNSRVT_PK' +GO +ALTER TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] + DROP CONSTRAINT IF EXISTS [LNSRVT_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop unique constraint dbo.PIMS_PRACQF_H_UK +PRINT N'Drop unique constraint dbo.PIMS_PRACQF_H_UK' +GO +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_PRACQF_H_UK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.PIMS_PRACQF_H_PK +PRINT N'Drop primary key constraint dbo.PIMS_PRACQF_H_PK' +GO +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_PRACQF_H_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.PRACQF_PK +PRINT N'Drop primary key constraint dbo.PRACQF_PK' +GO +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] + DROP CONSTRAINT IF EXISTS [PRACQF_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_PROPERTY_ACQUISITION_FILE +PRINT N'Drop table dbo.PIMS_PROPERTY_ACQUISITION_FILE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop unique constraint dbo.PIMS_ACQNFL_H_UK +PRINT N'Drop unique constraint dbo.PIMS_ACQNFL_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACQNFL_H_UK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.PIMS_ACQNFL_H_PK +PRINT N'Drop primary key constraint dbo.PIMS_ACQNFL_H_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACQNFL_H_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop unique constraint dbo.PIMS_ACQPER_H_UK +PRINT N'Drop unique constraint dbo.PIMS_ACQPER_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACQPER_H_UK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.PIMS_ACQPER_H_PK +PRINT N'Drop primary key constraint dbo.PIMS_ACQPER_H_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACQPER_H_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop unique constraint dbo.ACQPER_PERSON_PROFILE_TUC +PRINT N'Drop unique constraint dbo.ACQPER_PERSON_PROFILE_TUC' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + DROP CONSTRAINT IF EXISTS [ACQPER_PERSON_PROFILE_TUC] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACQPER_PK +PRINT N'Drop primary key constraint dbo.ACQPER_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + DROP CONSTRAINT IF EXISTS [ACQPER_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_FILE_PERSON +PRINT N'Drop table dbo.PIMS_ACQUISITION_FILE_PERSON' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_PERSON] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.AQFPPT_PK +PRINT N'Drop primary key constraint dbo.AQFPPT_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] + DROP CONSTRAINT IF EXISTS [AQFPPT_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACQOWN_PK +PRINT N'Drop primary key constraint dbo.ACQOWN_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] + DROP CONSTRAINT IF EXISTS [ACQOWN_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop unique constraint dbo.PIMS_ACQOWN_H_UK +PRINT N'Drop unique constraint dbo.PIMS_ACQOWN_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACQOWN_H_UK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.PIMS_ACQOWN_H_PK +PRINT N'Drop primary key constraint dbo.PIMS_ACQOWN_H_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACQOWN_H_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop unique constraint dbo.PIMS_ACQAIN_H_UK +PRINT N'Drop unique constraint dbo.PIMS_ACQAIN_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACQAIN_H_UK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.PIMS_ACQAIN_H_PK +PRINT N'Drop primary key constraint dbo.PIMS_ACQAIN_H_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST] + DROP CONSTRAINT IF EXISTS [PIMS_ACQAIN_H_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACQAIN_PK +PRINT N'Drop primary key constraint dbo.ACQAIN_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] + DROP CONSTRAINT IF EXISTS [ACQAIN_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE +PRINT N'Drop table dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACQNFL_PK +PRINT N'Drop primary key constraint dbo.ACQNFL_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + DROP CONSTRAINT IF EXISTS [ACQNFL_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACQFTY_PK +PRINT N'Drop primary key constraint dbo.ACQFTY_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] + DROP CONSTRAINT IF EXISTS [ACQFTY_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACQPFS_PK +PRINT N'Drop primary key constraint dbo.ACQPFS_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] + DROP CONSTRAINT IF EXISTS [ACQPFS_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACQTYP_PK +PRINT N'Drop primary key constraint dbo.ACQTYP_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_TYPE] + DROP CONSTRAINT IF EXISTS [ACQTYP_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACQFST_PK +PRINT N'Drop primary key constraint dbo.ACQFST_PK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] + DROP CONSTRAINT IF EXISTS [ACQFST_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACTTMP_PK +PRINT N'Drop primary key constraint dbo.ACTTMP_PK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] + DROP CONSTRAINT IF EXISTS [ACTTMP_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop primary key constraint dbo.ACTTTY_PK +PRINT N'Drop primary key constraint dbo.ACTTTY_PK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] + DROP CONSTRAINT IF EXISTS [ACTTTY_PK] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_ACTIVITY_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_ACTIVITY_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_ACTIVITY_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_FILE_NUMBER_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_FILE_NUMBER_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_NUMBER_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Alter table dbo.PIMS_ACTIVITY_INSTANCE +PRINT N'Alter table dbo.PIMS_ACTIVITY_INSTANCE' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] + DROP CONSTRAINT IF EXISTS [ACTINS_ACTIVITY_DATA_JSON_DEF] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] + DROP COLUMN IF EXISTS [ACTIVITY_TEMPLATE_ID], [ACTIVITY_DATA_JSON] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Alter table dbo.PIMS_ACTIVITY_INSTANCE_HIST +PRINT N'Alter table dbo.PIMS_ACTIVITY_INSTANCE_HIST' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] + DROP COLUMN IF EXISTS [ACTIVITY_TEMPLATE_ID] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Alter table dbo.PIMS_PROPERTY_RESEARCH_FILE +PRINT N'Alter table dbo.PIMS_PROPERTY_RESEARCH_FILE' +GO +EXEC sp_dropextendedproperty + @name = N'MS_Description' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTINS_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACTINS_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTINS_I_S_U_TR] ON PIMS_ACTIVITY_INSTANCE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACTIVITY_INSTANCE_ID = deleted.ACTIVITY_INSTANCE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_INSTANCE + set "ACTIVITY_INSTANCE_ID" = inserted."ACTIVITY_INSTANCE_ID", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_INSTANCE + inner join inserted + on (PIMS_ACTIVITY_INSTANCE.ACTIVITY_INSTANCE_ID = inserted.ACTIVITY_INSTANCE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTINS_A_S_IUD_TR +PRINT N'Create trigger dbo.PIMS_ACTINS_A_S_IUD_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTINS_A_S_IUD_TR] ON PIMS_ACTIVITY_INSTANCE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACTIVITY_INSTANCE_HIST set END_DATE_HIST = @curr_date where ACTIVITY_INSTANCE_ID in (select ACTIVITY_INSTANCE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACTIVITY_INSTANCE_HIST ([ACTIVITY_INSTANCE_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACTIVITY_INSTANCE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACTIVITY_INSTANCE_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACTIVITY_INSTANCE_H_ID_SEQ]) as [_ACTIVITY_INSTANCE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTINS_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACTINS_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTINS_I_S_I_TR] ON PIMS_ACTIVITY_INSTANCE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_INSTANCE ("ACTIVITY_INSTANCE_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACTIVITY_INSTANCE_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_SURVEY_PLAN_TYPE +PRINT N'Drop table dbo.PIMS_SURVEY_PLAN_TYPE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_SURVEY_PLAN_TYPE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACTIVITY_TEMPLATE_HIST +PRINT N'Drop table dbo.PIMS_ACTIVITY_TEMPLATE_HIST' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACTIVITY_TEMPLATE_HIST] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_LAND_SURVEYOR_TYPE +PRINT N'Drop table dbo.PIMS_LAND_SURVEYOR_TYPE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_LAND_SURVEYOR_TYPE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_PROPERTY_ACQUISITION_FILE_HIST +PRINT N'Drop table dbo.PIMS_PROPERTY_ACQUISITION_FILE_HIST' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_HIST] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_FILE_HIST +PRINT N'Drop table dbo.PIMS_ACQUISITION_FILE_HIST' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_HIST] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_FILE_H_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_FILE_H_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_H_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_FILE_PERSON_HIST +PRINT N'Drop table dbo.PIMS_ACQUISITION_FILE_PERSON_HIST' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_PERSON_HIST] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_FILE_PERSON_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_FILE_PERSON_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_PERSON_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQ_FL_PERSON_PROFILE_TYPE +PRINT N'Drop table dbo.PIMS_ACQ_FL_PERSON_PROFILE_TYPE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_OWNER +PRINT N'Drop table dbo.PIMS_ACQUISITION_OWNER' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_OWNER] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_OWNER_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_OWNER_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_OWNER_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_OWNER_HIST +PRINT N'Drop table dbo.PIMS_ACQUISITION_OWNER_HIST' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_OWNER_HIST] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_OWNER_H_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_OWNER_H_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_OWNER_H_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST +PRINT N'Drop table dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_FILE +PRINT N'Drop table dbo.PIMS_ACQUISITION_FILE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_FUNDING_TYPE +PRINT N'Drop table dbo.PIMS_ACQUISITION_FUNDING_TYPE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQ_PHYS_FILE_STATUS_TYPE +PRINT N'Drop table dbo.PIMS_ACQ_PHYS_FILE_STATUS_TYPE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_TYPE +PRINT N'Drop table dbo.PIMS_ACQUISITION_TYPE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_TYPE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACQUISITION_FILE_STATUS_TYPE +PRINT N'Drop table dbo.PIMS_ACQUISITION_FILE_STATUS_TYPE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACQUISITION_FILE_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACQUISITION_FILE_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACQUISITION_FILE_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACTIVITY_TEMPLATE +PRINT N'Drop table dbo.PIMS_ACTIVITY_TEMPLATE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACTIVITY_TEMPLATE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop sequence dbo.PIMS_ACTIVITY_TEMPLATE_ID_SEQ +PRINT N'Drop sequence dbo.PIMS_ACTIVITY_TEMPLATE_ID_SEQ' +GO +DROP SEQUENCE IF EXISTS [dbo].[PIMS_ACTIVITY_TEMPLATE_ID_SEQ] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop table dbo.PIMS_ACTIVITY_TEMPLATE_TYPE +PRINT N'Drop table dbo.PIMS_ACTIVITY_TEMPLATE_TYPE' +GO +DROP TABLE IF EXISTS [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +COMMIT TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DECLARE @Success AS BIT +SET @Success = 1 +SET NOEXEC OFF +IF (@Success = 1) PRINT 'The database update succeeded' +ELSE BEGIN + IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION + PRINT 'The database update failed' +END +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/10_DML_PIMS_STATIC_VARIABLE_VERSION.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/10_DML_PIMS_STATIC_VARIABLE_VERSION.sql new file mode 100644 index 0000000000..e3687a9287 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/10_DML_PIMS_STATIC_VARIABLE_VERSION.sql @@ -0,0 +1,26 @@ +/* ----------------------------------------------------------------------------- +Update the database version in the PIMS_STATIC_VARIABLE table. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Nov-24 Initial version +----------------------------------------------------------------------------- */ + +BEGIN TRANSACTION; + +DECLARE @CurrVer NVARCHAR(100) +SET @CurrVer = N'31.01' + +UPDATE PIMS_STATIC_VARIABLE +WITH (UPDLOCK, SERIALIZABLE) +SET STATIC_VARIABLE_VALUE = @CurrVer + , CONCURRENCY_CONTROL_NUMBER = CONCURRENCY_CONTROL_NUMBER + 1 +WHERE STATIC_VARIABLE_NAME = N'DBVERSION'; + +IF @@ROWCOUNT = 0 + BEGIN + INSERT INTO PIMS_STATIC_VARIABLE (STATIC_VARIABLE_NAME, STATIC_VARIABLE_VALUE) + VALUES (N'DBVERSION', @CurrVer); + END + +COMMIT TRANSACTION; diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/11_DML_PIMS_ROLE_CLAIM.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/11_DML_PIMS_ROLE_CLAIM.sql new file mode 100644 index 0000000000..167a3e9aaf --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/11_DML_PIMS_ROLE_CLAIM.sql @@ -0,0 +1,15 @@ +DECLARE @restricted BIGINT; +DECLARE @finance BIGINT; +SELECT @restricted = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Functional (Restricted)'; +SELECT @finance = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Finance'; + +DECLARE @researchAdd BIGINT; +DECLARE @leaseEdit BIGINT; +select @researchAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'researchfile-add'; +select @leaseEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'lease-edit'; + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @researchAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@finance, @leaseEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +GO \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/74_DML_PIMS_CLAIM.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/74_DML_PIMS_CLAIM.sql new file mode 100644 index 0000000000..e925b7f272 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/74_DML_PIMS_CLAIM.sql @@ -0,0 +1,14 @@ +DECLARE @noteView BIGINT; +DECLARE @noteAdd BIGINT; +DECLARE @noteEdit BIGINT; +DECLARE @noteDelete BIGINT; +SELECT @noteView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-view'; +SELECT @noteAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-add'; +SELECT @noteEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-edit'; +SELECT @noteDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-delete'; + +DELETE FROM [dbo].[PIMS_CLAIM] WHERE CLAIM_ID = @noteView; +DELETE FROM [dbo].[PIMS_CLAIM] WHERE CLAIM_ID = @noteAdd; +DELETE FROM [dbo].[PIMS_CLAIM] WHERE CLAIM_ID = @noteEdit; +DELETE FROM [dbo].[PIMS_CLAIM] WHERE CLAIM_ID = @noteDelete; +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/75_DML_PIMS_ROLE_CLAIM.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/75_DML_PIMS_ROLE_CLAIM.sql new file mode 100644 index 0000000000..2672cbe761 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/75_DML_PIMS_ROLE_CLAIM.sql @@ -0,0 +1,39 @@ +DECLARE @finance BIGINT; +DECLARE @functional BIGINT; +DECLARE @restricted BIGINT; +DECLARE @readOnly BIGINT; +DECLARE @systemAdministrator BIGINT; +SELECT @finance = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Finance'; +SELECT @functional = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Functional'; +SELECT @restricted = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Functional (Restricted)'; +SELECT @readOnly = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Read Only'; +SELECT @systemAdministrator = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'System Administrator'; + +DECLARE @noteView BIGINT; +DECLARE @noteAdd BIGINT; +DECLARE @noteEdit BIGINT; +DECLARE @noteDelete BIGINT; +SELECT @noteView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-view'; +SELECT @noteAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-add'; +SELECT @noteEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-edit'; +SELECT @noteDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-delete'; + +/* Functional */ +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteView AND ROLE_ID = @functional; +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteEdit AND ROLE_ID = @functional; +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteAdd AND ROLE_ID = @functional; + +/* Functional Restricted */ +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteView AND ROLE_ID = @restricted; +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteEdit AND ROLE_ID = @restricted; +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteAdd AND ROLE_ID = @restricted; + +/* Read Only */ +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteView AND ROLE_ID = @readOnly; + +/* System Administrator */ +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteView AND ROLE_ID = @systemAdministrator; +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteEdit AND ROLE_ID = @systemAdministrator; +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteAdd AND ROLE_ID = @systemAdministrator; +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE CLAIM_ID = @noteDelete AND ROLE_ID = @systemAdministrator; +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/Schema Compare.zip b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/Schema Compare.zip new file mode 100644 index 0000000000..3d4ee13858 Binary files /dev/null and b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Down/Schema Compare.zip differ diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/00_PSP_PIMS_PMBC_SCHEMA_Build.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/00_PSP_PIMS_PMBC_SCHEMA_Build.sql new file mode 100644 index 0000000000..e6a023c739 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/00_PSP_PIMS_PMBC_SCHEMA_Build.sql @@ -0,0 +1,38 @@ +-- Script generated by Aqua Data Studio Schema Synchronization for MS SQL Server 2016 on Tue Oct 05 16:47:03 PDT 2021 +-- Execute this script on: +-- pmbc schema will be created + +-- We recommend backing up the database prior to executing the script. + +SET XACT_ABORT ON +GO +SET TRANSACTION ISOLATION LEVEL SERIALIZABLE +GO +BEGIN TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create PMBC schema +IF NOT EXISTS (SELECT * + FROM sys.schemas + WHERE name = N'pmbc') + EXEC('CREATE SCHEMA [pmbc]'); +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +COMMIT TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DECLARE @Success AS BIT +SET @Success = 1 +SET NOEXEC OFF +IF (@Success = 1) PRINT 'The database update succeeded' +ELSE BEGIN + IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION + PRINT 'The database update failed' +END +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/01_PSP_PIMS_PMBC_Tables_Build.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/01_PSP_PIMS_PMBC_Tables_Build.sql new file mode 100644 index 0000000000..8e449f0e8c --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/01_PSP_PIMS_PMBC_Tables_Build.sql @@ -0,0 +1,111 @@ +-- Script generated by Aqua Data Studio Schema Synchronization for MS SQL Server 2016 on Tue Oct 05 16:47:03 PDT 2021 +-- Execute this script on: +-- PIMS_S09_01/pmbc - This database/schema will be modified +-- to synchronize it with MS SQL Server 2016: +-- PIMS_S09_02/pmbc + +-- We recommend backing up the database prior to executing the script. + +SET XACT_ABORT ON +GO +SET TRANSACTION ISOLATION LEVEL SERIALIZABLE +GO +BEGIN TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +-- Create table pmbc.PMBC_PARCEL_POLYGON_FABRIC if not existing +PRINT N'Create table pmbc.PMBC_PARCEL_POLYGON_FABRIC' +GO +IF NOT EXISTS (SELECT * + FROM information_schema.tables + WHERE table_schema = 'pmbc' + AND table_name = 'PMBC_PARCEL_POLYGON_FABRIC') + BEGIN + CREATE TABLE [pmbc].[PMBC_PARCEL_POLYGON_FABRIC] ( + [PARCEL_FABRIC_POLY_ID] INTEGER NOT NULL, + [GLOBAL_UID] NVARCHAR(254), + [PARCEL_NAME] NVARCHAR(50), + [PLAN_ID] INTEGER, + [PLAN_NUMBER] NVARCHAR(128), + [PIN] INTEGER, + [PID] NVARCHAR(9), + [PID_NUMBER] INTEGER, + [SOURCE_PARCEL_ID] NVARCHAR(50), + [PARCEL_STATUS] NVARCHAR(20), + [PARCEL_CLASS] NVARCHAR(50), + [OWNER_TYPE] NVARCHAR(50), + [PARCEL_START_DATE] DATETIME, + [SURVEY_DESIGNATION_1] NVARCHAR(30), + [SURVEY_DESIGNATION_2] NVARCHAR(30), + [SURVEY_DESIGNATION_3] NVARCHAR(30), + [LEGAL_DESCRIPTION] NVARCHAR(2000), + [MUNICIPALITY] NVARCHAR(254), + [REGIONAL_DISTRICT] NVARCHAR(50), + [IS_REMAINDER_IND] NVARCHAR(3), + [GEOMETRY_SOURCE] NVARCHAR(50), + [POSITIONAL_ERROR] BIGINT, + [ERROR_REPORTED_BY] NVARCHAR(50), + [CAPTURE_METHOD] NVARCHAR(50), + [COMPILED_IND] NVARCHAR(5), + [STATED_AREA] NVARCHAR(50), + [WHEN_CREATED] DATETIME, + [WHEN_UPDATED] DATETIME, + [FEATURE_AREA_SQM] BIGINT, + [FEATURE_LENGTH_M] BIGINT, + [SHAPE] GEOMETRY, + [OBJECTID] NUMERIC(38), + [SE_ANNO_CAD_DATA] VARBINARY(max), + CONSTRAINT [PRCPLY_PK] PRIMARY KEY ([PARCEL_FABRIC_POLY_ID]) + ) + EXECUTE sp_addextendedproperty N'MS_Description', N'The ParcelMap BC (PMBC) parcel fabric contains all active titled parcels and surveyed provincial Crown land parcels in BC. For building strata parcels, there is a record, with PID value, for each parcel within the strata parcel; the geometry for those records is the geometry for the overall strata. This dataset is polygonal and contains all parcel attributes.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', NULL, NULL + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_FABRIC_POLY_ID is a system generated unique identification number.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_FABRIC_POLY_ID' + EXECUTE sp_addextendedproperty N'MS_Description', N'GLOBAL_UID is a unique global identifier (GUID) for the parcel.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'GLOBAL_UID' + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_NAME is the same as the PID, if there is one. If there is a PIN but no PID, then PARCEL_NAME is the PIN. If there is no PID nor PIN, then PARCEL_NAME is the parcel class value, e.g., COMMON OWNERSHIP, BUILDING STRATA, AIR SPACE, ROAD, PARK.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_NAME' + EXECUTE sp_addextendedproperty N'MS_Description', N'PLAN_ID is the unique identifier of the land survey plan that corresponds to this parcel.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PLAN_ID' + EXECUTE sp_addextendedproperty N'MS_Description', N'PLAN_NUMBER is the Land Act, Land Title Act, or Strata Property Act Plan Number for the land survey plan that corresponds to this parcel, e.g., VIP1632, NO_PLAN.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PLAN_NUMBER' + EXECUTE sp_addextendedproperty N'MS_Description', N'PIN is the Crown Land Registry Parcel Identifier, if applicable.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PIN' + EXECUTE sp_addextendedproperty N'MS_Description', N'PID is the Land Title Register parcel identifier, a left-zero-padded nine-digit number that uniquely identifies a parcel in the land title register of in British Columbia. The registrar assigns PID numbers to parcels for which a title is being entered as a registered title. The Land Title Act refers to the PID as the permanent parcel identifier.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PID' + EXECUTE sp_addextendedproperty N'MS_Description', N'PID_NUMBER is the PID, without leading zeroes. PID is the Land Title Register parcel identifier, a nine-digit number that uniquely identifies a parcel in the land title register of in British Columbia. The registrar assigns PID numbers to parcels for which a title is being entered as a registered title. The Land Title Act refers to the PID as the permanent parcel identifier.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PID_NUMBER' + EXECUTE sp_addextendedproperty N'MS_Description', N'SOURCE_PARCEL_ID is the unique parcel identifier supplied by the source data provider. The value is intended to assist local governments by providing traceability back to the source data provider''s parcel ID. It will not be populated during on-going operations, e.g., DATA_NEW, CPG000050, 999, 01762.146.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SOURCE_PARCEL_ID' + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_STATUS is the status of the parcel, according to the Land Title Register or Crown Land Registry, as appropriate, i.e., ACTIVE, CANCELLED, INACTIVE, PENDING.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_STATUS' + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_CLASS is the Parcel classification for maintenance, mapping, publishing and analysis, i.e., PRIMARY, SUBDIVISION, PART OF PRIMARY, BUILDING STRATA, BARE LAND STRATA, AIR SPACE, ROAD, HIGHWAY, PARK, INTEREST, COMMON OWNERSHIP, ABSOLUTE FEE BOOK, CROWN SUBDIVISION, RETURN TO CROWN.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_CLASS' + EXECUTE sp_addextendedproperty N'MS_Description', N'OWNER_TYPE is the general ownership category, e.g., PRIVATE, CROWN PROVINCIAL, MUNICIPAL.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'OWNER_TYPE' + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_START_DATE is the date of the legal event that created the parcel, i.e., the date the plan was filed.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_START_DATE' + EXECUTE sp_addextendedproperty N'MS_Description', N'SURVEY_DESIGNATION_1 is, typically, the smallest division of lands in a survey. If available, this is generally the Parcel from a Subdivided short legal description or the Quadrant or Block from an Unsubdivided short legal description, e.g., PARCEL A, SW4.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SURVEY_DESIGNATION_1' + EXECUTE sp_addextendedproperty N'MS_Description', N'SURVEY_DESIGNATION_2 is, typically, the second smallest division of lands in a survey. If available, this is generally the Lot from a Subdivided short legal description or the District Lot, Lot or Section from an Unsubdivided short legal description, e.g., LOT 2.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SURVEY_DESIGNATION_2' + EXECUTE sp_addextendedproperty N'MS_Description', N'SURVEY_DESIGNATION_3 is, typically, the third smallest division of lands in a survey. If available, this is generally the Block from a Subdivided short legal description or the Range from an Unsubdivided short legal description, e.g., BLOCK H.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SURVEY_DESIGNATION_3' + EXECUTE sp_addextendedproperty N'MS_Description', N'LEGAL_DESCRIPTION is the full legal description of the parcel and is primarily recorded from the Land Title Register. Where recorded only in the Crown Land Registry, this attribute is to be populated from Tantalis for the fabric compilation, but maintained by PMBC during on-going operations.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'LEGAL_DESCRIPTION' + EXECUTE sp_addextendedproperty N'MS_Description', N'MUNICIPALITY is the municipal area within which the parcel is located. The value is either RURAL (for parcels in unincorporated regions) or the name of a BC municipality.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'MUNICIPALITY' + EXECUTE sp_addextendedproperty N'MS_Description', N'REGIONAL_DISTRICT is the name of the regional district in which the parcel is located, e.g., CAPITAL REGIONAL DISTRICT.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'REGIONAL_DISTRICT' + EXECUTE sp_addextendedproperty N'MS_Description', N'IS_REMAINDER_IND indicates if the parcel is a remainder of the original, i.e., YES, NO.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'IS_REMAINDER_IND' + EXECUTE sp_addextendedproperty N'MS_Description', N'GEOMETRY_SOURCE is the source of the parcel geometry data, e.g., ICIS CADASTRE, ICF, PMBC OPERATIONS.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'GEOMETRY_SOURCE' + EXECUTE sp_addextendedproperty N'MS_Description', N'POSITIONAL_ERROR is the semi-major axis at the 95% confidence level of the least accurate point of the parcel.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'POSITIONAL_ERROR' + EXECUTE sp_addextendedproperty N'MS_Description', N'ERROR_REPORTED_BY is the organization or process reporting the error, i.e., LSA, DATA COMPILATION.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'ERROR_REPORTED_BY' + EXECUTE sp_addextendedproperty N'MS_Description', N'CAPTURE_METHOD is an indicator of relative accuracy, i.e., UNKNOWN, COGO, SURVEY PLAN DATASET.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'CAPTURE_METHOD' + EXECUTE sp_addextendedproperty N'MS_Description', N'COMPILED_IND indicates if the parcel polygon was generated from inverted dimensions, i.e., True, False. "True" means that the parcel geometry was from a previous source cadastre and not precision input based on plan dimensions.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'COMPILED_IND' + EXECUTE sp_addextendedproperty N'MS_Description', N'STATED_AREA is the area of the parcel, in square metres. It is automatically calculated if misclose is small; it can be edited to reflect the recorded plan value.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'STATED_AREA' + EXECUTE sp_addextendedproperty N'MS_Description', N'WHEN_CREATED is the date and time the source record was created (not the time when it was loaded into the BC Geographic Warehouse).', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'WHEN_CREATED' + EXECUTE sp_addextendedproperty N'MS_Description', N'WHEN_UPDATED is the date and time the source record was last modified (not the time when it was loaded into, or modified in, the BC Geographic Warehouse).', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'WHEN_UPDATED' + EXECUTE sp_addextendedproperty N'MS_Description', N'FEATURE_AREA_SQM is the system calculated area of a two-dimensional polygon in square meters.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'FEATURE_AREA_SQM' + EXECUTE sp_addextendedproperty N'MS_Description', N'FEATURE_LENGTH_M is the system calculated length or perimeter of a geometry in meters.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'FEATURE_LENGTH_M' + EXECUTE sp_addextendedproperty N'MS_Description', N'SHAPE is the column used to reference the spatial coordinates defining the feature.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SHAPE' + EXECUTE sp_addextendedproperty N'MS_Description', N'OBJECTID is a column required by spatial layers that interact with ESRI ArcSDE. It is populated with unique values automatically by SDE.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'OBJECTID' + EXECUTE sp_addextendedproperty N'MS_Description', N'SE_ANNO_CAD_DATA is a binary column used by spatial tools to store annotation, curve features and CAD data when using the SDO_GEOMETRY storage data type.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SE_ANNO_CAD_DATA' + END + +COMMIT TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DECLARE @Success AS BIT +SET @Success = 1 +SET NOEXEC OFF +IF (@Success = 1) PRINT 'The database update succeeded' +ELSE BEGIN + IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION + PRINT 'The database update failed' +END +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/02_PSP_PIMS_S32_00_Alter_Up.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/02_PSP_PIMS_S32_00_Alter_Up.sql new file mode 100644 index 0000000000..19ef9ca0a4 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/02_PSP_PIMS_S32_00_Alter_Up.sql @@ -0,0 +1,2948 @@ +-- Script generated by Aqua Data Studio Schema Synchronization for MS SQL Server 2016 on Wed Jul 06 15:53:08 PDT 2022 +-- Execute this script on: +-- PSP_PIMS_S31_01/dbo - This database/schema will be modified +-- to synchronize it with MS SQL Server 2016: +-- PSP_PIMS_S32_00/dbo + +-- We recommend backing up the database prior to executing the script. + +SET XACT_ABORT ON +GO +SET TRANSACTION ISOLATION LEVEL SERIALIZABLE +GO +BEGIN TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTINS_I_S_I_TR +PRINT N'Drop trigger dbo.PIMS_ACTINS_I_S_I_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTINS_I_S_I_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTINS_A_S_IUD_TR +PRINT N'Drop trigger dbo.PIMS_ACTINS_A_S_IUD_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTINS_A_S_IUD_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Drop trigger dbo.PIMS_ACTINS_I_S_U_TR +PRINT N'Drop trigger dbo.PIMS_ACTINS_I_S_U_TR' +GO +DROP TRIGGER IF EXISTS [dbo].[PIMS_ACTINS_I_S_U_TR] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_FILE_NUMBER_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_FILE_NUMBER_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_NUMBER_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_ACTIVITY_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_ACTIVITY_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_ACTIVITY_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_FILE_PERSON_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_FILE_PERSON_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_PERSON_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQ_FL_PERSON_PROFILE_TYPE +PRINT N'Create table dbo.PIMS_ACQ_FL_PERSON_PROFILE_TYPE' +GO +CREATE TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] ( + [ACQ_FL_PERSON_PROFILE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [AQFPPT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [AQFPPT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [AQFPPT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [AQFPPT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [AQFPPT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [AQFPPT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [AQFPPT_PK] PRIMARY KEY CLUSTERED([ACQ_FL_PERSON_PROFILE_TYPE_CODE]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion file staff profile (role).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', + @level2type = N'Column', @level2name = N'ACQ_FL_PERSON_PROFILE_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion file staff profile (role).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion file staff profile (role).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_FILE_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_FILE_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQ_PHYS_FILE_STATUS_TYPE +PRINT N'Create table dbo.PIMS_ACQ_PHYS_FILE_STATUS_TYPE' +GO +CREATE TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] ( + [ACQ_PHYS_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACQPFS_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQPFS_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPFS_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPFS_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPFS_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPFS_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQPFS_PK] PRIMARY KEY CLUSTERED([ACQ_PHYS_FILE_STATUS_TYPE_CODE]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion physical file status type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'ACQ_PHYS_FILE_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion physical file status type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion physical file status type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_FILE_STATUS_TYPE +PRINT N'Create table dbo.PIMS_ACQUISITION_FILE_STATUS_TYPE' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] ( + [ACQUISITION_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACQFST_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQFST_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQFST_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQFST_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQFST_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQFST_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQFST_PK] PRIMARY KEY CLUSTERED([ACQUISITION_FILE_STATUS_TYPE_CODE]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion file status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'ACQUISITION_FILE_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion file status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion file status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_FUNDING_TYPE +PRINT N'Create table dbo.PIMS_ACQUISITION_FUNDING_TYPE' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] ( + [ACQUISITION_FUNDING_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACQFTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQFTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQFTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQFTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQFTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQFTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQFTY_PK] PRIMARY KEY CLUSTERED([ACQUISITION_FUNDING_TYPE_CODE]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion funding type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE', + @level2type = N'Column', @level2name = N'ACQUISITION_FUNDING_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion funding type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion funding type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_TYPE +PRINT N'Create table dbo.PIMS_ACQUISITION_TYPE' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_TYPE] ( + [ACQUISITION_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACQTYP_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQTYP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQTYP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQTYP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQTYP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQTYP_PK] PRIMARY KEY CLUSTERED([ACQUISITION_TYPE_CODE]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE', + @level2type = N'Column', @level2name = N'ACQUISITION_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_FILE +PRINT N'Create table dbo.PIMS_ACQUISITION_FILE' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE] ( + [ACQUISITION_FILE_ID] bigint NOT NULL CONSTRAINT [ACQNFL_ACQUISITION_FILE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_FILE_ID_SEQ]), + [ACQUISITION_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [ACQUISITION_TYPE_CODE] nvarchar(20) NOT NULL, + [ACQUISITION_FUNDING_TYPE_CODE] nvarchar(20) NULL, + [ACQ_PHYS_FILE_STATUS_TYPE_CODE] nvarchar(20) NULL, + [MINISTRY_PROJECT_NUMBER] nvarchar(20) NULL, + [MINISTRY_PROJECT_NAME] nvarchar(100) NULL, + [CPS_PRODUCT_CODE] nvarchar(12) NULL, + [FILE_NAME] nvarchar(500) NOT NULL, + [FILE_NUMBER] nvarchar(18) NULL, + [REGION_CODE] smallint NOT NULL CONSTRAINT [ACQNFL_REGION_CODE_DEF] DEFAULT ((-1)), + [FUNDING_OTHER] nvarchar(200) NULL, + [ASSIGNED_DATE] datetime NULL CONSTRAINT [ACQNFL_ASSIGNED_DATE_DEF] DEFAULT (getutcdate()), + [DELIVERY_DATE] datetime NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQNFL_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQNFL_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQNFL_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQNFL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQNFL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQNFL_PK] PRIMARY KEY CLUSTERED([ACQUISITION_FILE_ID]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Ministry project number.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'MINISTRY_PROJECT_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Ministry project name.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'MINISTRY_PROJECT_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'CPS product code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'CPS_PRODUCT_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Descriptive name given to the acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'FILE_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'File number assigned to the acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'FILE_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Region responsible for oversight of the acquisition.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'REGION_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of other funding type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'FUNDING_OTHER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date of file assignment.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'ASSIGNED_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date of file delivery.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'DELIVERY_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Entity containing information regarding an acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_FILE_PERSON +PRINT N'Create table dbo.PIMS_ACQUISITION_FILE_PERSON' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] ( + [ACQUISITION_FILE_PERSON_ID] bigint NOT NULL CONSTRAINT [ACQPER_ACQUISITION_FILE_PERSON_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_FILE_PERSON_ID_SEQ]), + [ACQUISITION_FILE_ID] bigint NOT NULL, + [PERSON_ID] bigint NOT NULL, + [ACQ_FL_PERSON_PROFILE_TYPE_CODE] nvarchar(20) NULL, + [IS_DISABLED] bit NULL CONSTRAINT [ACQPER_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQPER_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPER_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPER_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPER_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPER_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQPER_PK] PRIMARY KEY CLUSTERED([ACQUISITION_FILE_PERSON_ID]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the relationship is active.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_PERSON', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Table to associate an acquisition file to a person.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_PERSON' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create unique constraint dbo.ACQPER_PERSON_PROFILE_TUC +PRINT N'Create unique constraint dbo.ACQPER_PERSON_PROFILE_TUC' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + ADD CONSTRAINT [ACQPER_PERSON_PROFILE_TUC] + UNIQUE ([ACQ_FL_PERSON_PROFILE_TYPE_CODE], [PERSON_ID], [ACQUISITION_FILE_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_OWNER_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_OWNER_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_OWNER_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_OWNER +PRINT N'Create table dbo.PIMS_ACQUISITION_OWNER' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_OWNER] ( + [ACQUISITION_OWNER_ID] bigint NOT NULL CONSTRAINT [ACQOWN_ACQUISITION_OWNER_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_OWNER_ID_SEQ]), + [ACQUISITION_FILE_ID] bigint NULL, + [OWNER_NAME] nvarchar(300) NOT NULL CONSTRAINT [ACQOWN_OWNER_NAME_DEF] DEFAULT (''), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQOWN_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQOWN_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQOWN_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQOWN_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQOWN_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQOWN_PK] PRIMARY KEY CLUSTERED([ACQUISITION_OWNER_ID]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Name of the owner.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_OWNER', + @level2type = N'Column', @level2name = N'OWNER_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Entity containing information regarding an acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_OWNER' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ +PRINT N'Create sequence dbo.PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_PROPERTY_ACQUISITION_FILE +PRINT N'Create table dbo.PIMS_PROPERTY_ACQUISITION_FILE' +GO +CREATE TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] ( + [PROPERTY_ACQUISITION_FILE_ID] bigint NOT NULL CONSTRAINT [PRACQF_PROPERTY_ACQUISITION_FILE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ]), + [ACQUISITION_FILE_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [PRACQF_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRACQF_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRACQF_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRACQF_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRACQF_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRACQF_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRACQF_PK] PRIMARY KEY CLUSTERED([PROPERTY_ACQUISITION_FILE_ID]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the relationship is active.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Associates a property with an acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ACQUISITION_FILE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACTIVITY_TEMPLATE_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACTIVITY_TEMPLATE_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_TEMPLATE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACTIVITY_TEMPLATE_TYPE +PRINT N'Create table dbo.PIMS_ACTIVITY_TEMPLATE_TYPE' +GO +CREATE TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] ( + [ACTIVITY_TEMPLATE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACTTTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACTTTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACTTTY_PK] PRIMARY KEY CLUSTERED([ACTIVITY_TEMPLATE_TYPE_CODE]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the activity type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE', + @level2type = N'Column', @level2name = N'ACTIVITY_TEMPLATE_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the activity type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the activity type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACTIVITY_TEMPLATE +PRINT N'Create table dbo.PIMS_ACTIVITY_TEMPLATE' +GO +CREATE TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] ( + [ACTIVITY_TEMPLATE_ID] bigint NOT NULL CONSTRAINT [ACTTMP_ACTIVITY_TEMPLATE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_TEMPLATE_ID_SEQ]), + [ACTIVITY_TEMPLATE_TYPE_CODE] nvarchar(20) NULL, + [ACTIVITY_TEMPLATE_JSON] nvarchar(max) NOT NULL CONSTRAINT [ACTTMP_ACTIVITY_TEMPLATE_JSON_DEF] DEFAULT (''), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACTTMP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTMP_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTMP_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTMP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTMP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACTTMP_PK] PRIMARY KEY CLUSTERED([ACTIVITY_TEMPLATE_ID]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'JSON structure desribing how to construct the activity UI.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE', + @level2type = N'Column', @level2name = N'ACTIVITY_TEMPLATE_JSON' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Alter table dbo.PIMS_ACTIVITY_INSTANCE +PRINT N'Alter table dbo.PIMS_ACTIVITY_INSTANCE' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] + ADD [ACTIVITY_TEMPLATE_ID] bigint NULL, + [ACTIVITY_DATA_JSON] nvarchar(max) NOT NULL CONSTRAINT [ACTINS_ACTIVITY_DATA_JSON_DEF] DEFAULT ('') +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'JSON structure containing data specific to an activity instance.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_INSTANCE', + @level2type = N'Column', @level2name = N'ACTIVITY_DATA_JSON' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE +PRINT N'Create table dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] ( + [ACQUISITION_ACTIVITY_INSTANCE_ID] bigint NOT NULL CONSTRAINT [ACQAIN_ACQUISITION_ACTIVITY_INSTANCE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ]), + [ACQUISITION_FILE_ID] bigint NOT NULL, + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [ACQAIN_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQAIN_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQAIN_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQAIN_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQAIN_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQAIN_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQAIN_PK] PRIMARY KEY CLUSTERED([ACQUISITION_ACTIVITY_INSTANCE_ID]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the relationship is active.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_ACTIVITY_INSTANCE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_FILE_PERSON_HIST +PRINT N'Create table dbo.PIMS_ACQUISITION_FILE_PERSON_HIST' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON_HIST] ( + [_ACQUISITION_FILE_PERSON_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACQUISITION_FILE_PERSON_ID] bigint NOT NULL, + [ACQUISITION_FILE_ID] bigint NOT NULL, + [PERSON_ID] bigint NOT NULL, + [ACQ_FL_PERSON_PROFILE_TYPE_CODE] nvarchar(20) NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACQPER_H_PK] PRIMARY KEY CLUSTERED([_ACQUISITION_FILE_PERSON_HIST_ID]) + ON [PRIMARY]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create unique constraint dbo.PIMS_ACQPER_H_UK +PRINT N'Create unique constraint dbo.PIMS_ACQPER_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON_HIST] + ADD CONSTRAINT [PIMS_ACQPER_H_UK] + UNIQUE ([_ACQUISITION_FILE_PERSON_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Alter table dbo.PIMS_ACTIVITY_INSTANCE_HIST +PRINT N'Alter table dbo.PIMS_ACTIVITY_INSTANCE_HIST' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] + ADD [ACTIVITY_TEMPLATE_ID] bigint NULL +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_OWNER_H_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_OWNER_H_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_OWNER_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_OWNER_HIST +PRINT N'Create table dbo.PIMS_ACQUISITION_OWNER_HIST' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_OWNER_HIST] ( + [_ACQUISITION_OWNER_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_OWNER_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACQUISITION_OWNER_ID] bigint NOT NULL, + [ACQUISITION_FILE_ID] bigint NULL, + [OWNER_NAME] nvarchar(300) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACQOWN_H_PK] PRIMARY KEY CLUSTERED([_ACQUISITION_OWNER_HIST_ID]) + ON [PRIMARY]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create unique constraint dbo.PIMS_ACQOWN_H_UK +PRINT N'Create unique constraint dbo.PIMS_ACQOWN_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER_HIST] + ADD CONSTRAINT [PIMS_ACQOWN_H_UK] + UNIQUE ([_ACQUISITION_OWNER_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_LAND_SURVEYOR_TYPE +PRINT N'Create table dbo.PIMS_LAND_SURVEYOR_TYPE' +GO +CREATE TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] ( + [LAND_SURVEYOR_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LNSRVT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LNSRVT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LNSRVT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LNSRVT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LNSRVT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LNSRVT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LNSRVT_PK] PRIMARY KEY CLUSTERED([LAND_SURVEYOR_TYPE_CODE]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the land surveyor type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE', + @level2type = N'Column', @level2name = N'LAND_SURVEYOR_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the land surveyor type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the land surveyor type. This is an unassociated table that is used in the UI to populate JSON attributes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_FILE_H_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_FILE_H_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_FILE_HIST +PRINT N'Create table dbo.PIMS_ACQUISITION_FILE_HIST' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE_HIST] ( + [_ACQUISITION_FILE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_FILE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACQUISITION_FILE_ID] bigint NOT NULL, + [ACQUISITION_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [ACQUISITION_TYPE_CODE] nvarchar(20) NOT NULL, + [ACQUISITION_FUNDING_TYPE_CODE] nvarchar(20) NULL, + [ACQ_PHYS_FILE_STATUS_TYPE_CODE] nvarchar(20) NULL, + [MINISTRY_PROJECT_NUMBER] nvarchar(20) NULL, + [MINISTRY_PROJECT_NAME] nvarchar(100) NULL, + [CPS_PRODUCT_CODE] nvarchar(12) NULL, + [FILE_NAME] nvarchar(500) NOT NULL, + [FILE_NUMBER] nvarchar(18) NULL, + [REGION_CODE] smallint NOT NULL, + [FUNDING_OTHER] nvarchar(200) NULL, + [ASSIGNED_DATE] datetime NULL, + [DELIVERY_DATE] datetime NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACQNFL_H_PK] PRIMARY KEY CLUSTERED([_ACQUISITION_FILE_HIST_ID]) + ON [PRIMARY]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create unique constraint dbo.PIMS_ACQNFL_H_UK +PRINT N'Create unique constraint dbo.PIMS_ACQNFL_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_HIST] + ADD CONSTRAINT [PIMS_ACQNFL_H_UK] + UNIQUE ([_ACQUISITION_FILE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACTIVITY_TEMPLATE_HIST +PRINT N'Create table dbo.PIMS_ACTIVITY_TEMPLATE_HIST' +GO +CREATE TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_HIST] ( + [_ACTIVITY_TEMPLATE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACTIVITY_TEMPLATE_ID] bigint NOT NULL, + [ACTIVITY_TEMPLATE_TYPE_CODE] nvarchar(20) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACTTMP_H_PK] PRIMARY KEY CLUSTERED([_ACTIVITY_TEMPLATE_HIST_ID]) + ON [PRIMARY]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create unique constraint dbo.PIMS_ACTTMP_H_UK +PRINT N'Create unique constraint dbo.PIMS_ACTTMP_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_HIST] + ADD CONSTRAINT [PIMS_ACTTMP_H_UK] + UNIQUE ([_ACTIVITY_TEMPLATE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_SURVEY_PLAN_TYPE +PRINT N'Create table dbo.PIMS_SURVEY_PLAN_TYPE' +GO +CREATE TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] ( + [SURVEY_PLAN_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [SRVPLT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [SRVPLT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SRVPLT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SRVPLT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SRVPLT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SRVPLT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [SRVPLT_PK] PRIMARY KEY CLUSTERED([SURVEY_PLAN_TYPE_CODE]) + ON [PRIMARY]) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the survey plan type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE', + @level2type = N'Column', @level2name = N'SURVEY_PLAN_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the survey plan type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the survey plan type. This is an unassociated table that is used in the UI to populate JSON attributes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ +PRINT N'Create sequence dbo.PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_PROPERTY_ACQUISITION_FILE_HIST +PRINT N'Create table dbo.PIMS_PROPERTY_ACQUISITION_FILE_HIST' +GO +CREATE TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_HIST] ( + [_PROPERTY_ACQUISITION_FILE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_ACQUISITION_FILE_ID] bigint NOT NULL, + [ACQUISITION_FILE_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PRACQF_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_ACQUISITION_FILE_HIST_ID]) + ON [PRIMARY]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create unique constraint dbo.PIMS_PRACQF_H_UK +PRINT N'Create unique constraint dbo.PIMS_PRACQF_H_UK' +GO +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_HIST] + ADD CONSTRAINT [PIMS_PRACQF_H_UK] + UNIQUE ([_PROPERTY_ACQUISITION_FILE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create sequence dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ +PRINT N'Create sequence dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ' +GO +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST +PRINT N'Create table dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST' +GO +CREATE TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST] ( + [_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACQUISITION_ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [ACQUISITION_FILE_ID] bigint NOT NULL, + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACQAIN_H_PK] PRIMARY KEY CLUSTERED([_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID]) + ON [PRIMARY]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create unique constraint dbo.PIMS_ACQAIN_H_UK +PRINT N'Create unique constraint dbo.PIMS_ACQAIN_H_UK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST] + ADD CONSTRAINT [PIMS_ACQAIN_H_UK] + UNIQUE ([_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Alter table dbo.PIMS_PROPERTY_RESEARCH_FILE +PRINT N'Alter table dbo.PIMS_PROPERTY_RESEARCH_FILE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Associates a property with a research file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQPER_PERSON_ID_IDX +PRINT N'Create index dbo.ACQPER_PERSON_ID_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQPER_PERSON_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE_PERSON]([PERSON_ID]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQOWN_ACQUISITION_FILE_ID_IDX +PRINT N'Create index dbo.ACQOWN_ACQUISITION_FILE_ID_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQOWN_ACQUISITION_FILE_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_OWNER]([ACQUISITION_FILE_ID]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQPER_ACQUISITION_FILE_ID_IDX +PRINT N'Create index dbo.ACQPER_ACQUISITION_FILE_ID_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQPER_ACQUISITION_FILE_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE_PERSON]([ACQUISITION_FILE_ID]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQPER_ACQ_FL_PERSON_PROFILE_TYPE_CODE_IDX +PRINT N'Create index dbo.ACQPER_ACQ_FL_PERSON_PROFILE_TYPE_CODE_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQPER_ACQ_FL_PERSON_PROFILE_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE_PERSON]([ACQ_FL_PERSON_PROFILE_TYPE_CODE]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQNFL_ACQUISITION_TYPE_CODE_IDX +PRINT N'Create index dbo.ACQNFL_ACQUISITION_TYPE_CODE_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQNFL_ACQUISITION_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_TYPE_CODE]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQNFL_ACQ_PHYS_FILE_STATUS_TYPE_CODE_IDX +PRINT N'Create index dbo.ACQNFL_ACQ_PHYS_FILE_STATUS_TYPE_CODE_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQNFL_ACQ_PHYS_FILE_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE]([ACQ_PHYS_FILE_STATUS_TYPE_CODE]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.PRACQF_ACQUISITION_FILE_ID_IDX +PRINT N'Create index dbo.PRACQF_ACQUISITION_FILE_ID_IDX' +GO +CREATE NONCLUSTERED INDEX [PRACQF_ACQUISITION_FILE_ID_IDX] + ON [dbo].[PIMS_PROPERTY_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.PRACQF_PROPERTY_ID_IDX +PRINT N'Create index dbo.PRACQF_PROPERTY_ID_IDX' +GO +CREATE NONCLUSTERED INDEX [PRACQF_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROPERTY_ACQUISITION_FILE]([PROPERTY_ID]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACTINS_ACTIVITY_TEMPLATE_ID_IDX +PRINT N'Create index dbo.ACTINS_ACTIVITY_TEMPLATE_ID_IDX' +GO +CREATE NONCLUSTERED INDEX [ACTINS_ACTIVITY_TEMPLATE_ID_IDX] + ON [dbo].[PIMS_ACTIVITY_INSTANCE]([ACTIVITY_TEMPLATE_ID]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACTTMP_ACTIVITY_TEMPLATE_TYPE_CODE_IDX +PRINT N'Create index dbo.ACTTMP_ACTIVITY_TEMPLATE_TYPE_CODE_IDX' +GO +CREATE NONCLUSTERED INDEX [ACTTMP_ACTIVITY_TEMPLATE_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACTIVITY_TEMPLATE]([ACTIVITY_TEMPLATE_TYPE_CODE]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQAIN_ACTIVITY_INSTANCE_ID_IDX +PRINT N'Create index dbo.ACQAIN_ACTIVITY_INSTANCE_ID_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQAIN_ACTIVITY_INSTANCE_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE]([ACTIVITY_INSTANCE_ID]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQNFL_ACQUISITION_FILE_STATUS_TYPE_CODE_IDX +PRINT N'Create index dbo.ACQNFL_ACQUISITION_FILE_STATUS_TYPE_CODE_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQNFL_ACQUISITION_FILE_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_STATUS_TYPE_CODE]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQNFL_ACQUISITION_FUNDING_TYPE_CODE_IDX +PRINT N'Create index dbo.ACQNFL_ACQUISITION_FUNDING_TYPE_CODE_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQNFL_ACQUISITION_FUNDING_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FUNDING_TYPE_CODE]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create index dbo.ACQAIN_ACQUISITION_FILE_ID_IDX +PRINT N'Create index dbo.ACQAIN_ACQUISITION_FILE_ID_IDX' +GO +CREATE NONCLUSTERED INDEX [ACQAIN_ACQUISITION_FILE_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE]([ACQUISITION_FILE_ID]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACQPFS_PIM_ACQNFL_FK +PRINT N'Create foreign key constraint dbo.PIM_ACQPFS_PIM_ACQNFL_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQPFS_PIM_ACQNFL_FK] + FOREIGN KEY([ACQ_PHYS_FILE_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE]([ACQ_PHYS_FILE_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACQFST_PIM_ACQNFL_FK +PRINT N'Create foreign key constraint dbo.PIM_ACQFST_PIM_ACQNFL_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQFST_PIM_ACQNFL_FK] + FOREIGN KEY([ACQUISITION_FILE_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE]([ACQUISITION_FILE_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACQTYP_PIM_ACQNFL_FK +PRINT N'Create foreign key constraint dbo.PIM_ACQTYP_PIM_ACQNFL_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQTYP_PIM_ACQNFL_FK] + FOREIGN KEY([ACQUISITION_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQUISITION_TYPE]([ACQUISITION_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACQFTY_PIM_ACQNFL_FK +PRINT N'Create foreign key constraint dbo.PIM_ACQFTY_PIM_ACQNFL_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQFTY_PIM_ACQNFL_FK] + FOREIGN KEY([ACQUISITION_FUNDING_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQUISITION_FUNDING_TYPE]([ACQUISITION_FUNDING_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_PERSON_PIM_ACQPER_FK +PRINT N'Create foreign key constraint dbo.PIM_PERSON_PIM_ACQPER_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + ADD CONSTRAINT [PIM_PERSON_PIM_ACQPER_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_AQFPPT_PIM_ACQPER_FK +PRINT N'Create foreign key constraint dbo.PIM_AQFPPT_PIM_ACQPER_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + ADD CONSTRAINT [PIM_AQFPPT_PIM_ACQPER_FK] + FOREIGN KEY([ACQ_FL_PERSON_PROFILE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE]([ACQ_FL_PERSON_PROFILE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACQNFL_PIM_ACQPER_FK +PRINT N'Create foreign key constraint dbo.PIM_ACQNFL_PIM_ACQPER_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + ADD CONSTRAINT [PIM_ACQNFL_PIM_ACQPER_FK] + FOREIGN KEY([ACQUISITION_FILE_ID]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACQNFL_PIM_ACQOWN_FK +PRINT N'Create foreign key constraint dbo.PIM_ACQNFL_PIM_ACQOWN_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] + ADD CONSTRAINT [PIM_ACQNFL_PIM_ACQOWN_FK] + FOREIGN KEY([ACQUISITION_FILE_ID]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_PRPRTY_PIM_PRACQF_FK +PRINT N'Create foreign key constraint dbo.PIM_PRPRTY_PIM_PRACQF_FK' +GO +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRACQF_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACQNFL_PIM_PRACQF_FK +PRINT N'Create foreign key constraint dbo.PIM_ACQNFL_PIM_PRACQF_FK' +GO +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQNFL_PIM_PRACQF_FK] + FOREIGN KEY([ACQUISITION_FILE_ID]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACTTTY_PIM_ACTTMP_FK +PRINT N'Create foreign key constraint dbo.PIM_ACTTTY_PIM_ACTTMP_FK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] + ADD CONSTRAINT [PIM_ACTTTY_PIM_ACTTMP_FK] + FOREIGN KEY([ACTIVITY_TEMPLATE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE]([ACTIVITY_TEMPLATE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACTTMP_PIM_ACTINS_FK +PRINT N'Create foreign key constraint dbo.PIM_ACTTMP_PIM_ACTINS_FK' +GO +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] + ADD CONSTRAINT [PIM_ACTTMP_PIM_ACTINS_FK] + FOREIGN KEY([ACTIVITY_TEMPLATE_ID]) + REFERENCES [dbo].[PIMS_ACTIVITY_TEMPLATE]([ACTIVITY_TEMPLATE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACTINS_PIM_ACQAIN_FK +PRINT N'Create foreign key constraint dbo.PIM_ACTINS_PIM_ACQAIN_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] + ADD CONSTRAINT [PIM_ACTINS_PIM_ACQAIN_FK] + FOREIGN KEY([ACTIVITY_INSTANCE_ID]) + REFERENCES [dbo].[PIMS_ACTIVITY_INSTANCE]([ACTIVITY_INSTANCE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create foreign key constraint dbo.PIM_ACQNFL_PIM_ACQAIN_FK +PRINT N'Create foreign key constraint dbo.PIM_ACQNFL_PIM_ACQAIN_FK' +GO +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] + ADD CONSTRAINT [PIM_ACQNFL_PIM_ACQAIN_FK] + FOREIGN KEY([ACQUISITION_FILE_ID]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQNFL_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACQNFL_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQNFL_I_S_I_TR] ON PIMS_ACQUISITION_FILE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_FILE ("ACQUISITION_FILE_ID", + "ACQUISITION_FILE_STATUS_TYPE_CODE", + "ACQUISITION_TYPE_CODE", + "ACQUISITION_FUNDING_TYPE_CODE", + "ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "MINISTRY_PROJECT_NUMBER", + "MINISTRY_PROJECT_NAME", + "CPS_PRODUCT_CODE", + "FILE_NAME", + "FILE_NUMBER", + "REGION_CODE", + "FUNDING_OTHER", + "ASSIGNED_DATE", + "DELIVERY_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACQUISITION_FILE_ID", + "ACQUISITION_FILE_STATUS_TYPE_CODE", + "ACQUISITION_TYPE_CODE", + "ACQUISITION_FUNDING_TYPE_CODE", + "ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "MINISTRY_PROJECT_NUMBER", + "MINISTRY_PROJECT_NAME", + "CPS_PRODUCT_CODE", + "FILE_NAME", + "FILE_NUMBER", + "REGION_CODE", + "FUNDING_OTHER", + "ASSIGNED_DATE", + "DELIVERY_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQFTY_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACQFTY_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQFTY_I_S_U_TR] ON PIMS_ACQUISITION_FUNDING_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_FUNDING_TYPE_CODE = deleted.ACQUISITION_FUNDING_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_FUNDING_TYPE + set "ACQUISITION_FUNDING_TYPE_CODE" = inserted."ACQUISITION_FUNDING_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_FUNDING_TYPE + inner join inserted + on (PIMS_ACQUISITION_FUNDING_TYPE.ACQUISITION_FUNDING_TYPE_CODE = inserted.ACQUISITION_FUNDING_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQPER_A_S_IUD_TR +PRINT N'Create trigger dbo.PIMS_ACQPER_A_S_IUD_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQPER_A_S_IUD_TR] ON PIMS_ACQUISITION_FILE_PERSON FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACQUISITION_FILE_PERSON_HIST set END_DATE_HIST = @curr_date where ACQUISITION_FILE_PERSON_ID in (select ACQUISITION_FILE_PERSON_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACQUISITION_FILE_PERSON_HIST ([ACQUISITION_FILE_PERSON_ID], [ACQUISITION_FILE_ID], [PERSON_ID], [ACQ_FL_PERSON_PROFILE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACQUISITION_FILE_PERSON_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACQUISITION_FILE_PERSON_ID], [ACQUISITION_FILE_ID], [PERSON_ID], [ACQ_FL_PERSON_PROFILE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ]) as [_ACQUISITION_FILE_PERSON_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_PRACQF_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_PRACQF_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_PRACQF_I_S_I_TR] ON PIMS_PROPERTY_ACQUISITION_FILE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_ACQUISITION_FILE ("PROPERTY_ACQUISITION_FILE_ID", + "ACQUISITION_FILE_ID", + "PROPERTY_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_ACQUISITION_FILE_ID", + "ACQUISITION_FILE_ID", + "PROPERTY_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTINS_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACTINS_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTINS_I_S_U_TR] ON PIMS_ACTIVITY_INSTANCE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACTIVITY_INSTANCE_ID = deleted.ACTIVITY_INSTANCE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_INSTANCE + set "ACTIVITY_INSTANCE_ID" = inserted."ACTIVITY_INSTANCE_ID", + "ACTIVITY_TEMPLATE_ID" = inserted."ACTIVITY_TEMPLATE_ID", + "ACTIVITY_DATA_JSON" = inserted."ACTIVITY_DATA_JSON", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_INSTANCE + inner join inserted + on (PIMS_ACTIVITY_INSTANCE.ACTIVITY_INSTANCE_ID = inserted.ACTIVITY_INSTANCE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTINS_A_S_IUD_TR +PRINT N'Create trigger dbo.PIMS_ACTINS_A_S_IUD_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTINS_A_S_IUD_TR] ON PIMS_ACTIVITY_INSTANCE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACTIVITY_INSTANCE_HIST set END_DATE_HIST = @curr_date where ACTIVITY_INSTANCE_ID in (select ACTIVITY_INSTANCE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACTIVITY_INSTANCE_HIST ([ACTIVITY_INSTANCE_ID], [ACTIVITY_TEMPLATE_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACTIVITY_INSTANCE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACTIVITY_INSTANCE_ID], [ACTIVITY_TEMPLATE_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACTIVITY_INSTANCE_H_ID_SEQ]) as [_ACTIVITY_INSTANCE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQPFS_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACQPFS_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQPFS_I_S_U_TR] ON PIMS_ACQ_PHYS_FILE_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQ_PHYS_FILE_STATUS_TYPE_CODE = deleted.ACQ_PHYS_FILE_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQ_PHYS_FILE_STATUS_TYPE + set "ACQ_PHYS_FILE_STATUS_TYPE_CODE" = inserted."ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQ_PHYS_FILE_STATUS_TYPE + inner join inserted + on (PIMS_ACQ_PHYS_FILE_STATUS_TYPE.ACQ_PHYS_FILE_STATUS_TYPE_CODE = inserted.ACQ_PHYS_FILE_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTTMP_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACTTMP_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTTMP_I_S_I_TR] ON PIMS_ACTIVITY_TEMPLATE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_TEMPLATE ("ACTIVITY_TEMPLATE_ID", + "ACTIVITY_TEMPLATE_TYPE_CODE", + "ACTIVITY_TEMPLATE_JSON", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACTIVITY_TEMPLATE_ID", + "ACTIVITY_TEMPLATE_TYPE_CODE", + "ACTIVITY_TEMPLATE_JSON", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQOWN_A_S_IUD_TR +PRINT N'Create trigger dbo.PIMS_ACQOWN_A_S_IUD_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQOWN_A_S_IUD_TR] ON PIMS_ACQUISITION_OWNER FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACQUISITION_OWNER_HIST set END_DATE_HIST = @curr_date where ACQUISITION_OWNER_ID in (select ACQUISITION_OWNER_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACQUISITION_OWNER_HIST ([ACQUISITION_OWNER_ID], [ACQUISITION_FILE_ID], [OWNER_NAME], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACQUISITION_OWNER_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACQUISITION_OWNER_ID], [ACQUISITION_FILE_ID], [OWNER_NAME], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACQUISITION_OWNER_H_ID_SEQ]) as [_ACQUISITION_OWNER_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQFST_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACQFST_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQFST_I_S_U_TR] ON PIMS_ACQUISITION_FILE_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_FILE_STATUS_TYPE_CODE = deleted.ACQUISITION_FILE_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_FILE_STATUS_TYPE + set "ACQUISITION_FILE_STATUS_TYPE_CODE" = inserted."ACQUISITION_FILE_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_FILE_STATUS_TYPE + inner join inserted + on (PIMS_ACQUISITION_FILE_STATUS_TYPE.ACQUISITION_FILE_STATUS_TYPE_CODE = inserted.ACQUISITION_FILE_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQAIN_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACQAIN_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQAIN_I_S_U_TR] ON PIMS_ACQUISITION_ACTIVITY_INSTANCE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_ACTIVITY_INSTANCE_ID = deleted.ACQUISITION_ACTIVITY_INSTANCE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_ACTIVITY_INSTANCE + set "ACQUISITION_ACTIVITY_INSTANCE_ID" = inserted."ACQUISITION_ACTIVITY_INSTANCE_ID", + "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "ACTIVITY_INSTANCE_ID" = inserted."ACTIVITY_INSTANCE_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_ACTIVITY_INSTANCE + inner join inserted + on (PIMS_ACQUISITION_ACTIVITY_INSTANCE.ACQUISITION_ACTIVITY_INSTANCE_ID = inserted.ACQUISITION_ACTIVITY_INSTANCE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_LNSRVT_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_LNSRVT_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_LNSRVT_I_S_U_TR] ON PIMS_LAND_SURVEYOR_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LAND_SURVEYOR_TYPE_CODE = deleted.LAND_SURVEYOR_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LAND_SURVEYOR_TYPE + set "LAND_SURVEYOR_TYPE_CODE" = inserted."LAND_SURVEYOR_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LAND_SURVEYOR_TYPE + inner join inserted + on (PIMS_LAND_SURVEYOR_TYPE.LAND_SURVEYOR_TYPE_CODE = inserted.LAND_SURVEYOR_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQNFL_A_S_IUD_TR +PRINT N'Create trigger dbo.PIMS_ACQNFL_A_S_IUD_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQNFL_A_S_IUD_TR] ON PIMS_ACQUISITION_FILE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACQUISITION_FILE_HIST set END_DATE_HIST = @curr_date where ACQUISITION_FILE_ID in (select ACQUISITION_FILE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACQUISITION_FILE_HIST ([ACQUISITION_FILE_ID], [ACQUISITION_FILE_STATUS_TYPE_CODE], [ACQUISITION_TYPE_CODE], [ACQUISITION_FUNDING_TYPE_CODE], [ACQ_PHYS_FILE_STATUS_TYPE_CODE], [MINISTRY_PROJECT_NUMBER], [MINISTRY_PROJECT_NAME], [CPS_PRODUCT_CODE], [FILE_NAME], [FILE_NUMBER], [REGION_CODE], [FUNDING_OTHER], [ASSIGNED_DATE], [DELIVERY_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACQUISITION_FILE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACQUISITION_FILE_ID], [ACQUISITION_FILE_STATUS_TYPE_CODE], [ACQUISITION_TYPE_CODE], [ACQUISITION_FUNDING_TYPE_CODE], [ACQ_PHYS_FILE_STATUS_TYPE_CODE], [MINISTRY_PROJECT_NUMBER], [MINISTRY_PROJECT_NAME], [CPS_PRODUCT_CODE], [FILE_NAME], [FILE_NUMBER], [REGION_CODE], [FUNDING_OTHER], [ASSIGNED_DATE], [DELIVERY_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACQUISITION_FILE_H_ID_SEQ]) as [_ACQUISITION_FILE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQTYP_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACQTYP_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQTYP_I_S_U_TR] ON PIMS_ACQUISITION_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_TYPE_CODE = deleted.ACQUISITION_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_TYPE + set "ACQUISITION_TYPE_CODE" = inserted."ACQUISITION_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_TYPE + inner join inserted + on (PIMS_ACQUISITION_TYPE.ACQUISITION_TYPE_CODE = inserted.ACQUISITION_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQOWN_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACQOWN_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQOWN_I_S_I_TR] ON PIMS_ACQUISITION_OWNER INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_OWNER ("ACQUISITION_OWNER_ID", + "ACQUISITION_FILE_ID", + "OWNER_NAME", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACQUISITION_OWNER_ID", + "ACQUISITION_FILE_ID", + "OWNER_NAME", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTTMP_A_S_IUD_TR +PRINT N'Create trigger dbo.PIMS_ACTTMP_A_S_IUD_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTTMP_A_S_IUD_TR] ON PIMS_ACTIVITY_TEMPLATE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACTIVITY_TEMPLATE_HIST set END_DATE_HIST = @curr_date where ACTIVITY_TEMPLATE_ID in (select ACTIVITY_TEMPLATE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACTIVITY_TEMPLATE_HIST ([ACTIVITY_TEMPLATE_ID], [ACTIVITY_TEMPLATE_TYPE_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACTIVITY_TEMPLATE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACTIVITY_TEMPLATE_ID], [ACTIVITY_TEMPLATE_TYPE_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ]) as [_ACTIVITY_TEMPLATE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_AQFPPT_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_AQFPPT_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_AQFPPT_I_S_I_TR] ON PIMS_ACQ_FL_PERSON_PROFILE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQ_FL_PERSON_PROFILE_TYPE ("ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTTTY_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACTTTY_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTTTY_I_S_U_TR] ON PIMS_ACTIVITY_TEMPLATE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACTIVITY_TEMPLATE_TYPE_CODE = deleted.ACTIVITY_TEMPLATE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_TEMPLATE_TYPE + set "ACTIVITY_TEMPLATE_TYPE_CODE" = inserted."ACTIVITY_TEMPLATE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_TEMPLATE_TYPE + inner join inserted + on (PIMS_ACTIVITY_TEMPLATE_TYPE.ACTIVITY_TEMPLATE_TYPE_CODE = inserted.ACTIVITY_TEMPLATE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQPER_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACQPER_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQPER_I_S_I_TR] ON PIMS_ACQUISITION_FILE_PERSON INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_FILE_PERSON ("ACQUISITION_FILE_PERSON_ID", + "ACQUISITION_FILE_ID", + "PERSON_ID", + "ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACQUISITION_FILE_PERSON_ID", + "ACQUISITION_FILE_ID", + "PERSON_ID", + "ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_SRVPLT_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_SRVPLT_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_SRVPLT_I_S_I_TR] ON PIMS_SURVEY_PLAN_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_SURVEY_PLAN_TYPE ("SURVEY_PLAN_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "SURVEY_PLAN_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_PRACQF_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_PRACQF_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_PRACQF_I_S_U_TR] ON PIMS_PROPERTY_ACQUISITION_FILE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_ACQUISITION_FILE_ID = deleted.PROPERTY_ACQUISITION_FILE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_ACQUISITION_FILE + set "PROPERTY_ACQUISITION_FILE_ID" = inserted."PROPERTY_ACQUISITION_FILE_ID", + "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_ACQUISITION_FILE + inner join inserted + on (PIMS_PROPERTY_ACQUISITION_FILE.PROPERTY_ACQUISITION_FILE_ID = inserted.PROPERTY_ACQUISITION_FILE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQPFS_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACQPFS_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQPFS_I_S_I_TR] ON PIMS_ACQ_PHYS_FILE_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQ_PHYS_FILE_STATUS_TYPE ("ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTTMP_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACTTMP_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTTMP_I_S_U_TR] ON PIMS_ACTIVITY_TEMPLATE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACTIVITY_TEMPLATE_ID = deleted.ACTIVITY_TEMPLATE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_TEMPLATE + set "ACTIVITY_TEMPLATE_ID" = inserted."ACTIVITY_TEMPLATE_ID", + "ACTIVITY_TEMPLATE_TYPE_CODE" = inserted."ACTIVITY_TEMPLATE_TYPE_CODE", + "ACTIVITY_TEMPLATE_JSON" = inserted."ACTIVITY_TEMPLATE_JSON", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_TEMPLATE + inner join inserted + on (PIMS_ACTIVITY_TEMPLATE.ACTIVITY_TEMPLATE_ID = inserted.ACTIVITY_TEMPLATE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQTYP_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACQTYP_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQTYP_I_S_I_TR] ON PIMS_ACQUISITION_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_TYPE ("ACQUISITION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQUISITION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQNFL_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACQNFL_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQNFL_I_S_U_TR] ON PIMS_ACQUISITION_FILE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_FILE_ID = deleted.ACQUISITION_FILE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_FILE + set "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "ACQUISITION_FILE_STATUS_TYPE_CODE" = inserted."ACQUISITION_FILE_STATUS_TYPE_CODE", + "ACQUISITION_TYPE_CODE" = inserted."ACQUISITION_TYPE_CODE", + "ACQUISITION_FUNDING_TYPE_CODE" = inserted."ACQUISITION_FUNDING_TYPE_CODE", + "ACQ_PHYS_FILE_STATUS_TYPE_CODE" = inserted."ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "MINISTRY_PROJECT_NUMBER" = inserted."MINISTRY_PROJECT_NUMBER", + "MINISTRY_PROJECT_NAME" = inserted."MINISTRY_PROJECT_NAME", + "CPS_PRODUCT_CODE" = inserted."CPS_PRODUCT_CODE", + "FILE_NAME" = inserted."FILE_NAME", + "FILE_NUMBER" = inserted."FILE_NUMBER", + "REGION_CODE" = inserted."REGION_CODE", + "FUNDING_OTHER" = inserted."FUNDING_OTHER", + "ASSIGNED_DATE" = inserted."ASSIGNED_DATE", + "DELIVERY_DATE" = inserted."DELIVERY_DATE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_FILE + inner join inserted + on (PIMS_ACQUISITION_FILE.ACQUISITION_FILE_ID = inserted.ACQUISITION_FILE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTINS_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACTINS_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTINS_I_S_I_TR] ON PIMS_ACTIVITY_INSTANCE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_INSTANCE ("ACTIVITY_INSTANCE_ID", + "ACTIVITY_TEMPLATE_ID", + "ACTIVITY_DATA_JSON", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACTIVITY_INSTANCE_ID", + "ACTIVITY_TEMPLATE_ID", + "ACTIVITY_DATA_JSON", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQFTY_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACQFTY_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQFTY_I_S_I_TR] ON PIMS_ACQUISITION_FUNDING_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_FUNDING_TYPE ("ACQUISITION_FUNDING_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQUISITION_FUNDING_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_PRACQF_A_S_IUD_TR +PRINT N'Create trigger dbo.PIMS_PRACQF_A_S_IUD_TR' +GO +CREATE TRIGGER [dbo].[PIMS_PRACQF_A_S_IUD_TR] ON PIMS_PROPERTY_ACQUISITION_FILE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_ACQUISITION_FILE_HIST set END_DATE_HIST = @curr_date where PROPERTY_ACQUISITION_FILE_ID in (select PROPERTY_ACQUISITION_FILE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_ACQUISITION_FILE_HIST ([PROPERTY_ACQUISITION_FILE_ID], [ACQUISITION_FILE_ID], [PROPERTY_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_ACQUISITION_FILE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_ACQUISITION_FILE_ID], [ACQUISITION_FILE_ID], [PROPERTY_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ]) as [_PROPERTY_ACQUISITION_FILE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQAIN_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACQAIN_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQAIN_I_S_I_TR] ON PIMS_ACQUISITION_ACTIVITY_INSTANCE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_ACTIVITY_INSTANCE ("ACQUISITION_ACTIVITY_INSTANCE_ID", + "ACQUISITION_FILE_ID", + "ACTIVITY_INSTANCE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USER_DIRECTORY", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACQUISITION_ACTIVITY_INSTANCE_ID", + "ACQUISITION_FILE_ID", + "ACTIVITY_INSTANCE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USER_DIRECTORY", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQFST_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACQFST_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQFST_I_S_I_TR] ON PIMS_ACQUISITION_FILE_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_FILE_STATUS_TYPE ("ACQUISITION_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQUISITION_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_AQFPPT_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_AQFPPT_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_AQFPPT_I_S_U_TR] ON PIMS_ACQ_FL_PERSON_PROFILE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQ_FL_PERSON_PROFILE_TYPE_CODE = deleted.ACQ_FL_PERSON_PROFILE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQ_FL_PERSON_PROFILE_TYPE + set "ACQ_FL_PERSON_PROFILE_TYPE_CODE" = inserted."ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQ_FL_PERSON_PROFILE_TYPE + inner join inserted + on (PIMS_ACQ_FL_PERSON_PROFILE_TYPE.ACQ_FL_PERSON_PROFILE_TYPE_CODE = inserted.ACQ_FL_PERSON_PROFILE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQAIN_A_S_IUD_TR +PRINT N'Create trigger dbo.PIMS_ACQAIN_A_S_IUD_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQAIN_A_S_IUD_TR] ON PIMS_ACQUISITION_ACTIVITY_INSTANCE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST set END_DATE_HIST = @curr_date where ACQUISITION_ACTIVITY_INSTANCE_ID in (select ACQUISITION_ACTIVITY_INSTANCE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST ([ACQUISITION_ACTIVITY_INSTANCE_ID], [ACQUISITION_FILE_ID], [ACTIVITY_INSTANCE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USER_DIRECTORY], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACQUISITION_ACTIVITY_INSTANCE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACQUISITION_ACTIVITY_INSTANCE_ID], [ACQUISITION_FILE_ID], [ACTIVITY_INSTANCE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USER_DIRECTORY], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ]) as [_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_SRVPLT_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_SRVPLT_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_SRVPLT_I_S_U_TR] ON PIMS_SURVEY_PLAN_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.SURVEY_PLAN_TYPE_CODE = deleted.SURVEY_PLAN_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_SURVEY_PLAN_TYPE + set "SURVEY_PLAN_TYPE_CODE" = inserted."SURVEY_PLAN_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_SURVEY_PLAN_TYPE + inner join inserted + on (PIMS_SURVEY_PLAN_TYPE.SURVEY_PLAN_TYPE_CODE = inserted.SURVEY_PLAN_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_LNSRVT_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_LNSRVT_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_LNSRVT_I_S_I_TR] ON PIMS_LAND_SURVEYOR_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LAND_SURVEYOR_TYPE ("LAND_SURVEYOR_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LAND_SURVEYOR_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQOWN_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACQOWN_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQOWN_I_S_U_TR] ON PIMS_ACQUISITION_OWNER INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_OWNER_ID = deleted.ACQUISITION_OWNER_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_OWNER + set "ACQUISITION_OWNER_ID" = inserted."ACQUISITION_OWNER_ID", + "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "OWNER_NAME" = inserted."OWNER_NAME", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_OWNER + inner join inserted + on (PIMS_ACQUISITION_OWNER.ACQUISITION_OWNER_ID = inserted.ACQUISITION_OWNER_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACQPER_I_S_U_TR +PRINT N'Create trigger dbo.PIMS_ACQPER_I_S_U_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACQPER_I_S_U_TR] ON PIMS_ACQUISITION_FILE_PERSON INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_FILE_PERSON_ID = deleted.ACQUISITION_FILE_PERSON_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_FILE_PERSON + set "ACQUISITION_FILE_PERSON_ID" = inserted."ACQUISITION_FILE_PERSON_ID", + "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "PERSON_ID" = inserted."PERSON_ID", + "ACQ_FL_PERSON_PROFILE_TYPE_CODE" = inserted."ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_FILE_PERSON + inner join inserted + on (PIMS_ACQUISITION_FILE_PERSON.ACQUISITION_FILE_PERSON_ID = inserted.ACQUISITION_FILE_PERSON_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create trigger dbo.PIMS_ACTTTY_I_S_I_TR +PRINT N'Create trigger dbo.PIMS_ACTTTY_I_S_I_TR' +GO +CREATE TRIGGER [dbo].[PIMS_ACTTTY_I_S_I_TR] ON PIMS_ACTIVITY_TEMPLATE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_TEMPLATE_TYPE ("ACTIVITY_TEMPLATE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACTIVITY_TEMPLATE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; + +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +COMMIT TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DECLARE @Success AS BIT +SET @Success = 1 +SET NOEXEC OFF +IF (@Success = 1) PRINT 'The database update succeeded' +ELSE BEGIN + IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION + PRINT 'The database update failed' +END +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/10_DML_PIMS_STATIC_VARIABLE_VERSION.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/10_DML_PIMS_STATIC_VARIABLE_VERSION.sql new file mode 100644 index 0000000000..634056dc7f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/10_DML_PIMS_STATIC_VARIABLE_VERSION.sql @@ -0,0 +1,26 @@ +/* ----------------------------------------------------------------------------- +Update the database version in the PIMS_STATIC_VARIABLE table. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Nov-24 Initial version +----------------------------------------------------------------------------- */ + +BEGIN TRANSACTION; + +DECLARE @CurrVer NVARCHAR(100) +SET @CurrVer = N'32.00' + +UPDATE PIMS_STATIC_VARIABLE +WITH (UPDLOCK, SERIALIZABLE) +SET STATIC_VARIABLE_VALUE = @CurrVer + , CONCURRENCY_CONTROL_NUMBER = CONCURRENCY_CONTROL_NUMBER + 1 +WHERE STATIC_VARIABLE_NAME = N'DBVERSION'; + +IF @@ROWCOUNT = 0 + BEGIN + INSERT INTO PIMS_STATIC_VARIABLE (STATIC_VARIABLE_NAME, STATIC_VARIABLE_VALUE) + VALUES (N'DBVERSION', @CurrVer); + END + +COMMIT TRANSACTION; diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/74_DML_PIMS_CLAIM.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/74_DML_PIMS_CLAIM.sql new file mode 100644 index 0000000000..42ef3e381c --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/74_DML_PIMS_CLAIM.sql @@ -0,0 +1,12 @@ +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (30, N'595372a3-7a65-4893-84b1-1378dc697e81', N'note-view', N'595372a3-7a65-4893-84b1-1378dc697e81', N'Ability view existing notes.', 0, 1, CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T07:42:25.690' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-07-15T07:42:25.670' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (31, N'bf123896-dbd7-43bc-b9cd-44b844544b3c', N'note-add', N'bf123896-dbd7-43bc-b9cd-44b844544b3c', N'Ability to add new notes.', 0, 1, CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T07:42:25.790' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-07-15T07:42:25.780' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (32, N'363035c7-9ec0-4239-acd9-49aec29d5815', N'note-edit', N'363035c7-9ec0-4239-acd9-49aec29d5815', N'Ability to edit existing notes.', 0, 1, CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T07:42:25.890' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-07-15T07:42:25.873' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (33, N'ec671269-8c45-4702-9883-0fff1c6f98ce', N'note-delete', N'ec671269-8c45-4702-9883-0fff1c6f98ce', N'Ability to delete notes.', 0, 1, CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T07:42:25.990' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-07-15T07:42:25.967' AS DateTime), N'SEED') +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/75_DML_PIMS_ROLE_CLAIM.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/75_DML_PIMS_ROLE_CLAIM.sql new file mode 100644 index 0000000000..d0805f88bc --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/75_DML_PIMS_ROLE_CLAIM.sql @@ -0,0 +1,57 @@ +DECLARE @finance BIGINT; +DECLARE @functional BIGINT; +DECLARE @restricted BIGINT; +DECLARE @readOnly BIGINT; +DECLARE @systemAdministrator BIGINT; +SELECT @finance = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Finance'; +SELECT @functional = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Functional'; +SELECT @restricted = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Functional (Restricted)'; +SELECT @readOnly = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Read Only'; +SELECT @systemAdministrator = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'System Administrator'; + +DECLARE @noteView BIGINT; +DECLARE @noteAdd BIGINT; +DECLARE @noteEdit BIGINT; +DECLARE @noteDelete BIGINT; +SELECT @noteView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-view'; +SELECT @noteAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-add'; +SELECT @noteEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-edit'; +SELECT @noteDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-delete'; + +/* Functional */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@functional, @noteView, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@functional, @noteEdit, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@functional, @noteAdd, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +/* Functional Restricted */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@restricted, @noteView, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@restricted, @noteEdit, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@restricted, @noteAdd, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +/* Read Only */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@readOnly, @noteView, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +/* System Administrator */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@systemAdministrator, @noteView, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@systemAdministrator, @noteEdit, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@systemAdministrator, @noteAdd, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@systemAdministrator, @noteDelete, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/89_DML_PIMS_ACQUISITION_FILE_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/89_DML_PIMS_ACQUISITION_FILE_STATUS_TYPE.sql new file mode 100644 index 0000000000..dc10b754dd --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/89_DML_PIMS_ACQUISITION_FILE_STATUS_TYPE.sql @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQUISITION_FILE_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQUISITION_FILE_STATUS_TYPE +GO + +INSERT INTO PIMS_ACQUISITION_FILE_STATUS_TYPE (ACQUISITION_FILE_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'ACTIVE', N'Active'), + (N'CANCEL', N'Cancelled'), + (N'CLOSED', N'Closed'), + (N'ARCHIV', N'Archived'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/90_DML_PIMS_ACQUISITION_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/90_DML_PIMS_ACQUISITION_TYPE.sql new file mode 100644 index 0000000000..0da500bfe6 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/90_DML_PIMS_ACQUISITION_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQUISITION_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQUISITION_TYPE +GO + +INSERT INTO PIMS_ACQUISITION_TYPE (ACQUISITION_TYPE_CODE, DESCRIPTION) +VALUES + (N'CONSEN', N'Consensual Agreement'), + (N'SECTN3', N'Section 3 Agreement'), + (N'SECTN6', N'Section 6 Expropriation'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/91_DML_PIMS_ACQUISITION_FUNDING_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/91_DML_PIMS_ACQUISITION_FUNDING_TYPE.sql new file mode 100644 index 0000000000..b469fe8673 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/91_DML_PIMS_ACQUISITION_FUNDING_TYPE.sql @@ -0,0 +1,25 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQUISITION_FUNDING_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQUISITION_FUNDING_TYPE +GO + +INSERT INTO PIMS_ACQUISITION_FUNDING_TYPE (ACQUISITION_FUNDING_TYPE_CODE, DESCRIPTION) +VALUES + (N'MOTIDST', N'MoTI District'), + (N'MOTIREG', N'MoTI Region'), + (N'DFAA', N'DFAA (Disaster Financial Assistance Arrangement)'), + (N'REHAB', N'Rehab & Maintenance'), + (N'CAPITAL', N'Capital Program'), + (N'BCTFA', N'BCTFA'), + (N'TICORP', N'TI Corp'), + (N'MAJORPR', N'Major Projects'), + (N'FEDERAL', N'Federal'), + (N'EVERGRN', N'Evergreen'), + (N'OTHER', N'Other'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/92_DML_PIMS_ACQ_PHYS_FILE_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/92_DML_PIMS_ACQ_PHYS_FILE_STATUS_TYPE.sql new file mode 100644 index 0000000000..b559cd24c9 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/92_DML_PIMS_ACQ_PHYS_FILE_STATUS_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQ_PHYS_FILE_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQ_PHYS_FILE_STATUS_TYPE +GO + +INSERT INTO PIMS_ACQ_PHYS_FILE_STATUS_TYPE (ACQ_PHYS_FILE_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'ACTIVE', N'Active'), + (N'PENDING', N'Pending Litigation'), + (N'ARCHIVE', N'Archive - Offsite'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/93_DML_PIMS_ACQ_FL_PERSON_PROFILE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/93_DML_PIMS_ACQ_FL_PERSON_PROFILE_TYPE.sql new file mode 100644 index 0000000000..13f5786e19 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/93_DML_PIMS_ACQ_FL_PERSON_PROFILE_TYPE.sql @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQ_FL_PERSON_PROFILE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQ_FL_PERSON_PROFILE_TYPE +GO + +INSERT INTO PIMS_ACQ_FL_PERSON_PROFILE_TYPE (ACQ_FL_PERSON_PROFILE_TYPE_CODE, DESCRIPTION) +VALUES + (N'NEGOTAGENT', N'Negotiation agent'), + (N'PROPCOORD', N'Property Coordinator'), + (N'EXPRAGENT', N'Expropriation agent'), + (N'PROPAGENT', N'Property agent'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/94_DML_PIMS_ACTIVITY_TEMPLATE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/94_DML_PIMS_ACTIVITY_TEMPLATE_TYPE.sql new file mode 100644 index 0000000000..6d8dea628f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/94_DML_PIMS_ACTIVITY_TEMPLATE_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACTIVITY_TEMPLATE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACTIVITY_TEMPLATE_TYPE +GO + +INSERT INTO PIMS_ACTIVITY_TEMPLATE_TYPE (ACTIVITY_TEMPLATE_TYPE_CODE, DESCRIPTION) +VALUES + (N'GENERAL', N'General'), + (N'SURVEY', N'Survey'), + (N'SITEVIS', N'Site Visit'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/95_DML_PIMS_SURVEY_PLAN_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/95_DML_PIMS_SURVEY_PLAN_TYPE.sql new file mode 100644 index 0000000000..72a0b89855 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/95_DML_PIMS_SURVEY_PLAN_TYPE.sql @@ -0,0 +1,44 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_SURVEY_PLAN_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_SURVEY_PLAN_TYPE +GO + +INSERT INTO PIMS_SURVEY_PLAN_TYPE (SURVEY_PLAN_TYPE_CODE, DESCRIPTION) +VALUES + (N'S107REFART', N'S.107 Reference – arterial'), + (N'S107EXPLNART', N'S.107 Explanatory – arterial'), + (N'S107REFNART', N'S.107 Reference – not arterial'), + (N'S107EXPLNNART', N'S.107 Explanatory – not arterial'), + (N'S113REFHWYX', N'S.113 Reference SRW – Highway closure'), + (N'S113REFFRM12', N'S.113 Reference SRW – Form 12'), + (N'S113REFSRW', N'S.113 Reference SRW – SRW'), + (N'S99EXPLNTRY', N'S.99(1)(e) Explanatory – SRW'), + (N'S99SUB4TRAN', N'S.99(1)(h)(i) Reference – Subdivision for tran purpose'), + (N'S107S27TFAX', N'S.107LTA/s.27(3)(b) TA/s.6 EA ref – BCTFA Expropriation'), + (N'S107S10MOTX', N'S.107 LTA/ s.10 TA/ s.6 EA ref – MoTI Expropriation'), + (N'S113S10MOTX', N'S.113 LTA/ s.10 TA/s.6 EA ref – MoTI Expropriation SRW'), + (N'S113S27TFAX', N'S.113 LTA/s.27(3)(b) TA/s.6 EA ref – BCTFA expropriation SRW'), + (N'LNDACTPLCRW', N'Land Act Plan – Crown grant'), + (N'SKETCHSITEP', N'Sketch/site plan'), + (N'S1001BLTACP', N'S.100(1)(b) LTA – Consolidation plan'), + (N'S109REFHWYX', N'S.109 reference plan-hwy closure'), + (N'S109SUBHWYX', N'S.109 subdivision plan – hwy closure'), + (N'S219LTARCOV', N'S.219 LTA reference – Covenant'), + (N'S219LTAXCOV', N'S.219 LTA explanatory – Covenant'), + (N'S991EESMNT', N'S.99(1)(e) – easement'), + (N'S67LTASUBD', N'S.67LTA – subdivision'), + (N'BLKOTLNPST', N'Block Outline reference'), + (N'S69LTABLKO', N'S.69LTA – Block Outline Posting'), + (N'S68POSTING', N'S.68 – Posting'), + (N'AIRSPACE', N'Airspace'), + (N'S1001AREF', N'S.100(1)(a) reference'), + (N'S16MAPRSRV', N'S.16 Map Reserve'), + (N'S17MAPRSRV', N'S.17 Map Reserve'), + (N'OTHER', N'Other'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/96_DML_PIMS_LAND_SURVEYOR_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/96_DML_PIMS_LAND_SURVEYOR_TYPE.sql new file mode 100644 index 0000000000..93b98fbe4b --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/96_DML_PIMS_LAND_SURVEYOR_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LAND_SURVEYOR_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LAND_SURVEYOR_TYPE +GO + +INSERT INTO PIMS_LAND_SURVEYOR_TYPE (LAND_SURVEYOR_TYPE_CODE, DESCRIPTION) +VALUES + (N'CLS', N'CLS (Canada Land Surveyor)'), + (N'BCLS', N'BCLS (BC Land Surveyor)'), + (N'OTHER', N'Other'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/97_DML_PIMS_ROLE_CLAIM.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/97_DML_PIMS_ROLE_CLAIM.sql new file mode 100644 index 0000000000..3955c22742 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/97_DML_PIMS_ROLE_CLAIM.sql @@ -0,0 +1,15 @@ +DECLARE @restricted BIGINT; +DECLARE @finance BIGINT; +SELECT @restricted = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Functional (Restricted)'; +SELECT @finance = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Finance'; + +DECLARE @researchAdd BIGINT; +DECLARE @leaseEdit BIGINT; +select @researchAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'researchfile-add'; +select @leaseEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'lease-edit'; + +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE ROLE_ID = @restricted AND CLAIM_ID = @researchAdd; + +DELETE FROM [dbo].[PIMS_ROLE_CLAIM] WHERE ROLE_ID = @finance AND CLAIM_ID = @leaseEdit; + +GO \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/Schema Compare.zip b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/Schema Compare.zip new file mode 100644 index 0000000000..c75f978853 Binary files /dev/null and b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Alter Up/Schema Compare.zip differ diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/00_PSP_PIMS_ETL_SCHEMA_Build.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/00_PSP_PIMS_ETL_SCHEMA_Build.sql new file mode 100644 index 0000000000..af2a3e373b --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/00_PSP_PIMS_ETL_SCHEMA_Build.sql @@ -0,0 +1,38 @@ +-- Script generated by Aqua Data Studio Schema Synchronization for MS SQL Server 2016 on Tue Oct 05 16:47:03 PDT 2021 +-- Execute this script on: +-- etl schema will be created + +-- We recommend backing up the database prior to executing the script. + +SET XACT_ABORT ON +GO +SET TRANSACTION ISOLATION LEVEL SERIALIZABLE +GO +BEGIN TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create ETL schema +IF NOT EXISTS (SELECT * + FROM sys.schemas + WHERE name = N'etl') + EXEC('CREATE SCHEMA [etl]'); +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +COMMIT TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DECLARE @Success AS BIT +SET @Success = 1 +SET NOEXEC OFF +IF (@Success = 1) PRINT 'The database update succeeded' +ELSE BEGIN + IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION + PRINT 'The database update failed' +END +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/01_PSP_PIMS_PMBC_SCHEMA_Build.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/01_PSP_PIMS_PMBC_SCHEMA_Build.sql new file mode 100644 index 0000000000..e6a023c739 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/01_PSP_PIMS_PMBC_SCHEMA_Build.sql @@ -0,0 +1,38 @@ +-- Script generated by Aqua Data Studio Schema Synchronization for MS SQL Server 2016 on Tue Oct 05 16:47:03 PDT 2021 +-- Execute this script on: +-- pmbc schema will be created + +-- We recommend backing up the database prior to executing the script. + +SET XACT_ABORT ON +GO +SET TRANSACTION ISOLATION LEVEL SERIALIZABLE +GO +BEGIN TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create PMBC schema +IF NOT EXISTS (SELECT * + FROM sys.schemas + WHERE name = N'pmbc') + EXEC('CREATE SCHEMA [pmbc]'); +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +COMMIT TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DECLARE @Success AS BIT +SET @Success = 1 +SET NOEXEC OFF +IF (@Success = 1) PRINT 'The database update succeeded' +ELSE BEGIN + IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION + PRINT 'The database update failed' +END +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/02_PSP_PIMS_S32_00_Build.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/02_PSP_PIMS_S32_00_Build.sql new file mode 100644 index 0000000000..b8f44c2ca2 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/02_PSP_PIMS_S32_00_Build.sql @@ -0,0 +1,21762 @@ +/* +Script generated by Aqua Data Studio 22.1.3 on Jul-06-2022 01:32:49 PM +Database: PSP_PIMS_S32_00 +Schema: dbo +Objects: DATATYPE, DEFAULT, RULE, SEQUENCE, TABLE, VIEW, SYNONYM, PROCEDURE, FUNCTION, INDEX, TRIGGER, DATABASETRIGGER, DATABASE_AUDIT_SPEC +*/ +CREATE SEQUENCE [dbo].[BCA_DATA_ADVICE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[BCA_MINOR_TAXING_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[BCA_OWNER_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACCESS_REQUEST_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACCESS_REQUEST_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_ACTIVITY_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_NUMBER_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_PERSON_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_OWNER_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACQUISITION_OWNER_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_MODEL_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_MODEL_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_MODEL_TASK_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_SERVICE_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_TASK_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ACTIVITY_TEMPLATE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ADDRESS_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ADDRESS_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ASSET_EVALUATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_BUILDING_CONSTRUCTION_TYPE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_BUILDING_EVALUATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_BUILDING_FISCAL_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_BUILDING_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_BUILDING_OCCUPANT_TYPE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_BUILDING_PREDOMINATE_USE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_CLAIM_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_CLAIM_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_CONTACT_METHOD_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_CONTACT_METHOD_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_DOCUMENT_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_DOCUMENT_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_DOCUMENT_TYP_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_DOCUMENT_TYPE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_INSURANCE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_INSURANCE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_L_FILE_NO_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_ACTIVITY_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_ACTIVITY_PERIOD_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_FORECAST_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_FORECAST_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_PERIOD_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_PERIOD_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_TENANT_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_TENANT_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_TERM_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_LEASE_TERM_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_NOTE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_NOTE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ORGANIZATION_ADDRESS_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ORGANIZATION_ADDRESS_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ORGANIZATION_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ORGANIZATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PERSON_ADDRESS_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PERSON_ADDRESS_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PERSON_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PERSON_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PERSON_ORGANIZATION_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PERSON_ORGANIZATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 21474483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_NOTE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_NOTE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_NUMBER_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_ORGANIZATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_PROPERTY_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_PROPERTY_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_WORKFLOW_MODEL_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROJECT_WORKFLOW_MODEL_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROP_PROP_ROAD_TYPE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROP_PROP_TENURE_TYPE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ACTIVITY_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ACTIVITY_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_EVALUATION_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_EVALUATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_IMPROVEMENT_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_IMPROVEMENT_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_LEASE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_LEASE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ORGANIZATION_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_ORGANIZATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_RESEARCH_FILE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_RESEARCH_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_SERVICE_FILE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_SERVICE_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_STRUCTURE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_TAX_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_PROPERTY_TAX_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_REGION_USER_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_REGION_USER_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_RESEARCH_FILE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_RESEARCH_FILE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_RESEARCH_FILE_PURPOSE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_RESEARCH_FILE_PURPOSE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_RFILE_NUMBER_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ROLE_CLAIM_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ROLE_CLAIM_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ROLE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_ROLE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_STATIC_VARIABLE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_STRUCTURE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_TASK_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_TASK_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_TASK_TEMPLATE_ACTIVITY_MODEL_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_TASK_TEMPLATE_ACTIVITY_MODEL_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_TASK_TEMPLATE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_TASK_TEMPLATE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_TENANT_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_USER_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_USER_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_USER_ORGANIZATION_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_USER_ORGANIZATION_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_USER_ROLE_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_USER_ROLE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_USER_TASK_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_WORKFLOW_MODEL_H_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE SEQUENCE [dbo].[PIMS_WORKFLOW_MODEL_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO + +CREATE TABLE [dbo].[BCA_DATA_ADVICE] ( + [DATA_ADVICE_ID] bigint NOT NULL CONSTRAINT [BCDADV_DATA_ADVICE_ID_DEF] DEFAULT (NEXT VALUE FOR [BCA_DATA_ADVICE_ID_SEQ]), + [ROLL_YEAR] int NOT NULL, + [OWNERSHIP_YEAR] int NOT NULL, + [RUN_TYPE] nvarchar(16) NULL, + [START_DATE] date NOT NULL, + [END_DATE] date NOT NULL, + [TOTAL_FOLIO_COUNT] int NULL, + [TAXABLE_FOLIO_COUNT] int NULL, + [TAX_EXEMPT_FOLIO_COUNT] int NULL, + [TOTAL_GROSS_LAND_VALUE] money NULL, + [TOTAL_GROSS_IMPROVEMENT_VALUE] money NULL, + [TOTAL_TAX_EXEMPT_LAND_VALUE] money NULL, + [TOTAL_TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [TOTAL_NET_LAND_VALUE] money NULL, + [TOTAL_NET_IMPROVEMENT_VALUE] money NULL, + [VERSION] nvarchar(50) NOT NULL, + [REQUEST_ID] nvarchar(32) NOT NULL, + [ORDER_ID] nvarchar(32) NOT NULL, + [RUN_DATE] date NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDADV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDADV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDADV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDADV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [BCDADV_PK] PRIMARY KEY CLUSTERED([DATA_ADVICE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Primary key' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'DATA_ADVICE_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The roll year parameter used to generate the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'ROLL_YEAR' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The ownership year parameter used to generate the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'OWNERSHIP_YEAR' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Represents a code indicating the run type that generated the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'RUN_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The start date of the reporting period for the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'START_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The end date of the reporting period for the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'END_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The total number of folios included in the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TOTAL_FOLIO_COUNT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The number of taxable folios included in the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TAXABLE_FOLIO_COUNT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The number of exempt folios included in the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_FOLIO_COUNT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross sum of all land values reported for the folio group.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TOTAL_GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross sum of all improvement(s) values reported for the folio group.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TOTAL_GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt sum of all land values reported for the folio group.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TOTAL_TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt sum of all improvement(s) values reported for the folio group.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TOTAL_TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net sum of all land values reported for the folio group.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TOTAL_NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net sum of all improvement(s) values reported for the folio group.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'TOTAL_NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Represents a version number of one to four integers separated by periods (e.g. 1.0). Version numbers are assumed to be ordered according to standard conventions. If "x" and "y" are version numbers where "x" precedes "y" in sort order, then "x" shall ide' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'VERSION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A unique identifier for the request that specified the order parameters. The value is intended for BCA internal purposes only.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'REQUEST_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A unique identifier for the order that generated the Data Advice XML document. The value is intended for BCA internal purposes only.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'ORDER_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The date when the order was run to generate the Data Advice XML document.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE', + @level2type = N'Column', @level2name = N'RUN_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Represents an entire Data Advice XML delivery for a single order.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE' +GO + +CREATE TABLE [dbo].[BCA_ASSESSMENT_AREA] ( + [AREA_CODE] nvarchar(16) NOT NULL, + [DATA_ADVICE_ID] bigint NULL, + [DESCRIPTION] nvarchar(255) NULL, + [TOTAL_FOLIO_COUNT] int NULL, + [TAXABLE_FOLIO_COUNT] int NULL, + [TAX_EXEMPT_FOLIO_COUNT] int NULL, + [TOTAL_GROSS_LAND_VALUE] money NULL, + [TOTAL_GROSS_IMPROVEMENT_VALUE] money NULL, + [TOTAL_TAX_EXEMPT_LAND_VALUE] money NULL, + [TOTAL_TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [TOTAL_NET_NET_LAND_VALUE] money NULL, + [TOTAL_NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCASAR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCASAR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCASAR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCASAR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [BCASAR_PK] PRIMARY KEY CLUSTERED([AREA_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The BCA code that identifies the assessment area.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ASSESSMENT_AREA', + @level2type = N'Column', @level2name = N'AREA_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the BCA assessment area.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ASSESSMENT_AREA', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Represents a folio group for a single BCA assessment area.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ASSESSMENT_AREA' +GO + +CREATE TABLE [dbo].[BCA_AREA_AMENDMENT] ( + [AREA_CODE] nvarchar(16) NULL, + [AMENDMENT_REASON_CODE] nvarchar(16) NULL, + [AMENDMENT_REASON_DESCRIPTION] nvarchar(255) NULL, + [FOLIO_COUNT] int NOT NULL CONSTRAINT [BCAAMD_FOLIO_COUNT_DEF] DEFAULT ((0)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAAMD_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAAMD_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAAMD_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAAMD_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the amendment type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_REASON_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description of the amendment reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_REASON_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The folio count for the amendment type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_AMENDMENT', + @level2type = N'Column', @level2name = N'FOLIO_COUNT' +GO + +CREATE TABLE [dbo].[BCA_AREA_BCTRANSIT_VALUE] ( + [AREA_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCATRV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCATRV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCATRV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCATRV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the area class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The area class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the area sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The area sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for BC Transit purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_BCTRANSIT_VALUE' +GO + +CREATE TABLE [dbo].[BCA_AREA_DELETE] ( + [AREA_CODE] nvarchar(16) NULL, + [DELETE_REASON_CODE] nvarchar(16) NOT NULL CONSTRAINT [BCADEL_DELETE_REASON_CODE_DEF] DEFAULT ('UNKNOWN'), + [DELETE_REASON_DESCRIPTION] nvarchar(255) NULL, + [FOLIO_COUNT] int NOT NULL CONSTRAINT [BCADEL_FOLIO_COUNT_DEF] DEFAULT ((0)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCADEL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCADEL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCADEL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCADEL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_DELETE', + @level2type = N'Column', @level2name = N'DELETE_REASON_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description of the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_DELETE', + @level2type = N'Column', @level2name = N'DELETE_REASON_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The folio count for the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_DELETE', + @level2type = N'Column', @level2name = N'FOLIO_COUNT' +GO + +CREATE TABLE [dbo].[BCA_AREA_GENERAL_VALUE] ( + [AREA_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAGNV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAGNV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAGNV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAGNV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the area class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The area class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the area sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The area sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for general purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_GENERAL_VALUE' +GO + +CREATE TABLE [dbo].[BCA_AREA_SCHOOL_VALUE] ( + [AREA_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCASCV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCASCV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCASCV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCASCV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the area class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The area class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the area sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The area sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for school purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_AREA_SCHOOL_VALUE' +GO + +CREATE TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] ( + [DATA_ADVICE_ID] bigint NULL, + [AMENDMENT_REASON_CODE] nvarchar(16) NULL, + [AMENDMENT_REASON_DESCRIPTION] nvarchar(255) NULL, + [FOLIO_COUNT] int NOT NULL CONSTRAINT [BCDAMD_FOLIO_COUNT_DEF] DEFAULT ((0)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDAMD_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDAMD_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDAMD_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDAMD_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the amendment type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_REASON_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description of the amendment reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_REASON_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The folio count for the amendment type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_AMENDMENT', + @level2type = N'Column', @level2name = N'FOLIO_COUNT' +GO + +CREATE TABLE [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE] ( + [DATA_ADVICE_ID] bigint NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDTRV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDTRV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDTRV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDTRV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the property class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The property class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the property sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The property sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for BC Transit purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_BCTRANSIT_VALUE' +GO + +CREATE TABLE [dbo].[BCA_DATA_ADVICE_DELETE] ( + [DATA_ADVICE_ID] bigint NULL, + [DELETE_REASON_CODE] nvarchar(16) NOT NULL CONSTRAINT [BCDDEL_DELETE_REASON_CODE_DEF] DEFAULT ('UNKNOWN'), + [DELETE_REASON_DESCRIPTION] nvarchar(255) NULL, + [FOLIO_COUNT] int NOT NULL CONSTRAINT [BCDDEL_FOLIO_COUNT_DEF] DEFAULT ((0)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDDEL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDDEL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDDEL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDDEL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_DELETE', + @level2type = N'Column', @level2name = N'DELETE_REASON_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description of the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_DELETE', + @level2type = N'Column', @level2name = N'DELETE_REASON_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The folio count for the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_DELETE', + @level2type = N'Column', @level2name = N'FOLIO_COUNT' +GO + +CREATE TABLE [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE] ( + [DATA_ADVICE_ID] bigint NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDGNV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDGNV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDGNV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDGNV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the property class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The property class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the property sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The property sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for general purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_GENERAL_VALUE' +GO + +CREATE TABLE [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE] ( + [DATA_ADVICE_ID] bigint NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDSCV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDSCV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCDSCV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCDSCV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the property class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The property class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the property sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The property sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for school purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DATA_ADVICE_SCHOOL_VALUE' +GO + +CREATE TABLE [dbo].[BCA_JURISDICTION] ( + [JURISDICTION_CODE] nvarchar(16) NOT NULL, + [AREA_CODE] nvarchar(16) NULL, + [DESCRIPTION] nvarchar(255) NULL, + [TOTAL_FOLIO_COUNT] int NULL, + [TAXABLE_FOLIO_COUNT] int NULL, + [TAX_EXEMPT_FOLIO_COUNT] int NULL, + [TOTAL_GROSS_LAND_VALUE] money NULL, + [TOTAL_GROSS_IMPROVEMENT_VALUE] money NULL, + [TOTAL_TAX_EXEMPT_LAND_VALUE] money NULL, + [TOTAL_TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [TOTAL_NET_LAND_VALUE] money NULL, + [TOTAL_NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAJUR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAJUR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAJUR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAJUR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [BCAJUR_PK] PRIMARY KEY CLUSTERED([JURISDICTION_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The BCA code that identifies the jurisdiction.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION', + @level2type = N'Column', @level2name = N'JURISDICTION_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The short name/description of the jurisdiction.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_RECORD] ( + [ROLL_NUMBER] nvarchar(32) NOT NULL, + [JURISDICTION_CODE] nvarchar(16) NULL, + [FOLIO_STATUS] nvarchar(16) NULL, + [FOLIO_STATUS_DESCRIPTION] nvarchar(255) NULL, + [ACTION] nvarchar(16) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFOR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFOR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFOR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFOR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [BCAFOR_PK] PRIMARY KEY CLUSTERED([ROLL_NUMBER]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The unique identifier for the specific folio within its jurisdiction.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_RECORD', + @level2type = N'Column', @level2name = N'ROLL_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates the status of the folio at the time the Data Advice XML document was generated.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_RECORD', + @level2type = N'Column', @level2name = N'FOLIO_STATUS' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The short name/description of the folio status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_RECORD', + @level2type = N'Column', @level2name = N'FOLIO_STATUS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Specifies the folio action: Add, Delete.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_RECORD', + @level2type = N'Column', @level2name = N'ACTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Represents a data record for a single folio and its associated attributes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_RECORD' +GO + +CREATE TABLE [dbo].[BCA_MINOR_TAXING] ( + [MINOR_TAXING_ID] bigint NOT NULL CONSTRAINT [BCMNTX_MINOR_TAXING_ID_DEF] DEFAULT (NEXT VALUE FOR [BCA_MINOR_TAXING_ID_SEQ]), + [ROLL_NUMBER] nvarchar(32) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCMNTX_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCMNTX_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCMNTX_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCMNTX_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [BCMNTX_PK] PRIMARY KEY CLUSTERED([MINOR_TAXING_ID]) +) +GO + +CREATE TABLE [dbo].[BCA_DEFINED] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCADFN_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCADFN_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCADFN_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCADFN_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DEFINED', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DEFINED', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DEFINED', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Defined minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_DEFINED' +GO + +CREATE TABLE [dbo].[BCA_ELECTORAL_AREA] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCELCT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCELCT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCELCT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCELCT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ELECTORAL_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ELECTORAL_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ELECTORAL_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Electoral Areas minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ELECTORAL_AREA' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_ADDRESS] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [ADDRESS_ID] nvarchar(255) NULL, + [PRIMARY_FLAG] bit NULL CONSTRAINT [BCFADR_PRIMARY_FLAG_DEF] DEFAULT (CONVERT([bit],(0))), + [UNIT_NUMBER] nvarchar(255) NULL, + [STREET_NUMBER] nvarchar(255) NULL, + [STREET_DIRECTION_PREFIX] nvarchar(255) NULL, + [STREET_NAME] nvarchar(255) NULL, + [STREET_TYPE] nvarchar(255) NULL, + [STREET_DIRECTION_SUFFIX] nvarchar(255) NULL, + [CITY] nvarchar(255) NULL, + [PROVINCE_STATE] nvarchar(255) NULL, + [POSTAL_ZIP] nvarchar(255) NULL, + [MAP_REFERENCE_NUMBER] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFADR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFADR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFADR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFADR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Unique address identifier provided by BC Assessment.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'ADDRESS_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether the address is the primary address associated with the folio.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'PRIMARY_FLAG' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Apartment or suite or unit number.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'UNIT_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Street number assigned by a local government (municipality).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'STREET_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Further refinement of the street name to facilitate location of the folio (pre-directional).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'STREET_DIRECTION_PREFIX' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Street identifier assigned by a local government (municipality).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'STREET_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Road, Street, Place, etc.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'STREET_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Further refinement of the street name to facilitate location of the folio (post-directional).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'STREET_DIRECTION_SUFFIX' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'City name.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'CITY' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Province or state.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'PROVINCE_STATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Postal or zip code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'POSTAL_ZIP' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Formerly National Topographic System (NTS) number. A geographic reference.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_ADDRESS', + @level2type = N'Column', @level2name = N'MAP_REFERENCE_NUMBER' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_AMENDMENT] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [AMENDMENT_TYPE] nvarchar(16) NULL, + [AMENDMENT_TYPE_DESCRIPTION] nvarchar(255) NULL, + [AMENDMENT_REASON_CODE] nvarchar(16) NULL, + [AMENDMENT_REASON_DESCRIPTION] nvarchar(255) NULL, + [SUPP_OCCUPANCY_DATE] date NULL, + [SUPP_OCCUPANCY_CODE] nvarchar(16) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFAM_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFAM_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFAM_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFAM_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the process that resulted in the amendment.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description about the Amendment Type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_TYPE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the reason for the amendment.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_REASON_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description about the Amendment Reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_REASON_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Specifies the date when a SUPP occupancy began or ended.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_AMENDMENT', + @level2type = N'Column', @level2name = N'SUPP_OCCUPANCY_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Specifies whether the SUPP occupancy date indicates a begin (B) or end (E) date.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_AMENDMENT', + @level2type = N'Column', @level2name = N'SUPP_OCCUPANCY_CODE' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_BCTRANSIT_VALUE] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFTRV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFTRV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFTRV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFTRV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for BC Transit purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_BCTRANSIT_VALUE' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_DESCRIPTION] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [NEIGHBOURHOOD_CODE] nvarchar(16) NULL, + [NEIGHBOURHOOD_DESCRIPTION] nvarchar(255) NULL, + [ACTUAL_USE_CODE] nvarchar(16) NULL, + [ACTUAL_USE_DESCRIPTION] nvarchar(255) NULL, + [VACANT_FLAG] bit NULL, + [BCTRANSIT_FLAG] bit NULL, + [POLICE_TAX_FLAG] bit NULL, + [ADD_SCHOOL_TAX_3M_TO_4M_FLAG] bit NULL, + [ADD_SCHOOL_TAX_GREATER_4M_FLAG] bit NULL, + [CANDIDATE_FOR_SPEC_TAX_FLAG] bit NULL, + [ALR_CODE] nvarchar(16) NULL, + [ALR_DESCRIPTION] nvarchar(255) NULL, + [TENURE_CODE] nvarchar(16) NULL, + [TENURE_DESCRIPTION] nvarchar(255) NULL, + [PARKING_AREA] nvarchar(255) NULL, + [LAND_DIMENSION_TYPE] nvarchar(255) NULL, + [LAND_DIMENSION_TYPE_DESCRIPTION] nvarchar(255) NULL, + [LAND_DIMENSION] nvarchar(255) NULL, + [LAND_WIDTH] nvarchar(255) NULL, + [LAND_DEPTH] nvarchar(255) NULL, + [SCHOOL_DISTRICT_CODE] nvarchar(16) NULL, + [SCHOOL_DISTRICT_DESCRIPTION] nvarchar(255) NULL, + [REGIONAL_DISTRICT_CODE] nvarchar(16) NULL, + [REGIONAL_DISTRICT_DESCRIPTION] nvarchar(255) NULL, + [REGIONAL_HOSPITAL_DISTRICT_CODE] nvarchar(16) NULL, + [REGIONAL_HOSPITAL_DISTRICT_DESCRIPTION] nvarchar(255) NULL, + [PREDOMINANT_MANUAL_CLASS_CODE] nvarchar(16) NULL, + [PREDOMINANT_MANUAL_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PREDOMINANT_PERCENT_DEVIATION] decimal(9,3) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFDE_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFDE_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFDE_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFDE_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the neighbourhood.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'NEIGHBOURHOOD_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the neighbourhood.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'NEIGHBOURHOOD_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Represents the code for an entry in a lookup table.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'ACTUAL_USE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the Actual Use.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'ACTUAL_USE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether the folio is vacant or occupied.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'VACANT_FLAG' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether the folio is subject to BC Transit taxation.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'BCTRANSIT_FLAG' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether the folio is subject to exemption.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'POLICE_TAX_FLAG' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether the folio is a subject to additional school tax (residential portion assessed between $3 and $4 million).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'ADD_SCHOOL_TAX_3M_TO_4M_FLAG' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether the folio is a subject to additional school tax (residential portion assessed over $4 million).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'ADD_SCHOOL_TAX_GREATER_4M_FLAG' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether the folio is a candidate for speculation tax.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'CANDIDATE_FOR_SPEC_TAX_FLAG' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Agricultural Land Reserve identifier for the folio.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'ALR_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description about the ALR code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'ALR_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifies the type of ownership or occupation on land.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'TENURE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The short name/description of the tenure code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'TENURE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifies the total value of the parking area (TransLink values only for Roll Years 2005 to 2007).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'PARKING_AREA' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the type of land measurements being used.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'LAND_DIMENSION_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description about the land dimension type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'LAND_DIMENSION_TYPE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Freeform land measurement.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'LAND_DIMENSION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Land width measurement.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'LAND_WIDTH' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Land depth measurement.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'LAND_DEPTH' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the special district.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'SCHOOL_DISTRICT_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the special district.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'SCHOOL_DISTRICT_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the special district.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'REGIONAL_DISTRICT_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the special district.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'REGIONAL_DISTRICT_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the special district.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'REGIONAL_HOSPITAL_DISTRICT_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the special district.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'REGIONAL_HOSPITAL_DISTRICT_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the state and condition of improvements and structural components.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'PREDOMINANT_MANUAL_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description about the manual class code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'PREDOMINANT_MANUAL_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A percentage deviation from the manual class code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION', + @level2type = N'Column', @level2name = N'PREDOMINANT_PERCENT_DEVIATION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes general characteristics of the folio.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_DESCRIPTION' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_FARM] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [FARM_NUMBER] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFARM_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFARM_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFARM_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFARM_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A BCA farm identification number' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_FARM', + @level2type = N'Column', @level2name = N'FARM_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Farm associated with this folio.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_FARM' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_GENERAL_VALUE] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFGNV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFGNV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFGNV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFGNV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for general purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_GENERAL_VALUE' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [LAND_CHARACTERISTIC_CODE] nvarchar(16) NULL, + [LAND_CHARACTERISTIC_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCLCHR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCLCHR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCLCHR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCLCHR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating a characteristic of the land.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LAND_CHARACTERISTIC', + @level2type = N'Column', @level2name = N'LAND_CHARACTERISTIC_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A description of the LandCharacteristicCode.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LAND_CHARACTERISTIC', + @level2type = N'Column', @level2name = N'LAND_CHARACTERISTIC_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Represents a land characteristic.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LAND_CHARACTERISTIC' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [FORMATTED_LEGAL_DESCRIPTION] nvarchar(1024) NULL, + [PID] nvarchar(255) NULL, + [LOT] nvarchar(255) NULL, + [STRATA_LOT] nvarchar(255) NULL, + [PARCEL] nvarchar(255) NULL, + [BLOCK] nvarchar(255) NULL, + [SUB_BLOCK] nvarchar(255) NULL, + [PLAN_NUMBER] nvarchar(255) NULL, + [SUB_LOT] nvarchar(255) NULL, + [PART_1] nvarchar(255) NULL, + [PART_2] nvarchar(255) NULL, + [PART_3] nvarchar(255) NULL, + [PART_4] nvarchar(255) NULL, + [DISTRICT_LOT] nvarchar(255) NULL, + [LEGAL_SUBDIVISION] nvarchar(255) NULL, + [SECTION] nvarchar(255) NULL, + [TOWNSHIP] nvarchar(255) NULL, + [RANGE] nvarchar(255) NULL, + [MERIDIAN] nvarchar(255) NULL, + [MERIDIAN_SHORT] nvarchar(255) NULL, + [BCA_GROUP] nvarchar(255) NULL, + [LAND_DISTRICT] nvarchar(255) NULL, + [LAND_DISTRICT_DESCRIPTION] nvarchar(255) NULL, + [PORTION] nvarchar(255) NULL, + [EXCEPT_PLAN] nvarchar(255) NULL, + [FIRST_NATION_RESERVE_NUMBER] nvarchar(255) NULL, + [FIRST_NATION_RESERVE_DESCRIPTION] nvarchar(255) NULL, + [LEASE_LICENSE_NUMBER] nvarchar(255) NULL, + [LAND_BRANCH_FILE_NUMBER] nvarchar(255) NULL, + [AIR_SPACE_PARCEL_NUMBER] nvarchar(255) NULL, + [NTS_LOCATION] nvarchar(255) NULL, + [LEGAL_TEXT] nvarchar(1024) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFLD_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFLD_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFLD_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFLD_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A formatted string of all the legal description attributes with appropriate labels.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'FORMATTED_LEGAL_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The PID that uniquely identifies the legal description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'PID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Lot, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'LOT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Strata Lot, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'STRATA_LOT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Parcel, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'PARCEL' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Block, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'BLOCK' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Sub block, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'SUB_BLOCK' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Plan number, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'PLAN_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Suburban lot, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'SUB_LOT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Part 1, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'PART_1' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Part 2, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'PART_2' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Part 3, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'PART_3' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Part 4, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'PART_4' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'District lot, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'DISTRICT_LOT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Legal subdivision, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'LEGAL_SUBDIVISION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Section, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'SECTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Township, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'TOWNSHIP' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Range, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'RANGE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Meridian Code, identifies a line of longitude, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'MERIDIAN' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Meridian Code, identifies a line of longitude, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'MERIDIAN_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The legal description group as defined by BCA.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'BCA_GROUP' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Land district, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'LAND_DISTRICT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The short name/description of the LandDistrict.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'LAND_DISTRICT_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Portion, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'PORTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Except plan, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'EXCEPT_PLAN' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifier assigned to FN reserve properties by BCA.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'FIRST_NATION_RESERVE_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The short name/description of the FirstNationReserveNumber.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'FIRST_NATION_RESERVE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Lease licence number as defined by the Ministry of Forest, Lands, and Natural Resource Operations and other valid sources of leases added to the assessment roll.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'LEASE_LICENSE_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Lands Branch File Number as defined by the Ministry of Forest, Lands, and Natural Resource Operations.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'LAND_BRANCH_FILE_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A volumetric parcel identifier.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'AIR_SPACE_PARCEL_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'National Topographic System Reference Number.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'NTS_LOCATION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Freeform legal text, part of the legal description of a parcel of land as provided by the Land Title and Survey Authority.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_LEGAL_DESCRIPTION', + @level2type = N'Column', @level2name = N'LEGAL_TEXT' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_MANAGED_FOREST] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [FARM_NUMBER] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCMFOR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCMFOR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCMFOR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCMFOR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A BCA farm identification number' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_MANAGED_FOREST', + @level2type = N'Column', @level2name = N'FARM_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Managed forest information associated with this folio.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_MANAGED_FOREST' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_MANUFACTURED_HOME] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [MH_REGISTRY_NUMBER] nvarchar(255) NULL, + [MH_BAY_NUMBER] nvarchar(255) NULL, + [MH_PARK] nvarchar(255) NULL, + [MH_PARK_ROLL_NUMBER] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCMANH_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCMANH_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCMANH_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCMANH_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Registration number for a manufactured home (MH) by the Manufactured Home Registry.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_MANUFACTURED_HOME', + @level2type = N'Column', @level2name = N'MH_REGISTRY_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Bay number associated with the manufactured home.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_MANUFACTURED_HOME', + @level2type = N'Column', @level2name = N'MH_BAY_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The name or other identification of the park associated with the manufactured home.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_MANUFACTURED_HOME', + @level2type = N'Column', @level2name = N'MH_PARK' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Park roll number associated with the manufactured home.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_MANUFACTURED_HOME', + @level2type = N'Column', @level2name = N'MH_PARK_ROLL_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Provides information for a single manufactured home.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_MANUFACTURED_HOME' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_OIL_AND_GAS] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [FARM_NUMBER] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCOILG_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCOILG_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCOILG_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCOILG_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A BCA farm identification number' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_OIL_AND_GAS', + @level2type = N'Column', @level2name = N'FARM_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Oil and gas information associated with this folio.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_OIL_AND_GAS' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_SALES] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [DOCUMENT_NUMBER] nvarchar(255) NULL, + [SALE_DATE] date NULL, + [SALE_PRICE] money NULL, + [SALE_STATUS_CODE] nvarchar(16) NULL, + [SALE_STATUS_DESCRIPTION] nvarchar(255) NULL, + [CONVEYANCE_DATE] date NULL, + [CONVEYANCE_PRICE] money NULL, + [CONVEYANCE_TYPE] nvarchar(16) NULL, + [CONVEYANCE_TYPE_DESCRIPTION] nvarchar(255) NULL, + [REJECT_REASON_CODE] nvarchar(16) NULL, + [REJECT_REASON_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFSA_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFSA_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAFSA_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAFSA_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The LTSA Document Number assigned in regard to an Indefeasible State of Title Certificate, which indicates ownership or title.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'DOCUMENT_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The date the LTSA document was received for registration at Land Title and Survey Authority, subject to adjustment by BCA.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'SALE_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The price provided on the LTSA document as received for registration at Land Title and Survey Authority, subject to adjustment by BCA.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'SALE_PRICE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The code applied to the sale record by BCA property assessment staff to identify eligibility for inclusion into overall market analysis.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'SALE_STATUS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description about the sale status code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'SALE_STATUS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The date associated with this sale.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'CONVEYANCE_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The amount of money exchanged as part of this sale.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'CONVEYANCE_PRICE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The conveyance type code identifying the characteristics of the sale.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'CONVEYANCE_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description about the conveyance type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'CONVEYANCE_TYPE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The reject reason code identifying why a sale was rejected.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'REJECT_REASON_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description about the reject reason code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SALES', + @level2type = N'Column', @level2name = N'REJECT_REASON_DESCRIPTION' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_SCHOOL_VALUE] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFSCV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFSCV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCFSCV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCFSCV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for school purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_SCHOOL_VALUE' +GO + +CREATE TABLE [dbo].[BCA_FOLIO_VALUATION] ( + [ROLL_NUMBER] nvarchar(32) NULL, + [TAX_EXEMPT_CODE] nvarchar(16) NULL, + [TAX_EXEMPT_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [LAND_VALUE] money NULL, + [IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAVAL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAVAL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAVAL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAVAL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exemption code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_VALUATION', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exemption code description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_VALUATION', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the property class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_VALUATION', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The code class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_VALUATION', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_VALUATION', + @level2type = N'Column', @level2name = N'LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The improvement(s) value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_FOLIO_VALUATION', + @level2type = N'Column', @level2name = N'IMPROVEMENT_VALUE' +GO + +CREATE TABLE [dbo].[BCA_GENERAL_SERVICE] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCGSVC_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCGSVC_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCGSVC_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCGSVC_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_GENERAL_SERVICE', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_GENERAL_SERVICE', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_GENERAL_SERVICE', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The General Services minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_GENERAL_SERVICE' +GO + +CREATE TABLE [dbo].[BCA_IMPROVEMENT_DISTRICT] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCIMPD_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCIMPD_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCIMPD_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCIMPD_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_IMPROVEMENT_DISTRICT', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_IMPROVEMENT_DISTRICT', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_IMPROVEMENT_DISTRICT', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Improvement Districts minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_IMPROVEMENT_DISTRICT' +GO + +CREATE TABLE [dbo].[BCA_ISLANDS_TRUST] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCISLT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCISLT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCISLT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCISLT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ISLANDS_TRUST', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ISLANDS_TRUST', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ISLANDS_TRUST', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Islands Trusts minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_ISLANDS_TRUST' +GO + +CREATE TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] ( + [JURISDICTION_CODE] nvarchar(16) NULL, + [AMENDMENT_REASON_CODE] nvarchar(16) NULL, + [AMENDMENT_REASON_DESCRIPTION] nvarchar(255) NULL, + [FOLIO_COUNT] int NOT NULL CONSTRAINT [BCJAMD_FOLIO_COUNT_DEF] DEFAULT ((0)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJAMD_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJAMD_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJAMD_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJAMD_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the amendment type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_REASON_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description of the amendment reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_AMENDMENT', + @level2type = N'Column', @level2name = N'AMENDMENT_REASON_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The folio count for the amendment type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_AMENDMENT', + @level2type = N'Column', @level2name = N'FOLIO_COUNT' +GO + +CREATE TABLE [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE] ( + [JURISDICTION_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJTRV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJTRV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJTRV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJTRV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for BC Transit purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_BCTRANSIT_VALUE' +GO + +CREATE TABLE [dbo].[BCA_JURISDICTION_DELETE] ( + [JURISDICTION_CODE] nvarchar(16) NULL, + [DELETE_REASON_CODE] nvarchar(16) NOT NULL CONSTRAINT [BCJDEL_DELETE_REASON_CODE_DEF] DEFAULT ('UNKNOWN'), + [DELETE_REASON_DESCRIPTION] nvarchar(255) NULL, + [FOLIO_COUNT] int NOT NULL CONSTRAINT [BCJDEL_FOLIO_COUNT_DEF] DEFAULT ((0)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJDEL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJDEL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJDEL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJDEL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_DELETE', + @level2type = N'Column', @level2name = N'DELETE_REASON_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A short description of the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_DELETE', + @level2type = N'Column', @level2name = N'DELETE_REASON_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The folio count for the delete reason.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_DELETE', + @level2type = N'Column', @level2name = N'FOLIO_COUNT' +GO + +CREATE TABLE [dbo].[BCA_JURISDICTION_GENERAL_VALUE] ( + [JURISDICTION_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJGNV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJGNV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJGNV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJGNV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for general purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_GENERAL_VALUE' +GO + +CREATE TABLE [dbo].[BCA_JURISDICTION_SCHOOL_VALUE] ( + [JURISDICTION_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_CODE] nvarchar(16) NULL, + [PROPERTY_CLASS_DESCRIPTION] nvarchar(255) NULL, + [PROPERTY_SUBCLASS_CODE] nvarchar(16) NULL, + [PROPERTY_SUBCLASS_DESCRIPTION] nvarchar(255) NULL, + [GROSS_LAND_VALUE] money NULL, + [GROSS_IMPROVEMENT_VALUE] money NULL, + [TAX_EXEMPT_LAND_VALUE] money NULL, + [TAX_EXEMPT_IMPROVEMENT_VALUE] money NULL, + [NET_LAND_VALUE] money NULL, + [NET_IMPROVEMENT_VALUE] money NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJSCV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJSCV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCJSCV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCJSCV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_CLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code indicating the jurisdiction sub-class.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The jurisdiction sub-class description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'PROPERTY_SUBCLASS_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The gross improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'GROSS_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The tax exempt improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net land value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'NET_LAND_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The net improvement value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE', + @level2type = N'Column', @level2name = N'NET_IMPROVEMENT_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Values summarized by property class and sub-class for school purposes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_JURISDICTION_SCHOOL_VALUE' +GO + +CREATE TABLE [dbo].[BCA_LOCAL_AREA] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCLCLA_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCLCLA_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCLCLA_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCLCLA_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_LOCAL_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_LOCAL_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_LOCAL_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Local Areas minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_LOCAL_AREA' +GO + +CREATE TABLE [dbo].[BCA_OWNERSHIP_GROUP] ( + [OWNERSHIP_GROUP_ID] nvarchar(32) NOT NULL, + [ROLL_NUMBER] nvarchar(32) NULL, + [ASSESSMENT_NOTICE_RETURNED] bit NULL CONSTRAINT [BCAOWG_ASSESSMENT_NOTICE_RETURNED_DEF] DEFAULT (CONVERT([bit],(0))), + [ASSESSMENT_NOTICE_SUPPRESSED] bit NULL CONSTRAINT [BCAOWG_ASSESSMENT_NOTICE_SUPPRESSED_DEF] DEFAULT (CONVERT([bit],(0))), + [CHANGE_TYPE] nvarchar(16) NULL, + [CHANGE_TYPE_DESCRIPTION] nvarchar(255) NULL, + [CHANGE_DATE] date NULL, + [FORMATTED_MAILING_ADDR_LINE_1] nvarchar(40) NULL, + [FORMATTED_MAILING_ADDR_LINE_2] nvarchar(40) NULL, + [FORMATTED_MAILING_ADDR_LINE_3] nvarchar(40) NULL, + [FORMATTED_MAILING_ADDR_LINE_4] nvarchar(40) NULL, + [FORMATTED_MAILING_ADDR_LINE_5] nvarchar(40) NULL, + [FORMATTED_MAILING_ADDR_LINE_6] nvarchar(40) NULL, + [MAILING_ADDR_ATTENTION] nvarchar(255) NULL, + [MAILING_ADDR_CARE_OF] nvarchar(255) NULL, + [MAILING_ADDR_FLOOR] nvarchar(255) NULL, + [MAILING_ADDR_UNIT_NUMBER] nvarchar(255) NULL, + [MAILING_ADDR_STREET_DIRECTION_PREFIX] nvarchar(255) NULL, + [MAILING_ADDR_STREET_NUMBER] nvarchar(255) NULL, + [MAILING_ADDR_STREET_NAME] nvarchar(255) NULL, + [MAILING_ADDR_STREET_TYPE] nvarchar(255) NULL, + [MAILING_ADDR_STREET_DIRECTION_SUFFIX] nvarchar(255) NULL, + [MAILING_ADDR_CITY] nvarchar(255) NULL, + [MAILING_ADDR_PROVINCE_STATE] nvarchar(255) NULL, + [MAILING_ADDR_COUNTRY] nvarchar(255) NULL, + [MAILING_ADDR_POSTAL_ZIP] nvarchar(255) NULL, + [MAILING_ADDR_FREE_FORM] nvarchar(255) NULL, + [MAILING_ADDR_COMPARTMENT] nvarchar(255) NULL, + [MAILING_ADDR_DELIVERY_INSTALLATION_TYPE] nvarchar(255) NULL, + [MAILING_ADDR_MODE_OF_DELIVERY] nvarchar(255) NULL, + [MAILING_ADDR_MODE_OF_DELIVERY_VALUE] nvarchar(255) NULL, + [MAILING_ADDR_SITE] nvarchar(255) NULL, + [MAILING_ADDR_BULK_MAIL_CODE] nvarchar(255) NULL, + [CHANGE_SOURCE] nvarchar(16) NULL, + [CHANGE_SOURCE_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAOWG_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAOWG_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAOWG_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAOWG_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [BCAOWG_PK] PRIMARY KEY CLUSTERED([OWNERSHIP_GROUP_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifies the group of property owners.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'OWNERSHIP_GROUP_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether the Assessment Notice for the current roll year was returned' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'ASSESSMENT_NOTICE_RETURNED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether BCA has not sent out an Assessment Notice to this owner based' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'ASSESSMENT_NOTICE_SUPPRESSED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the type of the most recent change to the ownership information.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'CHANGE_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The short name/description of the ChangeType.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'CHANGE_TYPE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The date of the most recent change to the ownership information.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'CHANGE_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Formatted address line for mailing purposes: Line 1 consists of C/O label and value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'FORMATTED_MAILING_ADDR_LINE_1' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Formatted address line for mailing purposes: Line 2 consists of Attention label and value.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'FORMATTED_MAILING_ADDR_LINE_2' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Formatted address line for mailing purposes: Line 3 consists of value of freeform address field.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'FORMATTED_MAILING_ADDR_LINE_3' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Formatted address line for mailing purposes: Line 4 consists of Unit and Floor Number label and value if there is not enough room on Line 5.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'FORMATTED_MAILING_ADDR_LINE_4' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Formatted address line for mailing purposes: Line 5 consists of street number, name, type and directional data.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'FORMATTED_MAILING_ADDR_LINE_5' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Formatted address line for mailing purposes: Line 6 consists of Site and Compartment label and values' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'FORMATTED_MAILING_ADDR_LINE_6' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Attention, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_ATTENTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Care Of, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_CARE_OF' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Floor, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_FLOOR' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Apartment or Suite or Unit Number, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_UNIT_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Further refinement of the street name to facilitate location of building (pre-directional), as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_STREET_DIRECTION_PREFIX' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Street number assigned by a local government (municipality), as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_STREET_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Road name assigned by a local government (municipality), as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_STREET_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Street type assigned by a local government (municipality), as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_STREET_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Further refinement of the street name to facilitate location of building (post-directional), as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_STREET_DIRECTION_SUFFIX' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'City, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_CITY' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Province or state, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_PROVINCE_STATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Country, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_COUNTRY' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Postal or zip code, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_POSTAL_ZIP' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Additional mailing address information not fitting in any of the predefined fields, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_FREE_FORM' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Compartment, as required for mail to be sent to the owners mailing address.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_COMPARTMENT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Delivery installation type, as required for mail to be sent to the owners mailing address. E.g. Station, Post Office, Letter Carrier Depot, etc.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_DELIVERY_INSTALLATION_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Mode of Delivery, as required for mail to be sent to the owners mailing address. e.g. Rural Route, Post Office Box, General Delivery, etc.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_MODE_OF_DELIVERY' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Mode of delivery value, as required for mail to be sent to the owners mailing address. e.g. RR 876, PO Box 19, etc.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_MODE_OF_DELIVERY_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Site value, as required for mail to be sent to the owners mailing address. e.g. Site 10.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_SITE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifies when five or more properties are linked to a name record or when five or more name records with a single mailing address are linked to a folio.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'MAILING_ADDR_BULK_MAIL_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifies the source of the most recent change to the ownership information.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'CHANGE_SOURCE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The short name/description of the ChangeSource.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP', + @level2type = N'Column', @level2name = N'CHANGE_SOURCE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Represents a group of property owners with details in common.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNERSHIP_GROUP' +GO + +CREATE TABLE [dbo].[BCA_OWNER] ( + [OWNER_ID] bigint NOT NULL CONSTRAINT [BCAOWN_OWNER_ID_DEF] DEFAULT (NEXT VALUE FOR [BCA_OWNER_ID_SEQ]), + [OWNERSHIP_GROUP_ID] nvarchar(32) NOT NULL, + [FIRST_NAME] nvarchar(255) NULL, + [MIDDLE_NAME] nvarchar(255) NULL, + [MIDDLE_INITIAL] nvarchar(1) NULL, + [COMPANY_OR_LAST_NAME] nvarchar(255) NULL, + [OWNER_SEQUENCE_ID] nvarchar(32) NULL, + [EQUITY_TYPE] nvarchar(16) NULL, + [EQUITY_TYPE_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAOWN_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAOWN_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCAOWN_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCAOWN_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [BCAOWN_PK] PRIMARY KEY CLUSTERED([OWNER_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The first name of an owner.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNER', + @level2type = N'Column', @level2name = N'FIRST_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The middle name of an owner.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNER', + @level2type = N'Column', @level2name = N'MIDDLE_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The middle initial of an owner.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNER', + @level2type = N'Column', @level2name = N'MIDDLE_INITIAL' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The company name or last name of an owner.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNER', + @level2type = N'Column', @level2name = N'COMPANY_OR_LAST_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifies the sequence owners should be listed within an ownership group.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNER', + @level2type = N'Column', @level2name = N'OWNER_SEQUENCE_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifies the type of relationship an owner/lessee/occupier has to the folio.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNER', + @level2type = N'Column', @level2name = N'EQUITY_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The short name/description of the equity type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_OWNER', + @level2type = N'Column', @level2name = N'EQUITY_TYPE_DESCRIPTION' +GO + +CREATE TABLE [dbo].[BCA_SERVICE_AREA] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCSVCA_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCSVCA_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCSVCA_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCSVCA_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SERVICE_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SERVICE_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SERVICE_AREA', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Service Areas minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SERVICE_AREA' +GO + +CREATE TABLE [dbo].[BCA_SPECIFIED_MUNICIPAL] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCSPMU_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCSPMU_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCSPMU_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCSPMU_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SPECIFIED_MUNICIPAL', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SPECIFIED_MUNICIPAL', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SPECIFIED_MUNICIPAL', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Specified Municipal minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SPECIFIED_MUNICIPAL' +GO + +CREATE TABLE [dbo].[BCA_SPECIFIED_REGIONAL] ( + [MINOR_TAXING_ID] bigint NULL, + [MINOR_TAXING_CODE] nvarchar(16) NULL, + [MINOR_TAXING_CODE_SHORT] nvarchar(1) NULL, + [MINOR_TAXING_DESCRIPTION] nvarchar(255) NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCSPRG_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCSPRG_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [BCSPRG_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [BCSPRG_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()) + ) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SPECIFIED_REGIONAL', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A one-character code identifying the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SPECIFIED_REGIONAL', + @level2type = N'Column', @level2name = N'MINOR_TAXING_CODE_SHORT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The full name/description of the minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SPECIFIED_REGIONAL', + @level2type = N'Column', @level2name = N'MINOR_TAXING_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The Specified Regional minor taxing jurisdiction (MTXJ).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'BCA_SPECIFIED_REGIONAL' +GO + +CREATE TABLE [dbo].[PIMSX_TableDefinitions] ( + [TABLE_NAME] nvarchar(255) NULL, + [TABLE_ALIAS] nvarchar(255) NULL, + [HIST_REQUIRED] nvarchar(1) NULL, + [DESCRIPTION] nvarchar(max) NULL + ) +GO + +CREATE TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] ( + [ACCESS_REQUEST_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ARQSTT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ARQSTT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ARQSTT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ARQSTT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ARQSTT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ARQSTT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ARQSTT_PK] PRIMARY KEY CLUSTERED([ACCESS_REQUEST_STATUS_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_REGION] ( + [REGION_CODE] smallint NOT NULL, + [REGION_NAME] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [REGION_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [REGION_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [REGION_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [REGION_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [REGION_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [REGION_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [REGION_PK] PRIMARY KEY CLUSTERED([REGION_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_ROLE] ( + [ROLE_ID] bigint NOT NULL CONSTRAINT [ROLE_ROLE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ROLE_ID_SEQ]), + [ROLE_UID] uniqueidentifier NOT NULL, + [KEYCLOAK_GROUP_ID] uniqueidentifier NULL, + [NAME] nvarchar(100) NOT NULL, + [DESCRIPTION] nvarchar(500) NULL, + [IS_PUBLIC] bit NOT NULL CONSTRAINT [ROLE_IS_PUBLIC_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_DISABLED] bit NOT NULL CONSTRAINT [ROLE_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [SORT_ORDER] int NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ROLE_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ROLE_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ROLE_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ROLE_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ROLE_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ROLE_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ROLE_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ROLE_PK] PRIMARY KEY CLUSTERED([ROLE_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PERSON] ( + [PERSON_ID] bigint NOT NULL CONSTRAINT [PERSON_PERSON_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PERSON_ID_SEQ]), + [SURNAME] nvarchar(50) NOT NULL, + [FIRST_NAME] nvarchar(50) NOT NULL, + [MIDDLE_NAMES] nvarchar(200) NULL, + [NAME_SUFFIX] nvarchar(50) NULL, + [PREFERRED_NAME] nvarchar(200) NULL, + [BIRTH_DATE] date NULL, + [COMMENT] nvarchar(2000) NULL, + [ADDRESS_COMMENT] nvarchar(2000) NULL, + [USE_ORGANIZATION_ADDRESS] bit NULL CONSTRAINT [PERSON_USE_ORGANIZATION_ADDRESS_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_DISABLED] bit NOT NULL CONSTRAINT [PERSON_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PERSON_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERSON_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERSON_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERSON_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PERSON_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERSON_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PERSON_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PERSON_PK] PRIMARY KEY CLUSTERED([PERSON_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_USER] ( + [USER_ID] bigint NOT NULL CONSTRAINT [USER_USER_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_USER_ID_SEQ]), + [PERSON_ID] bigint NOT NULL, + [BUSINESS_IDENTIFIER_VALUE] nvarchar(30) NOT NULL, + [GUID_IDENTIFIER_VALUE] uniqueidentifier NULL, + [POSITION] nvarchar(100) NULL, + [NOTE] nvarchar(1000) NULL, + [LAST_LOGIN] datetime NULL, + [APPROVED_BY_ID] nvarchar(30) NULL, + [ISSUE_DATE] datetime NOT NULL, + [EXPIRY_DATE] datetime NULL, + [IS_DISABLED] bit NULL CONSTRAINT [USER_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [USER_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USER_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USER_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USER_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [USER_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USER_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [USER_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [USER_PK] PRIMARY KEY CLUSTERED([USER_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Accepted identifier of a user (e.g. IDIR)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'BUSINESS_IDENTIFIER_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Unique GUID associated with the user.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'GUID_IDENTIFIER_VALUE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Role/position assigned to the user.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'POSITION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes associated with this user.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'NOTE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Last date/time the user was logged into PIMS.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'LAST_LOGIN' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Identifier of the person that approved the creation of this PIMS user.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'APPROVED_BY_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date/time that this user was identified as a PIMS user,' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'ISSUE_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Expiry date/time of this user account.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'EXPIRY_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if this user account is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Information associated with an identified PIMS system user.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER' +GO + +CREATE TABLE [dbo].[PIMS_ACCESS_REQUEST] ( + [ACCESS_REQUEST_ID] bigint NOT NULL CONSTRAINT [ACRQST_ACCESS_REQUEST_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACCESS_REQUEST_ID_SEQ]), + [USER_ID] bigint NOT NULL, + [ROLE_ID] bigint NULL, + [ACCESS_REQUEST_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [REGION_CODE] smallint NOT NULL CONSTRAINT [ACRQST_REGION_CODE_DEF] DEFAULT ((4)), + [NOTE] nvarchar(max) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACRQST_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACRQST_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACRQST_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACRQST_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACRQST_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACRQST_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACRQST_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACRQST_PK] PRIMARY KEY CLUSTERED([ACCESS_REQUEST_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Note associated with this access request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACCESS_REQUEST', + @level2type = N'Column', @level2name = N'NOTE' +GO + +CREATE TABLE [dbo].[PIMS_ACCESS_REQUEST_HIST] ( + [_ACCESS_REQUEST_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACCESS_REQUEST_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACCESS_REQUEST_ID] bigint NOT NULL, + [USER_ID] bigint NOT NULL, + [ROLE_ID] bigint NULL, + [ACCESS_REQUEST_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [REGION_CODE] smallint NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACRQST_H_PK] PRIMARY KEY CLUSTERED([_ACCESS_REQUEST_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_DISTRICT] ( + [DISTRICT_CODE] smallint NOT NULL, + [REGION_CODE] smallint NOT NULL, + [DISTRICT_NAME] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [DSTRCT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [DSTRCT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DSTRCT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DSTRCT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DSTRCT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DSTRCT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [DSTRCT_PK] PRIMARY KEY CLUSTERED([DISTRICT_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] ( + [ORG_IDENTIFIER_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ORGIDT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ORGIDT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORGIDT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ORGIDT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORGIDT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ORGIDT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ORGIDT_PK] PRIMARY KEY CLUSTERED([ORG_IDENTIFIER_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_ORGANIZATION_TYPE] ( + [ORGANIZATION_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ORGTYP_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ORGTYP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORGTYP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ORGTYP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORGTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ORGTYP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ORGTYP_PK] PRIMARY KEY CLUSTERED([ORGANIZATION_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_ORGANIZATION] ( + [ORGANIZATION_ID] bigint NOT NULL CONSTRAINT [ORG_ORGANIZATION_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ORGANIZATION_ID_SEQ]), + [PRNT_ORGANIZATION_ID] bigint NULL, + [REGION_CODE] smallint NULL, + [DISTRICT_CODE] smallint NULL, + [ORGANIZATION_TYPE_CODE] nvarchar(20) NULL, + [ORG_IDENTIFIER_TYPE_CODE] nvarchar(20) NULL, + [ORGANIZATION_IDENTIFIER] nvarchar(100) NULL, + [ORGANIZATION_NAME] nvarchar(200) NOT NULL, + [ORGANIZATION_ALIAS] nvarchar(200) NULL, + [INCORPORATION_NUMBER] nvarchar(50) NULL, + [WEBSITE] nvarchar(200) NULL, + [COMMENT] nvarchar(2000) NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ORG_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ORG_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORG_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORG_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORG_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ORG_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORG_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ORG_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ORG_PK] PRIMARY KEY CLUSTERED([ORGANIZATION_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Incorporation number of the orgnization' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ORGANIZATION', + @level2type = N'Column', @level2name = N'INCORPORATION_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Information related to an organization identified in the PSP system.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ORGANIZATION' +GO + +CREATE TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] ( + [ACCESS_REQUEST_ORGANIZATION_ID] bigint NOT NULL CONSTRAINT [ACRQOR_ACCESS_REQUEST_ORGANIZATION_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACCESS_REQUEST_ORGANIZATION_ID_SEQ]), + [ORGANIZATION_ID] bigint NULL, + [ACCESS_REQUEST_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [ACRQOR_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACRQOR_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACRQOR_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACRQOR_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACRQOR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACRQOR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACRQOR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACRQOR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACRQOR_PK] PRIMARY KEY CLUSTERED([ACCESS_REQUEST_ORGANIZATION_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION_HIST] ( + [_ACCESS_REQUEST_ORGANIZATION_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACCESS_REQUEST_ORGANIZATION_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACCESS_REQUEST_ORGANIZATION_ID] bigint NOT NULL, + [ORGANIZATION_ID] bigint NULL, + [ACCESS_REQUEST_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACRQOR_H_PK] PRIMARY KEY CLUSTERED([_ACCESS_REQUEST_ORGANIZATION_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] ( + [ACQ_PHYS_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACQPFS_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQPFS_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPFS_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPFS_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPFS_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPFS_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQPFS_PK] PRIMARY KEY CLUSTERED([ACQ_PHYS_FILE_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion physical file status type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'ACQ_PHYS_FILE_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion physical file status type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion physical file status type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] ( + [ACQUISITION_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACQFST_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQFST_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQFST_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQFST_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQFST_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQFST_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQFST_PK] PRIMARY KEY CLUSTERED([ACQUISITION_FILE_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion file status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'ACQUISITION_FILE_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion file status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion file status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] ( + [ACQUISITION_FUNDING_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACQFTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQFTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQFTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQFTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQFTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQFTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQFTY_PK] PRIMARY KEY CLUSTERED([ACQUISITION_FUNDING_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion funding type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE', + @level2type = N'Column', @level2name = N'ACQUISITION_FUNDING_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion funding type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion funding type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FUNDING_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_TYPE] ( + [ACQUISITION_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACQTYP_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQTYP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQTYP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQTYP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQTYP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQTYP_PK] PRIMARY KEY CLUSTERED([ACQUISITION_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE', + @level2type = N'Column', @level2name = N'ACQUISITION_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE] ( + [ACQUISITION_FILE_ID] bigint NOT NULL CONSTRAINT [ACQNFL_ACQUISITION_FILE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_FILE_ID_SEQ]), + [ACQUISITION_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [ACQUISITION_TYPE_CODE] nvarchar(20) NOT NULL, + [ACQUISITION_FUNDING_TYPE_CODE] nvarchar(20) NULL, + [ACQ_PHYS_FILE_STATUS_TYPE_CODE] nvarchar(20) NULL, + [MINISTRY_PROJECT_NUMBER] nvarchar(20) NULL, + [MINISTRY_PROJECT_NAME] nvarchar(100) NULL, + [CPS_PRODUCT_CODE] nvarchar(12) NULL, + [FILE_NAME] nvarchar(500) NOT NULL, + [FILE_NUMBER] nvarchar(18) NULL, + [REGION_CODE] smallint NOT NULL CONSTRAINT [ACQNFL_REGION_CODE_DEF] DEFAULT ((-1)), + [FUNDING_OTHER] nvarchar(200) NULL, + [ASSIGNED_DATE] datetime NULL CONSTRAINT [ACQNFL_ASSIGNED_DATE_DEF] DEFAULT (getutcdate()), + [DELIVERY_DATE] datetime NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQNFL_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQNFL_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQNFL_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQNFL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQNFL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQNFL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQNFL_PK] PRIMARY KEY CLUSTERED([ACQUISITION_FILE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Ministry project number.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'MINISTRY_PROJECT_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Ministry project name.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'MINISTRY_PROJECT_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'CPS product code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'CPS_PRODUCT_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Descriptive name given to the acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'FILE_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'File number assigned to the acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'FILE_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Region responsible for oversight of the acquisition.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'REGION_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of other funding type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'FUNDING_OTHER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date of file assignment.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'ASSIGNED_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date of file delivery.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'DELIVERY_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Entity containing information regarding an acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE' +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] ( + [ACTIVITY_TEMPLATE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ACTTTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACTTTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACTTTY_PK] PRIMARY KEY CLUSTERED([ACTIVITY_TEMPLATE_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the activity type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE', + @level2type = N'Column', @level2name = N'ACTIVITY_TEMPLATE_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the activity type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the activity type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] ( + [ACTIVITY_TEMPLATE_ID] bigint NOT NULL CONSTRAINT [ACTTMP_ACTIVITY_TEMPLATE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_TEMPLATE_ID_SEQ]), + [ACTIVITY_TEMPLATE_TYPE_CODE] nvarchar(20) NULL, + [ACTIVITY_TEMPLATE_JSON] nvarchar(max) NOT NULL CONSTRAINT [ACTTMP_ACTIVITY_TEMPLATE_JSON_DEF] DEFAULT (''), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACTTMP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTMP_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTMP_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTMP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTTMP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTTMP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACTTMP_PK] PRIMARY KEY CLUSTERED([ACTIVITY_TEMPLATE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'JSON structure desribing how to construct the activity UI.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_TEMPLATE', + @level2type = N'Column', @level2name = N'ACTIVITY_TEMPLATE_JSON' +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] ( + [ACTIVITY_INSTANCE_ID] bigint NOT NULL CONSTRAINT [ACTINS_ACTIVITY_INSTANCE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_INSTANCE_ID_SEQ]), + [ACTIVITY_TEMPLATE_ID] bigint NULL, + [ACTIVITY_DATA_JSON] nvarchar(max) NOT NULL CONSTRAINT [ACTINS_ACTIVITY_DATA_JSON_DEF] DEFAULT (''), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACTINS_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTINS_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTINS_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTINS_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTINS_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTINS_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTINS_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTINS_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTINS_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTINS_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTINS_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACTINS_PK] PRIMARY KEY CLUSTERED([ACTIVITY_INSTANCE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'JSON structure containing data specific to an activity instance.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_INSTANCE', + @level2type = N'Column', @level2name = N'ACTIVITY_DATA_JSON' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Table to contain all applicable activity instances for the PIMS PSP system.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_INSTANCE' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] ( + [ACQUISITION_ACTIVITY_INSTANCE_ID] bigint NOT NULL CONSTRAINT [ACQAIN_ACQUISITION_ACTIVITY_INSTANCE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ]), + [ACQUISITION_FILE_ID] bigint NOT NULL, + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [ACQAIN_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQAIN_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQAIN_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQAIN_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQAIN_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQAIN_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQAIN_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQAIN_PK] PRIMARY KEY CLUSTERED([ACQUISITION_ACTIVITY_INSTANCE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the relationship is active.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_ACTIVITY_INSTANCE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST] ( + [_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACQUISITION_ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [ACQUISITION_FILE_ID] bigint NOT NULL, + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACQAIN_H_PK] PRIMARY KEY CLUSTERED([_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE_HIST] ( + [_ACQUISITION_FILE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_FILE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACQUISITION_FILE_ID] bigint NOT NULL, + [ACQUISITION_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [ACQUISITION_TYPE_CODE] nvarchar(20) NOT NULL, + [ACQUISITION_FUNDING_TYPE_CODE] nvarchar(20) NULL, + [ACQ_PHYS_FILE_STATUS_TYPE_CODE] nvarchar(20) NULL, + [MINISTRY_PROJECT_NUMBER] nvarchar(20) NULL, + [MINISTRY_PROJECT_NAME] nvarchar(100) NULL, + [CPS_PRODUCT_CODE] nvarchar(12) NULL, + [FILE_NAME] nvarchar(500) NOT NULL, + [FILE_NUMBER] nvarchar(18) NULL, + [REGION_CODE] smallint NOT NULL, + [FUNDING_OTHER] nvarchar(200) NULL, + [ASSIGNED_DATE] datetime NULL, + [DELIVERY_DATE] datetime NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACQNFL_H_PK] PRIMARY KEY CLUSTERED([_ACQUISITION_FILE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] ( + [ACQ_FL_PERSON_PROFILE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [AQFPPT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [AQFPPT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [AQFPPT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [AQFPPT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [AQFPPT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [AQFPPT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [AQFPPT_PK] PRIMARY KEY CLUSTERED([ACQ_FL_PERSON_PROFILE_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the acquistion file staff profile (role).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', + @level2type = N'Column', @level2name = N'ACQ_FL_PERSON_PROFILE_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the acquistion file staff profile (role).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the acquistion file staff profile (role).' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] ( + [ACQUISITION_FILE_PERSON_ID] bigint NOT NULL CONSTRAINT [ACQPER_ACQUISITION_FILE_PERSON_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_FILE_PERSON_ID_SEQ]), + [ACQUISITION_FILE_ID] bigint NOT NULL, + [PERSON_ID] bigint NOT NULL, + [ACQ_FL_PERSON_PROFILE_TYPE_CODE] nvarchar(20) NULL, + [IS_DISABLED] bit NULL CONSTRAINT [ACQPER_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQPER_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPER_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPER_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPER_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQPER_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQPER_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQPER_PK] PRIMARY KEY CLUSTERED([ACQUISITION_FILE_PERSON_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the relationship is active.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_PERSON', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Table to associate an acquisition file to a person.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_FILE_PERSON' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON_HIST] ( + [_ACQUISITION_FILE_PERSON_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACQUISITION_FILE_PERSON_ID] bigint NOT NULL, + [ACQUISITION_FILE_ID] bigint NOT NULL, + [PERSON_ID] bigint NOT NULL, + [ACQ_FL_PERSON_PROFILE_TYPE_CODE] nvarchar(20) NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACQPER_H_PK] PRIMARY KEY CLUSTERED([_ACQUISITION_FILE_PERSON_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_OWNER] ( + [ACQUISITION_OWNER_ID] bigint NOT NULL CONSTRAINT [ACQOWN_ACQUISITION_OWNER_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_OWNER_ID_SEQ]), + [ACQUISITION_FILE_ID] bigint NULL, + [OWNER_NAME] nvarchar(300) NOT NULL CONSTRAINT [ACQOWN_OWNER_NAME_DEF] DEFAULT (''), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACQOWN_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQOWN_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQOWN_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQOWN_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACQOWN_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACQOWN_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACQOWN_PK] PRIMARY KEY CLUSTERED([ACQUISITION_OWNER_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Name of the owner.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_OWNER', + @level2type = N'Column', @level2name = N'OWNER_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Entity containing information regarding an acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACQUISITION_OWNER' +GO + +CREATE TABLE [dbo].[PIMS_ACQUISITION_OWNER_HIST] ( + [_ACQUISITION_OWNER_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACQUISITION_OWNER_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACQUISITION_OWNER_ID] bigint NOT NULL, + [ACQUISITION_FILE_ID] bigint NULL, + [OWNER_NAME] nvarchar(300) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACQOWN_H_PK] PRIMARY KEY CLUSTERED([_ACQUISITION_OWNER_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] ( + [DOCUMENT_STATUS_TYPE_CODE] nvarchar(20) NOT NULL CONSTRAINT [DOCSTY_DOCUMENT_STATUS_TYPE_CODE_DEF] DEFAULT ('NEXT VALUE FOR [PIMS_DOCUMENT_ID_SEQ]'), + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [DOCSTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [DOCSTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCSTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCSTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCSTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCSTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [DOCSTY_PK] PRIMARY KEY CLUSTERED([DOCUMENT_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value of the document status type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DOCUMENT_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Descriptive translation of the document status type code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is still in use.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Determines the default display order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Table describing the available document types.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_DOCUMENT_TYP] ( + [DOCUMENT_TYPE_ID] bigint NOT NULL CONSTRAINT [DOCTYP_DOCUMENT_TYPE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_DOCUMENT_TYPE_ID_SEQ]), + [MAYAN_ID] bigint NOT NULL CONSTRAINT [DOCTYP_MAYAN_ID_DEF] DEFAULT ((-1)), + [DOCUMENT_TYPE] nvarchar(200) NOT NULL CONSTRAINT [DOCTYP_DOCUMENT_TYPE_DEF] DEFAULT (''), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [DOCTYP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCTYP_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCTYP_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [DOCTYP_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCTYP_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCTYP_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [DOCTYP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCTYP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCTYP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCTYP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [DOCTYP_PK] PRIMARY KEY CLUSTERED([DOCUMENT_TYPE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Mayan-generated document type number used for retrieval from Mayan EDMS.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT_TYP', + @level2type = N'Column', @level2name = N'MAYAN_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the available document types.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT_TYP', + @level2type = N'Column', @level2name = N'DOCUMENT_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Table describing the available document types.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT_TYP' +GO + +CREATE TABLE [dbo].[PIMS_DOCUMENT] ( + [DOCUMENT_ID] bigint NOT NULL CONSTRAINT [DOCMNT_DOCUMENT_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_DOCUMENT_ID_SEQ]), + [DOCUMENT_TYPE_ID] bigint NOT NULL, + [DOCUMENT_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [FILE_NAME] nvarchar(500) NOT NULL CONSTRAINT [DOCMNT_FILE_NAME_DEF] DEFAULT (''), + [MAYAN_ID] bigint NOT NULL CONSTRAINT [DOCMNT_MAYAN_ID_DEF] DEFAULT ((-1)), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [DOCMNT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCMNT_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCMNT_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [DOCMNT_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCMNT_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCMNT_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [DOCMNT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCMNT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCMNT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [DOCMNT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [DOCMNT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [DOCMNT_PK] PRIMARY KEY CLUSTERED([DOCUMENT_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Name of the file stored on Mayan EDMS.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT', + @level2type = N'Column', @level2name = N'FILE_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Mayan-generated document number used for retrieval from Mayan EDMS.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT', + @level2type = N'Column', @level2name = N'MAYAN_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Table describing the available document types.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DOCUMENT' +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] ( + [ACTIVITY_INSTANCE_DOCUMENT_ID] bigint NOT NULL CONSTRAINT [ACTDOC_ACTIVITY_INSTANCE_DOCUMENT_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_INSTANCE_DOCUMENT_ID_SEQ]), + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [DOCUMENT_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [ACTDOC_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACTDOC_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTDOC_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTDOC_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTDOC_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTDOC_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTDOC_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTDOC_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTDOC_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTDOC_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTDOC_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTDOC_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACTDOC_PK] PRIMARY KEY CLUSTERED([ACTIVITY_INSTANCE_DOCUMENT_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the relationship has been disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_INSTANCE_DOCUMENT', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Relates a document object to an activity instance.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_INSTANCE_DOCUMENT' +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST] ( + [_ACTIVITY_INSTANCE_DOCUMENT_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_INSTANCE_DOCUMENT_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACTIVITY_INSTANCE_DOCUMENT_ID] bigint NOT NULL, + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [DOCUMENT_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACTDOC_H_PK] PRIMARY KEY CLUSTERED([_ACTIVITY_INSTANCE_DOCUMENT_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] ( + [_ACTIVITY_INSTANCE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_INSTANCE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [ACTIVITY_TEMPLATE_ID] bigint NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACTINS_H_PK] PRIMARY KEY CLUSTERED([_ACTIVITY_INSTANCE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_NOTE] ( + [NOTE_ID] bigint NOT NULL CONSTRAINT [NOTE_NOTE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_NOTE_ID_SEQ]), + [NOTE_TXT] nvarchar(4000) NOT NULL CONSTRAINT [NOTE_NOTE_TXT_DEF] DEFAULT (''), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [NOTE_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [NOTE_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [NOTE_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [NOTE_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [NOTE_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [NOTE_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [NOTE_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [NOTE_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [NOTE_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [NOTE_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [NOTE_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [NOTE_PK] PRIMARY KEY CLUSTERED([NOTE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Contents of the note.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_NOTE', + @level2type = N'Column', @level2name = N'NOTE_TXT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Table to contain all applicable notes for the PIMS PSP system.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_NOTE' +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] ( + [PIMS_ACTIVITY_INSTANCE_NOTE_ID] bigint NOT NULL CONSTRAINT [ACTINN_PIMS_ACTIVITY_INSTANCE_NOTE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_INSTANCE_NOTE_ID_SEQ]), + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [NOTE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [ACTINN_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ACTINN_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTINN_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTINN_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTINN_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTINN_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTINN_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [ACTINN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTINN_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTINN_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ACTINN_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ACTINN_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ACTINN_PK] PRIMARY KEY CLUSTERED([PIMS_ACTIVITY_INSTANCE_NOTE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the relationship has been disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_INSTANCE_NOTE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Relates a note object to an activity instance.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ACTIVITY_INSTANCE_NOTE' +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_HIST] ( + [_ACTIVITY_INSTANCE_NOTE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_INSTANCE_NOTE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PIMS_ACTIVITY_INSTANCE_NOTE_ID] bigint NOT NULL, + [ACTIVITY_INSTANCE_ID] bigint NOT NULL, + [NOTE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACTINN_H_PK] PRIMARY KEY CLUSTERED([_ACTIVITY_INSTANCE_NOTE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_HIST] ( + [_ACTIVITY_TEMPLATE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ACTIVITY_TEMPLATE_ID] bigint NOT NULL, + [ACTIVITY_TEMPLATE_TYPE_CODE] nvarchar(20) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ACTTMP_H_PK] PRIMARY KEY CLUSTERED([_ACTIVITY_TEMPLATE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_COUNTRY] ( + [COUNTRY_ID] smallint NOT NULL, + [COUNTRY_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [CNTRY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CNTRY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [CNTRY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CNTRY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [CNTRY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [CNTRY_PK] PRIMARY KEY CLUSTERED([COUNTRY_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROVINCE_STATE] ( + [PROVINCE_STATE_ID] smallint NOT NULL, + [COUNTRY_ID] smallint NOT NULL, + [PROVINCE_STATE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PROVNC_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PROVNC_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PROVNC_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PROVNC_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PROVNC_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PROVNC_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PROVNC_PK] PRIMARY KEY CLUSTERED([PROVINCE_STATE_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ADDRESS] ( + [ADDRESS_ID] bigint NOT NULL CONSTRAINT [ADDRSS_ADDRESS_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ADDRESS_ID_SEQ]), + [REGION_CODE] smallint NULL, + [DISTRICT_CODE] smallint NULL, + [PROVINCE_STATE_ID] smallint NOT NULL, + [COUNTRY_ID] smallint NULL, + [STREET_ADDRESS_1] nvarchar(200) NULL, + [STREET_ADDRESS_2] nvarchar(200) NULL, + [STREET_ADDRESS_3] nvarchar(200) NULL, + [MUNICIPALITY_NAME] nvarchar(200) NULL, + [POSTAL_CODE] nvarchar(20) NULL, + [OTHER_COUNTRY] nvarchar(200) NULL, + [LATITUDE] numeric(8,6) NULL, + [LONGITUDE] numeric(9,6) NULL, + [COMMENT] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ADDRSS_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ADDRSS_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ADDRSS_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ADDRSS_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ADDRSS_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ADDRSS_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ADDRSS_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ADDRSS_PK] PRIMARY KEY CLUSTERED([ADDRESS_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Other country not listed in drop-down list' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ADDRESS', + @level2type = N'Column', @level2name = N'OTHER_COUNTRY' +GO + +CREATE TABLE [dbo].[PIMS_ADDRESS_HIST] ( + [_ADDRESS_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ADDRESS_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ADDRESS_ID] bigint NOT NULL, + [REGION_CODE] smallint NULL, + [DISTRICT_CODE] smallint NULL, + [PROVINCE_STATE_ID] smallint NOT NULL, + [COUNTRY_ID] smallint NULL, + [STREET_ADDRESS_1] nvarchar(200) NULL, + [STREET_ADDRESS_2] nvarchar(200) NULL, + [STREET_ADDRESS_3] nvarchar(200) NULL, + [MUNICIPALITY_NAME] nvarchar(200) NULL, + [POSTAL_CODE] nvarchar(20) NULL, + [OTHER_COUNTRY] nvarchar(200) NULL, + [LATITUDE] numeric(18,0) NULL, + [LONGITUDE] numeric(18,0) NULL, + [COMMENT] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ADDRSS_H_PK] PRIMARY KEY CLUSTERED([_ADDRESS_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] ( + [ADDRESS_USAGE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ADUSGT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ADUSGT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ADUSGT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ADUSGT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ADUSGT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ADUSGT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ADUSGT_PK] PRIMARY KEY CLUSTERED([ADDRESS_USAGE_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_AREA_UNIT_TYPE] ( + [AREA_UNIT_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ARUNIT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ARUNIT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ARUNIT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ARUNIT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ARUNIT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ARUNIT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ARUNIT_PK] PRIMARY KEY CLUSTERED([AREA_UNIT_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The area unit used for measuring Properties. The units must be in metric: square metres or hectares.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_AREA_UNIT_TYPE', + @level2type = N'Column', @level2name = N'AREA_UNIT_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Translation of the code value into a description that can be displayed to the user.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_AREA_UNIT_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is still active or is now disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_AREA_UNIT_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Order in which to display the code values, if required.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_AREA_UNIT_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The area unit used for measuring Properties. The units must be in metric: square metres or hectares.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_AREA_UNIT_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_CLAIM] ( + [CLAIM_ID] bigint NOT NULL CONSTRAINT [CLMTYP_CLAIM_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_CLAIM_ID_SEQ]), + [CLAIM_UID] uniqueidentifier NOT NULL, + [KEYCLOAK_ROLE_ID] uniqueidentifier NULL, + [NAME] nvarchar(100) NOT NULL, + [DESCRIPTION] nvarchar(500) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [CLMTYP_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [CLMTYP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CLMTYP_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CLMTYP_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CLMTYP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [CLMTYP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CLMTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [CLMTYP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [CLMTYP_PK] PRIMARY KEY CLUSTERED([CLAIM_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_CLAIM_HIST] ( + [_CLAIM_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_CLAIM_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [CLAIM_ID] bigint NOT NULL, + [CLAIM_UID] uniqueidentifier NOT NULL, + [KEYCLOAK_ROLE_ID] uniqueidentifier NULL, + [NAME] nvarchar(100) NOT NULL, + [DESCRIPTION] nvarchar(500) NOT NULL, + [IS_DISABLED] bit NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_CLMTYP_H_PK] PRIMARY KEY CLUSTERED([_CLAIM_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] ( + [CONTACT_METHOD_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [CNTMTT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [CNTMTT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CNTMTT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [CNTMTT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CNTMTT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [CNTMTT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [CNTMTT_PK] PRIMARY KEY CLUSTERED([CONTACT_METHOD_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_CONTACT_METHOD] ( + [CONTACT_METHOD_ID] bigint NOT NULL CONSTRAINT [CNTMTH_CONTACT_METHOD_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_CONTACT_METHOD_ID_SEQ]), + [CONTACT_METHOD_TYPE_CODE] nvarchar(20) NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [CONTACT_METHOD_VALUE] nvarchar(200) NOT NULL, + [IS_PREFERRED_METHOD] bit NULL CONSTRAINT [CNTMTH_IS_PREFERRED_METHOD_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [CNTMTH_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CNTMTH_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CNTMTH_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CNTMTH_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [CNTMTH_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [CNTMTH_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [CNTMTH_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [CNTMTH_PK] PRIMARY KEY CLUSTERED([CONTACT_METHOD_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_CONTACT_METHOD_HIST] ( + [_CONTACT_METHOD_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_CONTACT_METHOD_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [CONTACT_METHOD_ID] bigint NOT NULL, + [CONTACT_METHOD_TYPE_CODE] nvarchar(20) NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [CONTACT_METHOD_VALUE] nvarchar(200) NOT NULL, + [IS_PREFERRED_METHOD] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_CNTMTH_H_PK] PRIMARY KEY CLUSTERED([_CONTACT_METHOD_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] ( + [DATA_SOURCE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PIDSRT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PIDSRT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PIDSRT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PIDSRT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PIDSRT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PIDSRT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PIDSRT_PK] PRIMARY KEY CLUSTERED([DATA_SOURCE_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code val;ue of the source system of the data (PAIMS, LIS, etc.)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DATA_SOURCE_TYPE', + @level2type = N'Column', @level2name = N'DATA_SOURCE_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the source system of the data (PAIMS, LIS, etc.)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DATA_SOURCE_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is still in use' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DATA_SOURCE_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Defines the default display order of the descriptions' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DATA_SOURCE_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the source system of the data (PAIMS, LIS, etc.)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_DATA_SOURCE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_DOCUMENT_HIST] ( + [_DOCUMENT_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_DOCUMENT_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [DOCUMENT_ID] bigint NOT NULL, + [DOCUMENT_TYPE_ID] bigint NOT NULL, + [DOCUMENT_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [FILE_NAME] nvarchar(500) NOT NULL, + [MAYAN_ID] bigint NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_DOCMNT_H_PK] PRIMARY KEY CLUSTERED([_DOCUMENT_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_DOCUMENT_TYP_HIST] ( + [_DOCUMENT_TYP_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_DOCUMENT_TYP_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [DOCUMENT_TYPE_ID] bigint NOT NULL, + [MAYAN_ID] bigint NOT NULL, + [DOCUMENT_TYPE] nvarchar(200) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_DOCTYP_H_PK] PRIMARY KEY CLUSTERED([_DOCUMENT_TYP_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_INSURANCE_TYPE] ( + [INSURANCE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [INSPYT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [INSPYT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [INSPYT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [INSPYT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [INSPYT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [INSPYT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [INSPYT_PK] PRIMARY KEY CLUSTERED([INSURANCE_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] ( + [LEASE_CATEGORY_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LSCATT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSCATT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSCATT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSCATT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSCATT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSCATT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSCATT_PK] PRIMARY KEY CLUSTERED([LEASE_CATEGORY_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] ( + [LEASE_INITIATOR_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LINITT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LINITT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LINITT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LINITT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LINITT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LINITT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LINITT_PK] PRIMARY KEY CLUSTERED([LEASE_INITIATOR_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value of the initiator of the lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_INITIATOR_TYPE', + @level2type = N'Column', @level2name = N'LEASE_INITIATOR_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the initiator of the lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_INITIATOR_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the initiator of the lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_INITIATOR_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] ( + [LEASE_LICENSE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LELIST_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LELIST_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LELIST_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LELIST_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LELIST_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LELIST_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LELIST_PK] PRIMARY KEY CLUSTERED([LEASE_LICENSE_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] ( + [LEASE_PAY_RVBL_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LSPRTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSPRTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPRTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPRTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPRTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPRTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSPRTY_PK] PRIMARY KEY CLUSTERED([LEASE_PAY_RVBL_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] ( + [LEASE_PROGRAM_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LSPRGT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSPRGT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPRGT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPRGT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPRGT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPRGT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSPRGT_PK] PRIMARY KEY CLUSTERED([LEASE_PROGRAM_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the program type associated with a lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PROGRAM_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] ( + [LEASE_PURPOSE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LPRPTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LPRPTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LPRPTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LPRPTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LPRPTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LPRPTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LPRPTY_PK] PRIMARY KEY CLUSTERED([LEASE_PURPOSE_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the purpose type associated with a lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PURPOSE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] ( + [LEASE_RESPONSIBILITY_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LRESPT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LRESPT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LRESPT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LRESPT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LRESPT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LRESPT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LRESPT_PK] PRIMARY KEY CLUSTERED([LEASE_RESPONSIBILITY_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value of the organization responsible for this lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_RESPONSIBILITY_TYPE', + @level2type = N'Column', @level2name = N'LEASE_RESPONSIBILITY_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the organization responsible for this lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_RESPONSIBILITY_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes which organization is responsible for this lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_RESPONSIBILITY_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] ( + [LEASE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LSSTYP_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSSTYP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSSTYP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSSTYP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSSTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSSTYP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSSTYP_PK] PRIMARY KEY CLUSTERED([LEASE_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value of the status of the lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'LEASE_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the status of the lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the status of the lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE] ( + [LEASE_ID] bigint NOT NULL CONSTRAINT [LEASE_LEASE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_LEASE_ID_SEQ]), + [LEASE_PAY_RVBL_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_LICENSE_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_CATEGORY_TYPE_CODE] nvarchar(20) NULL, + [LEASE_PURPOSE_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_PROGRAM_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_INITIATOR_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_RESPONSIBILITY_TYPE_CODE] nvarchar(20) NULL, + [LEASE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [REGION_CODE] smallint NULL, + [L_FILE_NO] nvarchar(50) NULL, + [TFA_FILE_NO] int NULL, + [PS_FILE_NO] nvarchar(50) NULL, + [LEASE_DESCRIPTION] nvarchar(max) NULL, + [LEASE_CATEGORY_OTHER_DESC] nvarchar(200) NULL, + [LEASE_PURPOSE_OTHER_DESC] nvarchar(200) NULL, + [LEASE_NOTES] nvarchar(max) NULL, + [MOTI_CONTACT] nvarchar(200) NULL, + [DOCUMENTATION_REFERENCE] nvarchar(500) NULL, + [RETURN_NOTES] nvarchar(max) NULL, + [OTHER_LEASE_PROGRAM_TYPE] nvarchar(200) NULL, + [OTHER_LEASE_LICENSE_TYPE] nvarchar(200) NULL, + [OTHER_LEASE_PURPOSE_TYPE] nvarchar(200) NULL, + [ORIG_START_DATE] datetime NOT NULL, + [ORIG_EXPIRY_DATE] datetime NULL, + [LEASE_AMOUNT] money NULL, + [RESPONSIBILITY_EFFECTIVE_DATE] datetime NULL, + [INSPECTION_DATE] datetime NULL, + [INSPECTION_NOTES] nvarchar(max) NULL, + [IS_SUBJECT_TO_RTA] bit NULL CONSTRAINT [LEASE_IS_SUBJECT_TO_RTA_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_COMM_BLDG] bit NULL CONSTRAINT [LEASE_IS_COMM_BLDG_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_OTHER_IMPROVEMENT] bit NULL CONSTRAINT [LEASE_IS_OTHER_IMPROVEMENT_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_EXPIRED] bit NOT NULL CONSTRAINT [LEASE_EXPIRED_DEF] DEFAULT (CONVERT([bit],(0))), + [HAS_PHYSICAL_FILE] bit NULL, + [HAS_DIGITAL_FILE] bit NULL, + [HAS_PHYSICIAL_LICENSE] bit NULL, + [HAS_DIGITAL_LICENSE] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LEASE_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LEASE_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LEASE_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [LEASE_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LEASE_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LEASE_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [LEASE_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LEASE_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LEASE_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LEASE_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LEASE_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LEASE_PK] PRIMARY KEY CLUSTERED([LEASE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'MoTI region associated with the lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'REGION_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Generated identifying lease/licence number' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'L_FILE_NO' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Sourced from t_fileMain.TFA_File_Number' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'TFA_FILE_NO' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Sourced from t_fileSubOverrideData.PSFile_No' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'PS_FILE_NO' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Manually etered lease description, not the legal description' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'LEASE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'User-specified lease category description not included in standard set of lease purposes' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'LEASE_CATEGORY_OTHER_DESC' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'User-specified lease purpose description not included in standard set of lease purposes' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'LEASE_PURPOSE_OTHER_DESC' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes accompanying lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'LEASE_NOTES' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Contact of the MoTI person associated with the lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'MOTI_CONTACT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Location of documents pertianing to the lease/license' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'DOCUMENTATION_REFERENCE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes accompanying lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'RETURN_NOTES' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of a non-standard lease program type' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'OTHER_LEASE_PROGRAM_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of a non-standard lease/license type' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'OTHER_LEASE_LICENSE_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of a non-standard lease purpose type' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'OTHER_LEASE_PURPOSE_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Original start date of the lease/license' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'ORIG_START_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Original expiry date of the lease/license' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'ORIG_EXPIRY_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Lease/licence amount' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'LEASE_AMOUNT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date current responsibility came into effect for this lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'RESPONSIBILITY_EFFECTIVE_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Inspection date' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'INSPECTION_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes accompanying inspection' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'INSPECTION_NOTES' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is subject the Residential Tenancy Act' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'IS_SUBJECT_TO_RTA' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is a commercial building' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'IS_COMM_BLDG' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is improvement of another description' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'IS_OTHER_IMPROVEMENT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Incidcator that lease/license has expired' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'IS_EXPIRED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicator that phyical file exists' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'HAS_PHYSICAL_FILE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicator that digital file exists' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'HAS_DIGITAL_FILE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicator that physical license exists' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'HAS_PHYSICIAL_LICENSE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicator that digital license exists' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE', + @level2type = N'Column', @level2name = N'HAS_DIGITAL_LICENSE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Details of a lease that is inventoried in PIMS system.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE' +GO + +CREATE TABLE [dbo].[PIMS_INSURANCE] ( + [INSURANCE_ID] bigint NOT NULL CONSTRAINT [INSRNC_INSURANCE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_INSURANCE_ID_SEQ]), + [LEASE_ID] bigint NOT NULL, + [INSURANCE_TYPE_CODE] nvarchar(20) NOT NULL, + [OTHER_INSURANCE_TYPE] nvarchar(200) NULL, + [COVERAGE_DESCRIPTION] nvarchar(2000) NULL, + [COVERAGE_LIMIT] money NULL CONSTRAINT [INSRNC_COVERAGE_LIMIT_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_INSURANCE_IN_PLACE] bit NULL CONSTRAINT [INSRNC_IS_INSURANCE_IN_PLACE_DEF] DEFAULT (CONVERT([bit],(0))), + [EXPIRY_DATE] date NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [INSRNC_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [INSRNC_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [INSRNC_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [INSRNC_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [INSRNC_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [INSRNC_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [INSRNC_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [INSRNC_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [INSRNC_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [INSRNC_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [INSRNC_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [INSRNC_PK] PRIMARY KEY CLUSTERED([INSURANCE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the non-standard insurance coverage type' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_INSURANCE', + @level2type = N'Column', @level2name = N'OTHER_INSURANCE_TYPE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the insurance coverage' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_INSURANCE', + @level2type = N'Column', @level2name = N'COVERAGE_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Monetary limit of the insurance coverage' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_INSURANCE', + @level2type = N'Column', @level2name = N'COVERAGE_LIMIT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicator that digital license exists' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_INSURANCE', + @level2type = N'Column', @level2name = N'IS_INSURANCE_IN_PLACE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date the insurance expires' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_INSURANCE', + @level2type = N'Column', @level2name = N'EXPIRY_DATE' +GO + +CREATE TABLE [dbo].[PIMS_INSURANCE_HIST] ( + [_INSURANCE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_INSURANCE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [INSURANCE_ID] bigint NOT NULL, + [LEASE_ID] bigint NOT NULL, + [INSURANCE_TYPE_CODE] nvarchar(20) NOT NULL, + [OTHER_INSURANCE_TYPE] nvarchar(200) NULL, + [COVERAGE_DESCRIPTION] nvarchar(2000) NULL, + [COVERAGE_LIMIT] money NULL, + [IS_INSURANCE_IN_PLACE] bit NULL, + [EXPIRY_DATE] date NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_INSRNC_H_PK] PRIMARY KEY CLUSTERED([_INSURANCE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] ( + [LAND_SURVEYOR_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LNSRVT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LNSRVT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LNSRVT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LNSRVT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LNSRVT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LNSRVT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LNSRVT_PK] PRIMARY KEY CLUSTERED([LAND_SURVEYOR_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the land surveyor type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE', + @level2type = N'Column', @level2name = N'LAND_SURVEYOR_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the land surveyor type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the land surveyor type. This is an unassociated table that is used in the UI to populate JSON attributes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LAND_SURVEYOR_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_HIST] ( + [_LEASE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_LEASE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [LEASE_ID] bigint NOT NULL, + [LEASE_PAY_RVBL_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_LICENSE_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_CATEGORY_TYPE_CODE] nvarchar(20) NULL, + [LEASE_PURPOSE_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_PROGRAM_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_INITIATOR_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_RESPONSIBILITY_TYPE_CODE] nvarchar(20) NULL, + [LEASE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [REGION_CODE] smallint NULL, + [L_FILE_NO] nvarchar(50) NULL, + [TFA_FILE_NO] int NULL, + [PS_FILE_NO] nvarchar(50) NULL, + [LEASE_CATEGORY_OTHER_DESC] nvarchar(200) NULL, + [LEASE_PURPOSE_OTHER_DESC] nvarchar(200) NULL, + [MOTI_CONTACT] nvarchar(200) NULL, + [DOCUMENTATION_REFERENCE] nvarchar(500) NULL, + [OTHER_LEASE_PROGRAM_TYPE] nvarchar(200) NULL, + [OTHER_LEASE_LICENSE_TYPE] nvarchar(200) NULL, + [OTHER_LEASE_PURPOSE_TYPE] nvarchar(200) NULL, + [ORIG_START_DATE] datetime NOT NULL, + [ORIG_EXPIRY_DATE] datetime NULL, + [LEASE_AMOUNT] money NULL, + [RESPONSIBILITY_EFFECTIVE_DATE] datetime NULL, + [INSPECTION_DATE] datetime NULL, + [IS_SUBJECT_TO_RTA] bit NULL, + [IS_COMM_BLDG] bit NULL, + [IS_OTHER_IMPROVEMENT] bit NULL, + [IS_EXPIRED] bit NOT NULL, + [HAS_PHYSICAL_FILE] bit NULL, + [HAS_DIGITAL_FILE] bit NULL, + [HAS_PHYSICIAL_LICENSE] bit NULL, + [HAS_DIGITAL_LICENSE] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_LEASE_H_PK] PRIMARY KEY CLUSTERED([_LEASE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] ( + [LEASE_PAYMENT_METHOD_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LSPMMT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSPMMT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPMMT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPMMT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPMMT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPMMT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSPMMT_PK] PRIMARY KEY CLUSTERED([LEASE_PAYMENT_METHOD_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Payment method type code' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_METHOD_TYPE', + @level2type = N'Column', @level2name = N'LEASE_PAYMENT_METHOD_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Payment method type description' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_METHOD_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is this code disabled?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_METHOD_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Display order of the descriptions' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_METHOD_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the type of payment method for a lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_METHOD_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] ( + [LEASE_PAYMENT_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LPSTST_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LPSTST_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LPSTST_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LPSTST_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LPSTST_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LPSTST_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LPSTST_PK] PRIMARY KEY CLUSTERED([LEASE_PAYMENT_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Payment status type code' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_STATUS_TYPE', + @level2type = N'Column', @level2name = N'LEASE_PAYMENT_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Payment status type description' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is this code disabled?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Display order of the descriptions' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the status of forecast payments' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] ( + [LEASE_PMT_FREQ_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LSPMTF_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSPMTF_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPMTF_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPMTF_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPMTF_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPMTF_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSPMTF_PK] PRIMARY KEY CLUSTERED([LEASE_PMT_FREQ_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Payment frequency type code' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PMT_FREQ_TYPE', + @level2type = N'Column', @level2name = N'LEASE_PMT_FREQ_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Payment frequency type code description' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PMT_FREQ_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the frequency of payments for a lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PMT_FREQ_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] ( + [LEASE_TERM_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LTRMST_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LTRMST_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LTRMST_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LTRMST_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LTRMST_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LTRMST_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LTRMST_PK] PRIMARY KEY CLUSTERED([LEASE_TERM_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value of the status of the lease term' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM_STATUS_TYPE', + @level2type = N'Column', @level2name = N'LEASE_TERM_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the status of the lease term' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the status of the lease term' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_TERM] ( + [LEASE_TERM_ID] bigint NOT NULL CONSTRAINT [LSTERM_LEASE_TERM_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_LEASE_TERM_ID_SEQ]), + [LEASE_ID] bigint NOT NULL, + [LEASE_TERM_STATUS_TYPE_CODE] nvarchar(20) NULL, + [LEASE_PMT_FREQ_TYPE_CODE] nvarchar(20) NULL, + [TERM_START_DATE] datetime NOT NULL, + [TERM_EXPIRY_DATE] datetime NULL, + [TERM_RENEWAL_DATE] datetime NULL, + [PAYMENT AMOUNT] money NULL, + [PAYMENT_DUE_DATE] nvarchar(200) NULL, + [PAYMENT_NOTE] nvarchar(2000) NULL, + [IS_GST_ELIGIBLE] bit NULL, + [GST_AMOUNT] money NULL, + [IS_TERM_EXERCISED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSTERM_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSTERM_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSTERM_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [LSTERM_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSTERM_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSTERM_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [LSTERM_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSTERM_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSTERM_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSTERM_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSTERM_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSTERM_PK] PRIMARY KEY CLUSTERED([LEASE_TERM_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Foreign key to payment frequency values' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'LEASE_PMT_FREQ_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Start date of the current term of the lease/licence' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'TERM_START_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Expiry date of the current term of the lease/licence' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'TERM_EXPIRY_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Renewal date of the current term of the lease/licence' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'TERM_RENEWAL_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Agreed-to payment amount (exclusive of GST)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'PAYMENT AMOUNT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Anecdotal description of payment due date (e.g. 1st of month, end of month)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'PAYMENT_DUE_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes regarding payment status for the lease term' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'PAYMENT_NOTE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is the lease subject to GST?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'IS_GST_ELIGIBLE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Calculated/entered GST portion of the payment. Can be overridden by the user.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'GST_AMOUNT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Has the lease term been exercised?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM', + @level2type = N'Column', @level2name = N'IS_TERM_EXERCISED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes a term for the associated lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TERM' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_PAYMENT] ( + [LEASE_PAYMENT_ID] bigint NOT NULL CONSTRAINT [LSPYMT_LEASE_PAYMENT_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_LEASE_PAYMENT_ID_SEQ]), + [LEASE_TERM_ID] bigint NOT NULL, + [LEASE_PAYMENT_METHOD_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_PAYMENT_STATUS_TYPE_CODE] nvarchar(20) NULL, + [PAYMENT_RECEIVED_DATE] datetime NOT NULL, + [PAYMENT_AMOUNT_PRE_TAX] money NOT NULL, + [PAYMENT_AMOUNT_PST] money NULL, + [PAYMENT_AMOUNT_GST] money NULL, + [PAYMENT_AMOUNT_TOTAL] money NOT NULL, + [NOTE] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSPYMT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPYMT_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPYMT_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [LSPYMT_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPYMT_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPYMT_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [LSPYMT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPYMT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPYMT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSPYMT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSPYMT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSPYMT_PK] PRIMARY KEY CLUSTERED([LEASE_PAYMENT_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date the payment was received or sent' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT', + @level2type = N'Column', @level2name = N'PAYMENT_RECEIVED_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Principal amount of the payment before applicable taxes' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT', + @level2type = N'Column', @level2name = N'PAYMENT_AMOUNT_PRE_TAX' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'PST owing on payment if applicable' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT', + @level2type = N'Column', @level2name = N'PAYMENT_AMOUNT_PST' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'GST owing on payment if applicable' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT', + @level2type = N'Column', @level2name = N'PAYMENT_AMOUNT_GST' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Total amount of payment including principal plus all applicable taxes' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT', + @level2type = N'Column', @level2name = N'PAYMENT_AMOUNT_TOTAL' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes regarding this payment' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT', + @level2type = N'Column', @level2name = N'NOTE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes a payment associated with a lease term.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_PAYMENT' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_PAYMENT_HIST] ( + [_LEASE_PAYMENT_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_LEASE_PAYMENT_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [LEASE_PAYMENT_ID] bigint NOT NULL, + [LEASE_TERM_ID] bigint NOT NULL, + [LEASE_PAYMENT_METHOD_TYPE_CODE] nvarchar(20) NOT NULL, + [LEASE_PAYMENT_STATUS_TYPE_CODE] nvarchar(20) NULL, + [PAYMENT_RECEIVED_DATE] datetime NOT NULL, + [PAYMENT_AMOUNT_PRE_TAX] money NOT NULL, + [PAYMENT_AMOUNT_PST] money NULL, + [PAYMENT_AMOUNT_GST] money NULL, + [PAYMENT_AMOUNT_TOTAL] money NOT NULL, + [NOTE] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_LSPYMT_H_PK] PRIMARY KEY CLUSTERED([_LEASE_PAYMENT_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_LESSOR_TYPE] ( + [LESSOR_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [LSSRTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [LSSRTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSSRTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSSRTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [LSSRTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [LSSRTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [LSSRTY_PK] PRIMARY KEY CLUSTERED([LESSOR_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_LEASE_TENANT] ( + [LEASE_TENANT_ID] bigint NOT NULL CONSTRAINT [TENANT_LEASE_TENANT_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_LEASE_TENANT_ID_SEQ]), + [LEASE_ID] bigint NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [LESSOR_TYPE_CODE] nvarchar(20) NOT NULL, + [PRIMARY_CONTACT_ID] bigint NULL, + [NOTE] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [TENANT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [TENANT_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [TENANT_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [TENANT_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [TENANT_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [TENANT_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [TENANT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [TENANT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [TENANT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [TENANT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [TENANT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [TENANT_PK] PRIMARY KEY CLUSTERED([LEASE_TENANT_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes associated with the lease/tenant relationship.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TENANT', + @level2type = N'Column', @level2name = N'NOTE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Associates a tenant with a lease' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_LEASE_TENANT' +GO + +CREATE TABLE [dbo].[PIMS_LEASE_TENANT_HIST] ( + [_LEASE_TENANT_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_LEASE_TENANT_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [LEASE_TENANT_ID] bigint NOT NULL, + [LEASE_ID] bigint NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [LESSOR_TYPE_CODE] nvarchar(20) NOT NULL, + [PRIMARY_CONTACT_ID] bigint NULL, + [NOTE] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_TENANT_H_PK] PRIMARY KEY CLUSTERED([_LEASE_TENANT_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_LEASE_TERM_HIST] ( + [_LEASE_TERM_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_LEASE_TERM_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [LEASE_TERM_ID] bigint NOT NULL, + [LEASE_ID] bigint NOT NULL, + [LEASE_TERM_STATUS_TYPE_CODE] nvarchar(20) NULL, + [LEASE_PMT_FREQ_TYPE_CODE] nvarchar(20) NULL, + [TERM_START_DATE] datetime NOT NULL, + [TERM_EXPIRY_DATE] datetime NULL, + [TERM_RENEWAL_DATE] datetime NULL, + [PAYMENT AMOUNT] money NULL, + [PAYMENT_DUE_DATE] nvarchar(200) NULL, + [PAYMENT_NOTE] nvarchar(2000) NULL, + [IS_GST_ELIGIBLE] bit NULL, + [GST_AMOUNT] money NULL, + [IS_TERM_EXERCISED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_LSTERM_H_PK] PRIMARY KEY CLUSTERED([_LEASE_TERM_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_NOTE_HIST] ( + [_NOTE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_NOTE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [NOTE_ID] bigint NOT NULL, + [NOTE_TXT] nvarchar(4000) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_NOTE_H_PK] PRIMARY KEY CLUSTERED([_NOTE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] ( + [ORGANIZATION_ADDRESS_ID] bigint NOT NULL CONSTRAINT [ORGADD_ORGANIZATION_ADDRESS_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ORGANIZATION_ADDRESS_ID_SEQ]), + [ORGANIZATION_ID] bigint NOT NULL, + [ADDRESS_ID] bigint NOT NULL, + [ADDRESS_USAGE_TYPE_CODE] nvarchar(20) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [ORGADD_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ORGADD_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORGADD_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORGADD_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORGADD_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ORGADD_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ORGADD_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ORGADD_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ORGADD_PK] PRIMARY KEY CLUSTERED([ORGANIZATION_ADDRESS_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'An associative entity to define multiple addresses for a person.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_ORGANIZATION_ADDRESS' +GO + +CREATE TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS_HIST] ( + [_ORGANIZATION_ADDRESS_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ORGANIZATION_ADDRESS_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ORGANIZATION_ADDRESS_ID] bigint NOT NULL, + [ORGANIZATION_ID] bigint NOT NULL, + [ADDRESS_ID] bigint NOT NULL, + [ADDRESS_USAGE_TYPE_CODE] nvarchar(20) NOT NULL, + [IS_DISABLED] bit NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ORGADD_H_PK] PRIMARY KEY CLUSTERED([_ORGANIZATION_ADDRESS_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ORGANIZATION_HIST] ( + [_ORGANIZATION_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ORGANIZATION_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ORGANIZATION_ID] bigint NOT NULL, + [PRNT_ORGANIZATION_ID] bigint NULL, + [REGION_CODE] smallint NULL, + [DISTRICT_CODE] smallint NULL, + [ORGANIZATION_TYPE_CODE] nvarchar(20) NULL, + [ORG_IDENTIFIER_TYPE_CODE] nvarchar(20) NULL, + [ORGANIZATION_IDENTIFIER] nvarchar(100) NULL, + [ORGANIZATION_NAME] nvarchar(200) NOT NULL, + [ORGANIZATION_ALIAS] nvarchar(200) NULL, + [INCORPORATION_NUMBER] nvarchar(50) NULL, + [WEBSITE] nvarchar(200) NULL, + [COMMENT] nvarchar(2000) NULL, + [IS_DISABLED] bit NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ORG_H_PK] PRIMARY KEY CLUSTERED([_ORGANIZATION_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PERSON_ADDRESS] ( + [PERSON_ADDRESS_ID] bigint NOT NULL CONSTRAINT [PERADD_PERSON_ADDRESS_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PERSON_ADDRESS_ID_SEQ]), + [PERSON_ID] bigint NOT NULL, + [ADDRESS_ID] bigint NOT NULL, + [ADDRESS_USAGE_TYPE_CODE] nvarchar(20) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PERADD_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PERADD_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERADD_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERADD_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERADD_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PERADD_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERADD_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PERADD_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PERADD_PK] PRIMARY KEY CLUSTERED([PERSON_ADDRESS_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'An associative entity to define multiple addresses for a person.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PERSON_ADDRESS' +GO + +CREATE TABLE [dbo].[PIMS_PERSON_ADDRESS_HIST] ( + [_PERSON_ADDRESS_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PERSON_ADDRESS_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PERSON_ADDRESS_ID] bigint NOT NULL, + [PERSON_ID] bigint NOT NULL, + [ADDRESS_ID] bigint NOT NULL, + [ADDRESS_USAGE_TYPE_CODE] nvarchar(20) NOT NULL, + [IS_DISABLED] bit NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PERADD_H_PK] PRIMARY KEY CLUSTERED([_PERSON_ADDRESS_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PERSON_HIST] ( + [_PERSON_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PERSON_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PERSON_ID] bigint NOT NULL, + [SURNAME] nvarchar(50) NOT NULL, + [FIRST_NAME] nvarchar(50) NOT NULL, + [MIDDLE_NAMES] nvarchar(200) NULL, + [NAME_SUFFIX] nvarchar(50) NULL, + [PREFERRED_NAME] nvarchar(200) NULL, + [BIRTH_DATE] date NULL, + [COMMENT] nvarchar(2000) NULL, + [ADDRESS_COMMENT] nvarchar(2000) NULL, + [USE_ORGANIZATION_ADDRESS] bit NULL, + [IS_DISABLED] bit NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PERSON_H_PK] PRIMARY KEY CLUSTERED([_PERSON_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PERSON_ORGANIZATION] ( + [PERSON_ORGANIZATION_ID] bigint NOT NULL CONSTRAINT [PERORG_PERSON_ORGANIZATION_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PERSON_ORGANIZATION_ID_SEQ]), + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [IS_DISABLED] bit NULL CONSTRAINT [PERORG_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PERORG_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERORG_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERORG_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERORG_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PERORG_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PERORG_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PERORG_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PERORG_PK] PRIMARY KEY CLUSTERED([PERSON_ORGANIZATION_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PERSON_ORGANIZATION_HIST] ( + [_PERSON_ORGANIZATION_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PERSON_ORGANIZATION_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PERSON_ORGANIZATION_ID] bigint NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PERORG_H_PK] PRIMARY KEY CLUSTERED([_PERSON_ORGANIZATION_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PPH_STATUS_TYPE] ( + [PPH_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [PPHSTT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PPHSTT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PPHSTT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PPHSTT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PPHSTT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PPHSTT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PPHSTT_PK] PRIMARY KEY CLUSTERED([PPH_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code indicating the Provincial Public Highway status' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PPH_STATUS_TYPE', + @level2type = N'Column', @level2name = N'PPH_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the code indicating the purpose of the property research' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PPH_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PPH_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PPH_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe the Provincial Public Highway status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PPH_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] ( + [PROP_RESEARCH_PURPOSE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [RRESPT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [RRESPT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RRESPT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RRESPT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RRESPT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RRESPT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [RRESPT_PK] PRIMARY KEY CLUSTERED([PROP_RESEARCH_PURPOSE_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code indicating the purpose of the property research' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', + @level2type = N'Column', @level2name = N'PROP_RESEARCH_PURPOSE_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the code indicating the purpose of the property research' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe the purpose ot the property research' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_RESEARCH_PURPOSE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] ( + [PROPERTY_CLASSIFICATION_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRPCLT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPCLT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPCLT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPCLT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPCLT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPCLT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPCLT_PK] PRIMARY KEY CLUSTERED([PROPERTY_CLASSIFICATION_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] ( + [PROPERTY_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRPSTS_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPSTS_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPSTS_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPSTS_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPSTS_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPSTS_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPSTS_PK] PRIMARY KEY CLUSTERED([PROPERTY_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property status code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_STATUS_TYPE', + @level2type = N'Column', @level2name = N'PROPERTY_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property status code description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe property status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_TYPE] ( + [PROPERTY_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRPTYP_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPTYP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPTYP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPTYP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPTYP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPTYP_PK] PRIMARY KEY CLUSTERED([PROPERTY_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] ( + [SURPLUS_DECLARATION_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [SPDCLT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [SPDCLT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SPDCLT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SPDCLT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SPDCLT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SPDCLT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [SPDCLT_PK] PRIMARY KEY CLUSTERED([SURPLUS_DECLARATION_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value of the surplus property type' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURPLUS_DECLARATION_TYPE', + @level2type = N'Column', @level2name = N'SURPLUS_DECLARATION_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code description of the surplus property type' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURPLUS_DECLARATION_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates that the code value is disabled' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURPLUS_DECLARATION_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the surplus property type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURPLUS_DECLARATION_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] ( + [VOLUME_UNIT_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [VOLUTY_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [VOLUTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [VOLUTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [VOLUTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [VOLUTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [VOLUTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [VOLUTY_PK] PRIMARY KEY CLUSTERED([VOLUME_UNIT_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The volume unit used for measuring Properties.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUME_UNIT_TYPE', + @level2type = N'Column', @level2name = N'VOLUME_UNIT_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Translation of the code value into a description that can be displayed to the user.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUME_UNIT_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is still active or is now disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUME_UNIT_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Order in which to display the code values, if required.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUME_UNIT_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The volume unit used for measuring Properties.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUME_UNIT_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] ( + [VOLUMETRIC_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRVOLT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRVOLT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRVOLT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRVOLT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRVOLT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRVOLT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRVOLT_PK] PRIMARY KEY CLUSTERED([VOLUMETRIC_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property parcel/property volumetric code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUMETRIC_TYPE', + @level2type = N'Column', @level2name = N'VOLUMETRIC_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property parcel/property volumetric code description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUMETRIC_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUMETRIC_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUMETRIC_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe parcel/property volumetric type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_VOLUMETRIC_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY] ( + [PROPERTY_ID] bigint NOT NULL CONSTRAINT [PRPRTY_PROPERTY_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_ID_SEQ]), + [PROPERTY_MANAGER_ID] bigint NULL, + [PROP_MGMT_ORG_ID] bigint NULL, + [PROPERTY_TYPE_CODE] nvarchar(20) NOT NULL, + [PROPERTY_CLASSIFICATION_TYPE_CODE] nvarchar(20) NOT NULL, + [ADDRESS_ID] bigint NULL, + [REGION_CODE] smallint NOT NULL, + [DISTRICT_CODE] smallint NOT NULL, + [PROPERTY_AREA_UNIT_TYPE_CODE] nvarchar(20) NULL, + [PROPERTY_DATA_SOURCE_TYPE_CODE] nvarchar(20) NOT NULL, + [PROPERTY_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [SURPLUS_DECLARATION_TYPE_CODE] nvarchar(20) NOT NULL, + [VOLUMETRIC_TYPE_CODE] nvarchar(20) NULL, + [VOLUME_UNIT_TYPE_CODE] nvarchar(20) NULL, + [PPH_STATUS_TYPE_CODE] nvarchar(20) NULL, + [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE] date NOT NULL, + [NAME] nvarchar(250) NULL, + [DESCRIPTION] nvarchar(2000) NULL, + [PID] int NULL, + [PIN] int NULL, + [FILE_NUMBER] int NULL, + [FILE_NUMBER_SUFFIX] varchar(2) NULL, + [LAND_AREA] real NULL, + [LAND_LEGAL_DESCRIPTION] nvarchar(max) NULL, + [BOUNDARY] [sys].[geometry] NULL, + [LOCATION] [sys].[geometry] NULL, + [ENCUMBRANCE_REASON] nvarchar(500) NULL, + [SURPLUS_DECLARATION_COMMENT] nvarchar(2000) NULL, + [SURPLUS_DECLARATION_DATE] datetime NULL, + [NOTES] nvarchar(max) NULL, + [MUNICIPAL_ZONING] nvarchar(100) NULL, + [IS_VOLUMETRIC_PARCEL] bit NULL CONSTRAINT [PRPRTY_IS_VOLUMETRIC_PARCEL_DEF] DEFAULT (CONVERT([bit],(0))), + [VOLUMETRIC_MEASUREMENT] real NULL, + [IS_OWNED] bit NOT NULL CONSTRAINT [PRPRTY_IS_OWNED_DEF] DEFAULT (CONVERT([bit],(1))), + [IS_PROPERTY_OF_INTEREST] bit NOT NULL CONSTRAINT [PRPRTY_IS_PROPERTY_OF_INTEREST_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_VISIBLE_TO_OTHER_AGENCIES] bit NOT NULL CONSTRAINT [PRPRTY_IS_VISIBLE_TO_OTHER_AGENCIES_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_SENSITIVE] bit NOT NULL CONSTRAINT [PRPRTY_IS_SENSITIVE_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_PROVINCIAL_PUBLIC_HWY] bit NULL, + [PPH_STATUS_UPDATE_USERID] nvarchar(30) NULL, + [PPH_STATUS_UPDATE_TIMESTAMP] datetime NULL, + [PPH_STATUS_UPDATE_USER_GUID] uniqueidentifier NULL, + [IS_RWY_BELT_DOM_PATENT] bit NULL CONSTRAINT [PRPRTY_IS_RWY_BELT_DOM_PATENT_DEF] DEFAULT (CONVERT([bit],(0))), + [ZONING] nvarchar(50) NULL, + [ZONING_POTENTIAL] nvarchar(50) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPRTY_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRTY_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRTY_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRTY_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRTY_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRTY_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRTY_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPRTY_PK] PRIMARY KEY CLUSTERED([PROPERTY_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date the property was officially registered' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'PROPERTY_DATA_SOURCE_EFFECTIVE_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property name' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property description' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property ID' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'PID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property number' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'PIN' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'The (ARCS/ORCS) number identifying the Property File.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'FILE_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A suffix to distinguish between Property Files with the same number.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'FILE_NUMBER_SUFFIX' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Area occupied by property' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'LAND_AREA' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Legal description of property' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'LAND_LEGAL_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Spatial bundary of land' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'BOUNDARY' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Geospatial location (pin) of property' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'LOCATION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'reason for property encumbreance' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'ENCUMBRANCE_REASON' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Comment regarding the surplus declaration' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'SURPLUS_DECLARATION_COMMENT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date the property was declared surplus' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'SURPLUS_DECLARATION_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes about the property' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'NOTES' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Municipal zoning that applies this property.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'MUNICIPAL_ZONING' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is there a volumetric measurement for this parcel?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'IS_VOLUMETRIC_PARCEL' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Volumetric measurement of the parcel.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'VOLUMETRIC_MEASUREMENT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is the property currently owned?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'IS_OWNED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is this a property of interest to the Ministry?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'IS_PROPERTY_OF_INTEREST' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is the property visible to other agencies?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'IS_VISIBLE_TO_OTHER_AGENCIES' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is this a sensitive property?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'IS_SENSITIVE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is this property a provincial public highway?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'IS_PROVINCIAL_PUBLIC_HWY' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Userid that updated the Provincial Public Highway status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'PPH_STATUS_UPDATE_USERID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date / time that the Provincial Public Highway status was updated.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'PPH_STATUS_UPDATE_TIMESTAMP' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'GUID of the user that updated the PPH status.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'PPH_STATUS_UPDATE_USER_GUID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if this property is original federal vs. provincial ownership.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'IS_RWY_BELT_DOM_PATENT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Current property zoning' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'ZONING' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Potential property zoning' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY', + @level2type = N'Column', @level2name = N'ZONING_POTENTIAL' +GO + +CREATE TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] ( + [REQUEST_SOURCE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [RQSRCT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [RQSRCT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RQSRCT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RQSRCT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RQSRCT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RQSRCT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [RQSRCT_PK] PRIMARY KEY CLUSTERED([REQUEST_SOURCE_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code indicating the source of the research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_REQUEST_SOURCE_TYPE', + @level2type = N'Column', @level2name = N'REQUEST_SOURCE_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the code indicating the source of the research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_REQUEST_SOURCE_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_REQUEST_SOURCE_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_REQUEST_SOURCE_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe source ot the research request' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_REQUEST_SOURCE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] ( + [RESEARCH_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [RSRCHS_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [RSRCHS_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RSRCHS_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RSRCHS_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RSRCHS_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RSRCHS_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [RSRCHS_PK] PRIMARY KEY CLUSTERED([RESEARCH_FILE_STATUS_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code indicating the status of the research file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'RESEARCH_FILE_STATUS_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the code indicating the status of the research file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE_STATUS_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe property adjacent land type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE_STATUS_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_RESEARCH_FILE] ( + [RESEARCH_FILE_ID] bigint NOT NULL CONSTRAINT [RESRCH_RESEARCH_FILE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_RESEARCH_FILE_ID_SEQ]), + [RESEARCH_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL CONSTRAINT [RESRCH_RESEARCH_FILE_STATUS_TYPE_CODE_DEF] DEFAULT ('ACTIVE'), + [REQUEST_SOURCE_TYPE_CODE] nvarchar(20) NULL, + [REQUESTOR_NAME] bigint NULL, + [REQUESTOR_ORGANIZATION] bigint NULL, + [NAME] nvarchar(250) NOT NULL, + [RFILE_NUMBER] nvarchar(25) NOT NULL CONSTRAINT [RESRCH_RFILE_NUMBER_DEF] DEFAULT ('RFILE-UNKNOWN'), + [REQUEST_DATE] date NULL, + [ROAD_NAME] nvarchar(max) NULL, + [ROAD_ALIAS] nvarchar(max) NULL, + [REQUEST_DESCRIPTION] nvarchar(max) NULL, + [REQUEST_SOURCE_DESCRIPTION] nvarchar(2000) NULL, + [RESEARCH_RESULT] nvarchar(max) NULL, + [IS_EXPROPRIATION] bit NULL, + [EXPROPRIATION_NOTES] nvarchar(max) NULL, + [RESEARCH_COMPLETION_DATE] date NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [RESRCH_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RESRCH_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RESRCH_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [RESRCH_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RESRCH_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RESRCH_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [RESRCH_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RESRCH_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RESRCH_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RESRCH_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RESRCH_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [RESRCH_PK] PRIMARY KEY CLUSTERED([RESEARCH_FILE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Name of the research requestor.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'REQUESTOR_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Organization associated with the research requestor.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'REQUESTOR_ORGANIZATION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Name given to the research file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'R-File number assigned to the research file, formatted value from PIMS_RFILE_NUMBER_SEQ sequence generator' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'RFILE_NUMBER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date of the research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'REQUEST_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Name(s) of roads associated with this research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'ROAD_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Alias(es) of roads associated with this research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'ROAD_ALIAS' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'REQUEST_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Result of the research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'RESEARCH_RESULT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is this an expropriation?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'IS_EXPROPRIATION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Notes associated with an expropriation.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'EXPROPRIATION_NOTES' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date the research request was completed.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'RESEARCH_COMPLETION_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property research file' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_FILE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] ( + [PROPERTY_RESEARCH_FILE_ID] bigint NOT NULL CONSTRAINT [PRSCRC_PROPERTY_RESEARCH_FILE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_RESEARCH_FILE_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [RESEARCH_FILE_ID] bigint NOT NULL, + [PROPERTY_NAME] nvarchar(500) NULL, + [DISPLAY_ORDER] int NULL, + [IS_DISABLED] bit NULL CONSTRAINT [PRSCRC_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [IS_LEGAL_OPINION_REQUIRED] bit NULL, + [IS_LEGAL_OPINION_OBTAINED] bit NULL, + [DOCUMENT_REFERENCE] nvarchar(2000) NULL, + [RESEARCH_SUMMARY] nvarchar(max) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRSCRC_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSCRC_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSCRC_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRSCRC_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSCRC_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSCRC_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRSCRC_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSCRC_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSCRC_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSCRC_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSCRC_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRSCRC_PK] PRIMARY KEY CLUSTERED([PROPERTY_RESEARCH_FILE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Descriptive reference for the property being researched.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'PROPERTY_NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether a legal opinion is required (0 = No, 1 = Yes, null = Unknown)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'IS_LEGAL_OPINION_REQUIRED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates whether a legal opinion was obtained (0 = No, 1 = Yes, null = Unknown)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'IS_LEGAL_OPINION_OBTAINED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'URL / reference to a LAN Drive' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'DOCUMENT_REFERENCE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Summary of the property research.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE', + @level2type = N'Column', @level2name = N'RESEARCH_SUMMARY' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Associates a property with a research file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_RESEARCH_FILE' +GO + +CREATE TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] ( + [PRF_PROP_RESEARCH_PURPOSE_ID] bigint NOT NULL CONSTRAINT [PRSPRP_PRF_PROP_RESEARCH_PURPOSE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PRF_PROP_RESEARCH_PURPOSE_ID_SEQ]), + [PROPERTY_RESEARCH_FILE_ID] bigint NULL, + [PROP_RESEARCH_PURPOSE_TYPE_CODE] nvarchar(20) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRSPRP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSPRP_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSPRP_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRSPRP_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSPRP_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSPRP_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRSPRP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSPRP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSPRP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSPRP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSPRP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRSPRP_PK] PRIMARY KEY CLUSTERED([PRF_PROP_RESEARCH_PURPOSE_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] ( + [PROPERTY_ACQUISITION_FILE_ID] bigint NOT NULL CONSTRAINT [PRACQF_PROPERTY_ACQUISITION_FILE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ]), + [ACQUISITION_FILE_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [PRACQF_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRACQF_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRACQF_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRACQF_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRACQF_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRACQF_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRACQF_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRACQF_PK] PRIMARY KEY CLUSTERED([PROPERTY_ACQUISITION_FILE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the relationship is active.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ACQUISITION_FILE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Associates a property with an acquisition file.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ACQUISITION_FILE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_HIST] ( + [_PROPERTY_ACQUISITION_FILE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_ACQUISITION_FILE_ID] bigint NOT NULL, + [ACQUISITION_FILE_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PRACQF_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_ACQUISITION_FILE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] ( + [PROPERTY_ADJACENT_LAND_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRADJL_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRADJL_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRADJL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRADJL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRADJL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRADJL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRADJL_PK] PRIMARY KEY CLUSTERED([PROPERTY_ADJACENT_LAND_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property adjacent land code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', + @level2type = N'Column', @level2name = N'PROPERTY_ADJACENT_LAND_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property adjacent land code description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe property adjacent land type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ADJACENT_LAND_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] ( + [PROPERTY_ANOMALY_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRANOM_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRANOM_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRANOM_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRANOM_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRANOM_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRANOM_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRANOM_PK] PRIMARY KEY CLUSTERED([PROPERTY_ANOMALY_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property anomaly code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ANOMALY_TYPE', + @level2type = N'Column', @level2name = N'PROPERTY_ANOMALY_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property anomaly code description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ANOMALY_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ANOMALY_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ANOMALY_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe property anomalies.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ANOMALY_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_EVALUATION] ( + [PROPERTY_EVALUATION_ID] bigint NOT NULL CONSTRAINT [PRPEVL_PROPERTY_EVALUATION_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_EVALUATION_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [EVALUATION_DATE] date NOT NULL, + [KEY] int NOT NULL, + [VALUE] money NOT NULL, + [NOTE] nvarchar(1000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPEVL_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPEVL_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPEVL_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPEVL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPEVL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPEVL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPEVL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPEVL_PK] PRIMARY KEY CLUSTERED([PROPERTY_EVALUATION_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_EVALUATION_HIST] ( + [_PROPERTY_EVALUATION_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_EVALUATION_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_EVALUATION_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [EVALUATION_DATE] date NOT NULL, + [KEY] int NOT NULL, + [VALUE] money NOT NULL, + [NOTE] nvarchar(1000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PRPEVL_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_EVALUATION_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_HIST] ( + [_PROPERTY_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_MANAGER_ID] bigint NULL, + [PROP_MGMT_ORG_ID] bigint NULL, + [PROPERTY_TYPE_CODE] nvarchar(20) NOT NULL, + [PROPERTY_CLASSIFICATION_TYPE_CODE] nvarchar(20) NOT NULL, + [ADDRESS_ID] bigint NULL, + [REGION_CODE] smallint NOT NULL, + [DISTRICT_CODE] smallint NOT NULL, + [PROPERTY_AREA_UNIT_TYPE_CODE] nvarchar(20) NULL, + [PROPERTY_DATA_SOURCE_TYPE_CODE] nvarchar(20) NOT NULL, + [PROPERTY_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [SURPLUS_DECLARATION_TYPE_CODE] nvarchar(20) NOT NULL, + [VOLUMETRIC_TYPE_CODE] nvarchar(20) NULL, + [VOLUME_UNIT_TYPE_CODE] nvarchar(20) NULL, + [PPH_STATUS_TYPE_CODE] nvarchar(20) NULL, + [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE] date NOT NULL, + [NAME] nvarchar(250) NULL, + [DESCRIPTION] nvarchar(2000) NULL, + [PID] int NULL, + [PIN] int NULL, + [FILE_NUMBER] int NULL, + [FILE_NUMBER_SUFFIX] varchar(2) NULL, + [LAND_AREA] real NULL, + [ENCUMBRANCE_REASON] nvarchar(500) NULL, + [SURPLUS_DECLARATION_COMMENT] nvarchar(2000) NULL, + [SURPLUS_DECLARATION_DATE] datetime NULL, + [MUNICIPAL_ZONING] nvarchar(100) NULL, + [IS_VOLUMETRIC_PARCEL] bit NULL, + [VOLUMETRIC_MEASUREMENT] real NULL, + [IS_OWNED] bit NOT NULL, + [IS_PROPERTY_OF_INTEREST] bit NOT NULL, + [IS_VISIBLE_TO_OTHER_AGENCIES] bit NOT NULL, + [IS_SENSITIVE] bit NOT NULL, + [IS_PROVINCIAL_PUBLIC_HWY] bit NULL, + [PPH_STATUS_UPDATE_USERID] nvarchar(30) NULL, + [PPH_STATUS_UPDATE_TIMESTAMP] datetime NULL, + [PPH_STATUS_UPDATE_USER_GUID] uniqueidentifier NULL, + [IS_RWY_BELT_DOM_PATENT] bit NULL, + [ZONING] nvarchar(50) NULL, + [ZONING_POTENTIAL] nvarchar(50) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PRPRTY_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] ( + [PROPERTY_IMPROVEMENT_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PIMPRT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PIMPRT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PIMPRT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PIMPRT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PIMPRT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PIMPRT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PIMPRT_PK] PRIMARY KEY CLUSTERED([PROPERTY_IMPROVEMENT_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value of the types of improvements made to a property during the lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_IMPROVEMENT_TYPE', + @level2type = N'Column', @level2name = N'PROPERTY_IMPROVEMENT_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code description of the types of improvements made to a property during the lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_IMPROVEMENT_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_IMPROVEMENT_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the types of improvements made to a property during the lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_IMPROVEMENT_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] ( + [PROPERTY_IMPROVEMENT_ID] bigint NOT NULL CONSTRAINT [PIMPRV_PROPERTY_IMPROVEMENT_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_IMPROVEMENT_ID_SEQ]), + [LEASE_ID] bigint NOT NULL, + [PROPERTY_IMPROVEMENT_TYPE_CODE] nvarchar(20) NOT NULL, + [IMPROVEMENT_DESCRIPTION] nvarchar(2000) NULL, + [STRUCTURE_SIZE] nvarchar(2000) NULL, + [ADDRESS] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PIMPRV_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PIMPRV_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PIMPRV_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PIMPRV_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PIMPRV_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PIMPRV_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PIMPRV_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PIMPRV_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PIMPRV_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PIMPRV_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PIMPRV_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PIMPRV_PK] PRIMARY KEY CLUSTERED([PROPERTY_IMPROVEMENT_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the improvements' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_IMPROVEMENT', + @level2type = N'Column', @level2name = N'IMPROVEMENT_DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Size of the structure (house, building, bridge, etc,)' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_IMPROVEMENT', + @level2type = N'Column', @level2name = N'STRUCTURE_SIZE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Addresses affected' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_IMPROVEMENT', + @level2type = N'Column', @level2name = N'ADDRESS' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of property improvements associated with the lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_IMPROVEMENT' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_HIST] ( + [_PROPERTY_IMPROVEMENT_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_IMPROVEMENT_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_IMPROVEMENT_ID] bigint NOT NULL, + [LEASE_ID] bigint NOT NULL, + [PROPERTY_IMPROVEMENT_TYPE_CODE] nvarchar(20) NOT NULL, + [IMPROVEMENT_DESCRIPTION] nvarchar(2000) NULL, + [STRUCTURE_SIZE] nvarchar(2000) NULL, + [ADDRESS] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PIMPRV_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_IMPROVEMENT_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_LEASE] ( + [PROPERTY_LEASE_ID] bigint NOT NULL CONSTRAINT [PROPLS_PROPERTY_LEASE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_LEASE_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [LEASE_ID] bigint NOT NULL, + [AREA_UNIT_TYPE_CODE] nvarchar(20) NULL, + [LEASE_AREA] real NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PROPLS_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PROPLS_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PROPLS_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PROPLS_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PROPLS_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PROPLS_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PROPLS_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PROPLS_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PROPLS_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PROPLS_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PROPLS_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PROPLS_PK] PRIMARY KEY CLUSTERED([PROPERTY_LEASE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Leased area measurement' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_LEASE', + @level2type = N'Column', @level2name = N'LEASE_AREA' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_LEASE_HIST] ( + [_PROPERTY_LEASE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_LEASE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_LEASE_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [LEASE_ID] bigint NOT NULL, + [AREA_UNIT_TYPE_CODE] nvarchar(20) NULL, + [LEASE_AREA] real NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PROPLS_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_LEASE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] ( + [PROPERTY_ORGANIZATION_ID] bigint NOT NULL CONSTRAINT [PRPORG_PROPERTY_ORGANIZATION_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_ORGANIZATION_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [ORGANIZATION_ID] bigint NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPORG_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPORG_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPORG_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPORG_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPORG_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPORG_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPORG_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [IS_DISABLED] bit NULL CONSTRAINT [PRPORG_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + CONSTRAINT [PRPORG_PK] PRIMARY KEY CLUSTERED([PROPERTY_ORGANIZATION_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION_HIST] ( + [_PROPERTY_ORGANIZATION_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_ORGANIZATION_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_ORGANIZATION_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [ORGANIZATION_ID] bigint NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [IS_DISABLED] bit NULL, + CONSTRAINT [PIMS_PRPORG_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_ORGANIZATION_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] ( + [PROPERTY_SERVICE_FILE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRSVFT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRSVFT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSVFT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSVFT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRSVFT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRSVFT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRSVFT_PK] PRIMARY KEY CLUSTERED([PROPERTY_SERVICE_FILE_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] ( + [PROPERTY_SERVICE_FILE_ID] bigint NOT NULL CONSTRAINT [PRPSVC_PROPERTY_SERVICE_FILE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_SERVICE_FILE_ID_SEQ]), + [PROPERTY_SERVICE_FILE_TYPE_CODE] nvarchar(20) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPSVC_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPSVC_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPSVC_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPSVC_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPSVC_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPSVC_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPSVC_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPSVC_PK] PRIMARY KEY CLUSTERED([PROPERTY_SERVICE_FILE_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] ( + [PROPERTY_PROPERTY_SERVICE_FILE_ID] bigint NOT NULL CONSTRAINT [PRPRSF_PROPERTY_PROPERTY_SERVICE_FILE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_PROPERTY_SERVICE_FILE_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_SERVICE_FILE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [PRPRSF_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPRSF_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRSF_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRSF_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRSF_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRSF_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRSF_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRSF_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPRSF_PK] PRIMARY KEY CLUSTERED([PROPERTY_PROPERTY_SERVICE_FILE_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE_HIST] ( + [_PROPERTY_PROPERTY_SERVICE_FILE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_PROPERTY_SERVICE_FILE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_PROPERTY_SERVICE_FILE_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_SERVICE_FILE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PRPRSF_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_PROPERTY_SERVICE_FILE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE_HIST] ( + [_PROPERTY_RESEARCH_FILE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_RESEARCH_FILE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_RESEARCH_FILE_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [RESEARCH_FILE_ID] bigint NOT NULL, + [PROPERTY_NAME] nvarchar(500) NULL, + [DISPLAY_ORDER] int NULL, + [IS_DISABLED] bit NULL, + [IS_LEGAL_OPINION_REQUIRED] bit NULL, + [IS_LEGAL_OPINION_OBTAINED] bit NULL, + [DOCUMENT_REFERENCE] nvarchar(2000) NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PRSCRC_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_RESEARCH_FILE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] ( + [PROPERTY_ROAD_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRROAD_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRROAD_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRROAD_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRROAD_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRROAD_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRROAD_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRROAD_PK] PRIMARY KEY CLUSTERED([PROPERTY_ROAD_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property highway/road code.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ROAD_TYPE', + @level2type = N'Column', @level2name = N'PROPERTY_ROAD_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property highway/road code description.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ROAD_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ROAD_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ROAD_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe property highway/road type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_ROAD_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_HIST] ( + [_PROPERTY_SERVICE_FILE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_SERVICE_FILE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_SERVICE_FILE_ID] bigint NOT NULL, + [PROPERTY_SERVICE_FILE_TYPE_CODE] nvarchar(20) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PRPSVC_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_SERVICE_FILE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] ( + [PROPERTY_TAX_REMIT_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PTRMTT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PTRMTT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PTRMTT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PTRMTT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PTRMTT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PTRMTT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PTRMTT_PK] PRIMARY KEY CLUSTERED([PROPERTY_TAX_REMIT_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value of property tax remittance types' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_TAX_REMIT_TYPE', + @level2type = N'Column', @level2name = N'PROPERTY_TAX_REMIT_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code description of property tax remittance types' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_TAX_REMIT_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Is this code value disabled?' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_TAX_REMIT_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of property tax remittance types' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_TAX_REMIT_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_TAX] ( + [PROPERTY_TAX_ID] bigint NOT NULL CONSTRAINT [PRPTAX_PROPERTY_TAX_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_TAX_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_TAX_REMIT_TYPE_CODE] nvarchar(20) NOT NULL, + [TAX_FOLIO_NO] nvarchar(50) NOT NULL, + [PAYMENT_AMOUNT] money NOT NULL, + [LAST_PAYMENT_DATE] datetime NULL, + [PAYMENT_NOTES] money NULL, + [BCTFA_NOTIFICATION_DATE] datetime NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPTAX_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPTAX_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPTAX_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPTAX_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPTAX_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPTAX_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPTAX_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPTAX_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPTAX_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPTAX_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPTAX_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPTAX_PK] PRIMARY KEY CLUSTERED([PROPERTY_TAX_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Property tax folio number' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_TAX', + @level2type = N'Column', @level2name = N'TAX_FOLIO_NO' +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_TAX_HIST] ( + [_PROPERTY_TAX_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_PROPERTY_TAX_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [PROPERTY_TAX_ID] bigint NOT NULL, + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_TAX_REMIT_TYPE_CODE] nvarchar(20) NOT NULL, + [TAX_FOLIO_NO] nvarchar(50) NOT NULL, + [PAYMENT_AMOUNT] money NOT NULL, + [LAST_PAYMENT_DATE] datetime NULL, + [PAYMENT_NOTES] money NULL, + [BCTFA_NOTIFICATION_DATE] datetime NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_PRPTAX_H_PK] PRIMARY KEY CLUSTERED([_PROPERTY_TAX_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] ( + [PROPERTY_TENURE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [PRPTNR_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPTNR_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPTNR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPTNR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPTNR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPTNR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPTNR_PK] PRIMARY KEY CLUSTERED([PROPERTY_TENURE_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'A code table to store property tenure codes. Tenure is defined as : "The act, right, manner or term of holding something(as a landed property)" In this case, tenure is required on Properties to indicate MoTI''s legal tenure on the property. The land parcel' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROPERTY_TENURE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] ( + [PROP_PROP_ADJACENT_LAND_TYPE_ID] bigint NOT NULL CONSTRAINT [PRPALT_PROP_PROP_ADJACENT_LAND_TYPE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROP_PROP_ADJACENT_LAND_TYPE_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_ADJACENT_LAND_TYPE_CODE] nvarchar(20) NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPALT_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPALT_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPALT_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPALT_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPALT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPALT_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPALT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPALT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPALT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPALT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPALT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPALT_PK] PRIMARY KEY CLUSTERED([PROP_PROP_ADJACENT_LAND_TYPE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Resolves many-to-many relationship between PIMS_PROPERTY and PIMS_PROPERTY_ADJACENT_LAND_TYPE' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_PROP_ADJACENT_LAND_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] ( + [PROP_PROP_ANOMALY_TYPE_ID] bigint NOT NULL CONSTRAINT [PRPRAT_PROP_PROP_ANOMALY_TYPE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROP_PROP_ANOMALY_TYPE_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_ANOMALY_TYPE_CODE] nvarchar(20) NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRAT_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPRAT_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRAT_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRAT_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPRAT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRAT_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPRAT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRAT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRAT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRAT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRAT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPRAT_PK] PRIMARY KEY CLUSTERED([PROP_PROP_ANOMALY_TYPE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Resolves many-to-many relationship between PIMS_PROPERTY and PIMS_PROPERTY_ANOMALY_TYPE' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_PROP_ANOMALY_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] ( + [PROP_PROP_ROAD_TYPE_ID] bigint NOT NULL CONSTRAINT [PRPRRT_PROP_PROP_ROAD_TYPE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROP_PROP_ROAD_TYPE_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_ROAD_TYPE_CODE] nvarchar(20) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPRRT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRRT_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRRT_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPRRT_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRRT_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRRT_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPRRT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRRT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRRT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRRT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRRT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPRRT_PK] PRIMARY KEY CLUSTERED([PROP_PROP_ROAD_TYPE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Resolves many-to-many relationship between PIMS_PROPERTY and PIMS_PROPERTY_ROAD_TYPE' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_PROP_ROAD_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] ( + [PROP_PROP_TENURE_TYPE_ID] bigint NOT NULL CONSTRAINT [PRPRTT_PROP_PROP_TENURE_TYPE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_PROP_PROP_TENURE_TYPE_ID_SEQ]), + [PROPERTY_ID] bigint NOT NULL, + [PROPERTY_TENURE_TYPE_CODE] nvarchar(20) NOT NULL CONSTRAINT [PRPRTT_PROPERTY_TENURE_TYPE_CODE_DEF] DEFAULT ('UNKNOWN'), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [PRPRTT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRTT_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRTT_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPRTT_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRTT_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRTT_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [PRPRTT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRTT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRTT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [PRPRTT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [PRPRTT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [PRPRTT_PK] PRIMARY KEY CLUSTERED([PROP_PROP_TENURE_TYPE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Resolves many-to-many relationship between PIMS_PROPERTY and PIMS_PROPERTY_TENURE_TYPE' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_PROP_PROP_TENURE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_REGION_USER] ( + [REGION_USER_ID] bigint NOT NULL CONSTRAINT [RGNUSR_REGION_USER_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_REGION_USER_ID_SEQ]), + [REGION_CODE] smallint NOT NULL CONSTRAINT [RGNUSR_REGION_CODE_DEF] DEFAULT ((4)), + [USER_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [RGNUSR_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [RGNUSR_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RGNUSR_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RGNUSR_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [RGNUSR_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RGNUSR_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RGNUSR_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [RGNUSR_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RGNUSR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RGNUSR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RGNUSR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RGNUSR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [RGNUSR_PK] PRIMARY KEY CLUSTERED([REGION_USER_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_REGION_USER_HIST] ( + [_REGION_USER_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_REGION_USER_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [REGION_USER_ID] bigint NOT NULL, + [REGION_CODE] smallint NOT NULL, + [USER_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_RGNUSR_H_PK] PRIMARY KEY CLUSTERED([_REGION_USER_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_RESEARCH_FILE_HIST] ( + [_RESEARCH_FILE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_RESEARCH_FILE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [RESEARCH_FILE_ID] bigint NOT NULL, + [RESEARCH_FILE_STATUS_TYPE_CODE] nvarchar(20) NOT NULL, + [REQUEST_SOURCE_TYPE_CODE] nvarchar(20) NULL, + [REQUESTOR_NAME] bigint NULL, + [REQUESTOR_ORGANIZATION] bigint NULL, + [NAME] nvarchar(250) NOT NULL, + [RFILE_NUMBER] nvarchar(25) NOT NULL, + [REQUEST_DATE] date NULL, + [REQUEST_SOURCE_DESCRIPTION] nvarchar(2000) NULL, + [IS_EXPROPRIATION] bit NULL, + [RESEARCH_COMPLETION_DATE] date NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_RESRCH_H_PK] PRIMARY KEY CLUSTERED([_RESEARCH_FILE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] ( + [RESEARCH_PURPOSE_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [RSHPRT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [RSHPRT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RSHPRT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RSHPRT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RSHPRT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RSHPRT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [RSHPRT_PK] PRIMARY KEY CLUSTERED([RESEARCH_PURPOSE_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code indicating the purpose of the research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_PURPOSE_TYPE', + @level2type = N'Column', @level2name = N'RESEARCH_PURPOSE_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the code indicating the purpose of the research request.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_PURPOSE_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_PURPOSE_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Force the display order of the codes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_PURPOSE_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code table to describe the purpose ot the research request' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_RESEARCH_PURPOSE_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] ( + [RESEARCH_FILE_PURPOSE_ID] bigint NOT NULL CONSTRAINT [RSFLPR_RESEARCH_FILE_PURPOSE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_RESEARCH_FILE_PURPOSE_ID_SEQ]), + [RESEARCH_FILE_ID] bigint NOT NULL, + [RESEARCH_PURPOSE_TYPE_CODE] nvarchar(20) NOT NULL CONSTRAINT [RSFLPR_RESEARCH_PURPOSE_TYPE_CODE_DEF] DEFAULT ('GENENQ'), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [RSFLPR_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RSFLPR_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RSFLPR_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [RSFLPR_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RSFLPR_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RSFLPR_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [RSFLPR_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RSFLPR_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RSFLPR_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [RSFLPR_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [RSFLPR_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [RSFLPR_PK] PRIMARY KEY CLUSTERED([RESEARCH_FILE_PURPOSE_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE_HIST] ( + [_RESEARCH_FILE_PURPOSE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_RESEARCH_FILE_PURPOSE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [RESEARCH_FILE_PURPOSE_ID] bigint NOT NULL, + [RESEARCH_FILE_ID] bigint NOT NULL, + [RESEARCH_PURPOSE_TYPE_CODE] nvarchar(20) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_RSFLPR_H_PK] PRIMARY KEY CLUSTERED([_RESEARCH_FILE_PURPOSE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ROLE_CLAIM] ( + [ROLE_CLAIM_ID] bigint NOT NULL CONSTRAINT [ROLCLM_ROLE_CLAIM_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_ROLE_CLAIM_ID_SEQ]), + [ROLE_ID] bigint NOT NULL, + [CLAIM_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [ROLCLM_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [ROLCLM_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ROLCLM_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ROLCLM_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ROLCLM_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ROLCLM_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [ROLCLM_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [ROLCLM_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [ROLCLM_PK] PRIMARY KEY CLUSTERED([ROLE_CLAIM_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ROLE_CLAIM_HIST] ( + [_ROLE_CLAIM_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ROLE_CLAIM_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ROLE_CLAIM_ID] bigint NOT NULL, + [ROLE_ID] bigint NOT NULL, + [CLAIM_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ROLCLM_H_PK] PRIMARY KEY CLUSTERED([_ROLE_CLAIM_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_ROLE_HIST] ( + [_ROLE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_ROLE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [ROLE_ID] bigint NOT NULL, + [ROLE_UID] uniqueidentifier NOT NULL, + [KEYCLOAK_GROUP_ID] uniqueidentifier NULL, + [NAME] nvarchar(100) NOT NULL, + [DESCRIPTION] nvarchar(500) NULL, + [IS_PUBLIC] bit NOT NULL, + [IS_DISABLED] bit NOT NULL, + [SORT_ORDER] int NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_ROLE_H_PK] PRIMARY KEY CLUSTERED([_ROLE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] ( + [SECURITY_DEPOSIT_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [SECDPT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [SECDPT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SECDPT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SECDPT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SECDPT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SECDPT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [SECDPT_PK] PRIMARY KEY CLUSTERED([SECURITY_DEPOSIT_TYPE_CODE]) +) +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT] ( + [SECURITY_DEPOSIT_ID] bigint NOT NULL CONSTRAINT [SECDEP_SECURITY_DEPOSIT_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_SECURITY_DEPOSIT_ID_SEQ]), + [LEASE_ID] bigint NOT NULL, + [SECURITY_DEPOSIT_TYPE_CODE] nvarchar(20) NOT NULL, + [OTHER_DEPOSIT_TYPE_DESC] nvarchar(200) NULL, + [DESCRIPTION] nvarchar(2000) NOT NULL, + [AMOUNT_PAID] money NOT NULL, + [DEPOSIT_DATE] date NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [SECDEP_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SECDEP_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SECDEP_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [SECDEP_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SECDEP_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SECDEP_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [SECDEP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SECDEP_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SECDEP_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SECDEP_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SECDEP_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [SECDEP_PK] PRIMARY KEY CLUSTERED([SECURITY_DEPOSIT_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the deposit type If the SECURITY_DEPOSIT_TYPE_CODE has been chosen for this scurity deposit.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT', + @level2type = N'Column', @level2name = N'OTHER_DEPOSIT_TYPE_DESC' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Descirption of this security deposit' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Amount paid of this security deposit' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT', + @level2type = N'Column', @level2name = N'AMOUNT_PAID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date of this security deposit' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT', + @level2type = N'Column', @level2name = N'DEPOSIT_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of a security deposit associated with a lease.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT' +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HIST] ( + [_SECURITY_DEPOSIT_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_SECURITY_DEPOSIT_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [SECURITY_DEPOSIT_ID] bigint NOT NULL, + [LEASE_ID] bigint NOT NULL, + [SECURITY_DEPOSIT_TYPE_CODE] nvarchar(20) NOT NULL, + [OTHER_DEPOSIT_TYPE_DESC] nvarchar(200) NULL, + [DESCRIPTION] nvarchar(2000) NOT NULL, + [AMOUNT_PAID] money NOT NULL, + [DEPOSIT_DATE] date NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_SECDEP_H_PK] PRIMARY KEY CLUSTERED([_SECURITY_DEPOSIT_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] ( + [SECURITY_DEPOSIT_HOLDER_ID] bigint NOT NULL CONSTRAINT [SCDPHL_SECURITY_DEPOSIT_HOLDER_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_SECURITY_DEPOSIT_HOLDER_ID_SEQ]), + [SECURITY_DEPOSIT_ID] bigint NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [SCDPHL_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SCDPHL_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SCDPHL_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [SCDPHL_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SCDPHL_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SCDPHL_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [SCDPHL_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SCDPHL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SCDPHL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SCDPHL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SCDPHL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [SCDPHL_PK] PRIMARY KEY CLUSTERED([SECURITY_DEPOSIT_HOLDER_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER_HIST] ( + [_SECURITY_DEPOSIT_HOLDER_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_SECURITY_DEPOSIT_HOLDER_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [SECURITY_DEPOSIT_HOLDER_ID] bigint NOT NULL, + [SECURITY_DEPOSIT_ID] bigint NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_SCDPHL_H_PK] PRIMARY KEY CLUSTERED([_SECURITY_DEPOSIT_HOLDER_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] ( + [SECURITY_DEPOSIT_RETURN_ID] bigint NOT NULL CONSTRAINT [SDRTRN_SECURITY_DEPOSIT_RETURN_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_SECURITY_DEPOSIT_RETURN_ID_SEQ]), + [SECURITY_DEPOSIT_ID] bigint NOT NULL, + [TERMINATION_DATE] datetime NOT NULL, + [CLAIMS_AGAINST] money NULL, + [RETURN_AMOUNT] money NOT NULL, + [RETURN_DATE] datetime NOT NULL, + [INTEREST_PAID] money NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [SDRTRN_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SDRTRN_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SDRTRN_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [SDRTRN_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SDRTRN_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SDRTRN_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [SDRTRN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SDRTRN_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SDRTRN_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SDRTRN_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SDRTRN_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [SDRTRN_PK] PRIMARY KEY CLUSTERED([SECURITY_DEPOSIT_RETURN_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date the lease/license was terminated or surrendered' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT_RETURN', + @level2type = N'Column', @level2name = N'TERMINATION_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Amount of claims against the deposit' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT_RETURN', + @level2type = N'Column', @level2name = N'CLAIMS_AGAINST' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Amount returned minus claims' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT_RETURN', + @level2type = N'Column', @level2name = N'RETURN_AMOUNT' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Date of deposit return' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT_RETURN', + @level2type = N'Column', @level2name = N'RETURN_DATE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Interest paid on the deposit to the deposit holder' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT_RETURN', + @level2type = N'Column', @level2name = N'INTEREST_PAID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Describes the details of the return of a security deposit.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SECURITY_DEPOSIT_RETURN' +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HIST] ( + [_SECURITY_DEPOSIT_RETURN_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_SECURITY_DEPOSIT_RETURN_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [SECURITY_DEPOSIT_RETURN_ID] bigint NOT NULL, + [SECURITY_DEPOSIT_ID] bigint NOT NULL, + [TERMINATION_DATE] datetime NOT NULL, + [CLAIMS_AGAINST] money NULL, + [RETURN_AMOUNT] money NOT NULL, + [RETURN_DATE] datetime NOT NULL, + [INTEREST_PAID] money NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_SDRTRN_H_PK] PRIMARY KEY CLUSTERED([_SECURITY_DEPOSIT_RETURN_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] ( + [SECURITY_DEPOSIT_RETURN_HOLDER_ID] bigint NOT NULL CONSTRAINT [SCDPRH_SECURITY_DEPOSIT_RETURN_HOLDER_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_ID_SEQ]), + [SECURITY_DEPOSIT_RETURN_ID] bigint NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [SCDPRH_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SCDPRH_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SCDPRH_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [SCDPRH_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SCDPRH_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SCDPRH_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [SCDPRH_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SCDPRH_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SCDPRH_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SCDPRH_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SCDPRH_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [SCDPRH_PK] PRIMARY KEY CLUSTERED([SECURITY_DEPOSIT_RETURN_HOLDER_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_HIST] ( + [_SECURITY_DEPOSIT_RETURN_HOLDER_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [SECURITY_DEPOSIT_RETURN_HOLDER_ID] bigint NOT NULL, + [SECURITY_DEPOSIT_RETURN_ID] bigint NOT NULL, + [PERSON_ID] bigint NULL, + [ORGANIZATION_ID] bigint NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_SCDPRH_H_PK] PRIMARY KEY CLUSTERED([_SECURITY_DEPOSIT_RETURN_HOLDER_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_STATIC_VARIABLE] ( + [STATIC_VARIABLE_NAME] nvarchar(100) NOT NULL, + [STATIC_VARIABLE_VALUE] nvarchar(100) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [STAVBL_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [STAVBL_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [STAVBL_APP_CREATE_USERID_DEF] DEFAULT (user_name()), + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [STAVBL_APP_CREATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [STAVBL_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [STAVBL_APP_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL CONSTRAINT [STAVBL_APP_LAST_UPDATE_USER_DIRECTORY_DEF] DEFAULT (user_name()), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [STAVBL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [STAVBL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [STAVBL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [STAVBL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [STAVBL_PK] PRIMARY KEY CLUSTERED([STATIC_VARIABLE_NAME]) +) +GO + +CREATE TABLE [dbo].[PIMS_STATIC_VARIABLE_HIST] ( + [_STATIC_VARIABLE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_STATIC_VARIABLE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [STATIC_VARIABLE_NAME] nvarchar(100) NOT NULL, + [STATIC_VARIABLE_VALUE] nvarchar(100) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_STAVBL_H_PK] PRIMARY KEY CLUSTERED([_STATIC_VARIABLE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] ( + [SURVEY_PLAN_TYPE_CODE] nvarchar(20) NOT NULL, + [DESCRIPTION] nvarchar(200) NOT NULL, + [IS_DISABLED] bit NOT NULL CONSTRAINT [SRVPLT_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [DISPLAY_ORDER] int NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [SRVPLT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SRVPLT_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SRVPLT_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [SRVPLT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [SRVPLT_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [SRVPLT_PK] PRIMARY KEY CLUSTERED([SURVEY_PLAN_TYPE_CODE]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for the survey plan type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE', + @level2type = N'Column', @level2name = N'SURVEY_PLAN_TYPE_CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the survey plan type.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if the code value is inactive.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Designates a preferred presentation order of the code descriptions.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE', + @level2type = N'Column', @level2name = N'DISPLAY_ORDER' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Codified values for the survey plan type. This is an unassociated table that is used in the UI to populate JSON attributes.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_SURVEY_PLAN_TYPE' +GO + +CREATE TABLE [dbo].[PIMS_TENANT] ( + [TENANT_ID] bigint NOT NULL CONSTRAINT [TENNTX_TENANT_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_TENANT_ID_SEQ]), + [CODE] nvarchar(6) NOT NULL, + [NAME] nvarchar(150) NOT NULL, + [DESCRIPTION] nvarchar(500) NULL, + [SETTINGS] nvarchar(2000) NOT NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [TENNTX_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [TENNTX_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [TENNTX_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [TENNTX_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [TENNTX_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [TENNTX_PK] PRIMARY KEY CLUSTERED([TENANT_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Auto-sequenced unique key value' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_TENANT', + @level2type = N'Column', @level2name = N'TENANT_ID' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Code value for entry' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_TENANT', + @level2type = N'Column', @level2name = N'CODE' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Name of the entry for display purposes' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_TENANT', + @level2type = N'Column', @level2name = N'NAME' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Description of the entry for display purposes' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_TENANT', + @level2type = N'Column', @level2name = N'DESCRIPTION' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Serialized JSON value for the configuration' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_TENANT', + @level2type = N'Column', @level2name = N'SETTINGS' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Deprecated table to support legacy CITZ-PIMS application code. This table will be removed once the code dependency is removed from the system.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_TENANT' +GO + +CREATE TABLE [dbo].[PIMS_USER_HIST] ( + [_USER_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_USER_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [USER_ID] bigint NOT NULL, + [PERSON_ID] bigint NOT NULL, + [BUSINESS_IDENTIFIER_VALUE] nvarchar(30) NOT NULL, + [GUID_IDENTIFIER_VALUE] uniqueidentifier NULL, + [POSITION] nvarchar(100) NULL, + [NOTE] nvarchar(1000) NULL, + [LAST_LOGIN] datetime NULL, + [APPROVED_BY_ID] nvarchar(30) NULL, + [ISSUE_DATE] datetime NOT NULL, + [EXPIRY_DATE] datetime NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_USER_H_PK] PRIMARY KEY CLUSTERED([_USER_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_USER_ORGANIZATION] ( + [USER_ORGANIZATION_ID] bigint NOT NULL CONSTRAINT [USRORG_USER_ORGANIZATION_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_USER_ORGANIZATION_ID_SEQ]), + [ORGANIZATION_ID] bigint NOT NULL, + [USER_ID] bigint NOT NULL, + [ROLE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [USRORG_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [USRORG_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USRORG_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USRORG_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USRORG_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [USRORG_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USRORG_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [USRORG_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [USRORG_PK] PRIMARY KEY CLUSTERED([USER_ORGANIZATION_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if this association is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER_ORGANIZATION', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Associates a user with an organization.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER_ORGANIZATION' +GO + +CREATE TABLE [dbo].[PIMS_USER_ORGANIZATION_HIST] ( + [_USER_ORGANIZATION_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_USER_ORGANIZATION_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [USER_ORGANIZATION_ID] bigint NOT NULL, + [ORGANIZATION_ID] bigint NOT NULL, + [USER_ID] bigint NOT NULL, + [ROLE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_USRORG_H_PK] PRIMARY KEY CLUSTERED([_USER_ORGANIZATION_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[PIMS_USER_ROLE] ( + [USER_ROLE_ID] bigint NOT NULL CONSTRAINT [USERRL_USER_ROLE_ID_DEF] DEFAULT (NEXT VALUE FOR [PIMS_USER_ROLE_ID_SEQ]), + [USER_ID] bigint NOT NULL, + [ROLE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL CONSTRAINT [USERRL_IS_DISABLED_DEF] DEFAULT (CONVERT([bit],(0))), + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL CONSTRAINT [USERRL_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT ((1)), + [APP_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USERRL_APP_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USERRL_APP_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USERRL_DB_CREATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_CREATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [USERRL_DB_CREATE_USERID_DEF] DEFAULT (user_name()), + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL CONSTRAINT [USERRL_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT (getutcdate()), + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL CONSTRAINT [USERRL_DB_LAST_UPDATE_USERID_DEF] DEFAULT (user_name()), + CONSTRAINT [USERRL_PK] PRIMARY KEY CLUSTERED([USER_ROLE_ID]) +) +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Indicates if this association is disabled.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER_ROLE', + @level2type = N'Column', @level2name = N'IS_DISABLED' +GO +EXEC sp_addextendedproperty + @name = N'MS_Description', @value = N'Associates a user with an role.' , + @level0type = N'Schema', @level0name = N'dbo', + @level1type = N'Table', @level1name = N'PIMS_USER_ROLE' +GO + +CREATE TABLE [dbo].[PIMS_USER_ROLE_HIST] ( + [_USER_ROLE_HIST_ID] bigint NOT NULL DEFAULT (NEXT VALUE FOR [PIMS_USER_ROLE_H_ID_SEQ]), + [EFFECTIVE_DATE_HIST] datetime NOT NULL DEFAULT (getutcdate()), + [END_DATE_HIST] datetime NULL, + [USER_ROLE_ID] bigint NOT NULL, + [USER_ID] bigint NOT NULL, + [ROLE_ID] bigint NOT NULL, + [IS_DISABLED] bit NULL, + [CONCURRENCY_CONTROL_NUMBER] bigint NOT NULL, + [APP_CREATE_TIMESTAMP] datetime NOT NULL, + [APP_CREATE_USERID] nvarchar(30) NOT NULL, + [APP_CREATE_USER_GUID] uniqueidentifier NULL, + [APP_CREATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [APP_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + [APP_LAST_UPDATE_USER_GUID] uniqueidentifier NULL, + [APP_LAST_UPDATE_USER_DIRECTORY] nvarchar(30) NOT NULL, + [DB_CREATE_TIMESTAMP] datetime NOT NULL, + [DB_CREATE_USERID] nvarchar(30) NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] datetime NOT NULL, + [DB_LAST_UPDATE_USERID] nvarchar(30) NOT NULL, + CONSTRAINT [PIMS_USERRL_H_PK] PRIMARY KEY CLUSTERED([_USER_ROLE_HIST_ID]) +) +GO + +CREATE TABLE [dbo].[__EFMigrationsHistory] ( + [MigrationId] nvarchar(150) NOT NULL, + [ProductVersion] nvarchar(32) NULL, + CONSTRAINT [MIGHIS_PK] PRIMARY KEY CLUSTERED([MigrationId]) +) +GO + +CREATE VIEW [dbo].[PIMS_PERSON_CONTACT_VW] AS +SELECT DISTINCT PERSON_ID + , (SELECT TOP 1 CONTACT_METHOD_VALUE + FROM PIMS_CONTACT_METHOD + WHERE CONTACT_METHOD_TYPE_CODE = 'FAX' + AND PERSON_ID = TMP.PERSON_ID + ORDER BY IS_PREFERRED_METHOD DESC + , DB_LAST_UPDATE_TIMESTAMP DESC) AS FAX + , (SELECT TOP 1 CONTACT_METHOD_VALUE + FROM PIMS_CONTACT_METHOD + WHERE CONTACT_METHOD_TYPE_CODE = 'PERSMOBIL' + AND PERSON_ID = TMP.PERSON_ID + ORDER BY IS_PREFERRED_METHOD DESC + , DB_LAST_UPDATE_TIMESTAMP DESC) AS PERSONAL_MOBILE + , (SELECT TOP 1 CONTACT_METHOD_VALUE + FROM PIMS_CONTACT_METHOD + WHERE CONTACT_METHOD_TYPE_CODE = 'PERSPHONE' + AND PERSON_ID = TMP.PERSON_ID + ORDER BY IS_PREFERRED_METHOD DESC + , DB_LAST_UPDATE_TIMESTAMP DESC) AS PERSONAL_PHONE + , (SELECT TOP 1 CONTACT_METHOD_VALUE + FROM PIMS_CONTACT_METHOD + WHERE CONTACT_METHOD_TYPE_CODE = 'WORKMOBIL' + AND PERSON_ID = TMP.PERSON_ID + ORDER BY IS_PREFERRED_METHOD DESC + , DB_LAST_UPDATE_TIMESTAMP DESC) AS WORK_MOBILE + , (SELECT TOP 1 CONTACT_METHOD_VALUE + FROM PIMS_CONTACT_METHOD + WHERE CONTACT_METHOD_TYPE_CODE = 'WORKPHONE' + AND PERSON_ID = TMP.PERSON_ID + ORDER BY IS_PREFERRED_METHOD DESC + , DB_LAST_UPDATE_TIMESTAMP DESC) AS WORK_PHONE + , (SELECT TOP 1 CONTACT_METHOD_VALUE + FROM PIMS_CONTACT_METHOD + WHERE CONTACT_METHOD_TYPE_CODE = 'WORKEMAIL' + AND PERSON_ID = TMP.PERSON_ID + ORDER BY IS_PREFERRED_METHOD DESC + , DB_LAST_UPDATE_TIMESTAMP DESC) AS WORK_EMAIL + , (SELECT TOP 1 CONTACT_METHOD_VALUE + FROM PIMS_CONTACT_METHOD + WHERE CONTACT_METHOD_TYPE_CODE = 'PERSEMAIL' + AND PERSON_ID = TMP.PERSON_ID + ORDER BY IS_PREFERRED_METHOD DESC + , DB_LAST_UPDATE_TIMESTAMP DESC) AS PERSONAL_EMAIL +FROM PIMS_CONTACT_METHOD TMP +WHERE ORGANIZATION_ID IS NULL +GO + +CREATE VIEW [dbo].[PIMS_CONTACT_MGR_VW] AS + SELECT CONCAT('P', PER.PERSON_ID) AS ID + , PER.PERSON_ID + , ORG.ORGANIZATION_ID AS ORGANIZATION_ID + , PER.IS_DISABLED + , TRIM(CONCAT_WS(' ', NULLIF(PER.FIRST_NAME, ''), NULLIF(PER.MIDDLE_NAMES, ''), NULLIF(PER.SURNAME, ''))) AS SUMMARY + , PER.SURNAME + , PER.FIRST_NAME + , PER.MIDDLE_NAMES + , ORG.ORGANIZATION_NAME AS ORGANIZATION_NAME + , PAD.ADDRESS_ID + , ADR.STREET_ADDRESS_1 AS MAILING_ADDRESS + , ADR.MUNICIPALITY_NAME + , PRV.PROVINCE_STATE_CODE AS PROVINCE_STATE + , COALESCE(PVW.WORK_EMAIL, PVW.PERSONAL_EMAIL) AS EMAIL_ADDRESS + FROM PIMS_PERSON PER LEFT JOIN + PIMS_PERSON_ADDRESS PAD ON PAD.PERSON_ID = PER.PERSON_ID + AND PAD.ADDRESS_USAGE_TYPE_CODE = 'MAILING' LEFT JOIN + PIMS_ADDRESS ADR ON ADR.ADDRESS_ID = PAD.ADDRESS_ID LEFT JOIN + PIMS_PROVINCE_STATE PRV ON PRV.PROVINCE_STATE_ID = ADR.PROVINCE_STATE_ID LEFT JOIN + PIMS_PERSON_CONTACT_VW PVW ON PVW.PERSON_ID = PER.PERSON_ID LEFT JOIN + (SELECT PERSON_ID + , MAX(ORGANIZATION_ID) AS ORGANIZATION_ID + FROM PIMS_PERSON_ORGANIZATION + GROUP BY PERSON_ID) POR ON POR.PERSON_ID = PER.PERSON_ID LEFT JOIN + PIMS_ORGANIZATION ORG ON ORG.ORGANIZATION_ID = POR.ORGANIZATION_ID + UNION + SELECT CONCAT('O', ORG.ORGANIZATION_ID) + , NULL + , ORG.ORGANIZATION_ID + , ORG.IS_DISABLED + , ORG.ORGANIZATION_NAME + , NULL + , NULL + , NULL + , ORG.ORGANIZATION_NAME + , OAD.ADDRESS_ID + , ADR.STREET_ADDRESS_1 + , ADR.MUNICIPALITY_NAME + , PRV.PROVINCE_STATE_CODE + , CON.CONTACT_METHOD_VALUE + FROM PIMS_ORGANIZATION ORG LEFT JOIN + PIMS_ORGANIZATION_ADDRESS OAD ON OAD.ORGANIZATION_ID = ORG.ORGANIZATION_ID + AND OAD.ADDRESS_USAGE_TYPE_CODE = 'MAILING' LEFT JOIN + PIMS_ADDRESS ADR ON ADR.ADDRESS_ID = OAD.ADDRESS_ID LEFT JOIN + PIMS_PROVINCE_STATE PRV ON PRV.PROVINCE_STATE_ID = ADR.PROVINCE_STATE_ID LEFT JOIN + PIMS_CONTACT_METHOD CON ON CON.ORGANIZATION_ID = ORG.ORGANIZATION_ID + AND CON.CONTACT_METHOD_TYPE_CODE = 'WORKEMAIL' +GO + +CREATE VIEW [dbo].[PIMS_PROPERTY_BOUNDARY_VW] AS +SELECT PROP.PROPERTY_ID + , PROP.PID + , RIGHT('000000000' + CAST(PROP.PID AS VARCHAR(9)), 9) AS PID_PADDED + , PROP.PIN + , PROP.PROPERTY_TYPE_CODE + , PROP.PROPERTY_STATUS_TYPE_CODE + , PROP.PROPERTY_DATA_SOURCE_TYPE_CODE + , PROP.PROPERTY_DATA_SOURCE_EFFECTIVE_DATE + , PROP.PROPERTY_CLASSIFICATION_TYPE_CODE + , (SELECT STRING_AGG(TENURE_DESC, ', ') + FROM (SELECT TEN.DESCRIPTION AS TENURE_DESC + FROM PIMS_PROPERTY_TENURE_TYPE TEN INNER JOIN + PIMS_PROP_PROP_TENURE_TYPE TTY ON TTY.PROPERTY_TENURE_TYPE_CODE = TEN.PROPERTY_TENURE_TYPE_CODE + AND TTY.PROPERTY_ID = PROP.PROPERTY_ID) temp) AS PROPERTY_TENURE_TYPE_CODE + , ADDR.STREET_ADDRESS_1 + , ADDR.STREET_ADDRESS_2 + , ADDR.STREET_ADDRESS_3 + , ADDR.MUNICIPALITY_NAME + , ADDR.POSTAL_CODE + , PROV.PROVINCE_STATE_CODE + , PROV.DESCRIPTION AS PROVINCE_NAME + , CNTY.COUNTRY_CODE + , CNTY.DESCRIPTION AS COUNTRY_NAME + , PROP.NAME + , PROP.DESCRIPTION + , PROP.ADDRESS_ID + , PROP.REGION_CODE + , PROP.DISTRICT_CODE + , PROP.BOUNDARY AS GEOMETRY + , PROP.PROPERTY_AREA_UNIT_TYPE_CODE + , PROP.LAND_AREA + , PROP.LAND_LEGAL_DESCRIPTION + , PROP.ENCUMBRANCE_REASON + , PROP.IS_SENSITIVE + , PROP.IS_OWNED + , PROP.IS_PROPERTY_OF_INTEREST + , PROP.IS_VISIBLE_TO_OTHER_AGENCIES + , PROP.ZONING,ZONING_POTENTIAL +FROM PIMS_PROPERTY PROP LEFT OUTER JOIN + PIMS_ADDRESS ADDR ON ADDR.ADDRESS_ID = PROP.ADDRESS_ID LEFT OUTER JOIN + PIMS_PROVINCE_STATE PROV ON PROV.PROVINCE_STATE_ID = ADDR.PROVINCE_STATE_ID LEFT OUTER JOIN + PIMS_COUNTRY CNTY ON CNTY.COUNTRY_ID = ADDR.COUNTRY_ID +WHERE PROP.BOUNDARY IS NOT NULL +GO + +CREATE VIEW [dbo].[PIMS_PROPERTY_LOCATION_VW] AS +SELECT PROP.PROPERTY_ID + , PROP.PID + , RIGHT('000000000' + CAST(PROP.PID AS VARCHAR(9)), 9) AS PID_PADDED + , PROP.PIN + , PROP.PROPERTY_TYPE_CODE + , PROP.PROPERTY_STATUS_TYPE_CODE + , PROP.PROPERTY_DATA_SOURCE_TYPE_CODE + , PROP.PROPERTY_DATA_SOURCE_EFFECTIVE_DATE + , PROP.PROPERTY_CLASSIFICATION_TYPE_CODE + , (SELECT STRING_AGG(TENURE_DESC, ', ') + FROM (SELECT TEN.DESCRIPTION AS TENURE_DESC + FROM PIMS_PROPERTY_TENURE_TYPE TEN INNER JOIN + PIMS_PROP_PROP_TENURE_TYPE TTY ON TTY.PROPERTY_TENURE_TYPE_CODE = TEN.PROPERTY_TENURE_TYPE_CODE + AND TTY.PROPERTY_ID = PROP.PROPERTY_ID) temp) AS PROPERTY_TENURE_TYPE_CODE + , ADDR.STREET_ADDRESS_1 + , ADDR.STREET_ADDRESS_2 + , ADDR.STREET_ADDRESS_3 + , ADDR.MUNICIPALITY_NAME + , ADDR.POSTAL_CODE + , PROV.PROVINCE_STATE_CODE + , PROV.DESCRIPTION AS PROVINCE_NAME + , CNTY.COUNTRY_CODE + , CNTY.DESCRIPTION AS COUNTRY_NAME + , PROP.NAME + , PROP.DESCRIPTION + , PROP.ADDRESS_ID + , PROP.REGION_CODE + , PROP.DISTRICT_CODE + , PROP.LOCATION AS GEOMETRY + , PROP.PROPERTY_AREA_UNIT_TYPE_CODE + , PROP.LAND_AREA + , PROP.LAND_LEGAL_DESCRIPTION + , PROP.ENCUMBRANCE_REASON + , PROP.IS_SENSITIVE + , PROP.IS_OWNED + , PROP.IS_PROPERTY_OF_INTEREST + , PROP.IS_VISIBLE_TO_OTHER_AGENCIES + , PROP.ZONING,ZONING_POTENTIAL +FROM PIMS_PROPERTY PROP LEFT OUTER JOIN + PIMS_ADDRESS ADDR ON ADDR.ADDRESS_ID = PROP.ADDRESS_ID LEFT OUTER JOIN + PIMS_PROVINCE_STATE PROV ON PROV.PROVINCE_STATE_ID = ADDR.PROVINCE_STATE_ID LEFT OUTER JOIN + PIMS_COUNTRY CNTY ON CNTY.COUNTRY_ID = ADDR.COUNTRY_ID +WHERE PROP.LOCATION IS NOT NULL +GO + +-- ............................................................................................ + + +-- -------------------------------------------------------------------------------------------- +-- Create procedure pims_error_handling +-- -------------------------------------------------------------------------------------------- +CREATE PROCEDURE [dbo].[pims_error_handling] AS + begin + DECLARE @errmsg nvarchar(2048), + @severity tinyint, + @state tinyint, + @errno int, + @proc sysname, + @lineno int + + SELECT @errmsg = error_message(), @severity = error_severity(), + @state = error_state(), @errno = error_number(), + @proc = error_procedure(), @lineno = error_line() + + IF @errmsg NOT LIKE '***%' + BEGIN + SELECT @errmsg = '*** ' + coalesce(quotename(@proc), '') + + ', Line ' + ltrim(str(@lineno)) + '. Errno ' + + ltrim(str(@errno)) + ': ' + @errmsg + END + + RAISERROR('%s', @severity, @state, @errmsg) + end +GO + +-- -------------------------------------------------------------------------------------------- +-- Create function pims_ColumnExists +-- -------------------------------------------------------------------------------------------- +CREATE FUNCTION [dbo].[pims_ColumnExists](@TableName varchar(100), @ColumnName varchar(100)) +RETURNS nvarchar(1) +AS +BEGIN + DECLARE @Result nvarchar(1); + + IF EXISTS (SELECT * FROM INFORMATION_SCHEMA.Columns WHERE TABLE_NAME = @TableName AND COLUMN_NAME = @ColumnName) + SET @Result = 'Y' + ELSE + SET @Result = 'N' + + IF @TableName LIKE '%HIST' + SET @Result = 'N' + + RETURN @Result; +END +GO + +CREATE NONCLUSTERED INDEX [ACQAIN_ACQUISITION_FILE_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE]([ACQUISITION_FILE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACQAIN_ACTIVITY_INSTANCE_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE]([ACTIVITY_INSTANCE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACQNFL_ACQUISITION_FILE_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ACQNFL_ACQUISITION_FUNDING_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FUNDING_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ACQNFL_ACQUISITION_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ACQNFL_ACQ_PHYS_FILE_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE]([ACQ_PHYS_FILE_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ACQOWN_ACQUISITION_FILE_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_OWNER]([ACQUISITION_FILE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACQPER_ACQUISITION_FILE_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE_PERSON]([ACQUISITION_FILE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACQPER_ACQ_FL_PERSON_PROFILE_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE_PERSON]([ACQ_FL_PERSON_PROFILE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ACQPER_PERSON_ID_IDX] + ON [dbo].[PIMS_ACQUISITION_FILE_PERSON]([PERSON_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACRQOR_ACCESS_REQUEST_ID_IDX] + ON [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION]([ACCESS_REQUEST_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACRQOR_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACRQST_ACCESS_REQUEST_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACCESS_REQUEST]([ACCESS_REQUEST_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ACRQST_REGION_CODE_IDX] + ON [dbo].[PIMS_ACCESS_REQUEST]([REGION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ACRQST_ROLE_ID_IDX] + ON [dbo].[PIMS_ACCESS_REQUEST]([ROLE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACRQST_USER_ID_IDX] + ON [dbo].[PIMS_ACCESS_REQUEST]([USER_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACTDOC_ACTIVITY_INSTANCE_ID_IDX] + ON [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT]([ACTIVITY_INSTANCE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACTDOC_DOCUMENT_ID_IDX] + ON [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT]([DOCUMENT_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACTINN_ACTIVITY_INSTANCE_ID_IDX] + ON [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE]([ACTIVITY_INSTANCE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACTINN_NOTE_ID_IDX] + ON [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE]([NOTE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACTINS_ACTIVITY_TEMPLATE_ID_IDX] + ON [dbo].[PIMS_ACTIVITY_INSTANCE]([ACTIVITY_TEMPLATE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ACTTMP_ACTIVITY_TEMPLATE_TYPE_CODE_IDX] + ON [dbo].[PIMS_ACTIVITY_TEMPLATE]([ACTIVITY_TEMPLATE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ADDRSS_COUNTRY_ID_IDX] + ON [dbo].[PIMS_ADDRESS]([COUNTRY_ID]) +GO + +CREATE NONCLUSTERED INDEX [ADDRSS_DISTRICT_CODE_IDX] + ON [dbo].[PIMS_ADDRESS]([DISTRICT_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ADDRSS_PROVINCE_STATE_ID_IDX] + ON [dbo].[PIMS_ADDRESS]([PROVINCE_STATE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ADDRSS_REGION_CODE_IDX] + ON [dbo].[PIMS_ADDRESS]([REGION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCAAMD_AREA_CODE_IDX] + ON [dbo].[BCA_AREA_AMENDMENT]([AREA_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCADEL_AREA_CODE_IDX] + ON [dbo].[BCA_AREA_DELETE]([AREA_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCADFN_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_DEFINED]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCAFAM_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_AMENDMENT]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCAFDE_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_DESCRIPTION]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCAFLD_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCAFOR_JURISDICTION_CODE_IDX] + ON [dbo].[BCA_FOLIO_RECORD]([JURISDICTION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCAFSA_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_SALES]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCAGNV_AREA_CODE_IDX] + ON [dbo].[BCA_AREA_GENERAL_VALUE]([AREA_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCAJUR_AREA_CODE_IDX] + ON [dbo].[BCA_JURISDICTION]([AREA_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCAOWG_ROLL_NUMBER_IDX] + ON [dbo].[BCA_OWNERSHIP_GROUP]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCAOWN_OWNERSHIP_GROUP_ID_IDX] + ON [dbo].[BCA_OWNER]([OWNERSHIP_GROUP_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCASAR_DATA_ADVICE_ID_IDX] + ON [dbo].[BCA_ASSESSMENT_AREA]([DATA_ADVICE_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCASCV_AREA_CODE_IDX] + ON [dbo].[BCA_AREA_SCHOOL_VALUE]([AREA_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCATRV_AREA_CODE_IDX] + ON [dbo].[BCA_AREA_BCTRANSIT_VALUE]([AREA_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCAVAL_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_VALUATION]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCDAMD_DATA_ADVICE_ID_IDX] + ON [dbo].[BCA_DATA_ADVICE_AMENDMENT]([DATA_ADVICE_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCDDEL_DATA_ADVICE_ID_IDX] + ON [dbo].[BCA_DATA_ADVICE_DELETE]([DATA_ADVICE_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCDGNV_DATA_ADVICE_ID_IDX] + ON [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE]([DATA_ADVICE_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCDSCV_DATA_ADVICE_ID_IDX] + ON [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE]([DATA_ADVICE_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCDTRV_DATA_ADVICE_ID_IDX] + ON [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE]([DATA_ADVICE_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCELCT_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_ELECTORAL_AREA]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCFADR_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_ADDRESS]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCFARM_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_FARM]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCFGNV_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_GENERAL_VALUE]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCFSCV_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_SCHOOL_VALUE]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCFTRV_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_BCTRANSIT_VALUE]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCGSVC_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_GENERAL_SERVICE]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCIMPD_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_IMPROVEMENT_DISTRICT]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCISLT_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_ISLANDS_TRUST]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCJAMD_JURISDICTION_CODE_IDX] + ON [dbo].[BCA_JURISDICTION_AMENDMENT]([JURISDICTION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCJDEL_JURISDICTION_CODE_IDX] + ON [dbo].[BCA_JURISDICTION_DELETE]([JURISDICTION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCJGNV_JURISDICTION_CODE_IDX] + ON [dbo].[BCA_JURISDICTION_GENERAL_VALUE]([JURISDICTION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCJSCV_JURISDICTION_CODE_IDX] + ON [dbo].[BCA_JURISDICTION_SCHOOL_VALUE]([JURISDICTION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCJTRV_JURISDICTION_CODE_IDX] + ON [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE]([JURISDICTION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [BCLCHR_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCLCLA_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_LOCAL_AREA]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCMANH_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_MANUFACTURED_HOME]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCMFOR_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_MANAGED_FOREST]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCMNTX_ROLL_NUMBER_IDX] + ON [dbo].[BCA_MINOR_TAXING]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCOILG_ROLL_NUMBER_IDX] + ON [dbo].[BCA_FOLIO_OIL_AND_GAS]([ROLL_NUMBER]) +GO + +CREATE NONCLUSTERED INDEX [BCSPMU_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_SPECIFIED_MUNICIPAL]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCSPRG_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_SPECIFIED_REGIONAL]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [BCSVCA_MINOR_TAXING_ID_IDX] + ON [dbo].[BCA_SERVICE_AREA]([MINOR_TAXING_ID]) +GO + +CREATE NONCLUSTERED INDEX [CLMTYP_CLAIM_UID_IDX] + ON [dbo].[PIMS_CLAIM]([CLAIM_UID]) +GO + +CREATE NONCLUSTERED INDEX [CLMTYP_KEYCLOAK_ROLE_ID_IDX] + ON [dbo].[PIMS_CLAIM]([KEYCLOAK_ROLE_ID]) +GO + +CREATE NONCLUSTERED INDEX [CNTMTH_CONTACT_METHOD_TYPE_CODE_IDX] + ON [dbo].[PIMS_CONTACT_METHOD]([CONTACT_METHOD_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [CNTMTH_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_CONTACT_METHOD]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [CNTMTH_PERSON_ID_IDX] + ON [dbo].[PIMS_CONTACT_METHOD]([PERSON_ID]) +GO + +CREATE NONCLUSTERED INDEX [DOCMNT_DOCUMENT_ID_IDX] + ON [dbo].[PIMS_DOCUMENT]([DOCUMENT_ID]) +GO + +CREATE NONCLUSTERED INDEX [DOCMNT_DOCUMENT_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_DOCUMENT]([DOCUMENT_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [DSTRCT_REGION_CODE_IDX] + ON [dbo].[PIMS_DISTRICT]([REGION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [INSRNC_INSURANCE_TYPE_CODE_IDX] + ON [dbo].[PIMS_INSURANCE]([INSURANCE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [INSRNC_LEASE_ID_IDX] + ON [dbo].[PIMS_INSURANCE]([LEASE_ID]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_LEASE_CATEGORY_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE]([LEASE_CATEGORY_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_LEASE_INITIATOR_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE]([LEASE_INITIATOR_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_LEASE_LICENSE_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE]([LEASE_LICENSE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_LEASE_PAY_RVBL_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE]([LEASE_PAY_RVBL_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_LEASE_PROGRAM_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE]([LEASE_PROGRAM_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_LEASE_PURPOSE_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE]([LEASE_PURPOSE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_LEASE_RESPONSIBILITY_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE]([LEASE_RESPONSIBILITY_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_LEASE_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_L_FILE_NO_IDX] + ON [dbo].[PIMS_LEASE]([L_FILE_NO]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_PS_FILE_NO_IDX] + ON [dbo].[PIMS_LEASE]([PS_FILE_NO]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_REGION_CODE_IDX] + ON [dbo].[PIMS_LEASE]([REGION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LEASE_TFA_FILE_NO_IDX] + ON [dbo].[PIMS_LEASE]([TFA_FILE_NO]) +GO + +CREATE NONCLUSTERED INDEX [LSPYMT_LEASE_PAYMENT_METHOD_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE_PAYMENT]([LEASE_PAYMENT_METHOD_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LSPYMT_LEASE_TERM_ID_IDX] + ON [dbo].[PIMS_LEASE_PAYMENT]([LEASE_TERM_ID]) +GO + +CREATE NONCLUSTERED INDEX [LSTERM_LEASE_ID_IDX] + ON [dbo].[PIMS_LEASE_TERM]([LEASE_ID]) +GO + +CREATE NONCLUSTERED INDEX [LSTERM_LEASE_PMT_FREQ_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE_TERM]([LEASE_PMT_FREQ_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [LSTERM_LEASE_TERM_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE_TERM]([LEASE_TERM_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ORGADD_ADDRESS_ID_IDX] + ON [dbo].[PIMS_ORGANIZATION_ADDRESS]([ADDRESS_ID]) +GO + +CREATE NONCLUSTERED INDEX [ORGADD_ADDRESS_USAGE_TYPE_CODE_IDX] + ON [dbo].[PIMS_ORGANIZATION_ADDRESS]([ADDRESS_USAGE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ORGADD_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_ORGANIZATION_ADDRESS]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [ORG_DISTRICT_CODE_IDX] + ON [dbo].[PIMS_ORGANIZATION]([DISTRICT_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ORG_ORGANIZATION_TYPE_CODE_IDX] + ON [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ORG_ORG_IDENTIFIER_TYPE_CODE_IDX] + ON [dbo].[PIMS_ORGANIZATION]([ORG_IDENTIFIER_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [ORG_PRNT_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_ORGANIZATION]([PRNT_ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [ORG_REGION_CODE_IDX] + ON [dbo].[PIMS_ORGANIZATION]([REGION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PERADD_ADDRESS_ID_IDX] + ON [dbo].[PIMS_PERSON_ADDRESS]([ADDRESS_ID]) +GO + +CREATE NONCLUSTERED INDEX [PERADD_ADDRESS_USAGE_TYPE_CODE_IDX] + ON [dbo].[PIMS_PERSON_ADDRESS]([ADDRESS_USAGE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PERADD_PERSON_ID_IDX] + ON [dbo].[PIMS_PERSON_ADDRESS]([PERSON_ID]) +GO + +CREATE NONCLUSTERED INDEX [PERORG_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_PERSON_ORGANIZATION]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [PERORG_PERSON_ID_IDX] + ON [dbo].[PIMS_PERSON_ORGANIZATION]([PERSON_ID]) +GO + +CREATE NONCLUSTERED INDEX [PIMPRV_PROPERTY_IMPROVEMENT_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY_IMPROVEMENT]([PROPERTY_IMPROVEMENT_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PIMPRV_PROPERTY_LEASE_ID_IDX] + ON [dbo].[PIMS_PROPERTY_IMPROVEMENT]([LEASE_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRACQF_ACQUISITION_FILE_ID_IDX] + ON [dbo].[PIMS_PROPERTY_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRACQF_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROPERTY_ACQUISITION_FILE]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PROPLS_LEASE_ID_IDX] + ON [dbo].[PIMS_PROPERTY_LEASE]([LEASE_ID]) +GO + +CREATE NONCLUSTERED INDEX [PROPLS_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROPERTY_LEASE]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PROVNC_COUNTRY_ID_IDX] + ON [dbo].[PIMS_PROVINCE_STATE]([COUNTRY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPALT_PROPERTY_ADJACENT_LAND_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE]([PROPERTY_ADJACENT_LAND_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPALT_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPEVL_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROPERTY_EVALUATION]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPORG_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_PROPERTY_ORGANIZATION]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPORG_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROPERTY_ORGANIZATION]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRAT_PROPERTY_ANOMALY_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE]([PROPERTY_ANOMALY_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRAT_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRRT_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROP_PROP_ROAD_TYPE]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRRT_PROPERTY_ROAD_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROP_PROP_ROAD_TYPE]([PROPERTY_ROAD_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRSF_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRSF_PROPERTY_SERVICE_FILE_ID_IDX] + ON [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE]([PROPERTY_SERVICE_FILE_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTT_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTT_PROPERTY_TENURE_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_TENURE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_ADDRESS_ID_IDX] + ON [dbo].[PIMS_PROPERTY]([ADDRESS_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_DISTRICT_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([DISTRICT_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_PPH_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([PPH_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_PROPERTY_AREA_UNIT_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([PROPERTY_AREA_UNIT_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_PROPERTY_CLASSIFICATION_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([PROPERTY_CLASSIFICATION_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_PROPERTY_DATA_SOURCE_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([PROPERTY_DATA_SOURCE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_PROPERTY_MANAGER_ID_IDX] + ON [dbo].[PIMS_PROPERTY]([PROPERTY_MANAGER_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_PROPERTY_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([PROPERTY_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_PROPERTY_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([PROPERTY_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_PROP_MGMT_ORG_ID_IDX] + ON [dbo].[PIMS_PROPERTY]([PROP_MGMT_ORG_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_REGION_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([REGION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_SURPLUS_DECLARATION_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([SURPLUS_DECLARATION_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_VOLUMETRIC_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([VOLUMETRIC_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPRTY_VOLUME_UNIT_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY]([VOLUME_UNIT_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPSVC_PROPERTY_SERVICE_FILE_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY_SERVICE_FILE]([PROPERTY_SERVICE_FILE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRPTAX_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROPERTY_TAX]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRPTAX_PROPERTY_TAX_REMIT_TYPE_CODE_IDX] + ON [dbo].[PIMS_PROPERTY_TAX]([PROPERTY_TAX_REMIT_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [PRSCRC_PROPERTY_ID_IDX] + ON [dbo].[PIMS_PROPERTY_RESEARCH_FILE]([PROPERTY_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRSCRC_RESEARCH_FILE_ID_IDX] + ON [dbo].[PIMS_PROPERTY_RESEARCH_FILE]([RESEARCH_FILE_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRSPRP_PROPERTY_RESEARCH_FILE_ID_IDX] + ON [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE]([PROPERTY_RESEARCH_FILE_ID]) +GO + +CREATE NONCLUSTERED INDEX [PRSPRP_PROP_RESEARCH_PURPOSE_TYPE_CODE_IDX] + ON [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE]([PROP_RESEARCH_PURPOSE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [RESRCH_REQUESTOR_NAME_IDX] + ON [dbo].[PIMS_RESEARCH_FILE]([REQUESTOR_NAME]) +GO + +CREATE NONCLUSTERED INDEX [RESRCH_REQUESTOR_ORGANIZATION_IDX] + ON [dbo].[PIMS_RESEARCH_FILE]([REQUESTOR_ORGANIZATION]) +GO + +CREATE NONCLUSTERED INDEX [RESRCH_REQUEST_SOURCE_TYPE_CODE_IDX] + ON [dbo].[PIMS_RESEARCH_FILE]([REQUEST_SOURCE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [RESRCH_RESEARCH_FILE_STATUS_TYPE_CODE_IDX] + ON [dbo].[PIMS_RESEARCH_FILE]([RESEARCH_FILE_STATUS_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [RGNUSR_REGION_CODE_IDX] + ON [dbo].[PIMS_REGION_USER]([REGION_CODE]) +GO + +CREATE NONCLUSTERED INDEX [RGNUSR_USER_ID_IDX] + ON [dbo].[PIMS_REGION_USER]([USER_ID]) +GO + +CREATE NONCLUSTERED INDEX [ROLCLM_CLAIM_ID_IDX] + ON [dbo].[PIMS_ROLE_CLAIM]([CLAIM_ID]) +GO + +CREATE NONCLUSTERED INDEX [ROLCLM_ROLE_ID_IDX] + ON [dbo].[PIMS_ROLE_CLAIM]([ROLE_ID]) +GO + +CREATE NONCLUSTERED INDEX [ROLE_KEYCLOAK_GROUP_ID_IDX] + ON [dbo].[PIMS_ROLE]([KEYCLOAK_GROUP_ID]) +GO + +CREATE NONCLUSTERED INDEX [ROLE_ROLE_UID_IDX] + ON [dbo].[PIMS_ROLE]([ROLE_UID]) +GO + +CREATE NONCLUSTERED INDEX [RSFLPR_RESEARCH_FILE_ID_IDX] + ON [dbo].[PIMS_RESEARCH_FILE_PURPOSE]([RESEARCH_FILE_ID]) +GO + +CREATE NONCLUSTERED INDEX [RSFLPR_RESEARCH_PURPOSE_TYPE_CODE_IDX] + ON [dbo].[PIMS_RESEARCH_FILE_PURPOSE]([RESEARCH_PURPOSE_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [SCDPHL_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [SCDPHL_PERSON_ID_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER]([PERSON_ID]) +GO + +CREATE NONCLUSTERED INDEX [SCDPHL_SECURITY_DEPOSIT_ID_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER]([SECURITY_DEPOSIT_ID]) +GO + +CREATE NONCLUSTERED INDEX [SCDPRH_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [SCDPRH_PERSON_ID_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER]([PERSON_ID]) +GO + +CREATE NONCLUSTERED INDEX [SCDPRH_SECURITY_DEPOSIT_RETURN_ID_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER]([SECURITY_DEPOSIT_RETURN_ID]) +GO + +CREATE NONCLUSTERED INDEX [SDRTRN_SECURITY_DEPOSIT_ID_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT_RETURN]([SECURITY_DEPOSIT_ID]) +GO + +CREATE NONCLUSTERED INDEX [SECDEP_LEASE_ID_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT]([LEASE_ID]) +GO + +CREATE NONCLUSTERED INDEX [SECDEP_SECURITY_DEPOSIT_TYPE_CODE_IDX] + ON [dbo].[PIMS_SECURITY_DEPOSIT]([SECURITY_DEPOSIT_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [TENANT_LEASE_ID_IDX] + ON [dbo].[PIMS_LEASE_TENANT]([LEASE_ID]) +GO + +CREATE NONCLUSTERED INDEX [TENANT_LESSOR_TYPE_CODE_IDX] + ON [dbo].[PIMS_LEASE_TENANT]([LESSOR_TYPE_CODE]) +GO + +CREATE NONCLUSTERED INDEX [TENANT_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_LEASE_TENANT]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [TENANT_PERSON_ID_IDX] + ON [dbo].[PIMS_LEASE_TENANT]([PERSON_ID]) +GO + +CREATE NONCLUSTERED INDEX [TENANT_PRIMARY_CONTACT_ID_IDX] + ON [dbo].[PIMS_LEASE_TENANT]([PRIMARY_CONTACT_ID]) +GO + +CREATE NONCLUSTERED INDEX [USERRL_ROLE_ID_IDX] + ON [dbo].[PIMS_USER_ROLE]([ROLE_ID]) +GO + +CREATE NONCLUSTERED INDEX [USERRL_USER_ID_IDX] + ON [dbo].[PIMS_USER_ROLE]([USER_ID]) +GO + +CREATE NONCLUSTERED INDEX [USER_BUSINESS_IDENTIFIER_VALUE_IDX] + ON [dbo].[PIMS_USER]([BUSINESS_IDENTIFIER_VALUE]) +GO + +CREATE NONCLUSTERED INDEX [USER_GUID_IDENTIFIER_VALUE_IDX] + ON [dbo].[PIMS_USER]([GUID_IDENTIFIER_VALUE]) +GO + +CREATE NONCLUSTERED INDEX [USER_PERSON_ID_IDX] + ON [dbo].[PIMS_USER]([PERSON_ID]) +GO + +CREATE NONCLUSTERED INDEX [USRORG_ORGANIZATION_ID_IDX] + ON [dbo].[PIMS_USER_ORGANIZATION]([ORGANIZATION_ID]) +GO + +CREATE NONCLUSTERED INDEX [USRORG_ROLE_ID_IDX] + ON [dbo].[PIMS_USER_ORGANIZATION]([ROLE_ID]) +GO + +CREATE NONCLUSTERED INDEX [USRORG_USER_ID_IDX] + ON [dbo].[PIMS_USER_ORGANIZATION]([USER_ID]) +GO + +CREATE TRIGGER [dbo].[PIMS_ACQNFL_A_S_IUD_TR] ON PIMS_ACQUISITION_FILE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACQUISITION_FILE_HIST set END_DATE_HIST = @curr_date where ACQUISITION_FILE_ID in (select ACQUISITION_FILE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACQUISITION_FILE_HIST ([ACQUISITION_FILE_ID], [ACQUISITION_FILE_STATUS_TYPE_CODE], [ACQUISITION_TYPE_CODE], [ACQUISITION_FUNDING_TYPE_CODE], [ACQ_PHYS_FILE_STATUS_TYPE_CODE], [MINISTRY_PROJECT_NUMBER], [MINISTRY_PROJECT_NAME], [CPS_PRODUCT_CODE], [FILE_NAME], [FILE_NUMBER], [REGION_CODE], [FUNDING_OTHER], [ASSIGNED_DATE], [DELIVERY_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACQUISITION_FILE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACQUISITION_FILE_ID], [ACQUISITION_FILE_STATUS_TYPE_CODE], [ACQUISITION_TYPE_CODE], [ACQUISITION_FUNDING_TYPE_CODE], [ACQ_PHYS_FILE_STATUS_TYPE_CODE], [MINISTRY_PROJECT_NUMBER], [MINISTRY_PROJECT_NAME], [CPS_PRODUCT_CODE], [FILE_NAME], [FILE_NUMBER], [REGION_CODE], [FUNDING_OTHER], [ASSIGNED_DATE], [DELIVERY_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACQUISITION_FILE_H_ID_SEQ]) as [_ACQUISITION_FILE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RGNUSR_I_S_U_TR] ON PIMS_REGION_USER INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.REGION_USER_ID = deleted.REGION_USER_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_REGION_USER + set "REGION_USER_ID" = inserted."REGION_USER_ID", + "REGION_CODE" = inserted."REGION_CODE", + "USER_ID" = inserted."USER_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_REGION_USER + inner join inserted + on (PIMS_REGION_USER.REGION_USER_ID = inserted.REGION_USER_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQOWN_A_S_IUD_TR] ON PIMS_ACQUISITION_OWNER FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACQUISITION_OWNER_HIST set END_DATE_HIST = @curr_date where ACQUISITION_OWNER_ID in (select ACQUISITION_OWNER_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACQUISITION_OWNER_HIST ([ACQUISITION_OWNER_ID], [ACQUISITION_FILE_ID], [OWNER_NAME], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACQUISITION_OWNER_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACQUISITION_OWNER_ID], [ACQUISITION_FILE_ID], [OWNER_NAME], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACQUISITION_OWNER_H_ID_SEQ]) as [_ACQUISITION_OWNER_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RQSRCT_I_S_U_TR] ON PIMS_REQUEST_SOURCE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.REQUEST_SOURCE_TYPE_CODE = deleted.REQUEST_SOURCE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_REQUEST_SOURCE_TYPE + set "REQUEST_SOURCE_TYPE_CODE" = inserted."REQUEST_SOURCE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_REQUEST_SOURCE_TYPE + inner join inserted + on (PIMS_REQUEST_SOURCE_TYPE.REQUEST_SOURCE_TYPE_CODE = inserted.REQUEST_SOURCE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQPER_A_S_IUD_TR] ON PIMS_ACQUISITION_FILE_PERSON FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACQUISITION_FILE_PERSON_HIST set END_DATE_HIST = @curr_date where ACQUISITION_FILE_PERSON_ID in (select ACQUISITION_FILE_PERSON_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACQUISITION_FILE_PERSON_HIST ([ACQUISITION_FILE_PERSON_ID], [ACQUISITION_FILE_ID], [PERSON_ID], [ACQ_FL_PERSON_PROFILE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACQUISITION_FILE_PERSON_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACQUISITION_FILE_PERSON_ID], [ACQUISITION_FILE_ID], [PERSON_ID], [ACQ_FL_PERSON_PROFILE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACQUISITION_FILE_PERSON_H_ID_SEQ]) as [_ACQUISITION_FILE_PERSON_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RESRCH_I_S_U_TR] ON PIMS_RESEARCH_FILE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.RESEARCH_FILE_ID = deleted.RESEARCH_FILE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_RESEARCH_FILE + set "RESEARCH_FILE_ID" = inserted."RESEARCH_FILE_ID", + "RESEARCH_FILE_STATUS_TYPE_CODE" = inserted."RESEARCH_FILE_STATUS_TYPE_CODE", + "REQUEST_SOURCE_TYPE_CODE" = inserted."REQUEST_SOURCE_TYPE_CODE", + "REQUESTOR_NAME" = inserted."REQUESTOR_NAME", + "REQUESTOR_ORGANIZATION" = inserted."REQUESTOR_ORGANIZATION", + "NAME" = inserted."NAME", + "RFILE_NUMBER" = inserted."RFILE_NUMBER", + "REQUEST_DATE" = inserted."REQUEST_DATE", + "ROAD_NAME" = inserted."ROAD_NAME", + "ROAD_ALIAS" = inserted."ROAD_ALIAS", + "REQUEST_DESCRIPTION" = inserted."REQUEST_DESCRIPTION", + "REQUEST_SOURCE_DESCRIPTION" = inserted."REQUEST_SOURCE_DESCRIPTION", + "RESEARCH_RESULT" = inserted."RESEARCH_RESULT", + "IS_EXPROPRIATION" = inserted."IS_EXPROPRIATION", + "EXPROPRIATION_NOTES" = inserted."EXPROPRIATION_NOTES", + "RESEARCH_COMPLETION_DATE" = inserted."RESEARCH_COMPLETION_DATE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_RESEARCH_FILE + inner join inserted + on (PIMS_RESEARCH_FILE.RESEARCH_FILE_ID = inserted.RESEARCH_FILE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACRQOR_A_S_IUD_TR] ON PIMS_ACCESS_REQUEST_ORGANIZATION FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACCESS_REQUEST_ORGANIZATION_HIST set END_DATE_HIST = @curr_date where ACCESS_REQUEST_ORGANIZATION_ID in (select ACCESS_REQUEST_ORGANIZATION_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACCESS_REQUEST_ORGANIZATION_HIST ([ACCESS_REQUEST_ORGANIZATION_ID], [ORGANIZATION_ID], [ACCESS_REQUEST_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACCESS_REQUEST_ORGANIZATION_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACCESS_REQUEST_ORGANIZATION_ID], [ORGANIZATION_ID], [ACCESS_REQUEST_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION_H_ID_SEQ]) as [_ACCESS_REQUEST_ORGANIZATION_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RSFLPR_I_S_U_TR] ON PIMS_RESEARCH_FILE_PURPOSE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.RESEARCH_FILE_PURPOSE_ID = deleted.RESEARCH_FILE_PURPOSE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_RESEARCH_FILE_PURPOSE + set "RESEARCH_FILE_PURPOSE_ID" = inserted."RESEARCH_FILE_PURPOSE_ID", + "RESEARCH_FILE_ID" = inserted."RESEARCH_FILE_ID", + "RESEARCH_PURPOSE_TYPE_CODE" = inserted."RESEARCH_PURPOSE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_RESEARCH_FILE_PURPOSE + inner join inserted + on (PIMS_RESEARCH_FILE_PURPOSE.RESEARCH_FILE_PURPOSE_ID = inserted.RESEARCH_FILE_PURPOSE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACRQST_A_S_IUD_TR] ON PIMS_ACCESS_REQUEST FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACCESS_REQUEST_HIST set END_DATE_HIST = @curr_date where ACCESS_REQUEST_ID in (select ACCESS_REQUEST_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACCESS_REQUEST_HIST ([ACCESS_REQUEST_ID], [USER_ID], [ROLE_ID], [ACCESS_REQUEST_STATUS_TYPE_CODE], [REGION_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACCESS_REQUEST_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACCESS_REQUEST_ID], [USER_ID], [ROLE_ID], [ACCESS_REQUEST_STATUS_TYPE_CODE], [REGION_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACCESS_REQUEST_H_ID_SEQ]) as [_ACCESS_REQUEST_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RSRCHS_I_S_U_TR] ON PIMS_RESEARCH_FILE_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.RESEARCH_FILE_STATUS_TYPE_CODE = deleted.RESEARCH_FILE_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_RESEARCH_FILE_STATUS_TYPE + set "RESEARCH_FILE_STATUS_TYPE_CODE" = inserted."RESEARCH_FILE_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_RESEARCH_FILE_STATUS_TYPE + inner join inserted + on (PIMS_RESEARCH_FILE_STATUS_TYPE.RESEARCH_FILE_STATUS_TYPE_CODE = inserted.RESEARCH_FILE_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTDOC_A_S_IUD_TR] ON PIMS_ACTIVITY_INSTANCE_DOCUMENT FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST set END_DATE_HIST = @curr_date where ACTIVITY_INSTANCE_DOCUMENT_ID in (select ACTIVITY_INSTANCE_DOCUMENT_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST ([ACTIVITY_INSTANCE_DOCUMENT_ID], [ACTIVITY_INSTANCE_ID], [DOCUMENT_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACTIVITY_INSTANCE_DOCUMENT_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACTIVITY_INSTANCE_DOCUMENT_ID], [ACTIVITY_INSTANCE_ID], [DOCUMENT_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_H_ID_SEQ]) as [_ACTIVITY_INSTANCE_DOCUMENT_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RSHPRT_I_S_U_TR] ON PIMS_RESEARCH_PURPOSE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.RESEARCH_PURPOSE_TYPE_CODE = deleted.RESEARCH_PURPOSE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_RESEARCH_PURPOSE_TYPE + set "RESEARCH_PURPOSE_TYPE_CODE" = inserted."RESEARCH_PURPOSE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_RESEARCH_PURPOSE_TYPE + inner join inserted + on (PIMS_RESEARCH_PURPOSE_TYPE.RESEARCH_PURPOSE_TYPE_CODE = inserted.RESEARCH_PURPOSE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTINN_A_S_IUD_TR] ON PIMS_ACTIVITY_INSTANCE_NOTE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACTIVITY_INSTANCE_NOTE_HIST set END_DATE_HIST = @curr_date where PIMS_ACTIVITY_INSTANCE_NOTE_ID in (select PIMS_ACTIVITY_INSTANCE_NOTE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACTIVITY_INSTANCE_NOTE_HIST ([PIMS_ACTIVITY_INSTANCE_NOTE_ID], [ACTIVITY_INSTANCE_ID], [NOTE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACTIVITY_INSTANCE_NOTE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PIMS_ACTIVITY_INSTANCE_NOTE_ID], [ACTIVITY_INSTANCE_ID], [NOTE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_H_ID_SEQ]) as [_ACTIVITY_INSTANCE_NOTE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ROLE_I_S_U_TR] ON PIMS_ROLE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ROLE_ID = deleted.ROLE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ROLE + set "ROLE_ID" = inserted."ROLE_ID", + "ROLE_UID" = inserted."ROLE_UID", + "KEYCLOAK_GROUP_ID" = inserted."KEYCLOAK_GROUP_ID", + "NAME" = inserted."NAME", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_PUBLIC" = inserted."IS_PUBLIC", + "IS_DISABLED" = inserted."IS_DISABLED", + "SORT_ORDER" = inserted."SORT_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ROLE + inner join inserted + on (PIMS_ROLE.ROLE_ID = inserted.ROLE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTINS_A_S_IUD_TR] ON PIMS_ACTIVITY_INSTANCE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACTIVITY_INSTANCE_HIST set END_DATE_HIST = @curr_date where ACTIVITY_INSTANCE_ID in (select ACTIVITY_INSTANCE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACTIVITY_INSTANCE_HIST ([ACTIVITY_INSTANCE_ID], [ACTIVITY_TEMPLATE_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACTIVITY_INSTANCE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACTIVITY_INSTANCE_ID], [ACTIVITY_TEMPLATE_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACTIVITY_INSTANCE_H_ID_SEQ]) as [_ACTIVITY_INSTANCE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ROLCLM_I_S_U_TR] ON PIMS_ROLE_CLAIM INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ROLE_CLAIM_ID = deleted.ROLE_CLAIM_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ROLE_CLAIM + set "ROLE_CLAIM_ID" = inserted."ROLE_CLAIM_ID", + "ROLE_ID" = inserted."ROLE_ID", + "CLAIM_ID" = inserted."CLAIM_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ROLE_CLAIM + inner join inserted + on (PIMS_ROLE_CLAIM.ROLE_CLAIM_ID = inserted.ROLE_CLAIM_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTTMP_A_S_IUD_TR] ON PIMS_ACTIVITY_TEMPLATE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACTIVITY_TEMPLATE_HIST set END_DATE_HIST = @curr_date where ACTIVITY_TEMPLATE_ID in (select ACTIVITY_TEMPLATE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACTIVITY_TEMPLATE_HIST ([ACTIVITY_TEMPLATE_ID], [ACTIVITY_TEMPLATE_TYPE_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACTIVITY_TEMPLATE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACTIVITY_TEMPLATE_ID], [ACTIVITY_TEMPLATE_TYPE_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACTIVITY_TEMPLATE_H_ID_SEQ]) as [_ACTIVITY_TEMPLATE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SECDEP_I_S_U_TR] ON PIMS_SECURITY_DEPOSIT INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.SECURITY_DEPOSIT_ID = deleted.SECURITY_DEPOSIT_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_SECURITY_DEPOSIT + set "SECURITY_DEPOSIT_ID" = inserted."SECURITY_DEPOSIT_ID", + "LEASE_ID" = inserted."LEASE_ID", + "SECURITY_DEPOSIT_TYPE_CODE" = inserted."SECURITY_DEPOSIT_TYPE_CODE", + "OTHER_DEPOSIT_TYPE_DESC" = inserted."OTHER_DEPOSIT_TYPE_DESC", + "DESCRIPTION" = inserted."DESCRIPTION", + "AMOUNT_PAID" = inserted."AMOUNT_PAID", + "DEPOSIT_DATE" = inserted."DEPOSIT_DATE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_SECURITY_DEPOSIT + inner join inserted + on (PIMS_SECURITY_DEPOSIT.SECURITY_DEPOSIT_ID = inserted.SECURITY_DEPOSIT_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ADDRSS_A_S_IUD_TR] ON PIMS_ADDRESS FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ADDRESS_HIST set END_DATE_HIST = @curr_date where ADDRESS_ID in (select ADDRESS_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ADDRESS_HIST ([ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROVINCE_STATE_ID], [COUNTRY_ID], [STREET_ADDRESS_1], [STREET_ADDRESS_2], [STREET_ADDRESS_3], [MUNICIPALITY_NAME], [POSTAL_CODE], [OTHER_COUNTRY], [LATITUDE], [LONGITUDE], [COMMENT], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ADDRESS_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROVINCE_STATE_ID], [COUNTRY_ID], [STREET_ADDRESS_1], [STREET_ADDRESS_2], [STREET_ADDRESS_3], [MUNICIPALITY_NAME], [POSTAL_CODE], [OTHER_COUNTRY], [LATITUDE], [LONGITUDE], [COMMENT], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ADDRESS_H_ID_SEQ]) as [_ADDRESS_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SCDPHL_I_S_U_TR] ON PIMS_SECURITY_DEPOSIT_HOLDER INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.SECURITY_DEPOSIT_HOLDER_ID = deleted.SECURITY_DEPOSIT_HOLDER_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_SECURITY_DEPOSIT_HOLDER + set "SECURITY_DEPOSIT_HOLDER_ID" = inserted."SECURITY_DEPOSIT_HOLDER_ID", + "SECURITY_DEPOSIT_ID" = inserted."SECURITY_DEPOSIT_ID", + "PERSON_ID" = inserted."PERSON_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_SECURITY_DEPOSIT_HOLDER + inner join inserted + on (PIMS_SECURITY_DEPOSIT_HOLDER.SECURITY_DEPOSIT_HOLDER_ID = inserted.SECURITY_DEPOSIT_HOLDER_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CLMTYP_A_S_IUD_TR] ON PIMS_CLAIM FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_CLAIM_HIST set END_DATE_HIST = @curr_date where CLAIM_ID in (select CLAIM_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_CLAIM_HIST ([CLAIM_ID], [CLAIM_UID], [KEYCLOAK_ROLE_ID], [NAME], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _CLAIM_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [CLAIM_ID], [CLAIM_UID], [KEYCLOAK_ROLE_ID], [NAME], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_CLAIM_H_ID_SEQ]) as [_CLAIM_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SDRTRN_I_S_U_TR] ON PIMS_SECURITY_DEPOSIT_RETURN INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.SECURITY_DEPOSIT_RETURN_ID = deleted.SECURITY_DEPOSIT_RETURN_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_SECURITY_DEPOSIT_RETURN + set "SECURITY_DEPOSIT_RETURN_ID" = inserted."SECURITY_DEPOSIT_RETURN_ID", + "SECURITY_DEPOSIT_ID" = inserted."SECURITY_DEPOSIT_ID", + "TERMINATION_DATE" = inserted."TERMINATION_DATE", + "CLAIMS_AGAINST" = inserted."CLAIMS_AGAINST", + "RETURN_AMOUNT" = inserted."RETURN_AMOUNT", + "RETURN_DATE" = inserted."RETURN_DATE", + "INTEREST_PAID" = inserted."INTEREST_PAID", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_SECURITY_DEPOSIT_RETURN + inner join inserted + on (PIMS_SECURITY_DEPOSIT_RETURN.SECURITY_DEPOSIT_RETURN_ID = inserted.SECURITY_DEPOSIT_RETURN_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CNTMTH_A_S_IUD_TR] ON PIMS_CONTACT_METHOD FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_CONTACT_METHOD_HIST set END_DATE_HIST = @curr_date where CONTACT_METHOD_ID in (select CONTACT_METHOD_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_CONTACT_METHOD_HIST ([CONTACT_METHOD_ID], [CONTACT_METHOD_TYPE_CODE], [PERSON_ID], [ORGANIZATION_ID], [CONTACT_METHOD_VALUE], [IS_PREFERRED_METHOD], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _CONTACT_METHOD_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [CONTACT_METHOD_ID], [CONTACT_METHOD_TYPE_CODE], [PERSON_ID], [ORGANIZATION_ID], [CONTACT_METHOD_VALUE], [IS_PREFERRED_METHOD], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_CONTACT_METHOD_H_ID_SEQ]) as [_CONTACT_METHOD_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SCDPRH_I_S_U_TR] ON PIMS_SECURITY_DEPOSIT_RETURN_HOLDER INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.SECURITY_DEPOSIT_RETURN_HOLDER_ID = deleted.SECURITY_DEPOSIT_RETURN_HOLDER_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_SECURITY_DEPOSIT_RETURN_HOLDER + set "SECURITY_DEPOSIT_RETURN_HOLDER_ID" = inserted."SECURITY_DEPOSIT_RETURN_HOLDER_ID", + "SECURITY_DEPOSIT_RETURN_ID" = inserted."SECURITY_DEPOSIT_RETURN_ID", + "PERSON_ID" = inserted."PERSON_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_SECURITY_DEPOSIT_RETURN_HOLDER + inner join inserted + on (PIMS_SECURITY_DEPOSIT_RETURN_HOLDER.SECURITY_DEPOSIT_RETURN_HOLDER_ID = inserted.SECURITY_DEPOSIT_RETURN_HOLDER_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DOCMNT_A_S_IUD_TR] ON PIMS_DOCUMENT FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_DOCUMENT_HIST set END_DATE_HIST = @curr_date where DOCUMENT_ID in (select DOCUMENT_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_DOCUMENT_HIST ([DOCUMENT_ID], [DOCUMENT_TYPE_ID], [DOCUMENT_STATUS_TYPE_CODE], [FILE_NAME], [MAYAN_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _DOCUMENT_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [DOCUMENT_ID], [DOCUMENT_TYPE_ID], [DOCUMENT_STATUS_TYPE_CODE], [FILE_NAME], [MAYAN_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_DOCUMENT_H_ID_SEQ]) as [_DOCUMENT_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SECDPT_I_S_U_TR] ON PIMS_SECURITY_DEPOSIT_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.SECURITY_DEPOSIT_TYPE_CODE = deleted.SECURITY_DEPOSIT_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_SECURITY_DEPOSIT_TYPE + set "SECURITY_DEPOSIT_TYPE_CODE" = inserted."SECURITY_DEPOSIT_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_SECURITY_DEPOSIT_TYPE + inner join inserted + on (PIMS_SECURITY_DEPOSIT_TYPE.SECURITY_DEPOSIT_TYPE_CODE = inserted.SECURITY_DEPOSIT_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DOCTYP_A_S_IUD_TR] ON PIMS_DOCUMENT_TYP FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_DOCUMENT_TYP_HIST set END_DATE_HIST = @curr_date where DOCUMENT_TYPE_ID in (select DOCUMENT_TYPE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_DOCUMENT_TYP_HIST ([DOCUMENT_TYPE_ID], [MAYAN_ID], [DOCUMENT_TYPE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _DOCUMENT_TYP_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [DOCUMENT_TYPE_ID], [MAYAN_ID], [DOCUMENT_TYPE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_DOCUMENT_TYP_H_ID_SEQ]) as [_DOCUMENT_TYP_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_STAVBL_I_S_U_TR] ON PIMS_STATIC_VARIABLE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.STATIC_VARIABLE_NAME = deleted.STATIC_VARIABLE_NAME) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_STATIC_VARIABLE + set "STATIC_VARIABLE_NAME" = inserted."STATIC_VARIABLE_NAME", + "STATIC_VARIABLE_VALUE" = inserted."STATIC_VARIABLE_VALUE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_STATIC_VARIABLE + inner join inserted + on (PIMS_STATIC_VARIABLE.STATIC_VARIABLE_NAME = inserted.STATIC_VARIABLE_NAME); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_INSRNC_A_S_IUD_TR] ON PIMS_INSURANCE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_INSURANCE_HIST set END_DATE_HIST = @curr_date where INSURANCE_ID in (select INSURANCE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_INSURANCE_HIST ([INSURANCE_ID], [LEASE_ID], [INSURANCE_TYPE_CODE], [OTHER_INSURANCE_TYPE], [COVERAGE_DESCRIPTION], [COVERAGE_LIMIT], [IS_INSURANCE_IN_PLACE], [EXPIRY_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _INSURANCE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [INSURANCE_ID], [LEASE_ID], [INSURANCE_TYPE_CODE], [OTHER_INSURANCE_TYPE], [COVERAGE_DESCRIPTION], [COVERAGE_LIMIT], [IS_INSURANCE_IN_PLACE], [EXPIRY_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_INSURANCE_H_ID_SEQ]) as [_INSURANCE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SPDCLT_I_S_U_TR] ON PIMS_SURPLUS_DECLARATION_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.SURPLUS_DECLARATION_TYPE_CODE = deleted.SURPLUS_DECLARATION_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_SURPLUS_DECLARATION_TYPE + set "SURPLUS_DECLARATION_TYPE_CODE" = inserted."SURPLUS_DECLARATION_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_SURPLUS_DECLARATION_TYPE + inner join inserted + on (PIMS_SURPLUS_DECLARATION_TYPE.SURPLUS_DECLARATION_TYPE_CODE = inserted.SURPLUS_DECLARATION_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LEASE_A_S_IUD_TR] ON PIMS_LEASE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_LEASE_HIST set END_DATE_HIST = @curr_date where LEASE_ID in (select LEASE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_LEASE_HIST ([LEASE_ID], [LEASE_PAY_RVBL_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_STATUS_TYPE_CODE], [REGION_CODE], [L_FILE_NO], [TFA_FILE_NO], [PS_FILE_NO], [LEASE_CATEGORY_OTHER_DESC], [LEASE_PURPOSE_OTHER_DESC], [MOTI_CONTACT], [DOCUMENTATION_REFERENCE], [OTHER_LEASE_PROGRAM_TYPE], [OTHER_LEASE_LICENSE_TYPE], [OTHER_LEASE_PURPOSE_TYPE], [ORIG_START_DATE], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [RESPONSIBILITY_EFFECTIVE_DATE], [INSPECTION_DATE], [IS_SUBJECT_TO_RTA], [IS_COMM_BLDG], [IS_OTHER_IMPROVEMENT], [IS_EXPIRED], [HAS_PHYSICAL_FILE], [HAS_DIGITAL_FILE], [HAS_PHYSICIAL_LICENSE], [HAS_DIGITAL_LICENSE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _LEASE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [LEASE_ID], [LEASE_PAY_RVBL_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_STATUS_TYPE_CODE], [REGION_CODE], [L_FILE_NO], [TFA_FILE_NO], [PS_FILE_NO], [LEASE_CATEGORY_OTHER_DESC], [LEASE_PURPOSE_OTHER_DESC], [MOTI_CONTACT], [DOCUMENTATION_REFERENCE], [OTHER_LEASE_PROGRAM_TYPE], [OTHER_LEASE_LICENSE_TYPE], [OTHER_LEASE_PURPOSE_TYPE], [ORIG_START_DATE], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [RESPONSIBILITY_EFFECTIVE_DATE], [INSPECTION_DATE], [IS_SUBJECT_TO_RTA], [IS_COMM_BLDG], [IS_OTHER_IMPROVEMENT], [IS_EXPIRED], [HAS_PHYSICAL_FILE], [HAS_DIGITAL_FILE], [HAS_PHYSICIAL_LICENSE], [HAS_DIGITAL_LICENSE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_LEASE_H_ID_SEQ]) as [_LEASE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SRVPLT_I_S_U_TR] ON PIMS_SURVEY_PLAN_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.SURVEY_PLAN_TYPE_CODE = deleted.SURVEY_PLAN_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_SURVEY_PLAN_TYPE + set "SURVEY_PLAN_TYPE_CODE" = inserted."SURVEY_PLAN_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_SURVEY_PLAN_TYPE + inner join inserted + on (PIMS_SURVEY_PLAN_TYPE.SURVEY_PLAN_TYPE_CODE = inserted.SURVEY_PLAN_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPYMT_A_S_IUD_TR] ON PIMS_LEASE_PAYMENT FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_LEASE_PAYMENT_HIST set END_DATE_HIST = @curr_date where LEASE_PAYMENT_ID in (select LEASE_PAYMENT_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_LEASE_PAYMENT_HIST ([LEASE_PAYMENT_ID], [LEASE_TERM_ID], [LEASE_PAYMENT_METHOD_TYPE_CODE], [LEASE_PAYMENT_STATUS_TYPE_CODE], [PAYMENT_RECEIVED_DATE], [PAYMENT_AMOUNT_PRE_TAX], [PAYMENT_AMOUNT_PST], [PAYMENT_AMOUNT_GST], [PAYMENT_AMOUNT_TOTAL], [NOTE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _LEASE_PAYMENT_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [LEASE_PAYMENT_ID], [LEASE_TERM_ID], [LEASE_PAYMENT_METHOD_TYPE_CODE], [LEASE_PAYMENT_STATUS_TYPE_CODE], [PAYMENT_RECEIVED_DATE], [PAYMENT_AMOUNT_PRE_TAX], [PAYMENT_AMOUNT_PST], [PAYMENT_AMOUNT_GST], [PAYMENT_AMOUNT_TOTAL], [NOTE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_LEASE_PAYMENT_H_ID_SEQ]) as [_LEASE_PAYMENT_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_TENNTX_I_S_U_TR] ON PIMS_TENANT INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.TENANT_ID = deleted.TENANT_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_TENANT + set "TENANT_ID" = inserted."TENANT_ID", + "CODE" = inserted."CODE", + "NAME" = inserted."NAME", + "DESCRIPTION" = inserted."DESCRIPTION", + "SETTINGS" = inserted."SETTINGS", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_TENANT + inner join inserted + on (PIMS_TENANT.TENANT_ID = inserted.TENANT_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSTERM_A_S_IUD_TR] ON PIMS_LEASE_TERM FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_LEASE_TERM_HIST set END_DATE_HIST = @curr_date where LEASE_TERM_ID in (select LEASE_TERM_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_LEASE_TERM_HIST ([LEASE_TERM_ID], [LEASE_ID], [LEASE_TERM_STATUS_TYPE_CODE], [LEASE_PMT_FREQ_TYPE_CODE], [TERM_START_DATE], [TERM_EXPIRY_DATE], [TERM_RENEWAL_DATE], [PAYMENT AMOUNT], [PAYMENT_DUE_DATE], [PAYMENT_NOTE], [IS_GST_ELIGIBLE], [GST_AMOUNT], [IS_TERM_EXERCISED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _LEASE_TERM_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [LEASE_TERM_ID], [LEASE_ID], [LEASE_TERM_STATUS_TYPE_CODE], [LEASE_PMT_FREQ_TYPE_CODE], [TERM_START_DATE], [TERM_EXPIRY_DATE], [TERM_RENEWAL_DATE], [PAYMENT AMOUNT], [PAYMENT_DUE_DATE], [PAYMENT_NOTE], [IS_GST_ELIGIBLE], [GST_AMOUNT], [IS_TERM_EXERCISED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_LEASE_TERM_H_ID_SEQ]) as [_LEASE_TERM_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USER_I_S_U_TR] ON PIMS_USER INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.USER_ID = deleted.USER_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_USER + set "USER_ID" = inserted."USER_ID", + "PERSON_ID" = inserted."PERSON_ID", + "BUSINESS_IDENTIFIER_VALUE" = inserted."BUSINESS_IDENTIFIER_VALUE", + "GUID_IDENTIFIER_VALUE" = inserted."GUID_IDENTIFIER_VALUE", + "POSITION" = inserted."POSITION", + "NOTE" = inserted."NOTE", + "LAST_LOGIN" = inserted."LAST_LOGIN", + "APPROVED_BY_ID" = inserted."APPROVED_BY_ID", + "ISSUE_DATE" = inserted."ISSUE_DATE", + "EXPIRY_DATE" = inserted."EXPIRY_DATE", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_USER + inner join inserted + on (PIMS_USER.USER_ID = inserted.USER_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_NOTE_A_S_IUD_TR] ON PIMS_NOTE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_NOTE_HIST set END_DATE_HIST = @curr_date where NOTE_ID in (select NOTE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_NOTE_HIST ([NOTE_ID], [NOTE_TXT], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _NOTE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [NOTE_ID], [NOTE_TXT], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_NOTE_H_ID_SEQ]) as [_NOTE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USRORG_I_S_U_TR] ON PIMS_USER_ORGANIZATION INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.USER_ORGANIZATION_ID = deleted.USER_ORGANIZATION_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_USER_ORGANIZATION + set "USER_ORGANIZATION_ID" = inserted."USER_ORGANIZATION_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "USER_ID" = inserted."USER_ID", + "ROLE_ID" = inserted."ROLE_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_USER_ORGANIZATION + inner join inserted + on (PIMS_USER_ORGANIZATION.USER_ORGANIZATION_ID = inserted.USER_ORGANIZATION_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORG_A_S_IUD_TR] ON PIMS_ORGANIZATION FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ORGANIZATION_HIST set END_DATE_HIST = @curr_date where ORGANIZATION_ID in (select ORGANIZATION_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ORGANIZATION_HIST ([ORGANIZATION_ID], [PRNT_ORGANIZATION_ID], [REGION_CODE], [DISTRICT_CODE], [ORGANIZATION_TYPE_CODE], [ORG_IDENTIFIER_TYPE_CODE], [ORGANIZATION_IDENTIFIER], [ORGANIZATION_NAME], [ORGANIZATION_ALIAS], [INCORPORATION_NUMBER], [WEBSITE], [COMMENT], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ORGANIZATION_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ORGANIZATION_ID], [PRNT_ORGANIZATION_ID], [REGION_CODE], [DISTRICT_CODE], [ORGANIZATION_TYPE_CODE], [ORG_IDENTIFIER_TYPE_CODE], [ORGANIZATION_IDENTIFIER], [ORGANIZATION_NAME], [ORGANIZATION_ALIAS], [INCORPORATION_NUMBER], [WEBSITE], [COMMENT], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ORGANIZATION_H_ID_SEQ]) as [_ORGANIZATION_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USERRL_I_S_U_TR] ON PIMS_USER_ROLE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.USER_ROLE_ID = deleted.USER_ROLE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_USER_ROLE + set "USER_ROLE_ID" = inserted."USER_ROLE_ID", + "USER_ID" = inserted."USER_ID", + "ROLE_ID" = inserted."ROLE_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_USER_ROLE + inner join inserted + on (PIMS_USER_ROLE.USER_ROLE_ID = inserted.USER_ROLE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORGADD_A_S_IUD_TR] ON PIMS_ORGANIZATION_ADDRESS FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ORGANIZATION_ADDRESS_HIST set END_DATE_HIST = @curr_date where ORGANIZATION_ADDRESS_ID in (select ORGANIZATION_ADDRESS_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ORGANIZATION_ADDRESS_HIST ([ORGANIZATION_ADDRESS_ID], [ORGANIZATION_ID], [ADDRESS_ID], [ADDRESS_USAGE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ORGANIZATION_ADDRESS_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ORGANIZATION_ADDRESS_ID], [ORGANIZATION_ID], [ADDRESS_ID], [ADDRESS_USAGE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ORGANIZATION_ADDRESS_H_ID_SEQ]) as [_ORGANIZATION_ADDRESS_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_VOLUTY_I_S_U_TR] ON PIMS_VOLUME_UNIT_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.VOLUME_UNIT_TYPE_CODE = deleted.VOLUME_UNIT_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_VOLUME_UNIT_TYPE + set "VOLUME_UNIT_TYPE_CODE" = inserted."VOLUME_UNIT_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_VOLUME_UNIT_TYPE + inner join inserted + on (PIMS_VOLUME_UNIT_TYPE.VOLUME_UNIT_TYPE_CODE = inserted.VOLUME_UNIT_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERADD_A_S_IUD_TR] ON PIMS_PERSON_ADDRESS FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PERSON_ADDRESS_HIST set END_DATE_HIST = @curr_date where PERSON_ADDRESS_ID in (select PERSON_ADDRESS_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PERSON_ADDRESS_HIST ([PERSON_ADDRESS_ID], [PERSON_ID], [ADDRESS_ID], [ADDRESS_USAGE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PERSON_ADDRESS_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PERSON_ADDRESS_ID], [PERSON_ID], [ADDRESS_ID], [ADDRESS_USAGE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PERSON_ADDRESS_H_ID_SEQ]) as [_PERSON_ADDRESS_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRVOLT_I_S_U_TR] ON PIMS_VOLUMETRIC_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.VOLUMETRIC_TYPE_CODE = deleted.VOLUMETRIC_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_VOLUMETRIC_TYPE + set "VOLUMETRIC_TYPE_CODE" = inserted."VOLUMETRIC_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_VOLUMETRIC_TYPE + inner join inserted + on (PIMS_VOLUMETRIC_TYPE.VOLUMETRIC_TYPE_CODE = inserted.VOLUMETRIC_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERORG_A_S_IUD_TR] ON PIMS_PERSON_ORGANIZATION FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PERSON_ORGANIZATION_HIST set END_DATE_HIST = @curr_date where PERSON_ORGANIZATION_ID in (select PERSON_ORGANIZATION_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PERSON_ORGANIZATION_HIST ([PERSON_ORGANIZATION_ID], [PERSON_ID], [ORGANIZATION_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PERSON_ORGANIZATION_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PERSON_ORGANIZATION_ID], [PERSON_ID], [ORGANIZATION_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PERSON_ORGANIZATION_H_ID_SEQ]) as [_PERSON_ORGANIZATION_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACRQST_I_S_I_TR] ON PIMS_ACCESS_REQUEST INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACCESS_REQUEST ("ACCESS_REQUEST_ID", + "USER_ID", + "ROLE_ID", + "ACCESS_REQUEST_STATUS_TYPE_CODE", + "REGION_CODE", + "NOTE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACCESS_REQUEST_ID", + "USER_ID", + "ROLE_ID", + "ACCESS_REQUEST_STATUS_TYPE_CODE", + "REGION_CODE", + "NOTE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERSON_A_S_IUD_TR] ON PIMS_PERSON FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PERSON_HIST set END_DATE_HIST = @curr_date where PERSON_ID in (select PERSON_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PERSON_HIST ([PERSON_ID], [SURNAME], [FIRST_NAME], [MIDDLE_NAMES], [NAME_SUFFIX], [PREFERRED_NAME], [BIRTH_DATE], [COMMENT], [ADDRESS_COMMENT], [USE_ORGANIZATION_ADDRESS], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PERSON_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PERSON_ID], [SURNAME], [FIRST_NAME], [MIDDLE_NAMES], [NAME_SUFFIX], [PREFERRED_NAME], [BIRTH_DATE], [COMMENT], [ADDRESS_COMMENT], [USE_ORGANIZATION_ADDRESS], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PERSON_H_ID_SEQ]) as [_PERSON_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACRQOR_I_S_I_TR] ON PIMS_ACCESS_REQUEST_ORGANIZATION INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACCESS_REQUEST_ORGANIZATION ("ACCESS_REQUEST_ORGANIZATION_ID", + "ORGANIZATION_ID", + "ACCESS_REQUEST_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACCESS_REQUEST_ORGANIZATION_ID", + "ORGANIZATION_ID", + "ACCESS_REQUEST_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PIMPRV_A_S_IUD_TR] ON PIMS_PROPERTY_IMPROVEMENT FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_IMPROVEMENT_HIST set END_DATE_HIST = @curr_date where PROPERTY_IMPROVEMENT_ID in (select PROPERTY_IMPROVEMENT_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_IMPROVEMENT_HIST ([PROPERTY_IMPROVEMENT_ID], [LEASE_ID], [PROPERTY_IMPROVEMENT_TYPE_CODE], [IMPROVEMENT_DESCRIPTION], [STRUCTURE_SIZE], [ADDRESS], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_IMPROVEMENT_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_IMPROVEMENT_ID], [LEASE_ID], [PROPERTY_IMPROVEMENT_TYPE_CODE], [IMPROVEMENT_DESCRIPTION], [STRUCTURE_SIZE], [ADDRESS], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_IMPROVEMENT_H_ID_SEQ]) as [_PROPERTY_IMPROVEMENT_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ARQSTT_I_S_I_TR] ON PIMS_ACCESS_REQUEST_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACCESS_REQUEST_STATUS_TYPE ("ACCESS_REQUEST_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACCESS_REQUEST_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRACQF_A_S_IUD_TR] ON PIMS_PROPERTY_ACQUISITION_FILE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_ACQUISITION_FILE_HIST set END_DATE_HIST = @curr_date where PROPERTY_ACQUISITION_FILE_ID in (select PROPERTY_ACQUISITION_FILE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_ACQUISITION_FILE_HIST ([PROPERTY_ACQUISITION_FILE_ID], [ACQUISITION_FILE_ID], [PROPERTY_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_ACQUISITION_FILE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_ACQUISITION_FILE_ID], [ACQUISITION_FILE_ID], [PROPERTY_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_H_ID_SEQ]) as [_PROPERTY_ACQUISITION_FILE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_AQFPPT_I_S_I_TR] ON PIMS_ACQ_FL_PERSON_PROFILE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQ_FL_PERSON_PROFILE_TYPE ("ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PROPLS_A_S_IUD_TR] ON PIMS_PROPERTY_LEASE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_LEASE_HIST set END_DATE_HIST = @curr_date where PROPERTY_LEASE_ID in (select PROPERTY_LEASE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_LEASE_HIST ([PROPERTY_LEASE_ID], [PROPERTY_ID], [LEASE_ID], [AREA_UNIT_TYPE_CODE], [LEASE_AREA], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_LEASE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_LEASE_ID], [PROPERTY_ID], [LEASE_ID], [AREA_UNIT_TYPE_CODE], [LEASE_AREA], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_LEASE_H_ID_SEQ]) as [_PROPERTY_LEASE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQPFS_I_S_I_TR] ON PIMS_ACQ_PHYS_FILE_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQ_PHYS_FILE_STATUS_TYPE ("ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPEVL_A_S_IUD_TR] ON PIMS_PROPERTY_EVALUATION FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_EVALUATION_HIST set END_DATE_HIST = @curr_date where PROPERTY_EVALUATION_ID in (select PROPERTY_EVALUATION_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_EVALUATION_HIST ([PROPERTY_EVALUATION_ID], [PROPERTY_ID], [EVALUATION_DATE], [KEY], [VALUE], [NOTE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_EVALUATION_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_EVALUATION_ID], [PROPERTY_ID], [EVALUATION_DATE], [KEY], [VALUE], [NOTE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_EVALUATION_H_ID_SEQ]) as [_PROPERTY_EVALUATION_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQAIN_I_S_I_TR] ON PIMS_ACQUISITION_ACTIVITY_INSTANCE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_ACTIVITY_INSTANCE ("ACQUISITION_ACTIVITY_INSTANCE_ID", + "ACQUISITION_FILE_ID", + "ACTIVITY_INSTANCE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USER_DIRECTORY", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACQUISITION_ACTIVITY_INSTANCE_ID", + "ACQUISITION_FILE_ID", + "ACTIVITY_INSTANCE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USER_DIRECTORY", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPORG_A_S_IUD_TR] ON PIMS_PROPERTY_ORGANIZATION FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_ORGANIZATION_HIST set END_DATE_HIST = @curr_date where PROPERTY_ORGANIZATION_ID in (select PROPERTY_ORGANIZATION_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_ORGANIZATION_HIST ([PROPERTY_ORGANIZATION_ID], [PROPERTY_ID], [ORGANIZATION_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], [IS_DISABLED], _PROPERTY_ORGANIZATION_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_ORGANIZATION_ID], [PROPERTY_ID], [ORGANIZATION_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], [IS_DISABLED], (next value for [dbo].[PIMS_PROPERTY_ORGANIZATION_H_ID_SEQ]) as [_PROPERTY_ORGANIZATION_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQNFL_I_S_I_TR] ON PIMS_ACQUISITION_FILE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_FILE ("ACQUISITION_FILE_ID", + "ACQUISITION_FILE_STATUS_TYPE_CODE", + "ACQUISITION_TYPE_CODE", + "ACQUISITION_FUNDING_TYPE_CODE", + "ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "MINISTRY_PROJECT_NUMBER", + "MINISTRY_PROJECT_NAME", + "CPS_PRODUCT_CODE", + "FILE_NAME", + "FILE_NUMBER", + "REGION_CODE", + "FUNDING_OTHER", + "ASSIGNED_DATE", + "DELIVERY_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACQUISITION_FILE_ID", + "ACQUISITION_FILE_STATUS_TYPE_CODE", + "ACQUISITION_TYPE_CODE", + "ACQUISITION_FUNDING_TYPE_CODE", + "ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "MINISTRY_PROJECT_NUMBER", + "MINISTRY_PROJECT_NAME", + "CPS_PRODUCT_CODE", + "FILE_NAME", + "FILE_NUMBER", + "REGION_CODE", + "FUNDING_OTHER", + "ASSIGNED_DATE", + "DELIVERY_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRSF_A_S_IUD_TR] ON PIMS_PROPERTY_PROPERTY_SERVICE_FILE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_PROPERTY_SERVICE_FILE_HIST set END_DATE_HIST = @curr_date where PROPERTY_PROPERTY_SERVICE_FILE_ID in (select PROPERTY_PROPERTY_SERVICE_FILE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_PROPERTY_SERVICE_FILE_HIST ([PROPERTY_PROPERTY_SERVICE_FILE_ID], [PROPERTY_ID], [PROPERTY_SERVICE_FILE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_PROPERTY_SERVICE_FILE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_PROPERTY_SERVICE_FILE_ID], [PROPERTY_ID], [PROPERTY_SERVICE_FILE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE_H_ID_SEQ]) as [_PROPERTY_PROPERTY_SERVICE_FILE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQPER_I_S_I_TR] ON PIMS_ACQUISITION_FILE_PERSON INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_FILE_PERSON ("ACQUISITION_FILE_PERSON_ID", + "ACQUISITION_FILE_ID", + "PERSON_ID", + "ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACQUISITION_FILE_PERSON_ID", + "ACQUISITION_FILE_ID", + "PERSON_ID", + "ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRTY_A_S_IUD_TR] ON PIMS_PROPERTY FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_HIST set END_DATE_HIST = @curr_date where PROPERTY_ID in (select PROPERTY_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_HIST ([PROPERTY_ID], [PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [VOLUMETRIC_TYPE_CODE], [VOLUME_UNIT_TYPE_CODE], [PPH_STATUS_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [FILE_NUMBER], [FILE_NUMBER_SUFFIX], [LAND_AREA], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [MUNICIPAL_ZONING], [IS_VOLUMETRIC_PARCEL], [VOLUMETRIC_MEASUREMENT], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [IS_PROVINCIAL_PUBLIC_HWY], [PPH_STATUS_UPDATE_USERID], [PPH_STATUS_UPDATE_TIMESTAMP], [PPH_STATUS_UPDATE_USER_GUID], [IS_RWY_BELT_DOM_PATENT], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_ID], [PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [VOLUMETRIC_TYPE_CODE], [VOLUME_UNIT_TYPE_CODE], [PPH_STATUS_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [FILE_NUMBER], [FILE_NUMBER_SUFFIX], [LAND_AREA], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [MUNICIPAL_ZONING], [IS_VOLUMETRIC_PARCEL], [VOLUMETRIC_MEASUREMENT], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [IS_PROVINCIAL_PUBLIC_HWY], [PPH_STATUS_UPDATE_USERID], [PPH_STATUS_UPDATE_TIMESTAMP], [PPH_STATUS_UPDATE_USER_GUID], [IS_RWY_BELT_DOM_PATENT], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_H_ID_SEQ]) as [_PROPERTY_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQFST_I_S_I_TR] ON PIMS_ACQUISITION_FILE_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_FILE_STATUS_TYPE ("ACQUISITION_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQUISITION_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPSVC_A_S_IUD_TR] ON PIMS_PROPERTY_SERVICE_FILE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_SERVICE_FILE_HIST set END_DATE_HIST = @curr_date where PROPERTY_SERVICE_FILE_ID in (select PROPERTY_SERVICE_FILE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_SERVICE_FILE_HIST ([PROPERTY_SERVICE_FILE_ID], [PROPERTY_SERVICE_FILE_TYPE_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_SERVICE_FILE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_SERVICE_FILE_ID], [PROPERTY_SERVICE_FILE_TYPE_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_SERVICE_FILE_H_ID_SEQ]) as [_PROPERTY_SERVICE_FILE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQFTY_I_S_I_TR] ON PIMS_ACQUISITION_FUNDING_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_FUNDING_TYPE ("ACQUISITION_FUNDING_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQUISITION_FUNDING_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPTAX_A_S_IUD_TR] ON PIMS_PROPERTY_TAX FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_TAX_HIST set END_DATE_HIST = @curr_date where PROPERTY_TAX_ID in (select PROPERTY_TAX_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_TAX_HIST ([PROPERTY_TAX_ID], [PROPERTY_ID], [PROPERTY_TAX_REMIT_TYPE_CODE], [TAX_FOLIO_NO], [PAYMENT_AMOUNT], [LAST_PAYMENT_DATE], [PAYMENT_NOTES], [BCTFA_NOTIFICATION_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_TAX_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_TAX_ID], [PROPERTY_ID], [PROPERTY_TAX_REMIT_TYPE_CODE], [TAX_FOLIO_NO], [PAYMENT_AMOUNT], [LAST_PAYMENT_DATE], [PAYMENT_NOTES], [BCTFA_NOTIFICATION_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_TAX_H_ID_SEQ]) as [_PROPERTY_TAX_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQOWN_I_S_I_TR] ON PIMS_ACQUISITION_OWNER INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_OWNER ("ACQUISITION_OWNER_ID", + "ACQUISITION_FILE_ID", + "OWNER_NAME", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACQUISITION_OWNER_ID", + "ACQUISITION_FILE_ID", + "OWNER_NAME", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRSCRC_A_S_IUD_TR] ON PIMS_PROPERTY_RESEARCH_FILE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_PROPERTY_RESEARCH_FILE_HIST set END_DATE_HIST = @curr_date where PROPERTY_RESEARCH_FILE_ID in (select PROPERTY_RESEARCH_FILE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_PROPERTY_RESEARCH_FILE_HIST ([PROPERTY_RESEARCH_FILE_ID], [PROPERTY_ID], [RESEARCH_FILE_ID], [PROPERTY_NAME], [DISPLAY_ORDER], [IS_DISABLED], [IS_LEGAL_OPINION_REQUIRED], [IS_LEGAL_OPINION_OBTAINED], [DOCUMENT_REFERENCE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _PROPERTY_RESEARCH_FILE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [PROPERTY_RESEARCH_FILE_ID], [PROPERTY_ID], [RESEARCH_FILE_ID], [PROPERTY_NAME], [DISPLAY_ORDER], [IS_DISABLED], [IS_LEGAL_OPINION_REQUIRED], [IS_LEGAL_OPINION_OBTAINED], [DOCUMENT_REFERENCE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_PROPERTY_RESEARCH_FILE_H_ID_SEQ]) as [_PROPERTY_RESEARCH_FILE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQTYP_I_S_I_TR] ON PIMS_ACQUISITION_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACQUISITION_TYPE ("ACQUISITION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACQUISITION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RESRCH_A_S_IUD_TR] ON PIMS_RESEARCH_FILE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_RESEARCH_FILE_HIST set END_DATE_HIST = @curr_date where RESEARCH_FILE_ID in (select RESEARCH_FILE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_RESEARCH_FILE_HIST ([RESEARCH_FILE_ID], [RESEARCH_FILE_STATUS_TYPE_CODE], [REQUEST_SOURCE_TYPE_CODE], [REQUESTOR_NAME], [REQUESTOR_ORGANIZATION], [NAME], [RFILE_NUMBER], [REQUEST_DATE], [REQUEST_SOURCE_DESCRIPTION], [IS_EXPROPRIATION], [RESEARCH_COMPLETION_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _RESEARCH_FILE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [RESEARCH_FILE_ID], [RESEARCH_FILE_STATUS_TYPE_CODE], [REQUEST_SOURCE_TYPE_CODE], [REQUESTOR_NAME], [REQUESTOR_ORGANIZATION], [NAME], [RFILE_NUMBER], [REQUEST_DATE], [REQUEST_SOURCE_DESCRIPTION], [IS_EXPROPRIATION], [RESEARCH_COMPLETION_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_RESEARCH_FILE_H_ID_SEQ]) as [_RESEARCH_FILE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTINS_I_S_I_TR] ON PIMS_ACTIVITY_INSTANCE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_INSTANCE ("ACTIVITY_INSTANCE_ID", + "ACTIVITY_TEMPLATE_ID", + "ACTIVITY_DATA_JSON", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACTIVITY_INSTANCE_ID", + "ACTIVITY_TEMPLATE_ID", + "ACTIVITY_DATA_JSON", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RGNUSR_A_S_IUD_TR] ON PIMS_REGION_USER FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_REGION_USER_HIST set END_DATE_HIST = @curr_date where REGION_USER_ID in (select REGION_USER_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_REGION_USER_HIST ([REGION_USER_ID], [REGION_CODE], [USER_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _REGION_USER_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [REGION_USER_ID], [REGION_CODE], [USER_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_REGION_USER_H_ID_SEQ]) as [_REGION_USER_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTDOC_I_S_I_TR] ON PIMS_ACTIVITY_INSTANCE_DOCUMENT INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_INSTANCE_DOCUMENT ("ACTIVITY_INSTANCE_DOCUMENT_ID", + "ACTIVITY_INSTANCE_ID", + "DOCUMENT_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACTIVITY_INSTANCE_DOCUMENT_ID", + "ACTIVITY_INSTANCE_ID", + "DOCUMENT_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ROLCLM_A_S_IUD_TR] ON PIMS_ROLE_CLAIM FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ROLE_CLAIM_HIST set END_DATE_HIST = @curr_date where ROLE_CLAIM_ID in (select ROLE_CLAIM_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ROLE_CLAIM_HIST ([ROLE_CLAIM_ID], [ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ROLE_CLAIM_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ROLE_CLAIM_ID], [ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ROLE_CLAIM_H_ID_SEQ]) as [_ROLE_CLAIM_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTINN_I_S_I_TR] ON PIMS_ACTIVITY_INSTANCE_NOTE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_INSTANCE_NOTE ("PIMS_ACTIVITY_INSTANCE_NOTE_ID", + "ACTIVITY_INSTANCE_ID", + "NOTE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PIMS_ACTIVITY_INSTANCE_NOTE_ID", + "ACTIVITY_INSTANCE_ID", + "NOTE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ROLE_A_S_IUD_TR] ON PIMS_ROLE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ROLE_HIST set END_DATE_HIST = @curr_date where ROLE_ID in (select ROLE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ROLE_HIST ([ROLE_ID], [ROLE_UID], [KEYCLOAK_GROUP_ID], [NAME], [DESCRIPTION], [IS_PUBLIC], [IS_DISABLED], [SORT_ORDER], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ROLE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ROLE_ID], [ROLE_UID], [KEYCLOAK_GROUP_ID], [NAME], [DESCRIPTION], [IS_PUBLIC], [IS_DISABLED], [SORT_ORDER], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ROLE_H_ID_SEQ]) as [_ROLE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTTMP_I_S_I_TR] ON PIMS_ACTIVITY_TEMPLATE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_TEMPLATE ("ACTIVITY_TEMPLATE_ID", + "ACTIVITY_TEMPLATE_TYPE_CODE", + "ACTIVITY_TEMPLATE_JSON", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ACTIVITY_TEMPLATE_ID", + "ACTIVITY_TEMPLATE_TYPE_CODE", + "ACTIVITY_TEMPLATE_JSON", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RSFLPR_A_S_IUD_TR] ON PIMS_RESEARCH_FILE_PURPOSE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_RESEARCH_FILE_PURPOSE_HIST set END_DATE_HIST = @curr_date where RESEARCH_FILE_PURPOSE_ID in (select RESEARCH_FILE_PURPOSE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_RESEARCH_FILE_PURPOSE_HIST ([RESEARCH_FILE_PURPOSE_ID], [RESEARCH_FILE_ID], [RESEARCH_PURPOSE_TYPE_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _RESEARCH_FILE_PURPOSE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [RESEARCH_FILE_PURPOSE_ID], [RESEARCH_FILE_ID], [RESEARCH_PURPOSE_TYPE_CODE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_RESEARCH_FILE_PURPOSE_H_ID_SEQ]) as [_RESEARCH_FILE_PURPOSE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTTTY_I_S_I_TR] ON PIMS_ACTIVITY_TEMPLATE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ACTIVITY_TEMPLATE_TYPE ("ACTIVITY_TEMPLATE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ACTIVITY_TEMPLATE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SCDPHL_A_S_IUD_TR] ON PIMS_SECURITY_DEPOSIT_HOLDER FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_SECURITY_DEPOSIT_HOLDER_HIST set END_DATE_HIST = @curr_date where SECURITY_DEPOSIT_HOLDER_ID in (select SECURITY_DEPOSIT_HOLDER_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_SECURITY_DEPOSIT_HOLDER_HIST ([SECURITY_DEPOSIT_HOLDER_ID], [SECURITY_DEPOSIT_ID], [PERSON_ID], [ORGANIZATION_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _SECURITY_DEPOSIT_HOLDER_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [SECURITY_DEPOSIT_HOLDER_ID], [SECURITY_DEPOSIT_ID], [PERSON_ID], [ORGANIZATION_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER_H_ID_SEQ]) as [_SECURITY_DEPOSIT_HOLDER_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ADDRSS_I_S_I_TR] ON PIMS_ADDRESS INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ADDRESS ("ADDRESS_ID", + "REGION_CODE", + "DISTRICT_CODE", + "PROVINCE_STATE_ID", + "COUNTRY_ID", + "STREET_ADDRESS_1", + "STREET_ADDRESS_2", + "STREET_ADDRESS_3", + "MUNICIPALITY_NAME", + "POSTAL_CODE", + "OTHER_COUNTRY", + "LATITUDE", + "LONGITUDE", + "COMMENT", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ADDRESS_ID", + "REGION_CODE", + "DISTRICT_CODE", + "PROVINCE_STATE_ID", + "COUNTRY_ID", + "STREET_ADDRESS_1", + "STREET_ADDRESS_2", + "STREET_ADDRESS_3", + "MUNICIPALITY_NAME", + "POSTAL_CODE", + "OTHER_COUNTRY", + "LATITUDE", + "LONGITUDE", + "COMMENT", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SCDPRH_A_S_IUD_TR] ON PIMS_SECURITY_DEPOSIT_RETURN_HOLDER FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_HIST set END_DATE_HIST = @curr_date where SECURITY_DEPOSIT_RETURN_HOLDER_ID in (select SECURITY_DEPOSIT_RETURN_HOLDER_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_HIST ([SECURITY_DEPOSIT_RETURN_HOLDER_ID], [SECURITY_DEPOSIT_RETURN_ID], [PERSON_ID], [ORGANIZATION_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _SECURITY_DEPOSIT_RETURN_HOLDER_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [SECURITY_DEPOSIT_RETURN_HOLDER_ID], [SECURITY_DEPOSIT_RETURN_ID], [PERSON_ID], [ORGANIZATION_ID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_H_ID_SEQ]) as [_SECURITY_DEPOSIT_RETURN_HOLDER_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] ON PIMS_ADDRESS_USAGE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ADDRESS_USAGE_TYPE ("ADDRESS_USAGE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ADDRESS_USAGE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SDRTRN_A_S_IUD_TR] ON PIMS_SECURITY_DEPOSIT_RETURN FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_SECURITY_DEPOSIT_RETURN_HIST set END_DATE_HIST = @curr_date where SECURITY_DEPOSIT_RETURN_ID in (select SECURITY_DEPOSIT_RETURN_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_SECURITY_DEPOSIT_RETURN_HIST ([SECURITY_DEPOSIT_RETURN_ID], [SECURITY_DEPOSIT_ID], [TERMINATION_DATE], [CLAIMS_AGAINST], [RETURN_AMOUNT], [RETURN_DATE], [INTEREST_PAID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _SECURITY_DEPOSIT_RETURN_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [SECURITY_DEPOSIT_RETURN_ID], [SECURITY_DEPOSIT_ID], [TERMINATION_DATE], [CLAIMS_AGAINST], [RETURN_AMOUNT], [RETURN_DATE], [INTEREST_PAID], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_H_ID_SEQ]) as [_SECURITY_DEPOSIT_RETURN_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ARUNIT_I_S_I_TR] ON PIMS_AREA_UNIT_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_AREA_UNIT_TYPE ("AREA_UNIT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "AREA_UNIT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SECDEP_A_S_IUD_TR] ON PIMS_SECURITY_DEPOSIT FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_SECURITY_DEPOSIT_HIST set END_DATE_HIST = @curr_date where SECURITY_DEPOSIT_ID in (select SECURITY_DEPOSIT_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_SECURITY_DEPOSIT_HIST ([SECURITY_DEPOSIT_ID], [LEASE_ID], [SECURITY_DEPOSIT_TYPE_CODE], [OTHER_DEPOSIT_TYPE_DESC], [DESCRIPTION], [AMOUNT_PAID], [DEPOSIT_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _SECURITY_DEPOSIT_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [SECURITY_DEPOSIT_ID], [LEASE_ID], [SECURITY_DEPOSIT_TYPE_CODE], [OTHER_DEPOSIT_TYPE_DESC], [DESCRIPTION], [AMOUNT_PAID], [DEPOSIT_DATE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_SECURITY_DEPOSIT_H_ID_SEQ]) as [_SECURITY_DEPOSIT_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CLMTYP_I_S_I_TR] ON PIMS_CLAIM INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_CLAIM ("CLAIM_ID", + "CLAIM_UID", + "KEYCLOAK_ROLE_ID", + "NAME", + "DESCRIPTION", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "CLAIM_ID", + "CLAIM_UID", + "KEYCLOAK_ROLE_ID", + "NAME", + "DESCRIPTION", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_STAVBL_A_S_IUD_TR] ON PIMS_STATIC_VARIABLE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_STATIC_VARIABLE_HIST set END_DATE_HIST = @curr_date where STATIC_VARIABLE_NAME in (select STATIC_VARIABLE_NAME from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_STATIC_VARIABLE_HIST ([STATIC_VARIABLE_NAME], [STATIC_VARIABLE_VALUE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _STATIC_VARIABLE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [STATIC_VARIABLE_NAME], [STATIC_VARIABLE_VALUE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_STATIC_VARIABLE_H_ID_SEQ]) as [_STATIC_VARIABLE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CNTMTH_I_S_I_TR] ON PIMS_CONTACT_METHOD INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_CONTACT_METHOD ("CONTACT_METHOD_ID", + "CONTACT_METHOD_TYPE_CODE", + "PERSON_ID", + "ORGANIZATION_ID", + "CONTACT_METHOD_VALUE", + "IS_PREFERRED_METHOD", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "CONTACT_METHOD_ID", + "CONTACT_METHOD_TYPE_CODE", + "PERSON_ID", + "ORGANIZATION_ID", + "CONTACT_METHOD_VALUE", + "IS_PREFERRED_METHOD", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_TENANT_A_S_IUD_TR] ON PIMS_LEASE_TENANT FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_LEASE_TENANT_HIST set END_DATE_HIST = @curr_date where LEASE_TENANT_ID in (select LEASE_TENANT_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_LEASE_TENANT_HIST ([LEASE_TENANT_ID], [LEASE_ID], [PERSON_ID], [ORGANIZATION_ID], [LESSOR_TYPE_CODE], [PRIMARY_CONTACT_ID], [NOTE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _LEASE_TENANT_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [LEASE_TENANT_ID], [LEASE_ID], [PERSON_ID], [ORGANIZATION_ID], [LESSOR_TYPE_CODE], [PRIMARY_CONTACT_ID], [NOTE], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_LEASE_TENANT_H_ID_SEQ]) as [_LEASE_TENANT_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CNTMTT_I_S_I_TR] ON PIMS_CONTACT_METHOD_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_CONTACT_METHOD_TYPE ("CONTACT_METHOD_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "CONTACT_METHOD_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USER_A_S_IUD_TR] ON PIMS_USER FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_USER_HIST set END_DATE_HIST = @curr_date where USER_ID in (select USER_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_USER_HIST ([USER_ID], [PERSON_ID], [BUSINESS_IDENTIFIER_VALUE], [GUID_IDENTIFIER_VALUE], [POSITION], [NOTE], [LAST_LOGIN], [APPROVED_BY_ID], [ISSUE_DATE], [EXPIRY_DATE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _USER_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [USER_ID], [PERSON_ID], [BUSINESS_IDENTIFIER_VALUE], [GUID_IDENTIFIER_VALUE], [POSITION], [NOTE], [LAST_LOGIN], [APPROVED_BY_ID], [ISSUE_DATE], [EXPIRY_DATE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_USER_H_ID_SEQ]) as [_USER_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CNTRY_I_S_I_TR] ON PIMS_COUNTRY INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_COUNTRY ("COUNTRY_ID", + "COUNTRY_CODE", + "DESCRIPTION", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "COUNTRY_ID", + "COUNTRY_CODE", + "DESCRIPTION", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USERRL_A_S_IUD_TR] ON PIMS_USER_ROLE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_USER_ROLE_HIST set END_DATE_HIST = @curr_date where USER_ROLE_ID in (select USER_ROLE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_USER_ROLE_HIST ([USER_ROLE_ID], [USER_ID], [ROLE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _USER_ROLE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [USER_ROLE_ID], [USER_ID], [ROLE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_USER_ROLE_H_ID_SEQ]) as [_USER_ROLE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PIDSRT_I_S_I_TR] ON PIMS_DATA_SOURCE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_DATA_SOURCE_TYPE ("DATA_SOURCE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "DATA_SOURCE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USRORG_A_S_IUD_TR] ON PIMS_USER_ORGANIZATION FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_USER_ORGANIZATION_HIST set END_DATE_HIST = @curr_date where USER_ORGANIZATION_ID in (select USER_ORGANIZATION_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_USER_ORGANIZATION_HIST ([USER_ORGANIZATION_ID], [ORGANIZATION_ID], [USER_ID], [ROLE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _USER_ORGANIZATION_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [USER_ORGANIZATION_ID], [ORGANIZATION_ID], [USER_ID], [ROLE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_USER_ORGANIZATION_H_ID_SEQ]) as [_USER_ORGANIZATION_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DSTRCT_I_S_I_TR] ON PIMS_DISTRICT INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_DISTRICT ("DISTRICT_CODE", + "REGION_CODE", + "DISTRICT_NAME", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "DISTRICT_CODE", + "REGION_CODE", + "DISTRICT_NAME", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DOCMNT_I_S_I_TR] ON PIMS_DOCUMENT INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_DOCUMENT ("DOCUMENT_ID", + "DOCUMENT_TYPE_ID", + "DOCUMENT_STATUS_TYPE_CODE", + "FILE_NAME", + "MAYAN_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "DOCUMENT_ID", + "DOCUMENT_TYPE_ID", + "DOCUMENT_STATUS_TYPE_CODE", + "FILE_NAME", + "MAYAN_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACRQST_I_S_U_TR] ON PIMS_ACCESS_REQUEST INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACCESS_REQUEST_ID = deleted.ACCESS_REQUEST_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACCESS_REQUEST + set "ACCESS_REQUEST_ID" = inserted."ACCESS_REQUEST_ID", + "USER_ID" = inserted."USER_ID", + "ROLE_ID" = inserted."ROLE_ID", + "ACCESS_REQUEST_STATUS_TYPE_CODE" = inserted."ACCESS_REQUEST_STATUS_TYPE_CODE", + "REGION_CODE" = inserted."REGION_CODE", + "NOTE" = inserted."NOTE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACCESS_REQUEST + inner join inserted + on (PIMS_ACCESS_REQUEST.ACCESS_REQUEST_ID = inserted.ACCESS_REQUEST_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DOCSTY_I_S_I_TR] ON PIMS_DOCUMENT_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_DOCUMENT_STATUS_TYPE ("DOCUMENT_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "DOCUMENT_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACRQOR_I_S_U_TR] ON PIMS_ACCESS_REQUEST_ORGANIZATION INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACCESS_REQUEST_ORGANIZATION_ID = deleted.ACCESS_REQUEST_ORGANIZATION_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACCESS_REQUEST_ORGANIZATION + set "ACCESS_REQUEST_ORGANIZATION_ID" = inserted."ACCESS_REQUEST_ORGANIZATION_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "ACCESS_REQUEST_ID" = inserted."ACCESS_REQUEST_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACCESS_REQUEST_ORGANIZATION + inner join inserted + on (PIMS_ACCESS_REQUEST_ORGANIZATION.ACCESS_REQUEST_ORGANIZATION_ID = inserted.ACCESS_REQUEST_ORGANIZATION_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DOCTYP_I_S_I_TR] ON PIMS_DOCUMENT_TYP INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_DOCUMENT_TYP ("DOCUMENT_TYPE_ID", + "MAYAN_ID", + "DOCUMENT_TYPE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "DOCUMENT_TYPE_ID", + "MAYAN_ID", + "DOCUMENT_TYPE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ARQSTT_I_S_U_TR] ON PIMS_ACCESS_REQUEST_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACCESS_REQUEST_STATUS_TYPE_CODE = deleted.ACCESS_REQUEST_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACCESS_REQUEST_STATUS_TYPE + set "ACCESS_REQUEST_STATUS_TYPE_CODE" = inserted."ACCESS_REQUEST_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACCESS_REQUEST_STATUS_TYPE + inner join inserted + on (PIMS_ACCESS_REQUEST_STATUS_TYPE.ACCESS_REQUEST_STATUS_TYPE_CODE = inserted.ACCESS_REQUEST_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_INSRNC_I_S_I_TR] ON PIMS_INSURANCE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_INSURANCE ("INSURANCE_ID", + "LEASE_ID", + "INSURANCE_TYPE_CODE", + "OTHER_INSURANCE_TYPE", + "COVERAGE_DESCRIPTION", + "COVERAGE_LIMIT", + "IS_INSURANCE_IN_PLACE", + "EXPIRY_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "INSURANCE_ID", + "LEASE_ID", + "INSURANCE_TYPE_CODE", + "OTHER_INSURANCE_TYPE", + "COVERAGE_DESCRIPTION", + "COVERAGE_LIMIT", + "IS_INSURANCE_IN_PLACE", + "EXPIRY_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_AQFPPT_I_S_U_TR] ON PIMS_ACQ_FL_PERSON_PROFILE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQ_FL_PERSON_PROFILE_TYPE_CODE = deleted.ACQ_FL_PERSON_PROFILE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQ_FL_PERSON_PROFILE_TYPE + set "ACQ_FL_PERSON_PROFILE_TYPE_CODE" = inserted."ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQ_FL_PERSON_PROFILE_TYPE + inner join inserted + on (PIMS_ACQ_FL_PERSON_PROFILE_TYPE.ACQ_FL_PERSON_PROFILE_TYPE_CODE = inserted.ACQ_FL_PERSON_PROFILE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_INSPYT_I_S_I_TR] ON PIMS_INSURANCE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_INSURANCE_TYPE ("INSURANCE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "INSURANCE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQPFS_I_S_U_TR] ON PIMS_ACQ_PHYS_FILE_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQ_PHYS_FILE_STATUS_TYPE_CODE = deleted.ACQ_PHYS_FILE_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQ_PHYS_FILE_STATUS_TYPE + set "ACQ_PHYS_FILE_STATUS_TYPE_CODE" = inserted."ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQ_PHYS_FILE_STATUS_TYPE + inner join inserted + on (PIMS_ACQ_PHYS_FILE_STATUS_TYPE.ACQ_PHYS_FILE_STATUS_TYPE_CODE = inserted.ACQ_PHYS_FILE_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LNSRVT_I_S_I_TR] ON PIMS_LAND_SURVEYOR_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LAND_SURVEYOR_TYPE ("LAND_SURVEYOR_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LAND_SURVEYOR_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQAIN_I_S_U_TR] ON PIMS_ACQUISITION_ACTIVITY_INSTANCE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_ACTIVITY_INSTANCE_ID = deleted.ACQUISITION_ACTIVITY_INSTANCE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_ACTIVITY_INSTANCE + set "ACQUISITION_ACTIVITY_INSTANCE_ID" = inserted."ACQUISITION_ACTIVITY_INSTANCE_ID", + "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "ACTIVITY_INSTANCE_ID" = inserted."ACTIVITY_INSTANCE_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_ACTIVITY_INSTANCE + inner join inserted + on (PIMS_ACQUISITION_ACTIVITY_INSTANCE.ACQUISITION_ACTIVITY_INSTANCE_ID = inserted.ACQUISITION_ACTIVITY_INSTANCE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LEASE_I_S_I_TR] ON PIMS_LEASE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE ("LEASE_ID", + "LEASE_PAY_RVBL_TYPE_CODE", + "LEASE_LICENSE_TYPE_CODE", + "LEASE_CATEGORY_TYPE_CODE", + "LEASE_PURPOSE_TYPE_CODE", + "LEASE_PROGRAM_TYPE_CODE", + "LEASE_INITIATOR_TYPE_CODE", + "LEASE_RESPONSIBILITY_TYPE_CODE", + "LEASE_STATUS_TYPE_CODE", + "REGION_CODE", + "L_FILE_NO", + "TFA_FILE_NO", + "PS_FILE_NO", + "LEASE_DESCRIPTION", + "LEASE_CATEGORY_OTHER_DESC", + "LEASE_PURPOSE_OTHER_DESC", + "LEASE_NOTES", + "MOTI_CONTACT", + "DOCUMENTATION_REFERENCE", + "RETURN_NOTES", + "OTHER_LEASE_PROGRAM_TYPE", + "OTHER_LEASE_LICENSE_TYPE", + "OTHER_LEASE_PURPOSE_TYPE", + "ORIG_START_DATE", + "ORIG_EXPIRY_DATE", + "LEASE_AMOUNT", + "RESPONSIBILITY_EFFECTIVE_DATE", + "INSPECTION_DATE", + "INSPECTION_NOTES", + "IS_SUBJECT_TO_RTA", + "IS_COMM_BLDG", + "IS_OTHER_IMPROVEMENT", + "IS_EXPIRED", + "HAS_PHYSICAL_FILE", + "HAS_DIGITAL_FILE", + "HAS_PHYSICIAL_LICENSE", + "HAS_DIGITAL_LICENSE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "LEASE_ID", + "LEASE_PAY_RVBL_TYPE_CODE", + "LEASE_LICENSE_TYPE_CODE", + "LEASE_CATEGORY_TYPE_CODE", + "LEASE_PURPOSE_TYPE_CODE", + "LEASE_PROGRAM_TYPE_CODE", + "LEASE_INITIATOR_TYPE_CODE", + "LEASE_RESPONSIBILITY_TYPE_CODE", + "LEASE_STATUS_TYPE_CODE", + "REGION_CODE", + "L_FILE_NO", + "TFA_FILE_NO", + "PS_FILE_NO", + "LEASE_DESCRIPTION", + "LEASE_CATEGORY_OTHER_DESC", + "LEASE_PURPOSE_OTHER_DESC", + "LEASE_NOTES", + "MOTI_CONTACT", + "DOCUMENTATION_REFERENCE", + "RETURN_NOTES", + "OTHER_LEASE_PROGRAM_TYPE", + "OTHER_LEASE_LICENSE_TYPE", + "OTHER_LEASE_PURPOSE_TYPE", + "ORIG_START_DATE", + "ORIG_EXPIRY_DATE", + "LEASE_AMOUNT", + "RESPONSIBILITY_EFFECTIVE_DATE", + "INSPECTION_DATE", + "INSPECTION_NOTES", + "IS_SUBJECT_TO_RTA", + "IS_COMM_BLDG", + "IS_OTHER_IMPROVEMENT", + "IS_EXPIRED", + "HAS_PHYSICAL_FILE", + "HAS_DIGITAL_FILE", + "HAS_PHYSICIAL_LICENSE", + "HAS_DIGITAL_LICENSE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQNFL_I_S_U_TR] ON PIMS_ACQUISITION_FILE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_FILE_ID = deleted.ACQUISITION_FILE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_FILE + set "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "ACQUISITION_FILE_STATUS_TYPE_CODE" = inserted."ACQUISITION_FILE_STATUS_TYPE_CODE", + "ACQUISITION_TYPE_CODE" = inserted."ACQUISITION_TYPE_CODE", + "ACQUISITION_FUNDING_TYPE_CODE" = inserted."ACQUISITION_FUNDING_TYPE_CODE", + "ACQ_PHYS_FILE_STATUS_TYPE_CODE" = inserted."ACQ_PHYS_FILE_STATUS_TYPE_CODE", + "MINISTRY_PROJECT_NUMBER" = inserted."MINISTRY_PROJECT_NUMBER", + "MINISTRY_PROJECT_NAME" = inserted."MINISTRY_PROJECT_NAME", + "CPS_PRODUCT_CODE" = inserted."CPS_PRODUCT_CODE", + "FILE_NAME" = inserted."FILE_NAME", + "FILE_NUMBER" = inserted."FILE_NUMBER", + "REGION_CODE" = inserted."REGION_CODE", + "FUNDING_OTHER" = inserted."FUNDING_OTHER", + "ASSIGNED_DATE" = inserted."ASSIGNED_DATE", + "DELIVERY_DATE" = inserted."DELIVERY_DATE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_FILE + inner join inserted + on (PIMS_ACQUISITION_FILE.ACQUISITION_FILE_ID = inserted.ACQUISITION_FILE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSCATT_I_S_I_TR] ON PIMS_LEASE_CATEGORY_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_CATEGORY_TYPE ("LEASE_CATEGORY_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_CATEGORY_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQPER_I_S_U_TR] ON PIMS_ACQUISITION_FILE_PERSON INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_FILE_PERSON_ID = deleted.ACQUISITION_FILE_PERSON_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_FILE_PERSON + set "ACQUISITION_FILE_PERSON_ID" = inserted."ACQUISITION_FILE_PERSON_ID", + "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "PERSON_ID" = inserted."PERSON_ID", + "ACQ_FL_PERSON_PROFILE_TYPE_CODE" = inserted."ACQ_FL_PERSON_PROFILE_TYPE_CODE", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_FILE_PERSON + inner join inserted + on (PIMS_ACQUISITION_FILE_PERSON.ACQUISITION_FILE_PERSON_ID = inserted.ACQUISITION_FILE_PERSON_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LINITT_I_S_I_TR] ON PIMS_LEASE_INITIATOR_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_INITIATOR_TYPE ("LEASE_INITIATOR_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_INITIATOR_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQFST_I_S_U_TR] ON PIMS_ACQUISITION_FILE_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_FILE_STATUS_TYPE_CODE = deleted.ACQUISITION_FILE_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_FILE_STATUS_TYPE + set "ACQUISITION_FILE_STATUS_TYPE_CODE" = inserted."ACQUISITION_FILE_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_FILE_STATUS_TYPE + inner join inserted + on (PIMS_ACQUISITION_FILE_STATUS_TYPE.ACQUISITION_FILE_STATUS_TYPE_CODE = inserted.ACQUISITION_FILE_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LELIST_I_S_I_TR] ON PIMS_LEASE_LICENSE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_LICENSE_TYPE ("LEASE_LICENSE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_LICENSE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQFTY_I_S_U_TR] ON PIMS_ACQUISITION_FUNDING_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_FUNDING_TYPE_CODE = deleted.ACQUISITION_FUNDING_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_FUNDING_TYPE + set "ACQUISITION_FUNDING_TYPE_CODE" = inserted."ACQUISITION_FUNDING_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_FUNDING_TYPE + inner join inserted + on (PIMS_ACQUISITION_FUNDING_TYPE.ACQUISITION_FUNDING_TYPE_CODE = inserted.ACQUISITION_FUNDING_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPRTY_I_S_I_TR] ON PIMS_LEASE_PAY_RVBL_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_PAY_RVBL_TYPE ("LEASE_PAY_RVBL_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_PAY_RVBL_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQOWN_I_S_U_TR] ON PIMS_ACQUISITION_OWNER INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_OWNER_ID = deleted.ACQUISITION_OWNER_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_OWNER + set "ACQUISITION_OWNER_ID" = inserted."ACQUISITION_OWNER_ID", + "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "OWNER_NAME" = inserted."OWNER_NAME", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_OWNER + inner join inserted + on (PIMS_ACQUISITION_OWNER.ACQUISITION_OWNER_ID = inserted.ACQUISITION_OWNER_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPYMT_I_S_I_TR] ON PIMS_LEASE_PAYMENT INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_PAYMENT ("LEASE_PAYMENT_ID", + "LEASE_TERM_ID", + "LEASE_PAYMENT_METHOD_TYPE_CODE", + "LEASE_PAYMENT_STATUS_TYPE_CODE", + "PAYMENT_RECEIVED_DATE", + "PAYMENT_AMOUNT_PRE_TAX", + "PAYMENT_AMOUNT_PST", + "PAYMENT_AMOUNT_GST", + "PAYMENT_AMOUNT_TOTAL", + "NOTE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "LEASE_PAYMENT_ID", + "LEASE_TERM_ID", + "LEASE_PAYMENT_METHOD_TYPE_CODE", + "LEASE_PAYMENT_STATUS_TYPE_CODE", + "PAYMENT_RECEIVED_DATE", + "PAYMENT_AMOUNT_PRE_TAX", + "PAYMENT_AMOUNT_PST", + "PAYMENT_AMOUNT_GST", + "PAYMENT_AMOUNT_TOTAL", + "NOTE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQTYP_I_S_U_TR] ON PIMS_ACQUISITION_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACQUISITION_TYPE_CODE = deleted.ACQUISITION_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACQUISITION_TYPE + set "ACQUISITION_TYPE_CODE" = inserted."ACQUISITION_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACQUISITION_TYPE + inner join inserted + on (PIMS_ACQUISITION_TYPE.ACQUISITION_TYPE_CODE = inserted.ACQUISITION_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPMMT_I_S_I_TR] ON PIMS_LEASE_PAYMENT_METHOD_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_PAYMENT_METHOD_TYPE ("LEASE_PAYMENT_METHOD_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_PAYMENT_METHOD_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTINS_I_S_U_TR] ON PIMS_ACTIVITY_INSTANCE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACTIVITY_INSTANCE_ID = deleted.ACTIVITY_INSTANCE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_INSTANCE + set "ACTIVITY_INSTANCE_ID" = inserted."ACTIVITY_INSTANCE_ID", + "ACTIVITY_TEMPLATE_ID" = inserted."ACTIVITY_TEMPLATE_ID", + "ACTIVITY_DATA_JSON" = inserted."ACTIVITY_DATA_JSON", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_INSTANCE + inner join inserted + on (PIMS_ACTIVITY_INSTANCE.ACTIVITY_INSTANCE_ID = inserted.ACTIVITY_INSTANCE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LPSTST_I_S_I_TR] ON PIMS_LEASE_PAYMENT_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_PAYMENT_STATUS_TYPE ("LEASE_PAYMENT_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_PAYMENT_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTDOC_I_S_U_TR] ON PIMS_ACTIVITY_INSTANCE_DOCUMENT INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACTIVITY_INSTANCE_DOCUMENT_ID = deleted.ACTIVITY_INSTANCE_DOCUMENT_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_INSTANCE_DOCUMENT + set "ACTIVITY_INSTANCE_DOCUMENT_ID" = inserted."ACTIVITY_INSTANCE_DOCUMENT_ID", + "ACTIVITY_INSTANCE_ID" = inserted."ACTIVITY_INSTANCE_ID", + "DOCUMENT_ID" = inserted."DOCUMENT_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_INSTANCE_DOCUMENT + inner join inserted + on (PIMS_ACTIVITY_INSTANCE_DOCUMENT.ACTIVITY_INSTANCE_DOCUMENT_ID = inserted.ACTIVITY_INSTANCE_DOCUMENT_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPMTF_I_S_I_TR] ON PIMS_LEASE_PMT_FREQ_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_PMT_FREQ_TYPE ("LEASE_PMT_FREQ_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_PMT_FREQ_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTINN_I_S_U_TR] ON PIMS_ACTIVITY_INSTANCE_NOTE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PIMS_ACTIVITY_INSTANCE_NOTE_ID = deleted.PIMS_ACTIVITY_INSTANCE_NOTE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_INSTANCE_NOTE + set "PIMS_ACTIVITY_INSTANCE_NOTE_ID" = inserted."PIMS_ACTIVITY_INSTANCE_NOTE_ID", + "ACTIVITY_INSTANCE_ID" = inserted."ACTIVITY_INSTANCE_ID", + "NOTE_ID" = inserted."NOTE_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_INSTANCE_NOTE + inner join inserted + on (PIMS_ACTIVITY_INSTANCE_NOTE.PIMS_ACTIVITY_INSTANCE_NOTE_ID = inserted.PIMS_ACTIVITY_INSTANCE_NOTE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPRGT_I_S_I_TR] ON PIMS_LEASE_PROGRAM_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_PROGRAM_TYPE ("LEASE_PROGRAM_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_PROGRAM_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTTMP_I_S_U_TR] ON PIMS_ACTIVITY_TEMPLATE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACTIVITY_TEMPLATE_ID = deleted.ACTIVITY_TEMPLATE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_TEMPLATE + set "ACTIVITY_TEMPLATE_ID" = inserted."ACTIVITY_TEMPLATE_ID", + "ACTIVITY_TEMPLATE_TYPE_CODE" = inserted."ACTIVITY_TEMPLATE_TYPE_CODE", + "ACTIVITY_TEMPLATE_JSON" = inserted."ACTIVITY_TEMPLATE_JSON", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_TEMPLATE + inner join inserted + on (PIMS_ACTIVITY_TEMPLATE.ACTIVITY_TEMPLATE_ID = inserted.ACTIVITY_TEMPLATE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LPRPTY_I_S_I_TR] ON PIMS_LEASE_PURPOSE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_PURPOSE_TYPE ("LEASE_PURPOSE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_PURPOSE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACTTTY_I_S_U_TR] ON PIMS_ACTIVITY_TEMPLATE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ACTIVITY_TEMPLATE_TYPE_CODE = deleted.ACTIVITY_TEMPLATE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ACTIVITY_TEMPLATE_TYPE + set "ACTIVITY_TEMPLATE_TYPE_CODE" = inserted."ACTIVITY_TEMPLATE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ACTIVITY_TEMPLATE_TYPE + inner join inserted + on (PIMS_ACTIVITY_TEMPLATE_TYPE.ACTIVITY_TEMPLATE_TYPE_CODE = inserted.ACTIVITY_TEMPLATE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LRESPT_I_S_I_TR] ON PIMS_LEASE_RESPONSIBILITY_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_RESPONSIBILITY_TYPE ("LEASE_RESPONSIBILITY_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_RESPONSIBILITY_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ADDRSS_I_S_U_TR] ON PIMS_ADDRESS INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ADDRESS_ID = deleted.ADDRESS_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ADDRESS + set "ADDRESS_ID" = inserted."ADDRESS_ID", + "REGION_CODE" = inserted."REGION_CODE", + "DISTRICT_CODE" = inserted."DISTRICT_CODE", + "PROVINCE_STATE_ID" = inserted."PROVINCE_STATE_ID", + "COUNTRY_ID" = inserted."COUNTRY_ID", + "STREET_ADDRESS_1" = inserted."STREET_ADDRESS_1", + "STREET_ADDRESS_2" = inserted."STREET_ADDRESS_2", + "STREET_ADDRESS_3" = inserted."STREET_ADDRESS_3", + "MUNICIPALITY_NAME" = inserted."MUNICIPALITY_NAME", + "POSTAL_CODE" = inserted."POSTAL_CODE", + "OTHER_COUNTRY" = inserted."OTHER_COUNTRY", + "LATITUDE" = inserted."LATITUDE", + "LONGITUDE" = inserted."LONGITUDE", + "COMMENT" = inserted."COMMENT", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ADDRESS + inner join inserted + on (PIMS_ADDRESS.ADDRESS_ID = inserted.ADDRESS_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSSTYP_I_S_I_TR] ON PIMS_LEASE_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_STATUS_TYPE ("LEASE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] ON PIMS_ADDRESS_USAGE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ADDRESS_USAGE_TYPE_CODE = deleted.ADDRESS_USAGE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ADDRESS_USAGE_TYPE + set "ADDRESS_USAGE_TYPE_CODE" = inserted."ADDRESS_USAGE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ADDRESS_USAGE_TYPE + inner join inserted + on (PIMS_ADDRESS_USAGE_TYPE.ADDRESS_USAGE_TYPE_CODE = inserted.ADDRESS_USAGE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_TENANT_I_S_I_TR] ON PIMS_LEASE_TENANT INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_TENANT ("LEASE_TENANT_ID", + "LEASE_ID", + "PERSON_ID", + "ORGANIZATION_ID", + "LESSOR_TYPE_CODE", + "PRIMARY_CONTACT_ID", + "NOTE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "LEASE_TENANT_ID", + "LEASE_ID", + "PERSON_ID", + "ORGANIZATION_ID", + "LESSOR_TYPE_CODE", + "PRIMARY_CONTACT_ID", + "NOTE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ARUNIT_I_S_U_TR] ON PIMS_AREA_UNIT_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.AREA_UNIT_TYPE_CODE = deleted.AREA_UNIT_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_AREA_UNIT_TYPE + set "AREA_UNIT_TYPE_CODE" = inserted."AREA_UNIT_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_AREA_UNIT_TYPE + inner join inserted + on (PIMS_AREA_UNIT_TYPE.AREA_UNIT_TYPE_CODE = inserted.AREA_UNIT_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSTERM_I_S_I_TR] ON PIMS_LEASE_TERM INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_TERM ("LEASE_TERM_ID", + "LEASE_ID", + "LEASE_TERM_STATUS_TYPE_CODE", + "LEASE_PMT_FREQ_TYPE_CODE", + "TERM_START_DATE", + "TERM_EXPIRY_DATE", + "TERM_RENEWAL_DATE", + "PAYMENT AMOUNT", + "PAYMENT_DUE_DATE", + "PAYMENT_NOTE", + "IS_GST_ELIGIBLE", + "GST_AMOUNT", + "IS_TERM_EXERCISED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "LEASE_TERM_ID", + "LEASE_ID", + "LEASE_TERM_STATUS_TYPE_CODE", + "LEASE_PMT_FREQ_TYPE_CODE", + "TERM_START_DATE", + "TERM_EXPIRY_DATE", + "TERM_RENEWAL_DATE", + "PAYMENT AMOUNT", + "PAYMENT_DUE_DATE", + "PAYMENT_NOTE", + "IS_GST_ELIGIBLE", + "GST_AMOUNT", + "IS_TERM_EXERCISED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CLMTYP_I_S_U_TR] ON PIMS_CLAIM INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.CLAIM_ID = deleted.CLAIM_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_CLAIM + set "CLAIM_ID" = inserted."CLAIM_ID", + "CLAIM_UID" = inserted."CLAIM_UID", + "KEYCLOAK_ROLE_ID" = inserted."KEYCLOAK_ROLE_ID", + "NAME" = inserted."NAME", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_CLAIM + inner join inserted + on (PIMS_CLAIM.CLAIM_ID = inserted.CLAIM_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LTRMST_I_S_I_TR] ON PIMS_LEASE_TERM_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LEASE_TERM_STATUS_TYPE ("LEASE_TERM_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LEASE_TERM_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CNTMTH_I_S_U_TR] ON PIMS_CONTACT_METHOD INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.CONTACT_METHOD_ID = deleted.CONTACT_METHOD_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_CONTACT_METHOD + set "CONTACT_METHOD_ID" = inserted."CONTACT_METHOD_ID", + "CONTACT_METHOD_TYPE_CODE" = inserted."CONTACT_METHOD_TYPE_CODE", + "PERSON_ID" = inserted."PERSON_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "CONTACT_METHOD_VALUE" = inserted."CONTACT_METHOD_VALUE", + "IS_PREFERRED_METHOD" = inserted."IS_PREFERRED_METHOD", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_CONTACT_METHOD + inner join inserted + on (PIMS_CONTACT_METHOD.CONTACT_METHOD_ID = inserted.CONTACT_METHOD_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSSRTY_I_S_I_TR] ON PIMS_LESSOR_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_LESSOR_TYPE ("LESSOR_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "LESSOR_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CNTMTT_I_S_U_TR] ON PIMS_CONTACT_METHOD_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.CONTACT_METHOD_TYPE_CODE = deleted.CONTACT_METHOD_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_CONTACT_METHOD_TYPE + set "CONTACT_METHOD_TYPE_CODE" = inserted."CONTACT_METHOD_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_CONTACT_METHOD_TYPE + inner join inserted + on (PIMS_CONTACT_METHOD_TYPE.CONTACT_METHOD_TYPE_CODE = inserted.CONTACT_METHOD_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_NOTE_I_S_I_TR] ON PIMS_NOTE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_NOTE ("NOTE_ID", + "NOTE_TXT", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "NOTE_ID", + "NOTE_TXT", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_CNTRY_I_S_U_TR] ON PIMS_COUNTRY INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.COUNTRY_ID = deleted.COUNTRY_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_COUNTRY + set "COUNTRY_ID" = inserted."COUNTRY_ID", + "COUNTRY_CODE" = inserted."COUNTRY_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_COUNTRY + inner join inserted + on (PIMS_COUNTRY.COUNTRY_ID = inserted.COUNTRY_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORGIDT_I_S_I_TR] ON PIMS_ORG_IDENTIFIER_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ORG_IDENTIFIER_TYPE ("ORG_IDENTIFIER_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ORG_IDENTIFIER_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PIDSRT_I_S_U_TR] ON PIMS_DATA_SOURCE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.DATA_SOURCE_TYPE_CODE = deleted.DATA_SOURCE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_DATA_SOURCE_TYPE + set "DATA_SOURCE_TYPE_CODE" = inserted."DATA_SOURCE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_DATA_SOURCE_TYPE + inner join inserted + on (PIMS_DATA_SOURCE_TYPE.DATA_SOURCE_TYPE_CODE = inserted.DATA_SOURCE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORG_I_S_I_TR] ON PIMS_ORGANIZATION INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ORGANIZATION ("ORGANIZATION_ID", + "PRNT_ORGANIZATION_ID", + "REGION_CODE", + "DISTRICT_CODE", + "ORGANIZATION_TYPE_CODE", + "ORG_IDENTIFIER_TYPE_CODE", + "ORGANIZATION_IDENTIFIER", + "ORGANIZATION_NAME", + "ORGANIZATION_ALIAS", + "INCORPORATION_NUMBER", + "WEBSITE", + "COMMENT", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ORGANIZATION_ID", + "PRNT_ORGANIZATION_ID", + "REGION_CODE", + "DISTRICT_CODE", + "ORGANIZATION_TYPE_CODE", + "ORG_IDENTIFIER_TYPE_CODE", + "ORGANIZATION_IDENTIFIER", + "ORGANIZATION_NAME", + "ORGANIZATION_ALIAS", + "INCORPORATION_NUMBER", + "WEBSITE", + "COMMENT", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DSTRCT_I_S_U_TR] ON PIMS_DISTRICT INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.DISTRICT_CODE = deleted.DISTRICT_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_DISTRICT + set "DISTRICT_CODE" = inserted."DISTRICT_CODE", + "REGION_CODE" = inserted."REGION_CODE", + "DISTRICT_NAME" = inserted."DISTRICT_NAME", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_DISTRICT + inner join inserted + on (PIMS_DISTRICT.DISTRICT_CODE = inserted.DISTRICT_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORGADD_I_S_I_TR] ON PIMS_ORGANIZATION_ADDRESS INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ORGANIZATION_ADDRESS ("ORGANIZATION_ADDRESS_ID", + "ORGANIZATION_ID", + "ADDRESS_ID", + "ADDRESS_USAGE_TYPE_CODE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ORGANIZATION_ADDRESS_ID", + "ORGANIZATION_ID", + "ADDRESS_ID", + "ADDRESS_USAGE_TYPE_CODE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DOCMNT_I_S_U_TR] ON PIMS_DOCUMENT INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.DOCUMENT_ID = deleted.DOCUMENT_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_DOCUMENT + set "DOCUMENT_ID" = inserted."DOCUMENT_ID", + "DOCUMENT_TYPE_ID" = inserted."DOCUMENT_TYPE_ID", + "DOCUMENT_STATUS_TYPE_CODE" = inserted."DOCUMENT_STATUS_TYPE_CODE", + "FILE_NAME" = inserted."FILE_NAME", + "MAYAN_ID" = inserted."MAYAN_ID", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_DOCUMENT + inner join inserted + on (PIMS_DOCUMENT.DOCUMENT_ID = inserted.DOCUMENT_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORGTYP_I_S_I_TR] ON PIMS_ORGANIZATION_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ORGANIZATION_TYPE ("ORGANIZATION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "ORGANIZATION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DOCSTY_I_S_U_TR] ON PIMS_DOCUMENT_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.DOCUMENT_STATUS_TYPE_CODE = deleted.DOCUMENT_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_DOCUMENT_STATUS_TYPE + set "DOCUMENT_STATUS_TYPE_CODE" = inserted."DOCUMENT_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_DOCUMENT_STATUS_TYPE + inner join inserted + on (PIMS_DOCUMENT_STATUS_TYPE.DOCUMENT_STATUS_TYPE_CODE = inserted.DOCUMENT_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERSON_I_S_I_TR] ON PIMS_PERSON INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PERSON ("PERSON_ID", + "SURNAME", + "FIRST_NAME", + "MIDDLE_NAMES", + "NAME_SUFFIX", + "PREFERRED_NAME", + "BIRTH_DATE", + "COMMENT", + "ADDRESS_COMMENT", + "USE_ORGANIZATION_ADDRESS", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PERSON_ID", + "SURNAME", + "FIRST_NAME", + "MIDDLE_NAMES", + "NAME_SUFFIX", + "PREFERRED_NAME", + "BIRTH_DATE", + "COMMENT", + "ADDRESS_COMMENT", + "USE_ORGANIZATION_ADDRESS", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_DOCTYP_I_S_U_TR] ON PIMS_DOCUMENT_TYP INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.DOCUMENT_TYPE_ID = deleted.DOCUMENT_TYPE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_DOCUMENT_TYP + set "DOCUMENT_TYPE_ID" = inserted."DOCUMENT_TYPE_ID", + "MAYAN_ID" = inserted."MAYAN_ID", + "DOCUMENT_TYPE" = inserted."DOCUMENT_TYPE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_DOCUMENT_TYP + inner join inserted + on (PIMS_DOCUMENT_TYP.DOCUMENT_TYPE_ID = inserted.DOCUMENT_TYPE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERADD_I_S_I_TR] ON PIMS_PERSON_ADDRESS INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PERSON_ADDRESS ("PERSON_ADDRESS_ID", + "PERSON_ID", + "ADDRESS_ID", + "ADDRESS_USAGE_TYPE_CODE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PERSON_ADDRESS_ID", + "PERSON_ID", + "ADDRESS_ID", + "ADDRESS_USAGE_TYPE_CODE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_INSRNC_I_S_U_TR] ON PIMS_INSURANCE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.INSURANCE_ID = deleted.INSURANCE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_INSURANCE + set "INSURANCE_ID" = inserted."INSURANCE_ID", + "LEASE_ID" = inserted."LEASE_ID", + "INSURANCE_TYPE_CODE" = inserted."INSURANCE_TYPE_CODE", + "OTHER_INSURANCE_TYPE" = inserted."OTHER_INSURANCE_TYPE", + "COVERAGE_DESCRIPTION" = inserted."COVERAGE_DESCRIPTION", + "COVERAGE_LIMIT" = inserted."COVERAGE_LIMIT", + "IS_INSURANCE_IN_PLACE" = inserted."IS_INSURANCE_IN_PLACE", + "EXPIRY_DATE" = inserted."EXPIRY_DATE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_INSURANCE + inner join inserted + on (PIMS_INSURANCE.INSURANCE_ID = inserted.INSURANCE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERORG_I_S_I_TR] ON PIMS_PERSON_ORGANIZATION INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PERSON_ORGANIZATION ("PERSON_ORGANIZATION_ID", + "PERSON_ID", + "ORGANIZATION_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PERSON_ORGANIZATION_ID", + "PERSON_ID", + "ORGANIZATION_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_INSPYT_I_S_U_TR] ON PIMS_INSURANCE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.INSURANCE_TYPE_CODE = deleted.INSURANCE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_INSURANCE_TYPE + set "INSURANCE_TYPE_CODE" = inserted."INSURANCE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_INSURANCE_TYPE + inner join inserted + on (PIMS_INSURANCE_TYPE.INSURANCE_TYPE_CODE = inserted.INSURANCE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PPHSTT_I_S_I_TR] ON PIMS_PPH_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PPH_STATUS_TYPE ("PPH_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PPH_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LNSRVT_I_S_U_TR] ON PIMS_LAND_SURVEYOR_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LAND_SURVEYOR_TYPE_CODE = deleted.LAND_SURVEYOR_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LAND_SURVEYOR_TYPE + set "LAND_SURVEYOR_TYPE_CODE" = inserted."LAND_SURVEYOR_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LAND_SURVEYOR_TYPE + inner join inserted + on (PIMS_LAND_SURVEYOR_TYPE.LAND_SURVEYOR_TYPE_CODE = inserted.LAND_SURVEYOR_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRSPRP_I_S_I_TR] ON PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE ("PRF_PROP_RESEARCH_PURPOSE_ID", + "PROPERTY_RESEARCH_FILE_ID", + "PROP_RESEARCH_PURPOSE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PRF_PROP_RESEARCH_PURPOSE_ID", + "PROPERTY_RESEARCH_FILE_ID", + "PROP_RESEARCH_PURPOSE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LEASE_I_S_U_TR] ON PIMS_LEASE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_ID = deleted.LEASE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE + set "LEASE_ID" = inserted."LEASE_ID", + "LEASE_PAY_RVBL_TYPE_CODE" = inserted."LEASE_PAY_RVBL_TYPE_CODE", + "LEASE_LICENSE_TYPE_CODE" = inserted."LEASE_LICENSE_TYPE_CODE", + "LEASE_CATEGORY_TYPE_CODE" = inserted."LEASE_CATEGORY_TYPE_CODE", + "LEASE_PURPOSE_TYPE_CODE" = inserted."LEASE_PURPOSE_TYPE_CODE", + "LEASE_PROGRAM_TYPE_CODE" = inserted."LEASE_PROGRAM_TYPE_CODE", + "LEASE_INITIATOR_TYPE_CODE" = inserted."LEASE_INITIATOR_TYPE_CODE", + "LEASE_RESPONSIBILITY_TYPE_CODE" = inserted."LEASE_RESPONSIBILITY_TYPE_CODE", + "LEASE_STATUS_TYPE_CODE" = inserted."LEASE_STATUS_TYPE_CODE", + "REGION_CODE" = inserted."REGION_CODE", + "L_FILE_NO" = inserted."L_FILE_NO", + "TFA_FILE_NO" = inserted."TFA_FILE_NO", + "PS_FILE_NO" = inserted."PS_FILE_NO", + "LEASE_DESCRIPTION" = inserted."LEASE_DESCRIPTION", + "LEASE_CATEGORY_OTHER_DESC" = inserted."LEASE_CATEGORY_OTHER_DESC", + "LEASE_PURPOSE_OTHER_DESC" = inserted."LEASE_PURPOSE_OTHER_DESC", + "LEASE_NOTES" = inserted."LEASE_NOTES", + "MOTI_CONTACT" = inserted."MOTI_CONTACT", + "DOCUMENTATION_REFERENCE" = inserted."DOCUMENTATION_REFERENCE", + "RETURN_NOTES" = inserted."RETURN_NOTES", + "OTHER_LEASE_PROGRAM_TYPE" = inserted."OTHER_LEASE_PROGRAM_TYPE", + "OTHER_LEASE_LICENSE_TYPE" = inserted."OTHER_LEASE_LICENSE_TYPE", + "OTHER_LEASE_PURPOSE_TYPE" = inserted."OTHER_LEASE_PURPOSE_TYPE", + "ORIG_START_DATE" = inserted."ORIG_START_DATE", + "ORIG_EXPIRY_DATE" = inserted."ORIG_EXPIRY_DATE", + "LEASE_AMOUNT" = inserted."LEASE_AMOUNT", + "RESPONSIBILITY_EFFECTIVE_DATE" = inserted."RESPONSIBILITY_EFFECTIVE_DATE", + "INSPECTION_DATE" = inserted."INSPECTION_DATE", + "INSPECTION_NOTES" = inserted."INSPECTION_NOTES", + "IS_SUBJECT_TO_RTA" = inserted."IS_SUBJECT_TO_RTA", + "IS_COMM_BLDG" = inserted."IS_COMM_BLDG", + "IS_OTHER_IMPROVEMENT" = inserted."IS_OTHER_IMPROVEMENT", + "IS_EXPIRED" = inserted."IS_EXPIRED", + "HAS_PHYSICAL_FILE" = inserted."HAS_PHYSICAL_FILE", + "HAS_DIGITAL_FILE" = inserted."HAS_DIGITAL_FILE", + "HAS_PHYSICIAL_LICENSE" = inserted."HAS_PHYSICIAL_LICENSE", + "HAS_DIGITAL_LICENSE" = inserted."HAS_DIGITAL_LICENSE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE + inner join inserted + on (PIMS_LEASE.LEASE_ID = inserted.LEASE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPALT_I_S_I_TR] ON PIMS_PROP_PROP_ADJACENT_LAND_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROP_PROP_ADJACENT_LAND_TYPE ("PROP_PROP_ADJACENT_LAND_TYPE_ID", + "PROPERTY_ID", + "PROPERTY_ADJACENT_LAND_TYPE_CODE", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USER_DIRECTORY", + "APP_CREATE_USER_GUID", + "APP_CREATE_USERID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID", + "CONCURRENCY_CONTROL_NUMBER") + select "PROP_PROP_ADJACENT_LAND_TYPE_ID", + "PROPERTY_ID", + "PROPERTY_ADJACENT_LAND_TYPE_CODE", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USER_DIRECTORY", + "APP_CREATE_USER_GUID", + "APP_CREATE_USERID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSCATT_I_S_U_TR] ON PIMS_LEASE_CATEGORY_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_CATEGORY_TYPE_CODE = deleted.LEASE_CATEGORY_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_CATEGORY_TYPE + set "LEASE_CATEGORY_TYPE_CODE" = inserted."LEASE_CATEGORY_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_CATEGORY_TYPE + inner join inserted + on (PIMS_LEASE_CATEGORY_TYPE.LEASE_CATEGORY_TYPE_CODE = inserted.LEASE_CATEGORY_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRAT_I_S_I_TR] ON PIMS_PROP_PROP_ANOMALY_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROP_PROP_ANOMALY_TYPE ("PROP_PROP_ANOMALY_TYPE_ID", + "PROPERTY_ID", + "PROPERTY_ANOMALY_TYPE_CODE", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USER_DIRECTORY", + "APP_CREATE_USER_GUID", + "APP_CREATE_USERID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID", + "CONCURRENCY_CONTROL_NUMBER") + select "PROP_PROP_ANOMALY_TYPE_ID", + "PROPERTY_ID", + "PROPERTY_ANOMALY_TYPE_CODE", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USER_DIRECTORY", + "APP_CREATE_USER_GUID", + "APP_CREATE_USERID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LINITT_I_S_U_TR] ON PIMS_LEASE_INITIATOR_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_INITIATOR_TYPE_CODE = deleted.LEASE_INITIATOR_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_INITIATOR_TYPE + set "LEASE_INITIATOR_TYPE_CODE" = inserted."LEASE_INITIATOR_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_INITIATOR_TYPE + inner join inserted + on (PIMS_LEASE_INITIATOR_TYPE.LEASE_INITIATOR_TYPE_CODE = inserted.LEASE_INITIATOR_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRRT_I_S_I_TR] ON PIMS_PROP_PROP_ROAD_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROP_PROP_ROAD_TYPE ("PROP_PROP_ROAD_TYPE_ID", + "PROPERTY_ID", + "PROPERTY_ROAD_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROP_PROP_ROAD_TYPE_ID", + "PROPERTY_ID", + "PROPERTY_ROAD_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LELIST_I_S_U_TR] ON PIMS_LEASE_LICENSE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_LICENSE_TYPE_CODE = deleted.LEASE_LICENSE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_LICENSE_TYPE + set "LEASE_LICENSE_TYPE_CODE" = inserted."LEASE_LICENSE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_LICENSE_TYPE + inner join inserted + on (PIMS_LEASE_LICENSE_TYPE.LEASE_LICENSE_TYPE_CODE = inserted.LEASE_LICENSE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRTT_I_S_I_TR] ON PIMS_PROP_PROP_TENURE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROP_PROP_TENURE_TYPE ("PROP_PROP_TENURE_TYPE_ID", + "PROPERTY_ID", + "PROPERTY_TENURE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROP_PROP_TENURE_TYPE_ID", + "PROPERTY_ID", + "PROPERTY_TENURE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPRTY_I_S_U_TR] ON PIMS_LEASE_PAY_RVBL_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_PAY_RVBL_TYPE_CODE = deleted.LEASE_PAY_RVBL_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_PAY_RVBL_TYPE + set "LEASE_PAY_RVBL_TYPE_CODE" = inserted."LEASE_PAY_RVBL_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_PAY_RVBL_TYPE + inner join inserted + on (PIMS_LEASE_PAY_RVBL_TYPE.LEASE_PAY_RVBL_TYPE_CODE = inserted.LEASE_PAY_RVBL_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RRESPT_I_S_I_TR] ON PIMS_PROP_RESEARCH_PURPOSE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROP_RESEARCH_PURPOSE_TYPE ("PROP_RESEARCH_PURPOSE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROP_RESEARCH_PURPOSE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPYMT_I_S_U_TR] ON PIMS_LEASE_PAYMENT INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_PAYMENT_ID = deleted.LEASE_PAYMENT_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_PAYMENT + set "LEASE_PAYMENT_ID" = inserted."LEASE_PAYMENT_ID", + "LEASE_TERM_ID" = inserted."LEASE_TERM_ID", + "LEASE_PAYMENT_METHOD_TYPE_CODE" = inserted."LEASE_PAYMENT_METHOD_TYPE_CODE", + "LEASE_PAYMENT_STATUS_TYPE_CODE" = inserted."LEASE_PAYMENT_STATUS_TYPE_CODE", + "PAYMENT_RECEIVED_DATE" = inserted."PAYMENT_RECEIVED_DATE", + "PAYMENT_AMOUNT_PRE_TAX" = inserted."PAYMENT_AMOUNT_PRE_TAX", + "PAYMENT_AMOUNT_PST" = inserted."PAYMENT_AMOUNT_PST", + "PAYMENT_AMOUNT_GST" = inserted."PAYMENT_AMOUNT_GST", + "PAYMENT_AMOUNT_TOTAL" = inserted."PAYMENT_AMOUNT_TOTAL", + "NOTE" = inserted."NOTE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_PAYMENT + inner join inserted + on (PIMS_LEASE_PAYMENT.LEASE_PAYMENT_ID = inserted.LEASE_PAYMENT_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRTY_I_S_I_TR] ON PIMS_PROPERTY INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY ("PROPERTY_ID", + "PROPERTY_MANAGER_ID", + "PROP_MGMT_ORG_ID", + "PROPERTY_TYPE_CODE", + "PROPERTY_CLASSIFICATION_TYPE_CODE", + "ADDRESS_ID", + "REGION_CODE", + "DISTRICT_CODE", + "PROPERTY_AREA_UNIT_TYPE_CODE", + "PROPERTY_DATA_SOURCE_TYPE_CODE", + "PROPERTY_STATUS_TYPE_CODE", + "SURPLUS_DECLARATION_TYPE_CODE", + "VOLUMETRIC_TYPE_CODE", + "VOLUME_UNIT_TYPE_CODE", + "PPH_STATUS_TYPE_CODE", + "PROPERTY_DATA_SOURCE_EFFECTIVE_DATE", + "NAME", + "DESCRIPTION", + "PID", + "PIN", + "FILE_NUMBER", + "FILE_NUMBER_SUFFIX", + "LAND_AREA", + "LAND_LEGAL_DESCRIPTION", + "BOUNDARY", + "LOCATION", + "ENCUMBRANCE_REASON", + "SURPLUS_DECLARATION_COMMENT", + "SURPLUS_DECLARATION_DATE", + "NOTES", + "MUNICIPAL_ZONING", + "IS_VOLUMETRIC_PARCEL", + "VOLUMETRIC_MEASUREMENT", + "IS_OWNED", + "IS_PROPERTY_OF_INTEREST", + "IS_VISIBLE_TO_OTHER_AGENCIES", + "IS_SENSITIVE", + "IS_PROVINCIAL_PUBLIC_HWY", + "PPH_STATUS_UPDATE_USERID", + "PPH_STATUS_UPDATE_TIMESTAMP", + "PPH_STATUS_UPDATE_USER_GUID", + "IS_RWY_BELT_DOM_PATENT", + "ZONING", + "ZONING_POTENTIAL", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_ID", + "PROPERTY_MANAGER_ID", + "PROP_MGMT_ORG_ID", + "PROPERTY_TYPE_CODE", + "PROPERTY_CLASSIFICATION_TYPE_CODE", + "ADDRESS_ID", + "REGION_CODE", + "DISTRICT_CODE", + "PROPERTY_AREA_UNIT_TYPE_CODE", + "PROPERTY_DATA_SOURCE_TYPE_CODE", + "PROPERTY_STATUS_TYPE_CODE", + "SURPLUS_DECLARATION_TYPE_CODE", + "VOLUMETRIC_TYPE_CODE", + "VOLUME_UNIT_TYPE_CODE", + "PPH_STATUS_TYPE_CODE", + "PROPERTY_DATA_SOURCE_EFFECTIVE_DATE", + "NAME", + "DESCRIPTION", + "PID", + "PIN", + "FILE_NUMBER", + "FILE_NUMBER_SUFFIX", + "LAND_AREA", + "LAND_LEGAL_DESCRIPTION", + "BOUNDARY", + "LOCATION", + "ENCUMBRANCE_REASON", + "SURPLUS_DECLARATION_COMMENT", + "SURPLUS_DECLARATION_DATE", + "NOTES", + "MUNICIPAL_ZONING", + "IS_VOLUMETRIC_PARCEL", + "VOLUMETRIC_MEASUREMENT", + "IS_OWNED", + "IS_PROPERTY_OF_INTEREST", + "IS_VISIBLE_TO_OTHER_AGENCIES", + "IS_SENSITIVE", + "IS_PROVINCIAL_PUBLIC_HWY", + "PPH_STATUS_UPDATE_USERID", + "PPH_STATUS_UPDATE_TIMESTAMP", + "PPH_STATUS_UPDATE_USER_GUID", + "IS_RWY_BELT_DOM_PATENT", + "ZONING", + "ZONING_POTENTIAL", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPMMT_I_S_U_TR] ON PIMS_LEASE_PAYMENT_METHOD_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_PAYMENT_METHOD_TYPE_CODE = deleted.LEASE_PAYMENT_METHOD_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_PAYMENT_METHOD_TYPE + set "LEASE_PAYMENT_METHOD_TYPE_CODE" = inserted."LEASE_PAYMENT_METHOD_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_PAYMENT_METHOD_TYPE + inner join inserted + on (PIMS_LEASE_PAYMENT_METHOD_TYPE.LEASE_PAYMENT_METHOD_TYPE_CODE = inserted.LEASE_PAYMENT_METHOD_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRACQF_I_S_I_TR] ON PIMS_PROPERTY_ACQUISITION_FILE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_ACQUISITION_FILE ("PROPERTY_ACQUISITION_FILE_ID", + "ACQUISITION_FILE_ID", + "PROPERTY_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_ACQUISITION_FILE_ID", + "ACQUISITION_FILE_ID", + "PROPERTY_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LPSTST_I_S_U_TR] ON PIMS_LEASE_PAYMENT_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_PAYMENT_STATUS_TYPE_CODE = deleted.LEASE_PAYMENT_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_PAYMENT_STATUS_TYPE + set "LEASE_PAYMENT_STATUS_TYPE_CODE" = inserted."LEASE_PAYMENT_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_PAYMENT_STATUS_TYPE + inner join inserted + on (PIMS_LEASE_PAYMENT_STATUS_TYPE.LEASE_PAYMENT_STATUS_TYPE_CODE = inserted.LEASE_PAYMENT_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRADJL_I_S_I_TR] ON PIMS_PROPERTY_ADJACENT_LAND_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_ADJACENT_LAND_TYPE ("PROPERTY_ADJACENT_LAND_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_ADJACENT_LAND_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPMTF_I_S_U_TR] ON PIMS_LEASE_PMT_FREQ_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_PMT_FREQ_TYPE_CODE = deleted.LEASE_PMT_FREQ_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_PMT_FREQ_TYPE + set "LEASE_PMT_FREQ_TYPE_CODE" = inserted."LEASE_PMT_FREQ_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_PMT_FREQ_TYPE + inner join inserted + on (PIMS_LEASE_PMT_FREQ_TYPE.LEASE_PMT_FREQ_TYPE_CODE = inserted.LEASE_PMT_FREQ_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRANOM_I_S_I_TR] ON PIMS_PROPERTY_ANOMALY_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_ANOMALY_TYPE ("PROPERTY_ANOMALY_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_ANOMALY_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSPRGT_I_S_U_TR] ON PIMS_LEASE_PROGRAM_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_PROGRAM_TYPE_CODE = deleted.LEASE_PROGRAM_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_PROGRAM_TYPE + set "LEASE_PROGRAM_TYPE_CODE" = inserted."LEASE_PROGRAM_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_PROGRAM_TYPE + inner join inserted + on (PIMS_LEASE_PROGRAM_TYPE.LEASE_PROGRAM_TYPE_CODE = inserted.LEASE_PROGRAM_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPCLT_I_S_I_TR] ON PIMS_PROPERTY_CLASSIFICATION_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_CLASSIFICATION_TYPE ("PROPERTY_CLASSIFICATION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_CLASSIFICATION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LPRPTY_I_S_U_TR] ON PIMS_LEASE_PURPOSE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_PURPOSE_TYPE_CODE = deleted.LEASE_PURPOSE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_PURPOSE_TYPE + set "LEASE_PURPOSE_TYPE_CODE" = inserted."LEASE_PURPOSE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_PURPOSE_TYPE + inner join inserted + on (PIMS_LEASE_PURPOSE_TYPE.LEASE_PURPOSE_TYPE_CODE = inserted.LEASE_PURPOSE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPEVL_I_S_I_TR] ON PIMS_PROPERTY_EVALUATION INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_EVALUATION ("PROPERTY_EVALUATION_ID", + "PROPERTY_ID", + "EVALUATION_DATE", + "KEY", + "VALUE", + "NOTE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_EVALUATION_ID", + "PROPERTY_ID", + "EVALUATION_DATE", + "KEY", + "VALUE", + "NOTE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LRESPT_I_S_U_TR] ON PIMS_LEASE_RESPONSIBILITY_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_RESPONSIBILITY_TYPE_CODE = deleted.LEASE_RESPONSIBILITY_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_RESPONSIBILITY_TYPE + set "LEASE_RESPONSIBILITY_TYPE_CODE" = inserted."LEASE_RESPONSIBILITY_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_RESPONSIBILITY_TYPE + inner join inserted + on (PIMS_LEASE_RESPONSIBILITY_TYPE.LEASE_RESPONSIBILITY_TYPE_CODE = inserted.LEASE_RESPONSIBILITY_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PIMPRV_I_S_I_TR] ON PIMS_PROPERTY_IMPROVEMENT INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_IMPROVEMENT ("PROPERTY_IMPROVEMENT_ID", + "LEASE_ID", + "PROPERTY_IMPROVEMENT_TYPE_CODE", + "IMPROVEMENT_DESCRIPTION", + "STRUCTURE_SIZE", + "ADDRESS", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_IMPROVEMENT_ID", + "LEASE_ID", + "PROPERTY_IMPROVEMENT_TYPE_CODE", + "IMPROVEMENT_DESCRIPTION", + "STRUCTURE_SIZE", + "ADDRESS", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSSTYP_I_S_U_TR] ON PIMS_LEASE_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_STATUS_TYPE_CODE = deleted.LEASE_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_STATUS_TYPE + set "LEASE_STATUS_TYPE_CODE" = inserted."LEASE_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_STATUS_TYPE + inner join inserted + on (PIMS_LEASE_STATUS_TYPE.LEASE_STATUS_TYPE_CODE = inserted.LEASE_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PIMPRT_I_S_I_TR] ON PIMS_PROPERTY_IMPROVEMENT_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_IMPROVEMENT_TYPE ("PROPERTY_IMPROVEMENT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_IMPROVEMENT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_TENANT_I_S_U_TR] ON PIMS_LEASE_TENANT INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_TENANT_ID = deleted.LEASE_TENANT_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_TENANT + set "LEASE_TENANT_ID" = inserted."LEASE_TENANT_ID", + "LEASE_ID" = inserted."LEASE_ID", + "PERSON_ID" = inserted."PERSON_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "LESSOR_TYPE_CODE" = inserted."LESSOR_TYPE_CODE", + "PRIMARY_CONTACT_ID" = inserted."PRIMARY_CONTACT_ID", + "NOTE" = inserted."NOTE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_TENANT + inner join inserted + on (PIMS_LEASE_TENANT.LEASE_TENANT_ID = inserted.LEASE_TENANT_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PROPLS_I_S_I_TR] ON PIMS_PROPERTY_LEASE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_LEASE ("PROPERTY_LEASE_ID", + "PROPERTY_ID", + "LEASE_ID", + "AREA_UNIT_TYPE_CODE", + "LEASE_AREA", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_LEASE_ID", + "PROPERTY_ID", + "LEASE_ID", + "AREA_UNIT_TYPE_CODE", + "LEASE_AREA", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSTERM_I_S_U_TR] ON PIMS_LEASE_TERM INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_TERM_ID = deleted.LEASE_TERM_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_TERM + set "LEASE_TERM_ID" = inserted."LEASE_TERM_ID", + "LEASE_ID" = inserted."LEASE_ID", + "LEASE_TERM_STATUS_TYPE_CODE" = inserted."LEASE_TERM_STATUS_TYPE_CODE", + "LEASE_PMT_FREQ_TYPE_CODE" = inserted."LEASE_PMT_FREQ_TYPE_CODE", + "TERM_START_DATE" = inserted."TERM_START_DATE", + "TERM_EXPIRY_DATE" = inserted."TERM_EXPIRY_DATE", + "TERM_RENEWAL_DATE" = inserted."TERM_RENEWAL_DATE", + "PAYMENT AMOUNT" = inserted."PAYMENT AMOUNT", + "PAYMENT_DUE_DATE" = inserted."PAYMENT_DUE_DATE", + "PAYMENT_NOTE" = inserted."PAYMENT_NOTE", + "IS_GST_ELIGIBLE" = inserted."IS_GST_ELIGIBLE", + "GST_AMOUNT" = inserted."GST_AMOUNT", + "IS_TERM_EXERCISED" = inserted."IS_TERM_EXERCISED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_TERM + inner join inserted + on (PIMS_LEASE_TERM.LEASE_TERM_ID = inserted.LEASE_TERM_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPORG_I_S_I_TR] ON PIMS_PROPERTY_ORGANIZATION INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_ORGANIZATION ("PROPERTY_ORGANIZATION_ID", + "PROPERTY_ID", + "ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY", + "IS_DISABLED") + select "PROPERTY_ORGANIZATION_ID", + "PROPERTY_ID", + "ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY", + "IS_DISABLED" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LTRMST_I_S_U_TR] ON PIMS_LEASE_TERM_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LEASE_TERM_STATUS_TYPE_CODE = deleted.LEASE_TERM_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LEASE_TERM_STATUS_TYPE + set "LEASE_TERM_STATUS_TYPE_CODE" = inserted."LEASE_TERM_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LEASE_TERM_STATUS_TYPE + inner join inserted + on (PIMS_LEASE_TERM_STATUS_TYPE.LEASE_TERM_STATUS_TYPE_CODE = inserted.LEASE_TERM_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRSF_I_S_I_TR] ON PIMS_PROPERTY_PROPERTY_SERVICE_FILE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_PROPERTY_SERVICE_FILE ("PROPERTY_PROPERTY_SERVICE_FILE_ID", + "PROPERTY_ID", + "PROPERTY_SERVICE_FILE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_PROPERTY_SERVICE_FILE_ID", + "PROPERTY_ID", + "PROPERTY_SERVICE_FILE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_LSSRTY_I_S_U_TR] ON PIMS_LESSOR_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.LESSOR_TYPE_CODE = deleted.LESSOR_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_LESSOR_TYPE + set "LESSOR_TYPE_CODE" = inserted."LESSOR_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_LESSOR_TYPE + inner join inserted + on (PIMS_LESSOR_TYPE.LESSOR_TYPE_CODE = inserted.LESSOR_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRSCRC_I_S_I_TR] ON PIMS_PROPERTY_RESEARCH_FILE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_RESEARCH_FILE ("PROPERTY_RESEARCH_FILE_ID", + "PROPERTY_ID", + "RESEARCH_FILE_ID", + "PROPERTY_NAME", + "DISPLAY_ORDER", + "IS_DISABLED", + "IS_LEGAL_OPINION_REQUIRED", + "IS_LEGAL_OPINION_OBTAINED", + "DOCUMENT_REFERENCE", + "RESEARCH_SUMMARY", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_RESEARCH_FILE_ID", + "PROPERTY_ID", + "RESEARCH_FILE_ID", + "PROPERTY_NAME", + "DISPLAY_ORDER", + "IS_DISABLED", + "IS_LEGAL_OPINION_REQUIRED", + "IS_LEGAL_OPINION_OBTAINED", + "DOCUMENT_REFERENCE", + "RESEARCH_SUMMARY", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_NOTE_I_S_U_TR] ON PIMS_NOTE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.NOTE_ID = deleted.NOTE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_NOTE + set "NOTE_ID" = inserted."NOTE_ID", + "NOTE_TXT" = inserted."NOTE_TXT", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_NOTE + inner join inserted + on (PIMS_NOTE.NOTE_ID = inserted.NOTE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRROAD_I_S_I_TR] ON PIMS_PROPERTY_ROAD_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_ROAD_TYPE ("PROPERTY_ROAD_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_ROAD_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORGIDT_I_S_U_TR] ON PIMS_ORG_IDENTIFIER_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ORG_IDENTIFIER_TYPE_CODE = deleted.ORG_IDENTIFIER_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ORG_IDENTIFIER_TYPE + set "ORG_IDENTIFIER_TYPE_CODE" = inserted."ORG_IDENTIFIER_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ORG_IDENTIFIER_TYPE + inner join inserted + on (PIMS_ORG_IDENTIFIER_TYPE.ORG_IDENTIFIER_TYPE_CODE = inserted.ORG_IDENTIFIER_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPSVC_I_S_I_TR] ON PIMS_PROPERTY_SERVICE_FILE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_SERVICE_FILE ("PROPERTY_SERVICE_FILE_ID", + "PROPERTY_SERVICE_FILE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_SERVICE_FILE_ID", + "PROPERTY_SERVICE_FILE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORG_I_S_U_TR] ON PIMS_ORGANIZATION INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ORGANIZATION_ID = deleted.ORGANIZATION_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ORGANIZATION + set "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "PRNT_ORGANIZATION_ID" = inserted."PRNT_ORGANIZATION_ID", + "REGION_CODE" = inserted."REGION_CODE", + "DISTRICT_CODE" = inserted."DISTRICT_CODE", + "ORGANIZATION_TYPE_CODE" = inserted."ORGANIZATION_TYPE_CODE", + "ORG_IDENTIFIER_TYPE_CODE" = inserted."ORG_IDENTIFIER_TYPE_CODE", + "ORGANIZATION_IDENTIFIER" = inserted."ORGANIZATION_IDENTIFIER", + "ORGANIZATION_NAME" = inserted."ORGANIZATION_NAME", + "ORGANIZATION_ALIAS" = inserted."ORGANIZATION_ALIAS", + "INCORPORATION_NUMBER" = inserted."INCORPORATION_NUMBER", + "WEBSITE" = inserted."WEBSITE", + "COMMENT" = inserted."COMMENT", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ORGANIZATION + inner join inserted + on (PIMS_ORGANIZATION.ORGANIZATION_ID = inserted.ORGANIZATION_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRSVFT_I_S_I_TR] ON PIMS_PROPERTY_SERVICE_FILE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_SERVICE_FILE_TYPE ("PROPERTY_SERVICE_FILE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_SERVICE_FILE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORGADD_I_S_U_TR] ON PIMS_ORGANIZATION_ADDRESS INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ORGANIZATION_ADDRESS_ID = deleted.ORGANIZATION_ADDRESS_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ORGANIZATION_ADDRESS + set "ORGANIZATION_ADDRESS_ID" = inserted."ORGANIZATION_ADDRESS_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "ADDRESS_ID" = inserted."ADDRESS_ID", + "ADDRESS_USAGE_TYPE_CODE" = inserted."ADDRESS_USAGE_TYPE_CODE", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ORGANIZATION_ADDRESS + inner join inserted + on (PIMS_ORGANIZATION_ADDRESS.ORGANIZATION_ADDRESS_ID = inserted.ORGANIZATION_ADDRESS_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPSTS_I_S_I_TR] ON PIMS_PROPERTY_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_STATUS_TYPE ("PROPERTY_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ORGTYP_I_S_U_TR] ON PIMS_ORGANIZATION_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.ORGANIZATION_TYPE_CODE = deleted.ORGANIZATION_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_ORGANIZATION_TYPE + set "ORGANIZATION_TYPE_CODE" = inserted."ORGANIZATION_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_ORGANIZATION_TYPE + inner join inserted + on (PIMS_ORGANIZATION_TYPE.ORGANIZATION_TYPE_CODE = inserted.ORGANIZATION_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPTAX_I_S_I_TR] ON PIMS_PROPERTY_TAX INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_TAX ("PROPERTY_TAX_ID", + "PROPERTY_ID", + "PROPERTY_TAX_REMIT_TYPE_CODE", + "TAX_FOLIO_NO", + "PAYMENT_AMOUNT", + "LAST_PAYMENT_DATE", + "PAYMENT_NOTES", + "BCTFA_NOTIFICATION_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "PROPERTY_TAX_ID", + "PROPERTY_ID", + "PROPERTY_TAX_REMIT_TYPE_CODE", + "TAX_FOLIO_NO", + "PAYMENT_AMOUNT", + "LAST_PAYMENT_DATE", + "PAYMENT_NOTES", + "BCTFA_NOTIFICATION_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERSON_I_S_U_TR] ON PIMS_PERSON INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PERSON_ID = deleted.PERSON_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PERSON + set "PERSON_ID" = inserted."PERSON_ID", + "SURNAME" = inserted."SURNAME", + "FIRST_NAME" = inserted."FIRST_NAME", + "MIDDLE_NAMES" = inserted."MIDDLE_NAMES", + "NAME_SUFFIX" = inserted."NAME_SUFFIX", + "PREFERRED_NAME" = inserted."PREFERRED_NAME", + "BIRTH_DATE" = inserted."BIRTH_DATE", + "COMMENT" = inserted."COMMENT", + "ADDRESS_COMMENT" = inserted."ADDRESS_COMMENT", + "USE_ORGANIZATION_ADDRESS" = inserted."USE_ORGANIZATION_ADDRESS", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PERSON + inner join inserted + on (PIMS_PERSON.PERSON_ID = inserted.PERSON_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PTRMTT_I_S_I_TR] ON PIMS_PROPERTY_TAX_REMIT_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_TAX_REMIT_TYPE ("PROPERTY_TAX_REMIT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_TAX_REMIT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERADD_I_S_U_TR] ON PIMS_PERSON_ADDRESS INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PERSON_ADDRESS_ID = deleted.PERSON_ADDRESS_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PERSON_ADDRESS + set "PERSON_ADDRESS_ID" = inserted."PERSON_ADDRESS_ID", + "PERSON_ID" = inserted."PERSON_ID", + "ADDRESS_ID" = inserted."ADDRESS_ID", + "ADDRESS_USAGE_TYPE_CODE" = inserted."ADDRESS_USAGE_TYPE_CODE", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PERSON_ADDRESS + inner join inserted + on (PIMS_PERSON_ADDRESS.PERSON_ADDRESS_ID = inserted.PERSON_ADDRESS_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPTNR_I_S_I_TR] ON PIMS_PROPERTY_TENURE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_TENURE_TYPE ("PROPERTY_TENURE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_TENURE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PERORG_I_S_U_TR] ON PIMS_PERSON_ORGANIZATION INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PERSON_ORGANIZATION_ID = deleted.PERSON_ORGANIZATION_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PERSON_ORGANIZATION + set "PERSON_ORGANIZATION_ID" = inserted."PERSON_ORGANIZATION_ID", + "PERSON_ID" = inserted."PERSON_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PERSON_ORGANIZATION + inner join inserted + on (PIMS_PERSON_ORGANIZATION.PERSON_ORGANIZATION_ID = inserted.PERSON_ORGANIZATION_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPTYP_I_S_I_TR] ON PIMS_PROPERTY_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROPERTY_TYPE ("PROPERTY_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROPERTY_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PPHSTT_I_S_U_TR] ON PIMS_PPH_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PPH_STATUS_TYPE_CODE = deleted.PPH_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PPH_STATUS_TYPE + set "PPH_STATUS_TYPE_CODE" = inserted."PPH_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PPH_STATUS_TYPE + inner join inserted + on (PIMS_PPH_STATUS_TYPE.PPH_STATUS_TYPE_CODE = inserted.PPH_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PROVNC_I_S_I_TR] ON PIMS_PROVINCE_STATE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_PROVINCE_STATE ("PROVINCE_STATE_ID", + "COUNTRY_ID", + "PROVINCE_STATE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "PROVINCE_STATE_ID", + "COUNTRY_ID", + "PROVINCE_STATE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRSPRP_I_S_U_TR] ON PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PRF_PROP_RESEARCH_PURPOSE_ID = deleted.PRF_PROP_RESEARCH_PURPOSE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE + set "PRF_PROP_RESEARCH_PURPOSE_ID" = inserted."PRF_PROP_RESEARCH_PURPOSE_ID", + "PROPERTY_RESEARCH_FILE_ID" = inserted."PROPERTY_RESEARCH_FILE_ID", + "PROP_RESEARCH_PURPOSE_TYPE_CODE" = inserted."PROP_RESEARCH_PURPOSE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE + inner join inserted + on (PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE.PRF_PROP_RESEARCH_PURPOSE_ID = inserted.PRF_PROP_RESEARCH_PURPOSE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_REGION_I_S_I_TR] ON PIMS_REGION INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_REGION ("REGION_CODE", + "REGION_NAME", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "REGION_CODE", + "REGION_NAME", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPALT_I_S_U_TR] ON PIMS_PROP_PROP_ADJACENT_LAND_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROP_PROP_ADJACENT_LAND_TYPE_ID = deleted.PROP_PROP_ADJACENT_LAND_TYPE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROP_PROP_ADJACENT_LAND_TYPE + set "PROP_PROP_ADJACENT_LAND_TYPE_ID" = inserted."PROP_PROP_ADJACENT_LAND_TYPE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "PROPERTY_ADJACENT_LAND_TYPE_CODE" = inserted."PROPERTY_ADJACENT_LAND_TYPE_CODE", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROP_PROP_ADJACENT_LAND_TYPE + inner join inserted + on (PIMS_PROP_PROP_ADJACENT_LAND_TYPE.PROP_PROP_ADJACENT_LAND_TYPE_ID = inserted.PROP_PROP_ADJACENT_LAND_TYPE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RGNUSR_I_S_I_TR] ON PIMS_REGION_USER INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_REGION_USER ("REGION_USER_ID", + "REGION_CODE", + "USER_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "REGION_USER_ID", + "REGION_CODE", + "USER_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRAT_I_S_U_TR] ON PIMS_PROP_PROP_ANOMALY_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROP_PROP_ANOMALY_TYPE_ID = deleted.PROP_PROP_ANOMALY_TYPE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROP_PROP_ANOMALY_TYPE + set "PROP_PROP_ANOMALY_TYPE_ID" = inserted."PROP_PROP_ANOMALY_TYPE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "PROPERTY_ANOMALY_TYPE_CODE" = inserted."PROPERTY_ANOMALY_TYPE_CODE", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROP_PROP_ANOMALY_TYPE + inner join inserted + on (PIMS_PROP_PROP_ANOMALY_TYPE.PROP_PROP_ANOMALY_TYPE_ID = inserted.PROP_PROP_ANOMALY_TYPE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RQSRCT_I_S_I_TR] ON PIMS_REQUEST_SOURCE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_REQUEST_SOURCE_TYPE ("REQUEST_SOURCE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "REQUEST_SOURCE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRRT_I_S_U_TR] ON PIMS_PROP_PROP_ROAD_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROP_PROP_ROAD_TYPE_ID = deleted.PROP_PROP_ROAD_TYPE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROP_PROP_ROAD_TYPE + set "PROP_PROP_ROAD_TYPE_ID" = inserted."PROP_PROP_ROAD_TYPE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "PROPERTY_ROAD_TYPE_CODE" = inserted."PROPERTY_ROAD_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROP_PROP_ROAD_TYPE + inner join inserted + on (PIMS_PROP_PROP_ROAD_TYPE.PROP_PROP_ROAD_TYPE_ID = inserted.PROP_PROP_ROAD_TYPE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RESRCH_I_S_I_TR] ON PIMS_RESEARCH_FILE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_RESEARCH_FILE ("RESEARCH_FILE_ID", + "RESEARCH_FILE_STATUS_TYPE_CODE", + "REQUEST_SOURCE_TYPE_CODE", + "REQUESTOR_NAME", + "REQUESTOR_ORGANIZATION", + "NAME", + "RFILE_NUMBER", + "REQUEST_DATE", + "ROAD_NAME", + "ROAD_ALIAS", + "REQUEST_DESCRIPTION", + "REQUEST_SOURCE_DESCRIPTION", + "RESEARCH_RESULT", + "IS_EXPROPRIATION", + "EXPROPRIATION_NOTES", + "RESEARCH_COMPLETION_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "RESEARCH_FILE_ID", + "RESEARCH_FILE_STATUS_TYPE_CODE", + "REQUEST_SOURCE_TYPE_CODE", + "REQUESTOR_NAME", + "REQUESTOR_ORGANIZATION", + "NAME", + "RFILE_NUMBER", + "REQUEST_DATE", + "ROAD_NAME", + "ROAD_ALIAS", + "REQUEST_DESCRIPTION", + "REQUEST_SOURCE_DESCRIPTION", + "RESEARCH_RESULT", + "IS_EXPROPRIATION", + "EXPROPRIATION_NOTES", + "RESEARCH_COMPLETION_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRTT_I_S_U_TR] ON PIMS_PROP_PROP_TENURE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROP_PROP_TENURE_TYPE_ID = deleted.PROP_PROP_TENURE_TYPE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROP_PROP_TENURE_TYPE + set "PROP_PROP_TENURE_TYPE_ID" = inserted."PROP_PROP_TENURE_TYPE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "PROPERTY_TENURE_TYPE_CODE" = inserted."PROPERTY_TENURE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROP_PROP_TENURE_TYPE + inner join inserted + on (PIMS_PROP_PROP_TENURE_TYPE.PROP_PROP_TENURE_TYPE_ID = inserted.PROP_PROP_TENURE_TYPE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RSFLPR_I_S_I_TR] ON PIMS_RESEARCH_FILE_PURPOSE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_RESEARCH_FILE_PURPOSE ("RESEARCH_FILE_PURPOSE_ID", + "RESEARCH_FILE_ID", + "RESEARCH_PURPOSE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "RESEARCH_FILE_PURPOSE_ID", + "RESEARCH_FILE_ID", + "RESEARCH_PURPOSE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RRESPT_I_S_U_TR] ON PIMS_PROP_RESEARCH_PURPOSE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROP_RESEARCH_PURPOSE_TYPE_CODE = deleted.PROP_RESEARCH_PURPOSE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROP_RESEARCH_PURPOSE_TYPE + set "PROP_RESEARCH_PURPOSE_TYPE_CODE" = inserted."PROP_RESEARCH_PURPOSE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROP_RESEARCH_PURPOSE_TYPE + inner join inserted + on (PIMS_PROP_RESEARCH_PURPOSE_TYPE.PROP_RESEARCH_PURPOSE_TYPE_CODE = inserted.PROP_RESEARCH_PURPOSE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RSRCHS_I_S_I_TR] ON PIMS_RESEARCH_FILE_STATUS_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_RESEARCH_FILE_STATUS_TYPE ("RESEARCH_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "RESEARCH_FILE_STATUS_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRTY_I_S_U_TR] ON PIMS_PROPERTY INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_ID = deleted.PROPERTY_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY + set "PROPERTY_ID" = inserted."PROPERTY_ID", + "PROPERTY_MANAGER_ID" = inserted."PROPERTY_MANAGER_ID", + "PROP_MGMT_ORG_ID" = inserted."PROP_MGMT_ORG_ID", + "PROPERTY_TYPE_CODE" = inserted."PROPERTY_TYPE_CODE", + "PROPERTY_CLASSIFICATION_TYPE_CODE" = inserted."PROPERTY_CLASSIFICATION_TYPE_CODE", + "ADDRESS_ID" = inserted."ADDRESS_ID", + "REGION_CODE" = inserted."REGION_CODE", + "DISTRICT_CODE" = inserted."DISTRICT_CODE", + "PROPERTY_AREA_UNIT_TYPE_CODE" = inserted."PROPERTY_AREA_UNIT_TYPE_CODE", + "PROPERTY_DATA_SOURCE_TYPE_CODE" = inserted."PROPERTY_DATA_SOURCE_TYPE_CODE", + "PROPERTY_STATUS_TYPE_CODE" = inserted."PROPERTY_STATUS_TYPE_CODE", + "SURPLUS_DECLARATION_TYPE_CODE" = inserted."SURPLUS_DECLARATION_TYPE_CODE", + "VOLUMETRIC_TYPE_CODE" = inserted."VOLUMETRIC_TYPE_CODE", + "VOLUME_UNIT_TYPE_CODE" = inserted."VOLUME_UNIT_TYPE_CODE", + "PPH_STATUS_TYPE_CODE" = inserted."PPH_STATUS_TYPE_CODE", + "PROPERTY_DATA_SOURCE_EFFECTIVE_DATE" = inserted."PROPERTY_DATA_SOURCE_EFFECTIVE_DATE", + "NAME" = inserted."NAME", + "DESCRIPTION" = inserted."DESCRIPTION", + "PID" = inserted."PID", + "PIN" = inserted."PIN", + "FILE_NUMBER" = inserted."FILE_NUMBER", + "FILE_NUMBER_SUFFIX" = inserted."FILE_NUMBER_SUFFIX", + "LAND_AREA" = inserted."LAND_AREA", + "LAND_LEGAL_DESCRIPTION" = inserted."LAND_LEGAL_DESCRIPTION", + "BOUNDARY" = inserted."BOUNDARY", + "LOCATION" = inserted."LOCATION", + "ENCUMBRANCE_REASON" = inserted."ENCUMBRANCE_REASON", + "SURPLUS_DECLARATION_COMMENT" = inserted."SURPLUS_DECLARATION_COMMENT", + "SURPLUS_DECLARATION_DATE" = inserted."SURPLUS_DECLARATION_DATE", + "NOTES" = inserted."NOTES", + "MUNICIPAL_ZONING" = inserted."MUNICIPAL_ZONING", + "IS_VOLUMETRIC_PARCEL" = inserted."IS_VOLUMETRIC_PARCEL", + "VOLUMETRIC_MEASUREMENT" = inserted."VOLUMETRIC_MEASUREMENT", + "IS_OWNED" = inserted."IS_OWNED", + "IS_PROPERTY_OF_INTEREST" = inserted."IS_PROPERTY_OF_INTEREST", + "IS_VISIBLE_TO_OTHER_AGENCIES" = inserted."IS_VISIBLE_TO_OTHER_AGENCIES", + "IS_SENSITIVE" = inserted."IS_SENSITIVE", + "IS_PROVINCIAL_PUBLIC_HWY" = inserted."IS_PROVINCIAL_PUBLIC_HWY", + "PPH_STATUS_UPDATE_USERID" = inserted."PPH_STATUS_UPDATE_USERID", + "PPH_STATUS_UPDATE_TIMESTAMP" = inserted."PPH_STATUS_UPDATE_TIMESTAMP", + "PPH_STATUS_UPDATE_USER_GUID" = inserted."PPH_STATUS_UPDATE_USER_GUID", + "IS_RWY_BELT_DOM_PATENT" = inserted."IS_RWY_BELT_DOM_PATENT", + "ZONING" = inserted."ZONING", + "ZONING_POTENTIAL" = inserted."ZONING_POTENTIAL", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY + inner join inserted + on (PIMS_PROPERTY.PROPERTY_ID = inserted.PROPERTY_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_RSHPRT_I_S_I_TR] ON PIMS_RESEARCH_PURPOSE_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_RESEARCH_PURPOSE_TYPE ("RESEARCH_PURPOSE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "RESEARCH_PURPOSE_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRACQF_I_S_U_TR] ON PIMS_PROPERTY_ACQUISITION_FILE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_ACQUISITION_FILE_ID = deleted.PROPERTY_ACQUISITION_FILE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_ACQUISITION_FILE + set "PROPERTY_ACQUISITION_FILE_ID" = inserted."PROPERTY_ACQUISITION_FILE_ID", + "ACQUISITION_FILE_ID" = inserted."ACQUISITION_FILE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_ACQUISITION_FILE + inner join inserted + on (PIMS_PROPERTY_ACQUISITION_FILE.PROPERTY_ACQUISITION_FILE_ID = inserted.PROPERTY_ACQUISITION_FILE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ROLE_I_S_I_TR] ON PIMS_ROLE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ROLE ("ROLE_ID", + "ROLE_UID", + "KEYCLOAK_GROUP_ID", + "NAME", + "DESCRIPTION", + "IS_PUBLIC", + "IS_DISABLED", + "SORT_ORDER", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ROLE_ID", + "ROLE_UID", + "KEYCLOAK_GROUP_ID", + "NAME", + "DESCRIPTION", + "IS_PUBLIC", + "IS_DISABLED", + "SORT_ORDER", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRADJL_I_S_U_TR] ON PIMS_PROPERTY_ADJACENT_LAND_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_ADJACENT_LAND_TYPE_CODE = deleted.PROPERTY_ADJACENT_LAND_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_ADJACENT_LAND_TYPE + set "PROPERTY_ADJACENT_LAND_TYPE_CODE" = inserted."PROPERTY_ADJACENT_LAND_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_ADJACENT_LAND_TYPE + inner join inserted + on (PIMS_PROPERTY_ADJACENT_LAND_TYPE.PROPERTY_ADJACENT_LAND_TYPE_CODE = inserted.PROPERTY_ADJACENT_LAND_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ROLCLM_I_S_I_TR] ON PIMS_ROLE_CLAIM INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_ROLE_CLAIM ("ROLE_CLAIM_ID", + "ROLE_ID", + "CLAIM_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "ROLE_CLAIM_ID", + "ROLE_ID", + "CLAIM_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRANOM_I_S_U_TR] ON PIMS_PROPERTY_ANOMALY_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_ANOMALY_TYPE_CODE = deleted.PROPERTY_ANOMALY_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_ANOMALY_TYPE + set "PROPERTY_ANOMALY_TYPE_CODE" = inserted."PROPERTY_ANOMALY_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_ANOMALY_TYPE + inner join inserted + on (PIMS_PROPERTY_ANOMALY_TYPE.PROPERTY_ANOMALY_TYPE_CODE = inserted.PROPERTY_ANOMALY_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SECDEP_I_S_I_TR] ON PIMS_SECURITY_DEPOSIT INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_SECURITY_DEPOSIT ("SECURITY_DEPOSIT_ID", + "LEASE_ID", + "SECURITY_DEPOSIT_TYPE_CODE", + "OTHER_DEPOSIT_TYPE_DESC", + "DESCRIPTION", + "AMOUNT_PAID", + "DEPOSIT_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "SECURITY_DEPOSIT_ID", + "LEASE_ID", + "SECURITY_DEPOSIT_TYPE_CODE", + "OTHER_DEPOSIT_TYPE_DESC", + "DESCRIPTION", + "AMOUNT_PAID", + "DEPOSIT_DATE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPCLT_I_S_U_TR] ON PIMS_PROPERTY_CLASSIFICATION_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_CLASSIFICATION_TYPE_CODE = deleted.PROPERTY_CLASSIFICATION_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_CLASSIFICATION_TYPE + set "PROPERTY_CLASSIFICATION_TYPE_CODE" = inserted."PROPERTY_CLASSIFICATION_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_CLASSIFICATION_TYPE + inner join inserted + on (PIMS_PROPERTY_CLASSIFICATION_TYPE.PROPERTY_CLASSIFICATION_TYPE_CODE = inserted.PROPERTY_CLASSIFICATION_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SCDPHL_I_S_I_TR] ON PIMS_SECURITY_DEPOSIT_HOLDER INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_SECURITY_DEPOSIT_HOLDER ("SECURITY_DEPOSIT_HOLDER_ID", + "SECURITY_DEPOSIT_ID", + "PERSON_ID", + "ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "SECURITY_DEPOSIT_HOLDER_ID", + "SECURITY_DEPOSIT_ID", + "PERSON_ID", + "ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPEVL_I_S_U_TR] ON PIMS_PROPERTY_EVALUATION INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_EVALUATION_ID = deleted.PROPERTY_EVALUATION_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_EVALUATION + set "PROPERTY_EVALUATION_ID" = inserted."PROPERTY_EVALUATION_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "EVALUATION_DATE" = inserted."EVALUATION_DATE", + "KEY" = inserted."KEY", + "VALUE" = inserted."VALUE", + "NOTE" = inserted."NOTE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_EVALUATION + inner join inserted + on (PIMS_PROPERTY_EVALUATION.PROPERTY_EVALUATION_ID = inserted.PROPERTY_EVALUATION_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SDRTRN_I_S_I_TR] ON PIMS_SECURITY_DEPOSIT_RETURN INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_SECURITY_DEPOSIT_RETURN ("SECURITY_DEPOSIT_RETURN_ID", + "SECURITY_DEPOSIT_ID", + "TERMINATION_DATE", + "CLAIMS_AGAINST", + "RETURN_AMOUNT", + "RETURN_DATE", + "INTEREST_PAID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "SECURITY_DEPOSIT_RETURN_ID", + "SECURITY_DEPOSIT_ID", + "TERMINATION_DATE", + "CLAIMS_AGAINST", + "RETURN_AMOUNT", + "RETURN_DATE", + "INTEREST_PAID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PIMPRV_I_S_U_TR] ON PIMS_PROPERTY_IMPROVEMENT INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_IMPROVEMENT_ID = deleted.PROPERTY_IMPROVEMENT_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_IMPROVEMENT + set "PROPERTY_IMPROVEMENT_ID" = inserted."PROPERTY_IMPROVEMENT_ID", + "LEASE_ID" = inserted."LEASE_ID", + "PROPERTY_IMPROVEMENT_TYPE_CODE" = inserted."PROPERTY_IMPROVEMENT_TYPE_CODE", + "IMPROVEMENT_DESCRIPTION" = inserted."IMPROVEMENT_DESCRIPTION", + "STRUCTURE_SIZE" = inserted."STRUCTURE_SIZE", + "ADDRESS" = inserted."ADDRESS", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_IMPROVEMENT + inner join inserted + on (PIMS_PROPERTY_IMPROVEMENT.PROPERTY_IMPROVEMENT_ID = inserted.PROPERTY_IMPROVEMENT_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SCDPRH_I_S_I_TR] ON PIMS_SECURITY_DEPOSIT_RETURN_HOLDER INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_SECURITY_DEPOSIT_RETURN_HOLDER ("SECURITY_DEPOSIT_RETURN_HOLDER_ID", + "SECURITY_DEPOSIT_RETURN_ID", + "PERSON_ID", + "ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "SECURITY_DEPOSIT_RETURN_HOLDER_ID", + "SECURITY_DEPOSIT_RETURN_ID", + "PERSON_ID", + "ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PIMPRT_I_S_U_TR] ON PIMS_PROPERTY_IMPROVEMENT_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_IMPROVEMENT_TYPE_CODE = deleted.PROPERTY_IMPROVEMENT_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_IMPROVEMENT_TYPE + set "PROPERTY_IMPROVEMENT_TYPE_CODE" = inserted."PROPERTY_IMPROVEMENT_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_IMPROVEMENT_TYPE + inner join inserted + on (PIMS_PROPERTY_IMPROVEMENT_TYPE.PROPERTY_IMPROVEMENT_TYPE_CODE = inserted.PROPERTY_IMPROVEMENT_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SECDPT_I_S_I_TR] ON PIMS_SECURITY_DEPOSIT_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_SECURITY_DEPOSIT_TYPE ("SECURITY_DEPOSIT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "SECURITY_DEPOSIT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PROPLS_I_S_U_TR] ON PIMS_PROPERTY_LEASE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_LEASE_ID = deleted.PROPERTY_LEASE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_LEASE + set "PROPERTY_LEASE_ID" = inserted."PROPERTY_LEASE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "LEASE_ID" = inserted."LEASE_ID", + "AREA_UNIT_TYPE_CODE" = inserted."AREA_UNIT_TYPE_CODE", + "LEASE_AREA" = inserted."LEASE_AREA", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_LEASE + inner join inserted + on (PIMS_PROPERTY_LEASE.PROPERTY_LEASE_ID = inserted.PROPERTY_LEASE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_STAVBL_I_S_I_TR] ON PIMS_STATIC_VARIABLE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_STATIC_VARIABLE ("STATIC_VARIABLE_NAME", + "STATIC_VARIABLE_VALUE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "STATIC_VARIABLE_NAME", + "STATIC_VARIABLE_VALUE", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPORG_I_S_U_TR] ON PIMS_PROPERTY_ORGANIZATION INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_ORGANIZATION_ID = deleted.PROPERTY_ORGANIZATION_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_ORGANIZATION + set "PROPERTY_ORGANIZATION_ID" = inserted."PROPERTY_ORGANIZATION_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "ORGANIZATION_ID" = inserted."ORGANIZATION_ID", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY", + "IS_DISABLED" = inserted."IS_DISABLED" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_ORGANIZATION + inner join inserted + on (PIMS_PROPERTY_ORGANIZATION.PROPERTY_ORGANIZATION_ID = inserted.PROPERTY_ORGANIZATION_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SPDCLT_I_S_I_TR] ON PIMS_SURPLUS_DECLARATION_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_SURPLUS_DECLARATION_TYPE ("SURPLUS_DECLARATION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "SURPLUS_DECLARATION_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPRSF_I_S_U_TR] ON PIMS_PROPERTY_PROPERTY_SERVICE_FILE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_PROPERTY_SERVICE_FILE_ID = deleted.PROPERTY_PROPERTY_SERVICE_FILE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_PROPERTY_SERVICE_FILE + set "PROPERTY_PROPERTY_SERVICE_FILE_ID" = inserted."PROPERTY_PROPERTY_SERVICE_FILE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "PROPERTY_SERVICE_FILE_ID" = inserted."PROPERTY_SERVICE_FILE_ID", + "IS_DISABLED" = inserted."IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_PROPERTY_SERVICE_FILE + inner join inserted + on (PIMS_PROPERTY_PROPERTY_SERVICE_FILE.PROPERTY_PROPERTY_SERVICE_FILE_ID = inserted.PROPERTY_PROPERTY_SERVICE_FILE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_SRVPLT_I_S_I_TR] ON PIMS_SURVEY_PLAN_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_SURVEY_PLAN_TYPE ("SURVEY_PLAN_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "SURVEY_PLAN_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRSCRC_I_S_U_TR] ON PIMS_PROPERTY_RESEARCH_FILE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_RESEARCH_FILE_ID = deleted.PROPERTY_RESEARCH_FILE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_RESEARCH_FILE + set "PROPERTY_RESEARCH_FILE_ID" = inserted."PROPERTY_RESEARCH_FILE_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "RESEARCH_FILE_ID" = inserted."RESEARCH_FILE_ID", + "PROPERTY_NAME" = inserted."PROPERTY_NAME", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "IS_DISABLED" = inserted."IS_DISABLED", + "IS_LEGAL_OPINION_REQUIRED" = inserted."IS_LEGAL_OPINION_REQUIRED", + "IS_LEGAL_OPINION_OBTAINED" = inserted."IS_LEGAL_OPINION_OBTAINED", + "DOCUMENT_REFERENCE" = inserted."DOCUMENT_REFERENCE", + "RESEARCH_SUMMARY" = inserted."RESEARCH_SUMMARY", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_RESEARCH_FILE + inner join inserted + on (PIMS_PROPERTY_RESEARCH_FILE.PROPERTY_RESEARCH_FILE_ID = inserted.PROPERTY_RESEARCH_FILE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_TENNTX_I_S_I_TR] ON PIMS_TENANT INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_TENANT ("TENANT_ID", + "CODE", + "NAME", + "DESCRIPTION", + "SETTINGS", + "CONCURRENCY_CONTROL_NUMBER") + select "TENANT_ID", + "CODE", + "NAME", + "DESCRIPTION", + "SETTINGS", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRROAD_I_S_U_TR] ON PIMS_PROPERTY_ROAD_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_ROAD_TYPE_CODE = deleted.PROPERTY_ROAD_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_ROAD_TYPE + set "PROPERTY_ROAD_TYPE_CODE" = inserted."PROPERTY_ROAD_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_ROAD_TYPE + inner join inserted + on (PIMS_PROPERTY_ROAD_TYPE.PROPERTY_ROAD_TYPE_CODE = inserted.PROPERTY_ROAD_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USER_I_S_I_TR] ON PIMS_USER INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_USER ("USER_ID", + "PERSON_ID", + "BUSINESS_IDENTIFIER_VALUE", + "GUID_IDENTIFIER_VALUE", + "POSITION", + "NOTE", + "LAST_LOGIN", + "APPROVED_BY_ID", + "ISSUE_DATE", + "EXPIRY_DATE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "USER_ID", + "PERSON_ID", + "BUSINESS_IDENTIFIER_VALUE", + "GUID_IDENTIFIER_VALUE", + "POSITION", + "NOTE", + "LAST_LOGIN", + "APPROVED_BY_ID", + "ISSUE_DATE", + "EXPIRY_DATE", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPSVC_I_S_U_TR] ON PIMS_PROPERTY_SERVICE_FILE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_SERVICE_FILE_ID = deleted.PROPERTY_SERVICE_FILE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_SERVICE_FILE + set "PROPERTY_SERVICE_FILE_ID" = inserted."PROPERTY_SERVICE_FILE_ID", + "PROPERTY_SERVICE_FILE_TYPE_CODE" = inserted."PROPERTY_SERVICE_FILE_TYPE_CODE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_SERVICE_FILE + inner join inserted + on (PIMS_PROPERTY_SERVICE_FILE.PROPERTY_SERVICE_FILE_ID = inserted.PROPERTY_SERVICE_FILE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USRORG_I_S_I_TR] ON PIMS_USER_ORGANIZATION INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_USER_ORGANIZATION ("USER_ORGANIZATION_ID", + "ORGANIZATION_ID", + "USER_ID", + "ROLE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "USER_ORGANIZATION_ID", + "ORGANIZATION_ID", + "USER_ID", + "ROLE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRSVFT_I_S_U_TR] ON PIMS_PROPERTY_SERVICE_FILE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_SERVICE_FILE_TYPE_CODE = deleted.PROPERTY_SERVICE_FILE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_SERVICE_FILE_TYPE + set "PROPERTY_SERVICE_FILE_TYPE_CODE" = inserted."PROPERTY_SERVICE_FILE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_SERVICE_FILE_TYPE + inner join inserted + on (PIMS_PROPERTY_SERVICE_FILE_TYPE.PROPERTY_SERVICE_FILE_TYPE_CODE = inserted.PROPERTY_SERVICE_FILE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_USERRL_I_S_I_TR] ON PIMS_USER_ROLE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_USER_ROLE ("USER_ROLE_ID", + "USER_ID", + "ROLE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY") + select "USER_ROLE_ID", + "USER_ID", + "ROLE_ID", + "IS_DISABLED", + "CONCURRENCY_CONTROL_NUMBER", + "APP_CREATE_TIMESTAMP", + "APP_CREATE_USERID", + "APP_CREATE_USER_GUID", + "APP_CREATE_USER_DIRECTORY", + "APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPSTS_I_S_U_TR] ON PIMS_PROPERTY_STATUS_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_STATUS_TYPE_CODE = deleted.PROPERTY_STATUS_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_STATUS_TYPE + set "PROPERTY_STATUS_TYPE_CODE" = inserted."PROPERTY_STATUS_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_STATUS_TYPE + inner join inserted + on (PIMS_PROPERTY_STATUS_TYPE.PROPERTY_STATUS_TYPE_CODE = inserted.PROPERTY_STATUS_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_VOLUTY_I_S_I_TR] ON PIMS_VOLUME_UNIT_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_VOLUME_UNIT_TYPE ("VOLUME_UNIT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "VOLUME_UNIT_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPTAX_I_S_U_TR] ON PIMS_PROPERTY_TAX INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_TAX_ID = deleted.PROPERTY_TAX_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_TAX + set "PROPERTY_TAX_ID" = inserted."PROPERTY_TAX_ID", + "PROPERTY_ID" = inserted."PROPERTY_ID", + "PROPERTY_TAX_REMIT_TYPE_CODE" = inserted."PROPERTY_TAX_REMIT_TYPE_CODE", + "TAX_FOLIO_NO" = inserted."TAX_FOLIO_NO", + "PAYMENT_AMOUNT" = inserted."PAYMENT_AMOUNT", + "LAST_PAYMENT_DATE" = inserted."LAST_PAYMENT_DATE", + "PAYMENT_NOTES" = inserted."PAYMENT_NOTES", + "BCTFA_NOTIFICATION_DATE" = inserted."BCTFA_NOTIFICATION_DATE", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER", + "APP_LAST_UPDATE_TIMESTAMP" = inserted."APP_LAST_UPDATE_TIMESTAMP", + "APP_LAST_UPDATE_USERID" = inserted."APP_LAST_UPDATE_USERID", + "APP_LAST_UPDATE_USER_GUID" = inserted."APP_LAST_UPDATE_USER_GUID", + "APP_LAST_UPDATE_USER_DIRECTORY" = inserted."APP_LAST_UPDATE_USER_DIRECTORY" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_TAX + inner join inserted + on (PIMS_PROPERTY_TAX.PROPERTY_TAX_ID = inserted.PROPERTY_TAX_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRVOLT_I_S_I_TR] ON PIMS_VOLUMETRIC_TYPE INSTEAD OF INSERT AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM inserted) + RETURN; + + + insert into PIMS_VOLUMETRIC_TYPE ("VOLUMETRIC_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER") + select "VOLUMETRIC_TYPE_CODE", + "DESCRIPTION", + "IS_DISABLED", + "DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" + from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PTRMTT_I_S_U_TR] ON PIMS_PROPERTY_TAX_REMIT_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_TAX_REMIT_TYPE_CODE = deleted.PROPERTY_TAX_REMIT_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_TAX_REMIT_TYPE + set "PROPERTY_TAX_REMIT_TYPE_CODE" = inserted."PROPERTY_TAX_REMIT_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_TAX_REMIT_TYPE + inner join inserted + on (PIMS_PROPERTY_TAX_REMIT_TYPE.PROPERTY_TAX_REMIT_TYPE_CODE = inserted.PROPERTY_TAX_REMIT_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPTNR_I_S_U_TR] ON PIMS_PROPERTY_TENURE_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_TENURE_TYPE_CODE = deleted.PROPERTY_TENURE_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_TENURE_TYPE + set "PROPERTY_TENURE_TYPE_CODE" = inserted."PROPERTY_TENURE_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_TENURE_TYPE + inner join inserted + on (PIMS_PROPERTY_TENURE_TYPE.PROPERTY_TENURE_TYPE_CODE = inserted.PROPERTY_TENURE_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PRPTYP_I_S_U_TR] ON PIMS_PROPERTY_TYPE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROPERTY_TYPE_CODE = deleted.PROPERTY_TYPE_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROPERTY_TYPE + set "PROPERTY_TYPE_CODE" = inserted."PROPERTY_TYPE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROPERTY_TYPE + inner join inserted + on (PIMS_PROPERTY_TYPE.PROPERTY_TYPE_CODE = inserted.PROPERTY_TYPE_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_PROVNC_I_S_U_TR] ON PIMS_PROVINCE_STATE INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.PROVINCE_STATE_ID = deleted.PROVINCE_STATE_ID) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_PROVINCE_STATE + set "PROVINCE_STATE_ID" = inserted."PROVINCE_STATE_ID", + "COUNTRY_ID" = inserted."COUNTRY_ID", + "PROVINCE_STATE_CODE" = inserted."PROVINCE_STATE_CODE", + "DESCRIPTION" = inserted."DESCRIPTION", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_PROVINCE_STATE + inner join inserted + on (PIMS_PROVINCE_STATE.PROVINCE_STATE_ID = inserted.PROVINCE_STATE_ID); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_ACQAIN_A_S_IUD_TR] ON PIMS_ACQUISITION_ACTIVITY_INSTANCE FOR INSERT, UPDATE, DELETE AS +SET NOCOUNT ON +BEGIN TRY +DECLARE @curr_date datetime; +SET @curr_date = getutcdate(); + IF NOT EXISTS(SELECT * FROM inserted) AND NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- historical + IF EXISTS(SELECT * FROM deleted) + update PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST set END_DATE_HIST = @curr_date where ACQUISITION_ACTIVITY_INSTANCE_ID in (select ACQUISITION_ACTIVITY_INSTANCE_ID from deleted) and END_DATE_HIST is null; + + IF EXISTS(SELECT * FROM inserted) + insert into PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST ([ACQUISITION_ACTIVITY_INSTANCE_ID], [ACQUISITION_FILE_ID], [ACTIVITY_INSTANCE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USER_DIRECTORY], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], _ACQUISITION_ACTIVITY_INSTANCE_HIST_ID, END_DATE_HIST, EFFECTIVE_DATE_HIST) + select [ACQUISITION_ACTIVITY_INSTANCE_ID], [ACQUISITION_FILE_ID], [ACTIVITY_INSTANCE_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USER_DIRECTORY], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID], (next value for [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_H_ID_SEQ]) as [_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID], null as [END_DATE_HIST], @curr_date as [EFFECTIVE_DATE_HIST] from inserted; + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + +CREATE TRIGGER [dbo].[PIMS_REGION_I_S_U_TR] ON PIMS_REGION INSTEAD OF UPDATE AS +SET NOCOUNT ON +BEGIN TRY + IF NOT EXISTS(SELECT * FROM deleted) + RETURN; + + -- validate concurrency control + if exists (select 1 from inserted, deleted where inserted.CONCURRENCY_CONTROL_NUMBER != deleted.CONCURRENCY_CONTROL_NUMBER+1 AND inserted.REGION_CODE = deleted.REGION_CODE) + raiserror('CONCURRENCY FAILURE.',16,1) + + + -- update statement + update PIMS_REGION + set "REGION_CODE" = inserted."REGION_CODE", + "REGION_NAME" = inserted."REGION_NAME", + "IS_DISABLED" = inserted."IS_DISABLED", + "DISPLAY_ORDER" = inserted."DISPLAY_ORDER", + "CONCURRENCY_CONTROL_NUMBER" = inserted."CONCURRENCY_CONTROL_NUMBER" + , DB_LAST_UPDATE_TIMESTAMP = getutcdate() + , DB_LAST_UPDATE_USERID = user_name() + from PIMS_REGION + inner join inserted + on (PIMS_REGION.REGION_CODE = inserted.REGION_CODE); + +END TRY +BEGIN CATCH + IF @@trancount > 0 ROLLBACK TRANSACTION + EXEC pims_error_handling +END CATCH; +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_HIST] + ADD CONSTRAINT [PIMS_ACRQST_H_UK] + UNIQUE ([_ACCESS_REQUEST_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] + ADD CONSTRAINT [ACRQOR_ORGANIZATION_ACCESS_REQUEST_TUC] + UNIQUE ([ORGANIZATION_ID], [ACCESS_REQUEST_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION_HIST] + ADD CONSTRAINT [PIMS_ACRQOR_H_UK] + UNIQUE ([_ACCESS_REQUEST_ORGANIZATION_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST] + ADD CONSTRAINT [PIMS_ACQAIN_H_UK] + UNIQUE ([_ACQUISITION_ACTIVITY_INSTANCE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_HIST] + ADD CONSTRAINT [PIMS_ACQNFL_H_UK] + UNIQUE ([_ACQUISITION_FILE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + ADD CONSTRAINT [ACQPER_PERSON_PROFILE_TUC] + UNIQUE ([ACQ_FL_PERSON_PROFILE_TYPE_CODE], [PERSON_ID], [ACQUISITION_FILE_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON_HIST] + ADD CONSTRAINT [PIMS_ACQPER_H_UK] + UNIQUE ([_ACQUISITION_FILE_PERSON_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER_HIST] + ADD CONSTRAINT [PIMS_ACQOWN_H_UK] + UNIQUE ([_ACQUISITION_OWNER_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST] + ADD CONSTRAINT [PIMS_ACTDOC_H_UK] + UNIQUE ([_ACTIVITY_INSTANCE_DOCUMENT_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] + ADD CONSTRAINT [PIMS_ACTINS_H_UK] + UNIQUE ([_ACTIVITY_INSTANCE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_HIST] + ADD CONSTRAINT [PIMS_ACTINN_H_UK] + UNIQUE ([_ACTIVITY_INSTANCE_NOTE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_HIST] + ADD CONSTRAINT [PIMS_ACTTMP_H_UK] + UNIQUE ([_ACTIVITY_TEMPLATE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ADDRESS_HIST] + ADD CONSTRAINT [PIMS_ADDRSS_H_UK] + UNIQUE ([_ADDRESS_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_CLAIM_HIST] + ADD CONSTRAINT [PIMS_CLMTYP_H_UK] + UNIQUE ([_CLAIM_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD_HIST] + ADD CONSTRAINT [PIMS_CNTMTH_H_UK] + UNIQUE ([_CONTACT_METHOD_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_DOCUMENT_HIST] + ADD CONSTRAINT [PIMS_DOCMNT_H_UK] + UNIQUE ([_DOCUMENT_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP_HIST] + ADD CONSTRAINT [PIMS_DOCTYP_H_UK] + UNIQUE ([_DOCUMENT_TYP_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_INSURANCE_HIST] + ADD CONSTRAINT [PIMS_INSRNC_H_UK] + UNIQUE ([_INSURANCE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_LEASE_HIST] + ADD CONSTRAINT [PIMS_LEASE_H_UK] + UNIQUE ([_LEASE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_HIST] + ADD CONSTRAINT [PIMS_LSPYMT_H_UK] + UNIQUE ([_LEASE_PAYMENT_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT_HIST] + ADD CONSTRAINT [PIMS_TENANT_H_UK] + UNIQUE ([_LEASE_TENANT_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TERM_HIST] + ADD CONSTRAINT [PIMS_LSTERM_H_UK] + UNIQUE ([_LEASE_TERM_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_NOTE_HIST] + ADD CONSTRAINT [PIMS_NOTE_H_UK] + UNIQUE ([_NOTE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] + ADD CONSTRAINT [ORGADD_UNQ_ADDR_TYPE_TUC] + UNIQUE ([ORGANIZATION_ID], [ADDRESS_ID], [ADDRESS_USAGE_TYPE_CODE]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS_HIST] + ADD CONSTRAINT [PIMS_ORGADD_H_UK] + UNIQUE ([_ORGANIZATION_ADDRESS_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_HIST] + ADD CONSTRAINT [PIMS_ORG_H_UK] + UNIQUE ([_ORGANIZATION_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] + ADD CONSTRAINT [PERADD_UNQ_ADDR_TYPE_TUC] + UNIQUE ([PERSON_ID], [ADDRESS_ID], [ADDRESS_USAGE_TYPE_CODE]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS_HIST] + ADD CONSTRAINT [PIMS_PERADD_H_UK] + UNIQUE ([_PERSON_ADDRESS_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PERSON_HIST] + ADD CONSTRAINT [PIMS_PERSON_H_UK] + UNIQUE ([_PERSON_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] + ADD CONSTRAINT [PERORG_PERSON_ORGANIZATION_TUC] + UNIQUE ([ORGANIZATION_ID], [PERSON_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION_HIST] + ADD CONSTRAINT [PIMS_PERORG_H_UK] + UNIQUE ([_PERSON_ORGANIZATION_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] + ADD CONSTRAINT [PRSPRP_PROP_PURPOSE_TUC] + UNIQUE ([PROP_RESEARCH_PURPOSE_TYPE_CODE], [PROPERTY_RESEARCH_FILE_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_HIST] + ADD CONSTRAINT [PIMS_PRACQF_H_UK] + UNIQUE ([_PROPERTY_ACQUISITION_FILE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION_HIST] + ADD CONSTRAINT [PIMS_PRPEVL_H_UK] + UNIQUE ([_PROPERTY_EVALUATION_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_HIST] + ADD CONSTRAINT [PIMS_PRPRTY_H_UK] + UNIQUE ([_PROPERTY_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] + ADD CONSTRAINT [PIMPRV_LEASE_IMPROVEMENT_TUC] + UNIQUE ([LEASE_ID], [PROPERTY_IMPROVEMENT_TYPE_CODE]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_HIST] + ADD CONSTRAINT [PIMS_PIMPRV_H_UK] + UNIQUE ([_PROPERTY_IMPROVEMENT_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE_HIST] + ADD CONSTRAINT [PIMS_PROPLS_H_UK] + UNIQUE ([_PROPERTY_LEASE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] + ADD CONSTRAINT [PRPORG_PROPERTY_ORGANIZATION_TUC] + UNIQUE ([PROPERTY_ID], [ORGANIZATION_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION_HIST] + ADD CONSTRAINT [PIMS_PRPORG_H_UK] + UNIQUE ([_PROPERTY_ORGANIZATION_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] + ADD CONSTRAINT [PRPRSF_PROPERTY_SERVICE_FILE_TUC] + UNIQUE ([PROPERTY_ID], [PROPERTY_SERVICE_FILE_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE_HIST] + ADD CONSTRAINT [PIMS_PRPRSF_H_UK] + UNIQUE ([_PROPERTY_PROPERTY_SERVICE_FILE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE_HIST] + ADD CONSTRAINT [PIMS_PRSCRC_H_UK] + UNIQUE ([_PROPERTY_RESEARCH_FILE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_HIST] + ADD CONSTRAINT [PIMS_PRPSVC_H_UK] + UNIQUE ([_PROPERTY_SERVICE_FILE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX_HIST] + ADD CONSTRAINT [PIMS_PRPTAX_H_UK] + UNIQUE ([_PROPERTY_TAX_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] + ADD CONSTRAINT [PRPALT_PROP_ADJACENT_LAND_TYPE_TUC] + UNIQUE ([PROPERTY_ADJACENT_LAND_TYPE_CODE], [PROPERTY_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] + ADD CONSTRAINT [PRPRAT_PROP_ANOMALY_TYPE_TUC] + UNIQUE ([PROPERTY_ANOMALY_TYPE_CODE], [PROPERTY_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] + ADD CONSTRAINT [PRPRRT_PROP_ROAD_TYPE_TUC] + UNIQUE ([PROPERTY_ROAD_TYPE_CODE], [PROPERTY_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_REGION_USER] + ADD CONSTRAINT [RGNUSR_REGION_USER_TUC] + UNIQUE ([USER_ID], [REGION_CODE]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_REGION_USER_HIST] + ADD CONSTRAINT [PIMS_RGNUSR_H_UK] + UNIQUE ([_REGION_USER_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_HIST] + ADD CONSTRAINT [PIMS_RESRCH_H_UK] + UNIQUE ([_RESEARCH_FILE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE_HIST] + ADD CONSTRAINT [PIMS_RSFLPR_H_UK] + UNIQUE ([_RESEARCH_FILE_PURPOSE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] + ADD CONSTRAINT [ROLCLM_ROLE_CLAIM_TUC] + UNIQUE ([ROLE_ID], [CLAIM_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM_HIST] + ADD CONSTRAINT [PIMS_ROLCLM_H_UK] + UNIQUE ([_ROLE_CLAIM_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_ROLE_HIST] + ADD CONSTRAINT [PIMS_ROLE_H_UK] + UNIQUE ([_ROLE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HIST] + ADD CONSTRAINT [PIMS_SECDEP_H_UK] + UNIQUE ([_SECURITY_DEPOSIT_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] + ADD CONSTRAINT [SCDPHL_SECURITY_DEPOSIT_ID_TUC] + UNIQUE ([SECURITY_DEPOSIT_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER_HIST] + ADD CONSTRAINT [PIMS_SCDPHL_H_UK] + UNIQUE ([_SECURITY_DEPOSIT_HOLDER_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HIST] + ADD CONSTRAINT [PIMS_SDRTRN_H_UK] + UNIQUE ([_SECURITY_DEPOSIT_RETURN_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] + ADD CONSTRAINT [SCDPRH_SECURITY_DEPOSIT_RETURN_ID_TUC] + UNIQUE ([SECURITY_DEPOSIT_RETURN_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_HIST] + ADD CONSTRAINT [PIMS_SCDPRH_H_UK] + UNIQUE ([_SECURITY_DEPOSIT_RETURN_HOLDER_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE_HIST] + ADD CONSTRAINT [PIMS_STAVBL_H_UK] + UNIQUE ([_STATIC_VARIABLE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_USER_HIST] + ADD CONSTRAINT [PIMS_USER_H_UK] + UNIQUE ([_USER_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] + ADD CONSTRAINT [USRORG_USER_ROLE_ORGANIZATION_TUC] + UNIQUE ([ORGANIZATION_ID], [USER_ID], [ROLE_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION_HIST] + ADD CONSTRAINT [PIMS_USRORG_H_UK] + UNIQUE ([_USER_ORGANIZATION_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_USER_ROLE] + ADD CONSTRAINT [USERRL_USER_ROLE_TUC] + UNIQUE ([USER_ID], [ROLE_ID]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_USER_ROLE_HIST] + ADD CONSTRAINT [PIMS_USERRL_H_UK] + UNIQUE ([_USER_ROLE_HIST_ID], [END_DATE_HIST]) + WITH ( + DATA_COMPRESSION = NONE + ) ON [PRIMARY] +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] + ADD CONSTRAINT [SCDPHL_ONE_HOLDER_ONLY_TCC] CHECK ([PERSON_ID] IS NULL AND [ORGANIZATION_ID] IS NOT NULL OR [PERSON_ID] IS NOT NULL AND [ORGANIZATION_ID] IS NULL) +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] + ADD CONSTRAINT [SCDPRH_ONE_HOLDER_ONLY_TCC] CHECK ([PERSON_ID] IS NULL AND [ORGANIZATION_ID] IS NOT NULL OR [PERSON_ID] IS NOT NULL AND [ORGANIZATION_ID] IS NULL) +GO + +ALTER TABLE [dbo].[BCA_ASSESSMENT_AREA] + ADD CONSTRAINT [PIM_BCDADV_PIM_BCASAR_FK] + FOREIGN KEY([DATA_ADVICE_ID]) + REFERENCES [dbo].[BCA_DATA_ADVICE]([DATA_ADVICE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_AREA_AMENDMENT] + ADD CONSTRAINT [PIM_BCASAR_PIM_BCAAMD_FK] + FOREIGN KEY([AREA_CODE]) + REFERENCES [dbo].[BCA_ASSESSMENT_AREA]([AREA_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_AREA_BCTRANSIT_VALUE] + ADD CONSTRAINT [PIM_BCASAR_PIM_BCATRV_FK] + FOREIGN KEY([AREA_CODE]) + REFERENCES [dbo].[BCA_ASSESSMENT_AREA]([AREA_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_AREA_DELETE] + ADD CONSTRAINT [PIM_BCASAR_PIM_BCADEL_FK] + FOREIGN KEY([AREA_CODE]) + REFERENCES [dbo].[BCA_ASSESSMENT_AREA]([AREA_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_AREA_GENERAL_VALUE] + ADD CONSTRAINT [PIM_BCASAR_PIM_BCAGNV_FK] + FOREIGN KEY([AREA_CODE]) + REFERENCES [dbo].[BCA_ASSESSMENT_AREA]([AREA_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_AREA_SCHOOL_VALUE] + ADD CONSTRAINT [PIM_BCASAR_PIM_BCASCV_FK] + FOREIGN KEY([AREA_CODE]) + REFERENCES [dbo].[BCA_ASSESSMENT_AREA]([AREA_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] + ADD CONSTRAINT [PIM_BCDADV_PIM_BCDAMD_FK] + FOREIGN KEY([DATA_ADVICE_ID]) + REFERENCES [dbo].[BCA_DATA_ADVICE]([DATA_ADVICE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE] + ADD CONSTRAINT [PIM_BCDADV_PIM_BCDTRV_FK] + FOREIGN KEY([DATA_ADVICE_ID]) + REFERENCES [dbo].[BCA_DATA_ADVICE]([DATA_ADVICE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_DELETE] + ADD CONSTRAINT [PIM_BCDADV_PIM_BCDDEL_FK] + FOREIGN KEY([DATA_ADVICE_ID]) + REFERENCES [dbo].[BCA_DATA_ADVICE]([DATA_ADVICE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE] + ADD CONSTRAINT [PIM_BCDADV_PIM_BCDGNV_FK] + FOREIGN KEY([DATA_ADVICE_ID]) + REFERENCES [dbo].[BCA_DATA_ADVICE]([DATA_ADVICE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE] + ADD CONSTRAINT [PIM_BCDADV_PIM_BCDSCV_FK] + FOREIGN KEY([DATA_ADVICE_ID]) + REFERENCES [dbo].[BCA_DATA_ADVICE]([DATA_ADVICE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_JURISDICTION] + ADD CONSTRAINT [PIM_BCASAR_PIM_BCAJUR_FK] + FOREIGN KEY([AREA_CODE]) + REFERENCES [dbo].[BCA_ASSESSMENT_AREA]([AREA_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_RECORD] + ADD CONSTRAINT [PIM_BCAJUR_PIM_BCAFOR_FK] + FOREIGN KEY([JURISDICTION_CODE]) + REFERENCES [dbo].[BCA_JURISDICTION]([JURISDICTION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_MINOR_TAXING] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCMNTX_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_DEFINED] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCADFN_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_ELECTORAL_AREA] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCELCT_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_ADDRESS] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCFADR_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_AMENDMENT] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCAFAM_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_BCTRANSIT_VALUE] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCFTRV_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_DESCRIPTION] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCAFDE_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_FARM] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCFARM_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_GENERAL_VALUE] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCFGNV_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCLCHR_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCAFLD_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_MANAGED_FOREST] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCMFOR_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_MANUFACTURED_HOME] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCMANH_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_OIL_AND_GAS] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCOILG_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_SALES] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCAFSA_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_SCHOOL_VALUE] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCFSCV_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_FOLIO_VALUATION] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCAVAL_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_GENERAL_SERVICE] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCGSVC_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_IMPROVEMENT_DISTRICT] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCIMPD_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_ISLANDS_TRUST] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCISLT_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] + ADD CONSTRAINT [PIM_BCAJUR_PIM_BCJAMD_FK] + FOREIGN KEY([JURISDICTION_CODE]) + REFERENCES [dbo].[BCA_JURISDICTION]([JURISDICTION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE] + ADD CONSTRAINT [PIM_BCAJUR_PIM_BCJTRV_FK] + FOREIGN KEY([JURISDICTION_CODE]) + REFERENCES [dbo].[BCA_JURISDICTION]([JURISDICTION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_JURISDICTION_DELETE] + ADD CONSTRAINT [PIM_BCAJUR_PIM_BCJDEL_FK] + FOREIGN KEY([JURISDICTION_CODE]) + REFERENCES [dbo].[BCA_JURISDICTION]([JURISDICTION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_JURISDICTION_GENERAL_VALUE] + ADD CONSTRAINT [PIM_BCAJUR_PIM_BCJGNV_FK] + FOREIGN KEY([JURISDICTION_CODE]) + REFERENCES [dbo].[BCA_JURISDICTION]([JURISDICTION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_JURISDICTION_SCHOOL_VALUE] + ADD CONSTRAINT [PIM_BCAJUR_PIM_BCJSCV_FK] + FOREIGN KEY([JURISDICTION_CODE]) + REFERENCES [dbo].[BCA_JURISDICTION]([JURISDICTION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_LOCAL_AREA] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCLCLA_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] + ADD CONSTRAINT [PIM_BCAFOR_PIM_BCAOWG_FK] + FOREIGN KEY([ROLL_NUMBER]) + REFERENCES [dbo].[BCA_FOLIO_RECORD]([ROLL_NUMBER]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_OWNER] + ADD CONSTRAINT [PIM_BCAOWG_PIM_BCAOWN_FK] + FOREIGN KEY([OWNERSHIP_GROUP_ID]) + REFERENCES [dbo].[BCA_OWNERSHIP_GROUP]([OWNERSHIP_GROUP_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_SERVICE_AREA] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCSVCA_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_SPECIFIED_MUNICIPAL] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCSPMU_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[BCA_SPECIFIED_REGIONAL] + ADD CONSTRAINT [PIM_BCMNTX_PIM_BCSPRG_FK] + FOREIGN KEY([MINOR_TAXING_ID]) + REFERENCES [dbo].[BCA_MINOR_TAXING]([MINOR_TAXING_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_USER] + ADD CONSTRAINT [PIM_PERSON_PIM_USER_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] + ADD CONSTRAINT [PIM_USER_PIM_ACRQST_FK] + FOREIGN KEY([USER_ID]) + REFERENCES [dbo].[PIMS_USER]([USER_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] + ADD CONSTRAINT [PIM_ROLE_PIM_ACRQST_FK] + FOREIGN KEY([ROLE_ID]) + REFERENCES [dbo].[PIMS_ROLE]([ROLE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] + ADD CONSTRAINT [PIM_REGION_PIM_ACRQST_FK] + FOREIGN KEY([REGION_CODE]) + REFERENCES [dbo].[PIMS_REGION]([REGION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] + ADD CONSTRAINT [PIM_ARQSTT_PIM_ACRQST_FK] + FOREIGN KEY([ACCESS_REQUEST_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE]([ACCESS_REQUEST_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_DISTRICT] + ADD CONSTRAINT [PIM_REGION_PIM_DSTRCT_FK] + FOREIGN KEY([REGION_CODE]) + REFERENCES [dbo].[PIMS_REGION]([REGION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] + ADD CONSTRAINT [PIM_REGION_PIM_ORG_FK] + FOREIGN KEY([REGION_CODE]) + REFERENCES [dbo].[PIMS_REGION]([REGION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] + ADD CONSTRAINT [PIM_ORGTYP_PIM_ORG_FK] + FOREIGN KEY([ORGANIZATION_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ORGANIZATION_TYPE]([ORGANIZATION_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] + ADD CONSTRAINT [PIM_ORGIDT_PIM_ORG_FK] + FOREIGN KEY([ORG_IDENTIFIER_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ORG_IDENTIFIER_TYPE]([ORG_IDENTIFIER_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] + ADD CONSTRAINT [PIM_ORG_PIM_PRNT_ORG_FK] + FOREIGN KEY([PRNT_ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] + ADD CONSTRAINT [PIM_DSTRCT_PIM_ORG_FK] + FOREIGN KEY([DISTRICT_CODE]) + REFERENCES [dbo].[PIMS_DISTRICT]([DISTRICT_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] + ADD CONSTRAINT [PIM_ORG_PIM_ACRQOR_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] + ADD CONSTRAINT [PIM_ACRQST_PIM_ACRQOR_FK] + FOREIGN KEY([ACCESS_REQUEST_ID]) + REFERENCES [dbo].[PIMS_ACCESS_REQUEST]([ACCESS_REQUEST_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQTYP_PIM_ACQNFL_FK] + FOREIGN KEY([ACQUISITION_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQUISITION_TYPE]([ACQUISITION_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQPFS_PIM_ACQNFL_FK] + FOREIGN KEY([ACQ_PHYS_FILE_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE]([ACQ_PHYS_FILE_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQFTY_PIM_ACQNFL_FK] + FOREIGN KEY([ACQUISITION_FUNDING_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQUISITION_FUNDING_TYPE]([ACQUISITION_FUNDING_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQFST_PIM_ACQNFL_FK] + FOREIGN KEY([ACQUISITION_FILE_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE]([ACQUISITION_FILE_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] + ADD CONSTRAINT [PIM_ACTTTY_PIM_ACTTMP_FK] + FOREIGN KEY([ACTIVITY_TEMPLATE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE]([ACTIVITY_TEMPLATE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] + ADD CONSTRAINT [PIM_ACTTMP_PIM_ACTINS_FK] + FOREIGN KEY([ACTIVITY_TEMPLATE_ID]) + REFERENCES [dbo].[PIMS_ACTIVITY_TEMPLATE]([ACTIVITY_TEMPLATE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] + ADD CONSTRAINT [PIM_ACTINS_PIM_ACQAIN_FK] + FOREIGN KEY([ACTIVITY_INSTANCE_ID]) + REFERENCES [dbo].[PIMS_ACTIVITY_INSTANCE]([ACTIVITY_INSTANCE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] + ADD CONSTRAINT [PIM_ACQNFL_PIM_ACQAIN_FK] + FOREIGN KEY([ACQUISITION_FILE_ID]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + ADD CONSTRAINT [PIM_PERSON_PIM_ACQPER_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + ADD CONSTRAINT [PIM_AQFPPT_PIM_ACQPER_FK] + FOREIGN KEY([ACQ_FL_PERSON_PROFILE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE]([ACQ_FL_PERSON_PROFILE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] + ADD CONSTRAINT [PIM_ACQNFL_PIM_ACQPER_FK] + FOREIGN KEY([ACQUISITION_FILE_ID]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] + ADD CONSTRAINT [PIM_ACQNFL_PIM_ACQOWN_FK] + FOREIGN KEY([ACQUISITION_FILE_ID]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_DOCUMENT] + ADD CONSTRAINT [PIM_DOCTYP_PIM_DOCMNT_FK] + FOREIGN KEY([DOCUMENT_TYPE_ID]) + REFERENCES [dbo].[PIMS_DOCUMENT_TYP]([DOCUMENT_TYPE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_DOCUMENT] + ADD CONSTRAINT [PIM_DOCSTY_PIM_DOCMNT_FK] + FOREIGN KEY([DOCUMENT_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_DOCUMENT_STATUS_TYPE]([DOCUMENT_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] + ADD CONSTRAINT [PIM_DOCMNT_PIM_ACTDOC_FK] + FOREIGN KEY([DOCUMENT_ID]) + REFERENCES [dbo].[PIMS_DOCUMENT]([DOCUMENT_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] + ADD CONSTRAINT [PIM_ACTINS_PIM_ACTDOC_FK] + FOREIGN KEY([ACTIVITY_INSTANCE_ID]) + REFERENCES [dbo].[PIMS_ACTIVITY_INSTANCE]([ACTIVITY_INSTANCE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] + ADD CONSTRAINT [PIM_NOTE_PIM_ACTINN_FK] + FOREIGN KEY([NOTE_ID]) + REFERENCES [dbo].[PIMS_NOTE]([NOTE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] + ADD CONSTRAINT [PIM_ACTINS_PIM_ACTINN_FK] + FOREIGN KEY([ACTIVITY_INSTANCE_ID]) + REFERENCES [dbo].[PIMS_ACTIVITY_INSTANCE]([ACTIVITY_INSTANCE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] + ADD CONSTRAINT [PIM_CNTRY_PIM_PROVNC_FK] + FOREIGN KEY([COUNTRY_ID]) + REFERENCES [dbo].[PIMS_COUNTRY]([COUNTRY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ADDRESS] + ADD CONSTRAINT [PIM_REGION_PIM_ADDRSS_FK] + FOREIGN KEY([REGION_CODE]) + REFERENCES [dbo].[PIMS_REGION]([REGION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ADDRESS] + ADD CONSTRAINT [PIM_PROVNC_PIM_ADDRSS_FK] + FOREIGN KEY([PROVINCE_STATE_ID]) + REFERENCES [dbo].[PIMS_PROVINCE_STATE]([PROVINCE_STATE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ADDRESS] + ADD CONSTRAINT [PIM_DSTRCT_PIM_ADDRSS_FK] + FOREIGN KEY([DISTRICT_CODE]) + REFERENCES [dbo].[PIMS_DISTRICT]([DISTRICT_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ADDRESS] + ADD CONSTRAINT [PIM_CNTRY_PIM_ADDRSS_FK] + FOREIGN KEY([COUNTRY_ID]) + REFERENCES [dbo].[PIMS_COUNTRY]([COUNTRY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] + ADD CONSTRAINT [PIM_PERSON_PIM_CNTMTH_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] + ADD CONSTRAINT [PIM_ORG_PIM_CNTMTH_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] + ADD CONSTRAINT [PIM_CNTMTT_PIM_CNTMTH_FK] + FOREIGN KEY([CONTACT_METHOD_TYPE_CODE]) + REFERENCES [dbo].[PIMS_CONTACT_METHOD_TYPE]([CONTACT_METHOD_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_REGION_PIM_LEASE_FK] + FOREIGN KEY([REGION_CODE]) + REFERENCES [dbo].[PIMS_REGION]([REGION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_LSSTYP_PIM_LEASE_FK] + FOREIGN KEY([LEASE_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_STATUS_TYPE]([LEASE_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_LSPRTY_PIM_LEASE_FK] + FOREIGN KEY([LEASE_PAY_RVBL_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_PAY_RVBL_TYPE]([LEASE_PAY_RVBL_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_LSPRGT_PIM_LEASE_FK] + FOREIGN KEY([LEASE_PROGRAM_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_PROGRAM_TYPE]([LEASE_PROGRAM_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_LSCATT_PIM_LEASE_FK] + FOREIGN KEY([LEASE_CATEGORY_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_CATEGORY_TYPE]([LEASE_CATEGORY_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_LRESPT_PIM_LEASE_FK] + FOREIGN KEY([LEASE_RESPONSIBILITY_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE]([LEASE_RESPONSIBILITY_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_LPRPTY_PIM_LEASE_FK] + FOREIGN KEY([LEASE_PURPOSE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_PURPOSE_TYPE]([LEASE_PURPOSE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_LINITT_PIM_LEASE_FK] + FOREIGN KEY([LEASE_INITIATOR_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_INITIATOR_TYPE]([LEASE_INITIATOR_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE] + ADD CONSTRAINT [PIM_LELIST_PIM_LEASE_FK] + FOREIGN KEY([LEASE_LICENSE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_LICENSE_TYPE]([LEASE_LICENSE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_INSURANCE] + ADD CONSTRAINT [PIM_LEASE_PIM_INSRNC_FK] + FOREIGN KEY([LEASE_ID]) + REFERENCES [dbo].[PIMS_LEASE]([LEASE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_INSURANCE] + ADD CONSTRAINT [PIM_INSPYT_PIM_INSRNC_FK] + FOREIGN KEY([INSURANCE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_INSURANCE_TYPE]([INSURANCE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] + ADD CONSTRAINT [PIM_LTRMST_PIM_LSTERM_FK] + FOREIGN KEY([LEASE_TERM_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_TERM_STATUS_TYPE]([LEASE_TERM_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] + ADD CONSTRAINT [PIM_LSPMTF_PIM_LSTERM_FK] + FOREIGN KEY([LEASE_PMT_FREQ_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_PMT_FREQ_TYPE]([LEASE_PMT_FREQ_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] + ADD CONSTRAINT [PIM_LEASE_PIM_LSTERM_FK] + FOREIGN KEY([LEASE_ID]) + REFERENCES [dbo].[PIMS_LEASE]([LEASE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] + ADD CONSTRAINT [PIM_LSTERM_PIM_LSPYMT_FK] + FOREIGN KEY([LEASE_TERM_ID]) + REFERENCES [dbo].[PIMS_LEASE_TERM]([LEASE_TERM_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] + ADD CONSTRAINT [PIM_LSPMMT_PIM_LSPYMT_FK] + FOREIGN KEY([LEASE_PAYMENT_METHOD_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE]([LEASE_PAYMENT_METHOD_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] + ADD CONSTRAINT [PIM_LPSTST_PIM_LSPYMT_FK] + FOREIGN KEY([LEASE_PAYMENT_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE]([LEASE_PAYMENT_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] + ADD CONSTRAINT [PIM_PERSON_PIM_TENANT_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] + ADD CONSTRAINT [PIM_PERSON_PIM_PRIMARY_CONTACT_FK] + FOREIGN KEY([PRIMARY_CONTACT_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] + ADD CONSTRAINT [PIM_ORG_PIM_TENANT_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] + ADD CONSTRAINT [PIM_LSSRTY_PIM_TENANT_FK] + FOREIGN KEY([LESSOR_TYPE_CODE]) + REFERENCES [dbo].[PIMS_LESSOR_TYPE]([LESSOR_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] + ADD CONSTRAINT [PIM_LEASE_PIM_TENANT_FK] + FOREIGN KEY([LEASE_ID]) + REFERENCES [dbo].[PIMS_LEASE]([LEASE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] + ADD CONSTRAINT [PIM_ORG_PIM_ORGADD_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] + ADD CONSTRAINT [PIM_ADUSGT_PIM_ORGADD_FK] + FOREIGN KEY([ADDRESS_USAGE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ADDRESS_USAGE_TYPE]([ADDRESS_USAGE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] + ADD CONSTRAINT [PIM_ADDRSS_PIM_ORGADD_FK] + FOREIGN KEY([ADDRESS_ID]) + REFERENCES [dbo].[PIMS_ADDRESS]([ADDRESS_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] + ADD CONSTRAINT [PIM_PERSON_PIM_PERADD_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] + ADD CONSTRAINT [PIM_ADUSGT_PIM_PERADD_FK] + FOREIGN KEY([ADDRESS_USAGE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_ADDRESS_USAGE_TYPE]([ADDRESS_USAGE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] + ADD CONSTRAINT [PIM_ADDRSS_PIM_PERADD_FK] + FOREIGN KEY([ADDRESS_ID]) + REFERENCES [dbo].[PIMS_ADDRESS]([ADDRESS_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] + ADD CONSTRAINT [PIM_PERSON_PIM_PERORG_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] + ADD CONSTRAINT [PIM_ORG_PIM_PERORG_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_VOLUTY_PIM_PRPRTY_FK] + FOREIGN KEY([VOLUME_UNIT_TYPE_CODE]) + REFERENCES [dbo].[PIMS_VOLUME_UNIT_TYPE]([VOLUME_UNIT_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_SPDCLT_PIM_PRPRTY_FK] + FOREIGN KEY([SURPLUS_DECLARATION_TYPE_CODE]) + REFERENCES [dbo].[PIMS_SURPLUS_DECLARATION_TYPE]([SURPLUS_DECLARATION_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_REGION_PIM_PRPRTY_FK] + FOREIGN KEY([REGION_CODE]) + REFERENCES [dbo].[PIMS_REGION]([REGION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_PRVOLT_PIM_PRPRTY_FK] + FOREIGN KEY([VOLUMETRIC_TYPE_CODE]) + REFERENCES [dbo].[PIMS_VOLUMETRIC_TYPE]([VOLUMETRIC_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_PRPTYP_PIM_PRPRTY_FK] + FOREIGN KEY([PROPERTY_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_TYPE]([PROPERTY_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_PRPSTS_PIM_PRPRTY_FK] + FOREIGN KEY([PROPERTY_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_STATUS_TYPE]([PROPERTY_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_PRPCLT_PIM_PRPRTY_FK] + FOREIGN KEY([PROPERTY_CLASSIFICATION_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE]([PROPERTY_CLASSIFICATION_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_PPHSTT_PIM_PRPRTY_FK] + FOREIGN KEY([PPH_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PPH_STATUS_TYPE]([PPH_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_PIDSRT_PIM_PRPRTY_FK] + FOREIGN KEY([PROPERTY_DATA_SOURCE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_DATA_SOURCE_TYPE]([DATA_SOURCE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_PERSON_PIM_PRPRTY_FK] + FOREIGN KEY([PROPERTY_MANAGER_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_ORG_PIM_PRPRTY_FK] + FOREIGN KEY([PROP_MGMT_ORG_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_DSTRCT_PIM_PRPRTY_FK] + FOREIGN KEY([DISTRICT_CODE]) + REFERENCES [dbo].[PIMS_DISTRICT]([DISTRICT_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_ARUNIT_PIM_PRPRTY_FK] + FOREIGN KEY([PROPERTY_AREA_UNIT_TYPE_CODE]) + REFERENCES [dbo].[PIMS_AREA_UNIT_TYPE]([AREA_UNIT_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY] + ADD CONSTRAINT [PIM_ADDRSS_PIM_PRPRTY_FK] + FOREIGN KEY([ADDRESS_ID]) + REFERENCES [dbo].[PIMS_ADDRESS]([ADDRESS_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] + ADD CONSTRAINT [PIM_RSRCHS_PIM_RESRCH_FK] + FOREIGN KEY([RESEARCH_FILE_STATUS_TYPE_CODE]) + REFERENCES [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE]([RESEARCH_FILE_STATUS_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] + ADD CONSTRAINT [PIM_RQSRCT_PIM_RESRCH_FK] + FOREIGN KEY([REQUEST_SOURCE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_REQUEST_SOURCE_TYPE]([REQUEST_SOURCE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] + ADD CONSTRAINT [PIM_PERSON_PIM_RESRCH_FK] + FOREIGN KEY([REQUESTOR_NAME]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] + ADD CONSTRAINT [PIM_ORG_PIM_RESRCH_FK] + FOREIGN KEY([REQUESTOR_ORGANIZATION]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] + ADD CONSTRAINT [PIM_RESRCH_PIM_PRSCRC_FK] + FOREIGN KEY([RESEARCH_FILE_ID]) + REFERENCES [dbo].[PIMS_RESEARCH_FILE]([RESEARCH_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRSCRC_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] + ADD CONSTRAINT [PIM_RRESPT_PIM_PRSPRP_FK] + FOREIGN KEY([PROP_RESEARCH_PURPOSE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE]([PROP_RESEARCH_PURPOSE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] + ADD CONSTRAINT [PIM_PRSCRC_PIM_PRSPRP_FK] + FOREIGN KEY([PROPERTY_RESEARCH_FILE_ID]) + REFERENCES [dbo].[PIMS_PROPERTY_RESEARCH_FILE]([PROPERTY_RESEARCH_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRACQF_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] + ADD CONSTRAINT [PIM_ACQNFL_PIM_PRACQF_FK] + FOREIGN KEY([ACQUISITION_FILE_ID]) + REFERENCES [dbo].[PIMS_ACQUISITION_FILE]([ACQUISITION_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRPEVL_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] + ADD CONSTRAINT [PIM_PIMPRT_PIM_PIMPRV_FK] + FOREIGN KEY([PROPERTY_IMPROVEMENT_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE]([PROPERTY_IMPROVEMENT_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] + ADD CONSTRAINT [PIM_LEASE_PIM_PIMPRV_FK] + FOREIGN KEY([LEASE_ID]) + REFERENCES [dbo].[PIMS_LEASE]([LEASE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PROPLS_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] + ADD CONSTRAINT [PIM_LEASE_PIM_PROPLS_FK] + FOREIGN KEY([LEASE_ID]) + REFERENCES [dbo].[PIMS_LEASE]([LEASE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] + ADD CONSTRAINT [PIM_ARUNIT_PIM_PROPLS_FK] + FOREIGN KEY([AREA_UNIT_TYPE_CODE]) + REFERENCES [dbo].[PIMS_AREA_UNIT_TYPE]([AREA_UNIT_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRPORG_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] + ADD CONSTRAINT [PIM_ORG_PIM_PRPORG_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] + ADD CONSTRAINT [PIM_PRSVFT_PIM_PRPSVC_FK] + FOREIGN KEY([PROPERTY_SERVICE_FILE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE]([PROPERTY_SERVICE_FILE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] + ADD CONSTRAINT [PIM_PRPSVC_PIM_PRPRSF_FK] + FOREIGN KEY([PROPERTY_SERVICE_FILE_ID]) + REFERENCES [dbo].[PIMS_PROPERTY_SERVICE_FILE]([PROPERTY_SERVICE_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRPRSF_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] + ADD CONSTRAINT [PIM_PTRMTT_PIM_PRPTAX_FK] + FOREIGN KEY([PROPERTY_TAX_REMIT_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE]([PROPERTY_TAX_REMIT_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRPTAX_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRPALT_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] + ADD CONSTRAINT [PIM_PRADJL_PIM_PRPALT_FK] + FOREIGN KEY([PROPERTY_ADJACENT_LAND_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE]([PROPERTY_ADJACENT_LAND_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRPRAT_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] + ADD CONSTRAINT [PIM_PRANOM_PIM_PRPRAT_FK] + FOREIGN KEY([PROPERTY_ANOMALY_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_ANOMALY_TYPE]([PROPERTY_ANOMALY_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] + ADD CONSTRAINT [PIM_PRROAD_PIM_PRPRRT_FK] + FOREIGN KEY([PROPERTY_ROAD_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_ROAD_TYPE]([PROPERTY_ROAD_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRPRRT_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] + ADD CONSTRAINT [PIM_PRPTNR_PIM_PRPRTT_FK] + FOREIGN KEY([PROPERTY_TENURE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_PROPERTY_TENURE_TYPE]([PROPERTY_TENURE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] + ADD CONSTRAINT [PIM_PRPRTY_PIM_PRPRTT_FK] + FOREIGN KEY([PROPERTY_ID]) + REFERENCES [dbo].[PIMS_PROPERTY]([PROPERTY_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_REGION_USER] + ADD CONSTRAINT [PIM_USER_PIM_RGNUSR_FK] + FOREIGN KEY([USER_ID]) + REFERENCES [dbo].[PIMS_USER]([USER_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_REGION_USER] + ADD CONSTRAINT [PIM_REGION_PIM_RGNUSR_FK] + FOREIGN KEY([REGION_CODE]) + REFERENCES [dbo].[PIMS_REGION]([REGION_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] + ADD CONSTRAINT [PIM_RSHPRT_PIM_RSFLPR_FK] + FOREIGN KEY([RESEARCH_PURPOSE_TYPE_CODE]) + REFERENCES [dbo].[PIMS_RESEARCH_PURPOSE_TYPE]([RESEARCH_PURPOSE_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] + ADD CONSTRAINT [PIM_RESRCH_PIM_RSFLPR_FK] + FOREIGN KEY([RESEARCH_FILE_ID]) + REFERENCES [dbo].[PIMS_RESEARCH_FILE]([RESEARCH_FILE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] + ADD CONSTRAINT [PIM_ROLE_PIM_ROLCLM_FK] + FOREIGN KEY([ROLE_ID]) + REFERENCES [dbo].[PIMS_ROLE]([ROLE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] + ADD CONSTRAINT [PIM_CLMTYP_PIM_ROLCLM_FK] + FOREIGN KEY([CLAIM_ID]) + REFERENCES [dbo].[PIMS_CLAIM]([CLAIM_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] + ADD CONSTRAINT [PIM_SECDPT_PIM_SECDEP_FK] + FOREIGN KEY([SECURITY_DEPOSIT_TYPE_CODE]) + REFERENCES [dbo].[PIMS_SECURITY_DEPOSIT_TYPE]([SECURITY_DEPOSIT_TYPE_CODE]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] + ADD CONSTRAINT [PIM_LEASE_PIM_SECDEP_FK] + FOREIGN KEY([LEASE_ID]) + REFERENCES [dbo].[PIMS_LEASE]([LEASE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] + ADD CONSTRAINT [PIM_SECDEP_PIM_SCDPHL_FK] + FOREIGN KEY([SECURITY_DEPOSIT_ID]) + REFERENCES [dbo].[PIMS_SECURITY_DEPOSIT]([SECURITY_DEPOSIT_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] + ADD CONSTRAINT [PIM_PERSON_PIM_SCDPHL_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] + ADD CONSTRAINT [PIM_ORG_PIM_SCDPHL_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] + ADD CONSTRAINT [PIM_SECDEP_PIM_SDRTRN_FK] + FOREIGN KEY([SECURITY_DEPOSIT_ID]) + REFERENCES [dbo].[PIMS_SECURITY_DEPOSIT]([SECURITY_DEPOSIT_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] + ADD CONSTRAINT [PIM_SDRTRN_PIM_SCDPRH_FK] + FOREIGN KEY([SECURITY_DEPOSIT_RETURN_ID]) + REFERENCES [dbo].[PIMS_SECURITY_DEPOSIT_RETURN]([SECURITY_DEPOSIT_RETURN_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] + ADD CONSTRAINT [PIM_PERSON_PIM_SCDPRH_FK] + FOREIGN KEY([PERSON_ID]) + REFERENCES [dbo].[PIMS_PERSON]([PERSON_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] + ADD CONSTRAINT [PIM_ORG_PIM_SCDPRH_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] + ADD CONSTRAINT [PIM_USER_PIM_USRORG_FK] + FOREIGN KEY([USER_ID]) + REFERENCES [dbo].[PIMS_USER]([USER_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] + ADD CONSTRAINT [PIM_ROLE_PIM_USRORG_FK] + FOREIGN KEY([ROLE_ID]) + REFERENCES [dbo].[PIMS_ROLE]([ROLE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] + ADD CONSTRAINT [PIM_ORG_PIM_USRORG_FK] + FOREIGN KEY([ORGANIZATION_ID]) + REFERENCES [dbo].[PIMS_ORGANIZATION]([ORGANIZATION_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_USER_ROLE] + ADD CONSTRAINT [PIM_USER_PIM_USERRL_FK] + FOREIGN KEY([USER_ID]) + REFERENCES [dbo].[PIMS_USER]([USER_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + +ALTER TABLE [dbo].[PIMS_USER_ROLE] + ADD CONSTRAINT [PIM_ROLE_PIM_USERRL_FK] + FOREIGN KEY([ROLE_ID]) + REFERENCES [dbo].[PIMS_ROLE]([ROLE_ID]) + ON DELETE NO ACTION + ON UPDATE NO ACTION +GO + diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/03_PSP_PIMS_ETL_Tables_Build.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/03_PSP_PIMS_ETL_Tables_Build.sql new file mode 100644 index 0000000000..f112cb8359 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/03_PSP_PIMS_ETL_Tables_Build.sql @@ -0,0 +1,322 @@ +-- **************************************************************************** +-- Script to build the required tables for the ETL error logs. +-- **************************************************************************** + +SET XACT_ABORT ON +GO +SET TRANSACTION ISOLATION LEVEL SERIALIZABLE +GO +BEGIN TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create ETL schema +IF NOT EXISTS (SELECT * + FROM sys.schemas + WHERE name = N'etl') + EXEC('CREATE SCHEMA [etl]'); +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +-- If there's no dbo.PIMS_DATA SOURCE_TYPE table, create the table and populate +-- from the existing dbo.PIMS_PROPERTY_DATA_SOURCE_TYPE table. +PRINT N'Create PIMS_DATA_SOURCE_TABLE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +IF NOT EXISTS (SELECT * + FROM information_schema.tables + where table_schema = 'dbo' + and table_name = 'PIMS_DATA_SOURCE_TYPE') + BEGIN + CREATE TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] ( + [DATA_SOURCE_TYPE_CODE] NVARCHAR(20) NOT NULL, + [DESCRIPTION] NVARCHAR(200) NOT NULL, + [IS_DISABLED] BIT CONSTRAINT [PIDSRT_IS_DISABLED_DEF] DEFAULT CONVERT([bit],(0)) NOT NULL, + [DISPLAY_ORDER] INTEGER, + [CONCURRENCY_CONTROL_NUMBER] BIGINT CONSTRAINT [PIDSRT_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT 1 NOT NULL, + [DB_CREATE_TIMESTAMP] DATETIME CONSTRAINT [PIDSRT_DB_CREATE_TIMESTAMP_DEF] DEFAULT getutcdate() NOT NULL, + [DB_CREATE_USERID] NVARCHAR(30) CONSTRAINT [PIDSRT_DB_CREATE_USERID_DEF] DEFAULT user_name() NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] DATETIME CONSTRAINT [PIDSRT_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT getutcdate() NOT NULL, + [DB_LAST_UPDATE_USERID] NVARCHAR(30) CONSTRAINT [PIDSRT_DB_LAST_UPDATE_USERID_DEF] DEFAULT user_name() NOT NULL, + CONSTRAINT [PIDSRT_PK] PRIMARY KEY CLUSTERED ([DATA_SOURCE_TYPE_CODE]) + ) + END +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +IF NOT EXISTS (SELECT NULL FROM SYS.EXTENDED_PROPERTIES WHERE [major_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE') AND [name] = N'MS_Description' AND [minor_id] = 0) + EXECUTE sp_addextendedproperty N'MS_Description', N'Describes the source system of the data (PAIMS, LIS, etc.)', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', NULL, NULL +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +IF NOT EXISTS (SELECT NULL FROM SYS.EXTENDED_PROPERTIES WHERE [major_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE') AND [name] = N'MS_Description' AND [minor_id] = (SELECT [column_id] FROM SYS.COLUMNS WHERE [name] = 'DATA_SOURCE_TYPE_CODE' AND [object_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE'))) + EXECUTE sp_addextendedproperty N'MS_Description', N'Code value of the source system of the data (PAIMS, LIS, etc.)', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', 'COLUMN', N'DATA_SOURCE_TYPE_CODE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +IF NOT EXISTS (SELECT NULL FROM SYS.EXTENDED_PROPERTIES WHERE [major_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE') AND [name] = N'MS_Description' AND [minor_id] = (SELECT [column_id] FROM SYS.COLUMNS WHERE [name] = 'DESCRIPTION' AND [object_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE'))) + EXECUTE sp_addextendedproperty N'MS_Description', N'Description of the source system of the data (PAIMS, LIS, etc.)', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', 'COLUMN', N'DESCRIPTION' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +IF NOT EXISTS (SELECT NULL FROM SYS.EXTENDED_PROPERTIES WHERE [major_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE') AND [name] = N'MS_Description' AND [minor_id] = (SELECT [column_id] FROM SYS.COLUMNS WHERE [name] = 'IS_DISABLED' AND [object_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE'))) + EXECUTE sp_addextendedproperty N'MS_Description', N'Indicates if the code is still in use', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', 'COLUMN', N'IS_DISABLED' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +IF NOT EXISTS (SELECT NULL FROM SYS.EXTENDED_PROPERTIES WHERE [major_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE') AND [name] = N'MS_Description' AND [minor_id] = (SELECT [column_id] FROM SYS.COLUMNS WHERE [name] = 'DISPLAY_ORDER' AND [object_id] = OBJECT_ID('PIMS_DATA_SOURCE_TYPE'))) + EXECUTE sp_addextendedproperty N'MS_Description', N'Defines the default display order of the descriptions', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +DECLARE @RowCount INT +SET @RowCount = (SELECT COUNT(*) FROM [dbo].[PIMS_DATA_SOURCE_TYPE]) +IF @RowCount = 0 + BEGIN + INSERT INTO [dbo].[PIMS_DATA_SOURCE_TYPE] (DATA_SOURCE_TYPE_CODE, DESCRIPTION) + VALUES + (N'OPSS', N'Operational Spreadsheet'), + (N'LIS', N'Lease Information System (LIS)'), + (N'PAIMS', N'Property Acquisition and Inventory Management System (PAIMS)'), + (N'GAZ', N'BC Gazette') + END +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +-- Copy the contents of PIMS_PROPERTY_DATA_SOURCE_TYPE to PIMS_DATA_SOURCE_TYPE +PRINT N'Copy the contents of PIMS_PROPERTY_DATA_SOURCE_TYPE to PIMS_DATA_SOURCE_TYPE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +IF EXISTS (SELECT * + FROM information_schema.tables + where table_schema = 'dbo' + and table_name = 'PIMS_PROPERTY_DATA SOURCE_TYPE') + BEGIN + INSERT INTO [dbo].[PIMS_DATA_SOURCE_TYPE] (DATA_SOURCE_TYPE_CODE, DESCRIPTION, IS_DISABLED, DISPLAY_ORDER) + SELECT PROPERTY_DATA_SOURCE_TYPE_CODE + , DESCRIPTION + , IS_DISABLED + , DISPLAY_ORDER + FROM [dbo].[PIMS_PROPERTY_DATA_SOURCE_TYPE] + END +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +-- Drop table etl.ETL_ERROR_LOG +PRINT N'Drop table etl.ETL_ERROR_LOG' +GO +DROP TABLE IF EXISTS [etl].[ETL_ERROR_LOG] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table etl.ETL_ERROR_LOG +PRINT N'Create table etl.ETL_ERROR_LOG' +GO +CREATE TABLE [etl].[ETL_ERROR_LOG] ( + [ERROR_TIME] DATETIME, + [ERROR_OPERATION_NAME] NVARCHAR(100), + [ERROR_TASK_NAME] NVARCHAR(100), + [ERROR_ETL_NAME] NVARCHAR(100), + [ERROR_ROW] NVARCHAR(max), + [ERROR_CODE] INTEGER, + [ERROR_COLUMN] INTEGER +) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +-- Drop table etl.ETL_OPERATIONAL_SS_LOAD +PRINT N'Drop table etl.ETL_OPERATIONAL_SS_LOAD' +GO +DROP TABLE IF EXISTS [etl].[ETL_OPERATIONAL_SS_LOAD] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table etl.ETL_OPERATIONAL_SS_LOAD +PRINT N'Create table etl.ETL_OPERATIONAL_SS_LOAD' +GO +CREATE TABLE [etl].[ETL_OPERATIONAL_SS_LOAD] ( + [SS_TAB_NAME] NVARCHAR(500), + [LIS_FILE_NO] NVARCHAR(500), + [PS_FILE_NO] NVARCHAR(500), + [DISTRICT_NAME] NVARCHAR(500), + [PROGRAM_NAME] NVARCHAR(500), + [TENANT_NAME] NVARCHAR(500), + [CONTACT_NAME] NVARCHAR(500), + [CONTACT_PHONE_NO_EMAIL] NVARCHAR(500), + [PHYSICAL_FILE_EXISTS] NVARCHAR(500), + [DIGITAL_FILE_EXISTS] NVARCHAR(500), + [COMMENTS] NVARCHAR(max), + [PHYSICAL_LICENSE_COPY_EXISTS] NVARCHAR(500), + [DIGITAL_LICENSE_COPY_EXISTS] NVARCHAR(500), + [FOLIO_NO] NVARCHAR(500), + [PID] NVARCHAR(500), + [PROPERTY_LOCN_LEGAL_DESC] NVARCHAR(500), + [EXPECTED_ANNUAL_PMT_PRE_GST] NVARCHAR(500), + [PAYMENT_APR] NVARCHAR(500), + [PAYMENT_MAY] NVARCHAR(500), + [PAYMENT_JUN] NVARCHAR(500), + [PAYMENT_JUL] NVARCHAR(500), + [PAYMENT_AUG] NVARCHAR(500), + [PAYMENT_SEP] NVARCHAR(500), + [PAYMENT_OCT] NVARCHAR(500), + [PAYMENT_NOV] NVARCHAR(500), + [PAYMENT_DEC] NVARCHAR(500), + [PAYMENT_JAN] NVARCHAR(500), + [PAYMENT_FEB] NVARCHAR(500), + [PAYMENT_MAR] NVARCHAR(500), + [START_DATE] DATE, + [EXPIRY_DATE] DATE, + [NOTES] NVARCHAR(max), + [BONDING_AMOUNT_HELD] NVARCHAR(500), + [IS_INSURANCE_IN_PLACE] NVARCHAR(500), + [INSURANCE_EXPIRY_DATE] DATE, + [HAS_CHECKED_FOR_EXPIRY] NVARCHAR(500), + [ErrorCode] INTEGER, + [ErrorColumn] INTEGER +) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +-- Create sequence if not exists etl.ETL_DATA_SOURCE_TRACE_ID_SEQ +PRINT N'Create sequence if not exists etl.ETL_DATA_SOURCE_TRACE_ID_SEQ' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +IF NOT EXISTS (SELECT * + FROM sys.objects + WHERE object_id = OBJECT_ID(N'[etl].[ETL_DATA_SOURCE_TRACE_ID_SEQ]') + AND type = 'SO') + CREATE SEQUENCE [etl].[ETL_DATA_SOURCE_TRACE_ID_SEQ] + AS bigint + START WITH 1 + INCREMENT BY 1 + MINVALUE 1 + MAXVALUE 2147483647 + NO CYCLE + CACHE 50 +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +-- Drop table etl.ETL_DATA_SOURCE_TRACE +PRINT N'Drop table etl.ETL_DATA_SOURCE_TRACE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DROP TABLE IF EXISTS [etl].[ETL_DATA_SOURCE_TRACE] +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +-- Create table etl.ETL_DATA_SOURCE_TRACE +PRINT N'Create table etl.ETL_DATA_SOURCE_TRACE' +GO +CREATE TABLE [etl].[ETL_DATA_SOURCE_TRACE] ( + [DATA_SOURCE_TRACE_ID] BIGINT CONSTRAINT [SRCTRC_DATA_SOURCE_TRACE_ID_DEF] DEFAULT NEXT VALUE FOR [etl].[ETL_DATA_SOURCE_TRACE_ID_SEQ] NOT NULL, + [DATA_SOURCE_TYPE_CODE] NVARCHAR(20) NOT NULL, + [DEST_TABLE_NAME] NVARCHAR(100) NOT NULL, + [DEST_COLUMN_NAME] NVARCHAR(100) NOT NULL, + [DEST_COLUMN_VALUE] NVARCHAR(500) NOT NULL, + [SRC_TABLE_NAME] NVARCHAR(100) NOT NULL, + [SRC_COLUMN_NAME] NVARCHAR(100) NOT NULL, + [SRC_COLUMN_VALUE] NVARCHAR(500) NOT NULL, + [ErrorCode] INTEGER, + [ErrorColumn] INTEGER, + [CONCURRENCY_CONTROL_NUMBER] BIGINT CONSTRAINT [SRCTRC_CONCURRENCY_CONTROL_NUMBER_DEF] DEFAULT 1 NOT NULL, + [DB_CREATE_TIMESTAMP] DATETIME CONSTRAINT [SRCTRC_DB_CREATE_TIMESTAMP_DEF] DEFAULT getutcdate() NOT NULL, + [DB_CREATE_USERID] NVARCHAR(30) CONSTRAINT [SRCTRC_DB_CREATE_USERID_DEF] DEFAULT user_name() NOT NULL, + [DB_LAST_UPDATE_TIMESTAMP] DATETIME CONSTRAINT [SRCTRC_DB_LAST_UPDATE_TIMESTAMP_DEF] DEFAULT getutcdate() NOT NULL, + [DB_LAST_UPDATE_USERID] NVARCHAR(30) CONSTRAINT [SRCTRC_DB_LAST_UPDATE_USERID_DEF] DEFAULT user_name() NOT NULL, + CONSTRAINT [PK__ETL_DATA__BD9DF3486EC62F1C] PRIMARY KEY CLUSTERED ([DATA_SOURCE_TRACE_ID]) +) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +ALTER TABLE [etl].[ETL_DATA_SOURCE_TRACE] ADD CONSTRAINT [PIM_PIDSRT_PIM_SRCTRC_FK] + FOREIGN KEY ([DATA_SOURCE_TYPE_CODE]) REFERENCES [dbo].[PIMS_DATA_SOURCE_TYPE] ([DATA_SOURCE_TYPE_CODE]) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +CREATE NONCLUSTERED INDEX [SRCTRC_DATA_SOURCE_TYPE_CODE_IDX] ON [etl].[ETL_DATA_SOURCE_TRACE] ([DATA_SOURCE_TYPE_CODE] ASC) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +CREATE UNIQUE NONCLUSTERED INDEX [SRCTRC_DATA_SOURCE_UK] ON [etl].[ETL_DATA_SOURCE_TRACE] ([DATA_SOURCE_TYPE_CODE] ASC,[DEST_TABLE_NAME] ASC,[DEST_COLUMN_NAME] ASC,[DEST_COLUMN_VALUE] ASC) +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +EXECUTE sp_addextendedproperty N'MS_Description', N'Persistent table to trace the source of ETL data to assist in data matching.', 'SCHEMA', N'etl', 'TABLE', N'ETL_DATA_SOURCE_TRACE', NULL, NULL +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +EXECUTE sp_addextendedproperty N'MS_Description', N'The PIMS destination table name', 'SCHEMA', N'etl', 'TABLE', N'ETL_DATA_SOURCE_TRACE', 'COLUMN', N'DEST_TABLE_NAME' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +EXECUTE sp_addextendedproperty N'MS_Description', N'The PIMS destination column name', 'SCHEMA', N'etl', 'TABLE', N'ETL_DATA_SOURCE_TRACE', 'COLUMN', N'DEST_COLUMN_NAME' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +EXECUTE sp_addextendedproperty N'MS_Description', N'The PIMS destination column value', 'SCHEMA', N'etl', 'TABLE', N'ETL_DATA_SOURCE_TRACE', 'COLUMN', N'DEST_COLUMN_VALUE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +EXECUTE sp_addextendedproperty N'MS_Description', N'The data source table name', 'SCHEMA', N'etl', 'TABLE', N'ETL_DATA_SOURCE_TRACE', 'COLUMN', N'SRC_TABLE_NAME' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +EXECUTE sp_addextendedproperty N'MS_Description', N'The data source column name', 'SCHEMA', N'etl', 'TABLE', N'ETL_DATA_SOURCE_TRACE', 'COLUMN', N'SRC_COLUMN_NAME' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + +EXECUTE sp_addextendedproperty N'MS_Description', N'The data source column value', 'SCHEMA', N'etl', 'TABLE', N'ETL_DATA_SOURCE_TRACE', 'COLUMN', N'SRC_COLUMN_VALUE' +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +COMMIT TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DECLARE @Success AS BIT +SET @Success = 1 +SET NOEXEC OFF +IF (@Success = 1) PRINT 'The database update succeeded' +ELSE BEGIN + IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION + PRINT 'The database update failed' +END +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/04_PSP_PIMS_PMBC_Tables_Build.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/04_PSP_PIMS_PMBC_Tables_Build.sql new file mode 100644 index 0000000000..8e449f0e8c --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/04_PSP_PIMS_PMBC_Tables_Build.sql @@ -0,0 +1,111 @@ +-- Script generated by Aqua Data Studio Schema Synchronization for MS SQL Server 2016 on Tue Oct 05 16:47:03 PDT 2021 +-- Execute this script on: +-- PIMS_S09_01/pmbc - This database/schema will be modified +-- to synchronize it with MS SQL Server 2016: +-- PIMS_S09_02/pmbc + +-- We recommend backing up the database prior to executing the script. + +SET XACT_ABORT ON +GO +SET TRANSACTION ISOLATION LEVEL SERIALIZABLE +GO +BEGIN TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO + + +-- Create table pmbc.PMBC_PARCEL_POLYGON_FABRIC if not existing +PRINT N'Create table pmbc.PMBC_PARCEL_POLYGON_FABRIC' +GO +IF NOT EXISTS (SELECT * + FROM information_schema.tables + WHERE table_schema = 'pmbc' + AND table_name = 'PMBC_PARCEL_POLYGON_FABRIC') + BEGIN + CREATE TABLE [pmbc].[PMBC_PARCEL_POLYGON_FABRIC] ( + [PARCEL_FABRIC_POLY_ID] INTEGER NOT NULL, + [GLOBAL_UID] NVARCHAR(254), + [PARCEL_NAME] NVARCHAR(50), + [PLAN_ID] INTEGER, + [PLAN_NUMBER] NVARCHAR(128), + [PIN] INTEGER, + [PID] NVARCHAR(9), + [PID_NUMBER] INTEGER, + [SOURCE_PARCEL_ID] NVARCHAR(50), + [PARCEL_STATUS] NVARCHAR(20), + [PARCEL_CLASS] NVARCHAR(50), + [OWNER_TYPE] NVARCHAR(50), + [PARCEL_START_DATE] DATETIME, + [SURVEY_DESIGNATION_1] NVARCHAR(30), + [SURVEY_DESIGNATION_2] NVARCHAR(30), + [SURVEY_DESIGNATION_3] NVARCHAR(30), + [LEGAL_DESCRIPTION] NVARCHAR(2000), + [MUNICIPALITY] NVARCHAR(254), + [REGIONAL_DISTRICT] NVARCHAR(50), + [IS_REMAINDER_IND] NVARCHAR(3), + [GEOMETRY_SOURCE] NVARCHAR(50), + [POSITIONAL_ERROR] BIGINT, + [ERROR_REPORTED_BY] NVARCHAR(50), + [CAPTURE_METHOD] NVARCHAR(50), + [COMPILED_IND] NVARCHAR(5), + [STATED_AREA] NVARCHAR(50), + [WHEN_CREATED] DATETIME, + [WHEN_UPDATED] DATETIME, + [FEATURE_AREA_SQM] BIGINT, + [FEATURE_LENGTH_M] BIGINT, + [SHAPE] GEOMETRY, + [OBJECTID] NUMERIC(38), + [SE_ANNO_CAD_DATA] VARBINARY(max), + CONSTRAINT [PRCPLY_PK] PRIMARY KEY ([PARCEL_FABRIC_POLY_ID]) + ) + EXECUTE sp_addextendedproperty N'MS_Description', N'The ParcelMap BC (PMBC) parcel fabric contains all active titled parcels and surveyed provincial Crown land parcels in BC. For building strata parcels, there is a record, with PID value, for each parcel within the strata parcel; the geometry for those records is the geometry for the overall strata. This dataset is polygonal and contains all parcel attributes.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', NULL, NULL + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_FABRIC_POLY_ID is a system generated unique identification number.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_FABRIC_POLY_ID' + EXECUTE sp_addextendedproperty N'MS_Description', N'GLOBAL_UID is a unique global identifier (GUID) for the parcel.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'GLOBAL_UID' + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_NAME is the same as the PID, if there is one. If there is a PIN but no PID, then PARCEL_NAME is the PIN. If there is no PID nor PIN, then PARCEL_NAME is the parcel class value, e.g., COMMON OWNERSHIP, BUILDING STRATA, AIR SPACE, ROAD, PARK.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_NAME' + EXECUTE sp_addextendedproperty N'MS_Description', N'PLAN_ID is the unique identifier of the land survey plan that corresponds to this parcel.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PLAN_ID' + EXECUTE sp_addextendedproperty N'MS_Description', N'PLAN_NUMBER is the Land Act, Land Title Act, or Strata Property Act Plan Number for the land survey plan that corresponds to this parcel, e.g., VIP1632, NO_PLAN.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PLAN_NUMBER' + EXECUTE sp_addextendedproperty N'MS_Description', N'PIN is the Crown Land Registry Parcel Identifier, if applicable.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PIN' + EXECUTE sp_addextendedproperty N'MS_Description', N'PID is the Land Title Register parcel identifier, a left-zero-padded nine-digit number that uniquely identifies a parcel in the land title register of in British Columbia. The registrar assigns PID numbers to parcels for which a title is being entered as a registered title. The Land Title Act refers to the PID as the permanent parcel identifier.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PID' + EXECUTE sp_addextendedproperty N'MS_Description', N'PID_NUMBER is the PID, without leading zeroes. PID is the Land Title Register parcel identifier, a nine-digit number that uniquely identifies a parcel in the land title register of in British Columbia. The registrar assigns PID numbers to parcels for which a title is being entered as a registered title. The Land Title Act refers to the PID as the permanent parcel identifier.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PID_NUMBER' + EXECUTE sp_addextendedproperty N'MS_Description', N'SOURCE_PARCEL_ID is the unique parcel identifier supplied by the source data provider. The value is intended to assist local governments by providing traceability back to the source data provider''s parcel ID. It will not be populated during on-going operations, e.g., DATA_NEW, CPG000050, 999, 01762.146.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SOURCE_PARCEL_ID' + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_STATUS is the status of the parcel, according to the Land Title Register or Crown Land Registry, as appropriate, i.e., ACTIVE, CANCELLED, INACTIVE, PENDING.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_STATUS' + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_CLASS is the Parcel classification for maintenance, mapping, publishing and analysis, i.e., PRIMARY, SUBDIVISION, PART OF PRIMARY, BUILDING STRATA, BARE LAND STRATA, AIR SPACE, ROAD, HIGHWAY, PARK, INTEREST, COMMON OWNERSHIP, ABSOLUTE FEE BOOK, CROWN SUBDIVISION, RETURN TO CROWN.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_CLASS' + EXECUTE sp_addextendedproperty N'MS_Description', N'OWNER_TYPE is the general ownership category, e.g., PRIVATE, CROWN PROVINCIAL, MUNICIPAL.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'OWNER_TYPE' + EXECUTE sp_addextendedproperty N'MS_Description', N'PARCEL_START_DATE is the date of the legal event that created the parcel, i.e., the date the plan was filed.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'PARCEL_START_DATE' + EXECUTE sp_addextendedproperty N'MS_Description', N'SURVEY_DESIGNATION_1 is, typically, the smallest division of lands in a survey. If available, this is generally the Parcel from a Subdivided short legal description or the Quadrant or Block from an Unsubdivided short legal description, e.g., PARCEL A, SW4.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SURVEY_DESIGNATION_1' + EXECUTE sp_addextendedproperty N'MS_Description', N'SURVEY_DESIGNATION_2 is, typically, the second smallest division of lands in a survey. If available, this is generally the Lot from a Subdivided short legal description or the District Lot, Lot or Section from an Unsubdivided short legal description, e.g., LOT 2.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SURVEY_DESIGNATION_2' + EXECUTE sp_addextendedproperty N'MS_Description', N'SURVEY_DESIGNATION_3 is, typically, the third smallest division of lands in a survey. If available, this is generally the Block from a Subdivided short legal description or the Range from an Unsubdivided short legal description, e.g., BLOCK H.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SURVEY_DESIGNATION_3' + EXECUTE sp_addextendedproperty N'MS_Description', N'LEGAL_DESCRIPTION is the full legal description of the parcel and is primarily recorded from the Land Title Register. Where recorded only in the Crown Land Registry, this attribute is to be populated from Tantalis for the fabric compilation, but maintained by PMBC during on-going operations.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'LEGAL_DESCRIPTION' + EXECUTE sp_addextendedproperty N'MS_Description', N'MUNICIPALITY is the municipal area within which the parcel is located. The value is either RURAL (for parcels in unincorporated regions) or the name of a BC municipality.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'MUNICIPALITY' + EXECUTE sp_addextendedproperty N'MS_Description', N'REGIONAL_DISTRICT is the name of the regional district in which the parcel is located, e.g., CAPITAL REGIONAL DISTRICT.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'REGIONAL_DISTRICT' + EXECUTE sp_addextendedproperty N'MS_Description', N'IS_REMAINDER_IND indicates if the parcel is a remainder of the original, i.e., YES, NO.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'IS_REMAINDER_IND' + EXECUTE sp_addextendedproperty N'MS_Description', N'GEOMETRY_SOURCE is the source of the parcel geometry data, e.g., ICIS CADASTRE, ICF, PMBC OPERATIONS.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'GEOMETRY_SOURCE' + EXECUTE sp_addextendedproperty N'MS_Description', N'POSITIONAL_ERROR is the semi-major axis at the 95% confidence level of the least accurate point of the parcel.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'POSITIONAL_ERROR' + EXECUTE sp_addextendedproperty N'MS_Description', N'ERROR_REPORTED_BY is the organization or process reporting the error, i.e., LSA, DATA COMPILATION.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'ERROR_REPORTED_BY' + EXECUTE sp_addextendedproperty N'MS_Description', N'CAPTURE_METHOD is an indicator of relative accuracy, i.e., UNKNOWN, COGO, SURVEY PLAN DATASET.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'CAPTURE_METHOD' + EXECUTE sp_addextendedproperty N'MS_Description', N'COMPILED_IND indicates if the parcel polygon was generated from inverted dimensions, i.e., True, False. "True" means that the parcel geometry was from a previous source cadastre and not precision input based on plan dimensions.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'COMPILED_IND' + EXECUTE sp_addextendedproperty N'MS_Description', N'STATED_AREA is the area of the parcel, in square metres. It is automatically calculated if misclose is small; it can be edited to reflect the recorded plan value.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'STATED_AREA' + EXECUTE sp_addextendedproperty N'MS_Description', N'WHEN_CREATED is the date and time the source record was created (not the time when it was loaded into the BC Geographic Warehouse).', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'WHEN_CREATED' + EXECUTE sp_addextendedproperty N'MS_Description', N'WHEN_UPDATED is the date and time the source record was last modified (not the time when it was loaded into, or modified in, the BC Geographic Warehouse).', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'WHEN_UPDATED' + EXECUTE sp_addextendedproperty N'MS_Description', N'FEATURE_AREA_SQM is the system calculated area of a two-dimensional polygon in square meters.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'FEATURE_AREA_SQM' + EXECUTE sp_addextendedproperty N'MS_Description', N'FEATURE_LENGTH_M is the system calculated length or perimeter of a geometry in meters.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'FEATURE_LENGTH_M' + EXECUTE sp_addextendedproperty N'MS_Description', N'SHAPE is the column used to reference the spatial coordinates defining the feature.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SHAPE' + EXECUTE sp_addextendedproperty N'MS_Description', N'OBJECTID is a column required by spatial layers that interact with ESRI ArcSDE. It is populated with unique values automatically by SDE.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'OBJECTID' + EXECUTE sp_addextendedproperty N'MS_Description', N'SE_ANNO_CAD_DATA is a binary column used by spatial tools to store annotation, curve features and CAD data when using the SDO_GEOMETRY storage data type.', 'SCHEMA', N'pmbc', 'TABLE', N'PMBC_PARCEL_POLYGON_FABRIC', 'COLUMN', N'SE_ANNO_CAD_DATA' + END + +COMMIT TRANSACTION +GO +IF @@ERROR <> 0 SET NOEXEC ON +GO +DECLARE @Success AS BIT +SET @Success = 1 +SET NOEXEC OFF +IF (@Success = 1) PRINT 'The database update succeeded' +ELSE BEGIN + IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION + PRINT 'The database update failed' +END +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/20_DML_PIMS_STATIC_VARIABLE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/20_DML_PIMS_STATIC_VARIABLE.sql new file mode 100644 index 0000000000..bddcac3685 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/20_DML_PIMS_STATIC_VARIABLE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_STATIC_VARIABLE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_STATIC_VARIABLE +GO + +INSERT INTO PIMS_STATIC_VARIABLE (STATIC_VARIABLE_NAME, STATIC_VARIABLE_VALUE) +VALUES + (N'DBVERSION', N'32.00'), + (N'GST', N'5.0'), + (N'FYSTART', N'01/04/2020'), + (N'FYEND', N'31/03/2021'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/30_DML_PIMS_ADDRESS_USAGE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/30_DML_PIMS_ADDRESS_USAGE_TYPE.sql new file mode 100644 index 0000000000..a5c8d74162 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/30_DML_PIMS_ADDRESS_USAGE_TYPE.sql @@ -0,0 +1,29 @@ +/* ----------------------------------------------------------------------------- +Disable all existing data on the PIMS_ADDRESS_USAGE_TYPE table and insert new +usage type codes. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-09 Initial version +----------------------------------------------------------------------------- */ + +-- Set all current address usage type codes to disabled. +UPDATE PIMS_ADDRESS_USAGE_TYPE +SET IS_DISABLED = CONVERT([bit],(1)) + , CONCURRENCY_CONTROL_NUMBER = CONCURRENCY_CONTROL_NUMBER + 1 +WHERE ADDRESS_USAGE_TYPE_CODE <> 'UNKNOWN'; +GO + +-- Insert the new address usage type codes into the table. +INSERT INTO PIMS_ADDRESS_USAGE_TYPE (ADDRESS_USAGE_TYPE_CODE, DESCRIPTION, IS_DISABLED) +VALUES + (N'MAILADDR', N'Mailing address', CONVERT([bit],(1))), + (N'INSURE', N'Proof of insurance address', CONVERT([bit],(1))), + (N'RENTAL', N'Rental payment address', CONVERT([bit],(1))), + (N'PROPNOTIFY', N'Property notification address', CONVERT([bit],(1))), + (N'PHYSADDR', N'Physical address', CONVERT([bit],(1))), + (N'MAILING', N'Mailing address', CONVERT([bit],(0))), + (N'BILLING', N'Billing address', CONVERT([bit],(0))), + (N'RESIDNT', N'Property address', CONVERT([bit],(0))), + (N'ETLUNKN ', N'ETL unknown address', CONVERT([bit],(0))), + (N'UNKNOWN', N'Unknown address type', CONVERT([bit],(0))); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/31_DML_PIMS_AREA_UNIT_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/31_DML_PIMS_AREA_UNIT_TYPE.sql new file mode 100644 index 0000000000..e6bf1acf0b --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/31_DML_PIMS_AREA_UNIT_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_AREA_UNIT_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-09 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_AREA_UNIT_TYPE +GO + +INSERT INTO PIMS_AREA_UNIT_TYPE (AREA_UNIT_TYPE_CODE, DESCRIPTION) +VALUES + (N'HA', N'Hectares'), + (N'ACRE', N'Acres'), + (N'M2', N'Meters sq'), + (N'FEET2', N'Feet sq'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/32_DML_PIMS_PROPERTY_TENURE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/32_DML_PIMS_PROPERTY_TENURE_TYPE.sql new file mode 100644 index 0000000000..851bb254d8 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/32_DML_PIMS_PROPERTY_TENURE_TYPE.sql @@ -0,0 +1,24 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_TENURE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-09 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_TENURE_TYPE +GO + +INSERT INTO PIMS_PROPERTY_TENURE_TYPE (PROPERTY_TENURE_TYPE_CODE, DESCRIPTION, IS_DISABLED) +VALUES + (N'PL', N'Payable Contract', CONVERT([bit],(1))), + (N'TM', N'Titled Land - MoTI', CONVERT([bit],(1))), + (N'CL', N'Crown Land Reserve', CONVERT([bit],(1))), + (N'TT', N'Titled Land - TFA', CONVERT([bit],(1))), + (N'RW', N'Right of Way', CONVERT([bit],(1))), + (N'CR', N'Closed Road', CONVERT([bit],(1))), + (N'HWYROAD', N'Highway/Road', CONVERT([bit],(0))), + (N'ADJLAND', N'Adjacent Land', CONVERT([bit],(0))), + (N'CLOSEDRD', N'Closed Road', CONVERT([bit],(0))), + (N'UNKNOWN', N'Unknown', CONVERT([bit],(0))); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/33_DML_PIMS_PROPERTY_SERVICE_FILE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/33_DML_PIMS_PROPERTY_SERVICE_FILE_TYPE.sql new file mode 100644 index 0000000000..61ee122fa0 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/33_DML_PIMS_PROPERTY_SERVICE_FILE_TYPE.sql @@ -0,0 +1,24 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_SERVICE_FILE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-16 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_SERVICE_FILE_TYPE +GO + +INSERT INTO PIMS_PROPERTY_SERVICE_FILE_TYPE (PROPERTY_SERVICE_FILE_TYPE_CODE, DESCRIPTION) +VALUES + (N'WATERTEST', N'Test Water'), + (N'MUNGARBAGE', N'Municipal Garbage'), + (N'ACCESS', N'Access'), + (N'NOACCESS', N'No Access'), + (N'MUNWATER', N'Municipal Water'), + (N'ELECTRIC', N'Electricity'), + (N'MUNSEWER', N'Municipal Sewer'), + (N'PHONE', N'Phone'), + (N'GAS', N'Gas'), + (N'SEPTIC', N'Septic'), + (N'WELL', N'Well'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/40_DML_PIMS_CONTACT_METHOD_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/40_DML_PIMS_CONTACT_METHOD_TYPE.sql new file mode 100644 index 0000000000..8b38572e91 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/40_DML_PIMS_CONTACT_METHOD_TYPE.sql @@ -0,0 +1,20 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_CONTACT_METHOD_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-16 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_CONTACT_METHOD_TYPE +GO + +INSERT INTO PIMS_CONTACT_METHOD_TYPE (CONTACT_METHOD_TYPE_CODE, DESCRIPTION) +VALUES + (N'FAX', N'Facsimile machine'), + (N'PERSMOBIL', N'Personal mobile phone'), + (N'PERSPHONE', N'Personal phone'), + (N'WORKMOBIL', N'Work mobile phone'), + (N'WORKPHONE', N'Work phone'), + (N'PERSEMAIL', N'Personal email'), + (N'WORKEMAIL', N'Work email'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/41_DML_PIMS_ORGANIZATION_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/41_DML_PIMS_ORGANIZATION_TYPE.sql new file mode 100644 index 0000000000..0eb1e966c3 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/41_DML_PIMS_ORGANIZATION_TYPE.sql @@ -0,0 +1,22 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ORGANIZATION_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-16 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ORGANIZATION_TYPE +GO + +INSERT INTO PIMS_ORGANIZATION_TYPE (ORGANIZATION_TYPE_CODE, DESCRIPTION) +VALUES + (N'FIRSTNAT', N'First Nations'), + (N'REALTOR', N'Real estate corporation'), + (N'PRIVATE', N'Private owner'), + (N'RAILWAY', N'Railway corporation'), + (N'OTHER', N'Other'), + (N'BCMIN', N'BC Ministry'), + (N'BCREG', N'BC Regional Office'), + (N'BCDIST', N'BC District Office'), + (N'PARTNER', N'Partnership'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/42_DML_PIMS_ACCESS_REQUEST_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/42_DML_PIMS_ACCESS_REQUEST_STATUS_TYPE.sql new file mode 100644 index 0000000000..7e638bca75 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/42_DML_PIMS_ACCESS_REQUEST_STATUS_TYPE.sql @@ -0,0 +1,20 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACCESS_REQUEST_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-16 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACCESS_REQUEST_STATUS_TYPE +GO + +INSERT INTO PIMS_ACCESS_REQUEST_STATUS_TYPE (ACCESS_REQUEST_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'INITIATED', N'Access Request initiated but receipt not acknowedged'), + (N'RECEIVED', N'Access Request confirmed received'), + (N'UNDERREVIEW', N'Access Request under review'), + (N'REVIEWCOMPLETE', N'Access Request review compleeted'), + (N'MOREINFO', N'Access Request requires additional information'), + (N'APPROVED', N'Access Request approved'), + (N'DENIED', N'Access Request denied'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/43_DML_PIMS_PROPERTY_CLASSIFICATION_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/43_DML_PIMS_PROPERTY_CLASSIFICATION_TYPE.sql new file mode 100644 index 0000000000..da12e50aa6 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/43_DML_PIMS_PROPERTY_CLASSIFICATION_TYPE.sql @@ -0,0 +1,21 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_CLASSIFICATION_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-16 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_CLASSIFICATION_TYPE +GO + +INSERT INTO PIMS_PROPERTY_CLASSIFICATION_TYPE (PROPERTY_CLASSIFICATION_TYPE_CODE, DESCRIPTION, DISPLAY_ORDER) +VALUES + (N'COREOPER', N'Core Operational', 1), + (N'CORESTRAT', N'Core Strategic', 2), + (N'SURPACTIVE', N'Surplus Active', 3), + (N'SURPENCUM', N'Surplus Encumbered', 4), + (N'DISPOSED', N'Disposed', 5), + (N'DEMOLISHED', N'Demolished', 6), + (N'SUBDIVIDED', N'Subdivided', 7), + (N'UNKNOWN', N'Unknown', 8); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/44_DML_PIMS_PROPERTY_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/44_DML_PIMS_PROPERTY_TYPE.sql new file mode 100644 index 0000000000..1bc36dc45e --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/44_DML_PIMS_PROPERTY_TYPE.sql @@ -0,0 +1,26 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2022-Mar-09 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_TYPE +GO + +INSERT INTO PIMS_PROPERTY_TYPE (PROPERTY_TYPE_CODE, DESCRIPTION, IS_DISABLED) +VALUES + (N'LAND', N'Land', CONVERT([bit],(1))), + (N'BUILD', N'Buiding', CONVERT([bit],(1))), + (N'SUBDIV', N'Subdivison', CONVERT([bit],(1))), + (N'TITLED', N'Titled', CONVERT([bit],(0))), + (N'HWYROAD', N'Hwy / Road', CONVERT([bit],(0))), + (N'STRATACP', N'Strata Common Property', CONVERT([bit],(0))), + (N'CROWNPSRVD', N'Crown - Provincial - Surveyed', CONVERT([bit],(0))), + (N'CROWNPUSRVD', N'Crown - Provincial - Unsurveyed', CONVERT([bit],(0))), + (N'CROWNFSRVD', N'Crown - Federal - Surveyed', CONVERT([bit],(0))), + (N'CROWNFUSRVD', N'Crown - Federal - Unsurveyed', CONVERT([bit],(0))), + (N'RESERVE', N'Reserve (IR)', CONVERT([bit],(0))), + (N'PARKS', N'Parks', CONVERT([bit],(0))), + (N'UNKNOWN', N'Unknown', CONVERT([bit],(0))); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/45_DML_PIMS_COUNTRY.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/45_DML_PIMS_COUNTRY.sql new file mode 100644 index 0000000000..83e54ae1ad --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/45_DML_PIMS_COUNTRY.sql @@ -0,0 +1,20 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_COUNTRY table and repopulate. + +*** NOTE *** +The PIMS_PROVINCE_STATE table must be empty due to a foreign key dependency. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-09 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_COUNTRY +GO + +INSERT INTO PIMS_COUNTRY (COUNTRY_ID, COUNTRY_CODE, DESCRIPTION, DISPLAY_ORDER) +VALUES + (1, N'CA', N'Canada', 1), + (2, N'US', N'United States of America', 2), + (3, N'MX', N'Mexico', 3), + (4, N'OTHER', N'Other', 99); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/46_DML_PIMS_PROVINCE_STATE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/46_DML_PIMS_PROVINCE_STATE.sql new file mode 100644 index 0000000000..82f7b44dc8 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/46_DML_PIMS_PROVINCE_STATE.sql @@ -0,0 +1,81 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROVINCE_STATE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-09 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROVINCE_STATE +GO + +INSERT INTO PIMS_PROVINCE_STATE (PROVINCE_STATE_ID, PROVINCE_STATE_CODE, DESCRIPTION, COUNTRY_ID, DISPLAY_ORDER) +VALUES + (1, N'BC', N'British Columbia', 1, 10), + (2, N'AB', N'Alberta', 1, 20), + (3, N'MB', N'Manitoba', 1, 30), + (4, N'NL', N'Newfoundland', 1, 40), + (5, N'NB', N'New Brunswick', 1, 50), + (6, N'NS', N'Nova Scotia', 1, 60), + (7, N'NT', N'North West Territories', 1, 70), + (8, N'NU', N'Nunavut', 1, 80), + (9, N'ON', N'Ontario', 1, 90), + (10, N'PE', N'Prince Edward Island', 1, 100), + (11, N'QC', N'Quebec', 1, 110), + (12, N'SK', N'Saskatchewan', 1, 120), + (13, N'YT', N'Yukon Territory', 1, 130), + (14, N'AK', N'Alaska', 2, 140), + (15, N'AL', N'Alabama', 2, 150), + (16, N'AR', N'Arkansas', 2, 160), + (17, N'AZ', N'Arizona', 2, 170), + (18, N'CA', N'California', 2, 180), + (19, N'CO', N'Colorado', 2, 190), + (20, N'CT', N'Connecticut', 2, 200), + (21, N'DC', N'District Of Columbia', 2, 210), + (22, N'DE', N'Delaware', 2, 220), + (23, N'FL', N'Florida', 2, 230), + (24, N'GA', N'Georgia', 2, 240), + (25, N'HI', N'Hawaii', 2, 250), + (26, N'IA', N'Iowa', 2, 260), + (27, N'ID', N'Idaho', 2, 270), + (28, N'IL', N'Illinois', 2, 280), + (29, N'IN', N'Indiana', 2, 290), + (30, N'KS', N'Kansas', 2, 300), + (31, N'KY', N'Kentucky', 2, 310), + (32, N'LA', N'Louisiana', 2, 320), + (33, N'MA', N'Massachusetts', 2, 330), + (34, N'MD', N'Maryland', 2, 340), + (35, N'ME', N'Maine', 2, 350), + (36, N'MI', N'Michigan', 2, 360), + (37, N'MN', N'Minnesota', 2, 370), + (38, N'MO', N'Missouri', 2, 380), + (39, N'MS', N'Mississippi', 2, 390), + (40, N'MT', N'Montana', 2, 400), + (41, N'NC', N'North Carolina', 2, 410), + (42, N'ND', N'North Dakota', 2, 420), + (43, N'NE', N'Nebraska', 2, 430), + (44, N'NH', N'New Hampshire', 2, 440), + (45, N'NJ', N'New Jersey', 2, 450), + (46, N'NM', N'New Mexico', 2, 460), + (47, N'NV', N'Nevada', 2, 470), + (48, N'NY', N'New York', 2, 480), + (49, N'OH', N'Ohio', 2, 490), + (50, N'OK', N'Oklahoma', 2, 500), + (51, N'OR', N'Oregon', 2, 510), + (52, N'PA', N'Pennsylvania', 2, 520), + (53, N'RI', N'Rhode Island', 2, 530), + (54, N'SC', N'South Carolina', 2, 540), + (55, N'SD', N'South Dakota', 2, 550), + (56, N'TN', N'Tennessee', 2, 560), + (57, N'TX', N'Texas', 2, 570), + (58, N'UT', N'Utah', 2, 580), + (59, N'VA', N'Virginia', 2, 590), + (60, N'VT', N'Vermont', 2, 600), + (61, N'WA', N'Washington', 2, 610), + (62, N'WI', N'Wisconsin', 2, 620), + (63, N'WV', N'West Virginia', 2, 630), + (64, N'WY', N'Wyoming', 2, 640), + (65, N'MX', N'Mexico', 3, 900), + (78, N'OTHER', N'Other', 4, 99995), + (79, N'XX', N'Unknown', 4, 99999); +GO \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/47_DML_PIMS_REGION.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/47_DML_PIMS_REGION.sql new file mode 100644 index 0000000000..4962206920 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/47_DML_PIMS_REGION.sql @@ -0,0 +1,21 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_REGION table and repopulate. + +*** NOTE *** +The PIMS_DISTRICT table must be empty due to a foreign key dependency. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-09 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_REGION; +GO + +INSERT INTO PIMS_REGION (REGION_CODE, REGION_NAME) +VALUES + (1, N'South Coast Region'), + (2, N'Southern Interior Region'), + (3, N'Northern Region'), + (4, N'Cannot determine'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/48_DML_PIMS_DISTRICT.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/48_DML_PIMS_DISTRICT.sql new file mode 100644 index 0000000000..0ee182dd50 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/48_DML_PIMS_DISTRICT.sql @@ -0,0 +1,26 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_DISTRICT table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-09 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_DISTRICT; +GO + +INSERT INTO PIMS_DISTRICT (DISTRICT_CODE, REGION_CODE, DISTRICT_NAME) +VALUES + (1, 1, N'Lower Mainland District'), + (2, 1, N'Vancouver Island District'), + (3, 2, N'Rocky Mountain District'), + (4, 2, N'West Kootenay District'), + (5, 2, N'Okanagan-Shuswap District'), + (6, 2, N'Thompson-Nicola District'), + (7, 2, N'Cariboo District'), + (8, 3, N'Peace District'), + (9, 3, N'Fort George District'), + (10, 3, N'Bulkley-Stikine District'), + (11, 3, N'Skeena District'), + (12, 4, N'Cannot determine'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/49_DML_PIMS_PROPERTY_DATA_SOURCE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/49_DML_PIMS_PROPERTY_DATA_SOURCE_TYPE.sql new file mode 100644 index 0000000000..6d4d688286 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/49_DML_PIMS_PROPERTY_DATA_SOURCE_TYPE.sql @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_DATA_SOURCE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-16 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_DATA_SOURCE_TYPE +GO + +INSERT INTO PIMS_DATA_SOURCE_TYPE (DATA_SOURCE_TYPE_CODE, DESCRIPTION) +VALUES + (N'OPSS', N'Operational Spreadsheet'), + (N'LIS', N'Lease Information System (LIS)'), + (N'PAIMS', N'Property Acquisition and Inventory Management System (PAIMS)'), + (N'GAZ', N'BC Gazette'), + (N'PMBC', N'ParcelMap BC'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/50_DML_PIMS_ORG_IDENTIFIER_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/50_DML_PIMS_ORG_IDENTIFIER_TYPE.sql new file mode 100644 index 0000000000..21f8b9af38 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/50_DML_PIMS_ORG_IDENTIFIER_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ORG_IDENTIFIER_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Jul-16 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ORG_IDENTIFIER_TYPE +GO + +INSERT INTO PIMS_ORG_IDENTIFIER_TYPE (ORG_IDENTIFIER_TYPE_CODE, DESCRIPTION) +VALUES + (N'BCeIDBUSINESS', N'A BC electronic identifier that allows businesses to connect to the BC Government to manage a variety of company information'), + (N'GUID', N'A global unique identifier for an Organization that is a user of the Property Information Management System'), + (N'GOV', N'A Government organization identifier'), + (N'OTHINCORPNO', N'Other form of identifier for an Organization'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/51_DML_PIMS_ROLE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/51_DML_PIMS_ROLE.sql new file mode 100644 index 0000000000..b2d7141df6 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/51_DML_PIMS_ROLE.sql @@ -0,0 +1,14 @@ +DELETE FROM PIMS_ROLE +GO + +INSERT INTO PIMS_ROLE (ROLE_UID, NAME, DESCRIPTION, IS_PUBLIC, IS_DISABLED, SORT_ORDER, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + (NEWID(), N'System Administrator', N'System Administrator of the PIMS solution.', CONVERT([bit],(0)), CONVERT([bit],(0)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (NEWID(), N'Organization Administrator', N'Administrator of the user''s organization.', CONVERT([bit],(0)), CONVERT([bit],(1)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (NEWID(), N'Undetermined', N'The user has an undetermined role with their organization.', CONVERT([bit],(0)), CONVERT([bit],(1)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (NEWID(), N'Real Estate Manager', N'Real Estate Manager can manage properties within their agency.', CONVERT([bit],(1)), CONVERT([bit],(1)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (NEWID(), N'Real Estate Analyst', N'Real Estate Analyst can manage properties within their organization.', CONVERT([bit],(1)), CONVERT([bit],(1)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (NEWID(), N'Finance', N'Finance team members.', CONVERT([bit],(1)), CONVERT([bit],(0)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (NEWID(), N'Functional', N'PLMB staff (includes team members from HQ, regions and districts).', CONVERT([bit],(1)), CONVERT([bit],(0)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (NEWID(), N'Functional (Restricted)', N'Contractors, Internal ministry staff.', CONVERT([bit],(1)), CONVERT([bit],(0)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (NEWID(), N'Read Only', N'Other ministries (e.g. Attorney General).', CONVERT([bit],(1)), CONVERT([bit],(0)), 0, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/52_DML_PIMS_PROPERTY_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/52_DML_PIMS_PROPERTY_STATUS_TYPE.sql new file mode 100644 index 0000000000..196825d344 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/52_DML_PIMS_PROPERTY_STATUS_TYPE.sql @@ -0,0 +1,20 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_STATUS_TYPE +GO + +INSERT INTO PIMS_PROPERTY_STATUS_TYPE (PROPERTY_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'ARTHWY', N'Arterial highway'), + (N'FEESIMP', N'Fee simple'), + (N'CROWNLND', N'Crown land'), + (N'MOTIADMIN', N'Under MoTI administration'), + (N'UNSURVYED', N'Unsurveyed travelled road (i.e. Section42)'), + (N'UNDERSCRUT', N'Properties under scrutiny'), + (N'UNKNOWN', N'Unknown'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/53_DML_PIMS_LEASE_PAY_RVBL_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/53_DML_PIMS_LEASE_PAY_RVBL_TYPE.sql new file mode 100644 index 0000000000..f327db9235 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/53_DML_PIMS_LEASE_PAY_RVBL_TYPE.sql @@ -0,0 +1,16 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_PAY_RVBL_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_PAY_RVBL_TYPE +GO + +INSERT INTO PIMS_LEASE_PAY_RVBL_TYPE (LEASE_PAY_RVBL_TYPE_CODE, DESCRIPTION) +VALUES + (N'RCVBL', N'Receivable'), + (N'PYBLMOTI', N'Payable (MOTI as tenant)'), + (N'PYBLBCTFA', N'Payable (BCTFA as tenant)'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/54_DML_PIMS_LEASE_LICENSE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/54_DML_PIMS_LEASE_LICENSE_TYPE.sql new file mode 100644 index 0000000000..bc2976bb34 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/54_DML_PIMS_LEASE_LICENSE_TYPE.sql @@ -0,0 +1,27 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_LICENSE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_LICENSE_TYPE +GO + +INSERT INTO PIMS_LEASE_LICENSE_TYPE (LEASE_LICENSE_TYPE_CODE, DESCRIPTION) +VALUES + (N'LSREG', N'Lease - Registered'), + (N'LSUNREG', N'Lease - Unregistered'), + (N'LSGRND', N'Ground Lease'), + (N'LIOCCTTLD', N'License of Occupation (titled)'), + (N'LIOCCUSE', N'License of Occupation (use)'), + (N'LIOCCACCS', N'License of Occupation (access)'), + (N'LIOCCUTIL', N'License of Occupation (utilities)'), + (N'LICONSTRC', N'License to Construct'), + (N'LIPPUBHWY', N'License of Prov Public Highway'), + (N'RESLNDTEN', N'Residential Tenancy Act'), + (N'LIMOTIPRJ', N'MOTI Project Use License'), + (N'MANUFHOME', N'Manufactured Home Act'), + (N'ROADXING', N'Road Crossing'), + (N'OTHER', N'Other'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/55_DML_PIMS_LEASE_CATEGORY_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/55_DML_PIMS_LEASE_CATEGORY_TYPE.sql new file mode 100644 index 0000000000..84c120f8af --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/55_DML_PIMS_LEASE_CATEGORY_TYPE.sql @@ -0,0 +1,19 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_CATEGORY_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_CATEGORY_TYPE +GO + +INSERT INTO PIMS_LEASE_CATEGORY_TYPE (LEASE_CATEGORY_TYPE_CODE, DESCRIPTION) +VALUES + (N'RESID', N'Residential'), + (N'COMM', N'Commercial'), + (N'INDUS', N'Industrial'), + (N'AGRIC', N'Agricultural'), + (N'OTHER', N'Other'), + (N'GOVGOV', N'Gov''t to Gov''t'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/56_DML_PIMS_LEASE_PURPOSE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/56_DML_PIMS_LEASE_PURPOSE_TYPE.sql new file mode 100644 index 0000000000..2b92249fd9 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/56_DML_PIMS_LEASE_PURPOSE_TYPE.sql @@ -0,0 +1,52 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_PURPOSE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_PURPOSE_TYPE +GO + +INSERT INTO PIMS_LEASE_PURPOSE_TYPE (LEASE_PURPOSE_TYPE_CODE, DESCRIPTION) +VALUES + (N'ACCRES', N'Access (Residential)'), + (N'ACCCCOM', N'Access (Industrial/Commercial)'), + (N'AGRIC', N'Agricultural'), + (N'COMMBLDG', N'Commercial Building'), + (N'CAMPING', N'Camping'), + (N'XING', N'Crossing'), + (N'ENCROACH', N'Encroachment'), + (N'FENCEGATE', N'Fencing/Gate'), + (N'MARINEFAC', N'Marine Facility'), + (N'EMERGSVCS', N'Emergency Services'), + (N'BCFERRIES', N'BC Ferries'), + (N'GARDENING', N'Gardening'), + (N'GRAVEL', N'Gravel'), + (N'GRAZING', N'Grazing'), + (N'SIDEWALK', N'Sidewalks/Landscaping'), + (N'LOGGING', N'Logging/Timber Harvest'), + (N'MTCYARD', N'Maintenance Yard'), + (N'MOBILEHM', N'Mobile Home Pad'), + (N'OTHER', N'Other*'), + (N'PARK', N'Park'), + (N'PARKNRID', N'Park and Ride'), + (N'PARKING', N'Parking'), + (N'PIPELINE', N'Pipeline'), + (N'PRVTRANS', N'Private transportation'), + (N'PRELOAD', N'Preload'), + (N'RAILWAY', N'Railway'), + (N'RESTAREA', N'Rest Area/Pullout'), + (N'SIGNAGE', N'Signage'), + (N'SPCLEVNT', N'Special Event'), + (N'STGNGAREA', N'Staging Area'), + (N'STKPILING', N'Stockpiling'), + (N'STORAGE', N'Storage'), + (N'TOURINFO', N'Tourist Info'), + (N'TRAIL', N'Trail'), + (N'UTILINFRA', N'Utilities-infrastructure'), + (N'UTILOHDXG', N'Utilities-overhead xing'), + (N'UTILUGDXG', N'Utilities-underground xing'), + (N'WATERRES', N'Water Reservoir'), + (N'WEIGHSCL', N'Weigh Scale'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/57_DML_PIMS_LEASE_PROGRAM_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/57_DML_PIMS_LEASE_PROGRAM_TYPE.sql new file mode 100644 index 0000000000..00dbe15bff --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/57_DML_PIMS_LEASE_PROGRAM_TYPE.sql @@ -0,0 +1,24 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_PROGRAM_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_PROGRAM_TYPE +GO + +INSERT INTO PIMS_LEASE_PROGRAM_TYPE (LEASE_PROGRAM_TYPE_CODE, DESCRIPTION) +VALUES + (N'BCFERRIES', N'BC Ferries'), + (N'BCTRANSIT', N'BC Transit'), + (N'BELLETERM', N'Belleville Terminal'), + (N'COMMBLDG', N'Commercial Buildings'), + (N'LCLGOVT', N'Local Government/RCMP'), + (N'OTHER', N'Other Licencing'), + (N'RAILTRAIL', N'Rail Trails'), + (N'RESRENTAL', N'Residential Rentals'), + (N'TMEP', N'TMEP'), + (N'TRANSLINK', N'TransLink'), + (N'UTILITY', N'Utilities'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/58_DML_PIMS_LEASE_PMT_FREQ_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/58_DML_PIMS_LEASE_PMT_FREQ_TYPE.sql new file mode 100644 index 0000000000..87e016d9cd --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/58_DML_PIMS_LEASE_PMT_FREQ_TYPE.sql @@ -0,0 +1,23 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_PMT_FREQ_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_PMT_FREQ_TYPE +GO + +INSERT INTO PIMS_LEASE_PMT_FREQ_TYPE (LEASE_PMT_FREQ_TYPE_CODE, DESCRIPTION) +VALUES + (N'ANNUAL', N'Annually'), + (N'SEMIANN', N'Semi Annually'), + (N'QUARTER', N'Quarterly'), + (N'BIMONTH', N'Bi-Monthly'), + (N'MONTHLY', N'Monthly'), + (N'BIWEEK', N'Bi-Weekly'), + (N'WEEKLY', N'Weekly'), + (N'DAILY', N'Daily'), + (N'PREPAID', N'Prepaid / One Time'), + (N'NOMINAL', N'Nominal ($1)'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/59_DML_PIMS_PROPERTY_TAX_REMIT_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/59_DML_PIMS_PROPERTY_TAX_REMIT_TYPE.sql new file mode 100644 index 0000000000..e47eb6902e --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/59_DML_PIMS_PROPERTY_TAX_REMIT_TYPE.sql @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_TAX_REMIT_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_TAX_REMIT_TYPE +GO + +INSERT INTO PIMS_PROPERTY_TAX_REMIT_TYPE (PROPERTY_TAX_REMIT_TYPE_CODE, DESCRIPTION) +VALUES + (N'LESSEE', N'Lessee'), + (N'LICENSEE', N'Licensee'), + (N'PERMITEE', N'Permitee'), + (N'BCTFA', N'BCTFA'), + (N'OTHER', N'Other'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/61_DML_PIMS_SURPLUS_DECLARATION_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/61_DML_PIMS_SURPLUS_DECLARATION_TYPE.sql new file mode 100644 index 0000000000..ca21bdfee2 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/61_DML_PIMS_SURPLUS_DECLARATION_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_SURPLUS_DECLARATION_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_SURPLUS_DECLARATION_TYPE +GO + +INSERT INTO PIMS_SURPLUS_DECLARATION_TYPE (SURPLUS_DECLARATION_TYPE_CODE, DESCRIPTION) +VALUES + (N'YES', N'Yes'), + (N'NO', N'No'), + (N'EXPIRED', N'Expired'), + (N'UNKNOWN', N'Unknown'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/62_DML_PIMS_PROPERTY_IMPROVEMENT_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/62_DML_PIMS_PROPERTY_IMPROVEMENT_TYPE.sql new file mode 100644 index 0000000000..3b29a7551f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/62_DML_PIMS_PROPERTY_IMPROVEMENT_TYPE.sql @@ -0,0 +1,16 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_IMPROVEMENT_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_IMPROVEMENT_TYPE +GO + +INSERT INTO PIMS_PROPERTY_IMPROVEMENT_TYPE (PROPERTY_IMPROVEMENT_TYPE_CODE, DESCRIPTION, DISPLAY_ORDER) +VALUES + (N'RTA', N'Residential Tenancy Act', 2), + (N'COMMBLDG', N'Commercial Building', 1), + (N'OTHER', N'Other', 99); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/64_DML_PIMS_SECURITY_DEPOSIT_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/64_DML_PIMS_SECURITY_DEPOSIT_TYPE.sql new file mode 100644 index 0000000000..e658766533 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/64_DML_PIMS_SECURITY_DEPOSIT_TYPE.sql @@ -0,0 +1,16 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_SECURITY_DEPOSIT_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_SECURITY_DEPOSIT_TYPE +GO + +INSERT INTO PIMS_SECURITY_DEPOSIT_TYPE (SECURITY_DEPOSIT_TYPE_CODE, DESCRIPTION) +VALUES + (N'SECURITY', N'Security deposit'), + (N'PET', N'Pet deposit'), + (N'OTHER', N'Other deposit'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/65_DML_PIMS_LESSOR_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/65_DML_PIMS_LESSOR_TYPE.sql new file mode 100644 index 0000000000..94ecde2bad --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/65_DML_PIMS_LESSOR_TYPE.sql @@ -0,0 +1,15 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LESSOR_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LESSOR_TYPE +GO + +INSERT INTO PIMS_LESSOR_TYPE (LESSOR_TYPE_CODE, DESCRIPTION) +VALUES + (N'PER', N'Person'), + (N'ORG', N'Organization'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/66_DML_PIMS_LEASE_INITIATOR_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/66_DML_PIMS_LEASE_INITIATOR_TYPE.sql new file mode 100644 index 0000000000..ea30bd2d8f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/66_DML_PIMS_LEASE_INITIATOR_TYPE.sql @@ -0,0 +1,16 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_INITIATOR_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_INITIATOR_TYPE +GO + +INSERT INTO PIMS_LEASE_INITIATOR_TYPE (LEASE_INITIATOR_TYPE_CODE, DESCRIPTION) +VALUES + (N'PROJECT', N'Project'), + (N'REGION', N'Region'), + (N'HQ', N'Headquarters'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/67_DML_PIMS_LEASE_RESPONSIBILITY_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/67_DML_PIMS_LEASE_RESPONSIBILITY_TYPE.sql new file mode 100644 index 0000000000..9093166577 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/67_DML_PIMS_LEASE_RESPONSIBILITY_TYPE.sql @@ -0,0 +1,16 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_RESPONSIBILITY_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_RESPONSIBILITY_TYPE +GO + +INSERT INTO PIMS_LEASE_RESPONSIBILITY_TYPE (LEASE_RESPONSIBILITY_TYPE_CODE, DESCRIPTION) +VALUES + (N'PROJECT', N'Project'), + (N'REGION', N'Region'), + (N'HQ', N'Headquarters'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/68_DML_PIMS_LEASE_TERM_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/68_DML_PIMS_LEASE_TERM_STATUS_TYPE.sql new file mode 100644 index 0000000000..6e5c042fe9 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/68_DML_PIMS_LEASE_TERM_STATUS_TYPE.sql @@ -0,0 +1,15 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_TERM_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_TERM_STATUS_TYPE +GO + +INSERT INTO PIMS_LEASE_TERM_STATUS_TYPE (LEASE_TERM_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'EXER', N'Exercised'), + (N'NEXER', N'Not Exercised'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/70_DML_PIMS_LEASE_PAYMENT_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/70_DML_PIMS_LEASE_PAYMENT_STATUS_TYPE.sql new file mode 100644 index 0000000000..59f6f451a7 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/70_DML_PIMS_LEASE_PAYMENT_STATUS_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_PAYMENT_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_PAYMENT_STATUS_TYPE +GO + +INSERT INTO PIMS_LEASE_PAYMENT_STATUS_TYPE (LEASE_PAYMENT_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'PAID', N'Paid'), + (N'UNPAID', N'Unpaid'), + (N'PARTIAL', N'Partial'), + (N'OVERPAID', N'Overpayment'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/71_DML_PIMS_LEASE_PAYMENT_METHOD_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/71_DML_PIMS_LEASE_PAYMENT_METHOD_TYPE.sql new file mode 100644 index 0000000000..d4797f63d7 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/71_DML_PIMS_LEASE_PAYMENT_METHOD_TYPE.sql @@ -0,0 +1,20 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_PAYMENT_METHOD_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_PAYMENT_METHOD_TYPE +GO + +INSERT INTO PIMS_LEASE_PAYMENT_METHOD_TYPE (LEASE_PAYMENT_METHOD_TYPE_CODE, DESCRIPTION) +VALUES + (N'CASH', N'Cash'), + (N'CHEQ', N'Cheque'), + (N'POST', N'Post-dated cheque'), + (N'CRDR', N'Credit / Debit'), + (N'EFT', N'EFT'), + (N'OTHR', N'Other'), + (N'H120', N'H120'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/72_DML_PIMS_INSURANCE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/72_DML_PIMS_INSURANCE_TYPE.sql new file mode 100644 index 0000000000..f7552d6856 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/72_DML_PIMS_INSURANCE_TYPE.sql @@ -0,0 +1,19 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_INSURANCE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_INSURANCE_TYPE +GO + +INSERT INTO PIMS_INSURANCE_TYPE (INSURANCE_TYPE_CODE, DESCRIPTION, DISPLAY_ORDER) +VALUES + (N'GENERAL', N'Commercial General Liability (CGL)', 2), + (N'VEHICLE', N'Vehicle Liability Coverage', 4), + (N'AIRCRAFT', N'Aircraft Liability Coverage', 1), + (N'MARINE', N'Marine Liability Coverage', 3), + (N'OTHER', N'Other Insurance Coverage', 99); + \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/73_DML_PIMS_LEASE_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/73_DML_PIMS_LEASE_STATUS_TYPE.sql new file mode 100644 index 0000000000..560a886078 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/73_DML_PIMS_LEASE_STATUS_TYPE.sql @@ -0,0 +1,19 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LEASE_STATUS_TYPE +GO + +INSERT INTO PIMS_LEASE_STATUS_TYPE (LEASE_STATUS_TYPE_CODE, DESCRIPTION, IS_DISABLED) +VALUES + (N'ACTIVE', N'Active', CONVERT([bit],(0))), + (N'EXPIRED', N'Expired', CONVERT([bit],(1))), + (N'TERMINATED', N'Terminated', CONVERT([bit],(0))), + (N'DRAFT', N'Draft', CONVERT([bit],(0))), + (N'DISCARD', N'Discarded', CONVERT([bit],(0))), + (N'INACTIVE', N'Inactive', CONVERT([bit],(0))); diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/74_DML_PIMS_CLAIM.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/74_DML_PIMS_CLAIM.sql new file mode 100644 index 0000000000..250192d8aa --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/74_DML_PIMS_CLAIM.sql @@ -0,0 +1,90 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_CLAIM table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Devin Smith 2021-Nov-18 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_CLAIM +GO + +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (1, N'a9be4883-9c67-4a0e-9ce2-cbab2fb0ee87', N'system-administrator', N'a9be4883-9c67-4a0e-9ce2-cbab2fb0ee87', N'Ability to administrate system.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:24.493' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:24.483' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (2, N'f8a38d52-e535-4054-ba8d-fb88af416abc', N'organization-administrator', N'f8a38d52-e535-4054-ba8d-fb88af416abc', N'Ability to administrate organizations.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:24.603' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:24.593' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (3, N'a0263138-1d2b-4a34-8331-e9df181802d0', N'admin-users', N'a0263138-1d2b-4a34-8331-e9df181802d0', N'Ability to administrate users.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:24.690' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:24.670' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (4, N'df915c23-84de-4d04-b2f6-c3ab6d1e215b', N'admin-roles', N'df915c23-84de-4d04-b2f6-c3ab6d1e215b', N'Ability to administrate roles.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:24.790' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:24.780' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (5, N'865a322e-c80f-4ed3-8a35-58d634091e63', N'admin-properties', N'865a322e-c80f-4ed3-8a35-58d634091e63', N'Ability to administrate properties.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:24.887' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:24.873' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (6, N'3ab44a68-1404-4d71-9b41-da4aa257a430', N'admin-organizations', N'3ab44a68-1404-4d71-9b41-da4aa257a430', N'Ability to administrate organizations.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:24.987' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:24.967' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (7, N'2e28bc73-d77e-434b-8b6f-effd5019e55f', N'admin-projects', N'2e28bc73-d77e-434b-8b6f-effd5019e55f', N'Ability to administrate projects.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:25.087' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.077' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (8, N'9070efd2-b63c-4d17-9753-e64c8ac2b9cb', N'property-view', N'9070efd2-b63c-4d17-9753-e64c8ac2b9cb', N'Ability to view properties.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:25.190' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.170' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (9, N'4e765676-4c44-4006-86f4-3ba22754ac30', N'property-add', N'4e765676-4c44-4006-86f4-3ba22754ac30', N'Ability to add properties.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:25.290' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.280' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (10, N'e21770e4-a689-4524-97a1-498715683a71', N'property-edit', N'e21770e4-a689-4524-97a1-498715683a71', N'Ability to edit properties.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:25.390' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.373' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (11, N'227c85d3-42fe-4b77-ad34-13df07a3b6ad', N'property-delete', N'227c85d3-42fe-4b77-ad34-13df07a3b6ad', N'Ability to delete properties.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:25.490' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.467' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (12, N'ba44955c-6903-4202-a6d6-c0b5c65156ec', N'sensitive-view', N'ba44955c-6903-4202-a6d6-c0b5c65156ec', N'Ability to view sensitive properties.', 0, 6, CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'system', NULL, N'', CAST(N'2021-11-16T07:42:25.590' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-10-13T04:10:53.897' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.577' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (13, N'671b9624-b576-4379-8b29-e4fea2697974', N'contact-view', N'671b9624-b576-4379-8b29-e4fea2697974', N'Ability view existing contacts.', 0, 3, CAST(N'2021-11-10T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-16T07:42:25.690' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-10T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.670' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (14, N'4a1a9150-7cde-4d58-a1b0-9f8fe48570a0', N'contact-add', N'4a1a9150-7cde-4d58-a1b0-9f8fe48570a0', N'Ability to add new contacts.', 0, 3, CAST(N'2021-11-10T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-16T07:42:25.790' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-10T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.780' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (15, N'606f1744-6f2c-4ca5-97d6-aa0f6e151343', N'contact-edit', N'606f1744-6f2c-4ca5-97d6-aa0f6e151343', N'Ability to edit existing contacts.', 0, 3, CAST(N'2021-11-10T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-16T07:42:25.890' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-10T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.873' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (16, N'386ccfb2-0b3c-47f8-98cb-86bf97c79bd1', N'contact-delete', N'386ccfb2-0b3c-47f8-98cb-86bf97c79bd1', N'Ability to delete contacts.', 0, 3, CAST(N'2021-11-10T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-16T07:42:25.990' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-10T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-16T07:42:25.967' AS DateTime), N'SEED') +GO + +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (17, N'd4953f15-c011-4fed-9146-4f54eeab6029', N'lease-view', N'd4953f15-c011-4fed-9146-4f54eeab6029', N'Ability view existing leases.', 0, 3, CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-29T07:42:25.690' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-29T07:42:25.670' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (18, N'6a3f0a3f-2448-4b5f-97ab-0b361d122e65', N'lease-add', N'6a3f0a3f-2448-4b5f-97ab-0b361d122e65', N'Ability to add new leases.', 0, 3, CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-29T07:42:25.790' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-29T07:42:25.780' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (19, N'20fa0b55-598a-41d3-898b-be5958558f8e', N'lease-edit', N'20fa0b55-598a-41d3-898b-be5958558f8e', N'Ability to edit existing leases.', 0, 3, CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-29T07:42:25.890' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-29T07:42:25.873' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (20, N'95791d9a-986f-48ae-a3b3-1eebb54282cc', N'lease-delete', N'95791d9a-986f-48ae-a3b3-1eebb54282cc', N'Ability to delete leases.', 0, 3, CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-29T07:42:25.990' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-29T07:42:25.967' AS DateTime), N'SEED') +GO + +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (21, N'a9b9075b-2ea5-43b6-91df-2cc075453428', N'ROLE_PIMS_R', N'a9b9075b-2ea5-43b6-91df-2cc075453428', N'Read access to Property-related map layers', 0, 3, CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-29T07:42:25.990' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2021-11-29T02:17:49.903' AS DateTime), N'SEED', CAST(N'2021-11-29T07:42:25.967' AS DateTime), N'SEED') +GO + +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (22, N'e3dc1c05-aae5-46b8-9b80-65a492a72a0a', N'researchfile-view', N'e3dc1c05-aae5-46b8-9b80-65a492a72a0a', N'Ability view existing research files.', 0, 3, CAST(N'2022-04-12T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-04-12T07:42:25.690' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-04-12T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-04-12T07:42:25.670' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (23, N'2e0eefb5-30ac-4d02-8439-fac5c4554dbb', N'researchfile-add', N'2e0eefb5-30ac-4d02-8439-fac5c4554dbb', N'Ability to add new research files.', 0, 3, CAST(N'2022-04-12T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-04-12T07:42:25.790' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-04-12T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-04-12T07:42:25.780' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (24, N'38028c27-0a87-4875-a5d4-40879d13cfd6', N'researchfile-edit', N'38028c27-0a87-4875-a5d4-40879d13cfd6', N'Ability to edit existing research files.', 0, 3, CAST(N'2022-04-12T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-04-12T07:42:25.890' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-04-12T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-04-12T07:42:25.873' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (25, N'6f147aed-e377-40b7-93c4-5ab736378bc6', N'researchfile-delete', N'6f147aed-e377-40b7-93c4-5ab736378bc6', N'Ability to delete research files.', 0, 3, CAST(N'2022-04-12T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-04-12T07:42:25.990' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-04-12T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-04-12T07:42:25.967' AS DateTime), N'SEED') +GO + +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (26, N'53e43047-200a-4315-9f15-e0d3887c05f2', N'acquisitionfile-view', N'53e43047-200a-4315-9f15-e0d3887c05f2', N'Ability view existing acquisition files.', 0, 3, CAST(N'2022-06-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-06-15T07:42:25.690' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-06-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-06-15T07:42:25.670' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (27, N'81537f39-b520-4692-a7b4-40b0a2500bd8', N'acquisitionfile-add', N'81537f39-b520-4692-a7b4-40b0a2500bd8', N'Ability to add new acquisition files.', 0, 3, CAST(N'2022-06-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-06-15T07:42:25.790' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-06-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-06-15T07:42:25.780' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (28, N'8f996eb9-4f1b-4eb0-a40e-d08b453ee804', N'acquisitionfile-edit', N'8f996eb9-4f1b-4eb0-a40e-d08b453ee804', N'Ability to edit existing acquisition files.', 0, 3, CAST(N'2022-06-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-06-15T07:42:25.890' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-06-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-06-15T07:42:25.873' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (29, N'a2916c02-7f0d-42cf-a7aa-5b47379a1e00', N'acquisitionfile-delete', N'a2916c02-7f0d-42cf-a7aa-5b47379a1e00', N'Ability to delete acquisition files.', 0, 3, CAST(N'2022-06-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-06-15T07:42:25.990' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-06-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-06-15T07:42:25.967' AS DateTime), N'SEED') +GO + +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (30, N'595372a3-7a65-4893-84b1-1378dc697e81', N'note-view', N'595372a3-7a65-4893-84b1-1378dc697e81', N'Ability view existing notes.', 0, 3, CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T07:42:25.690' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-07-15T07:42:25.670' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (31, N'bf123896-dbd7-43bc-b9cd-44b844544b3c', N'note-add', N'bf123896-dbd7-43bc-b9cd-44b844544b3c', N'Ability to add new notes.', 0, 3, CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T07:42:25.790' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-07-15T07:42:25.780' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (32, N'363035c7-9ec0-4239-acd9-49aec29d5815', N'note-edit', N'363035c7-9ec0-4239-acd9-49aec29d5815', N'Ability to edit existing notes.', 0, 3, CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T07:42:25.890' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-07-15T07:42:25.873' AS DateTime), N'SEED') +GO +INSERT [dbo].[PIMS_CLAIM] ([CLAIM_ID], [CLAIM_UID], [NAME], [KEYCLOAK_ROLE_ID], [DESCRIPTION], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (33, N'ec671269-8c45-4702-9883-0fff1c6f98ce', N'note-delete', N'ec671269-8c45-4702-9883-0fff1c6f98ce', N'Ability to delete notes.', 0, 3, CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T07:42:25.990' AS DateTime), N'service', N'1b93f614-91da-4b32-b36e-bd2c6ebd12e2', N'', CAST(N'2022-07-15T02:17:49.903' AS DateTime), N'SEED', CAST(N'2022-07-15T07:42:25.967' AS DateTime), N'SEED') +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/75_DML_PIMS_ROLE_CLAIM.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/75_DML_PIMS_ROLE_CLAIM.sql new file mode 100644 index 0000000000..fe84da1623 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/75_DML_PIMS_ROLE_CLAIM.sql @@ -0,0 +1,265 @@ +DECLARE @finance BIGINT; +DECLARE @functional BIGINT; +DECLARE @restricted BIGINT; +DECLARE @readOnly BIGINT; +DECLARE @admin BIGINT; +SELECT @finance = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Finance'; +SELECT @functional = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Functional'; +SELECT @restricted = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Functional (Restricted)'; +SELECT @readOnly = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'Read Only'; +SELECT @admin = ROLE_ID FROM PIMS_ROLE WHERE NAME = 'System Administrator'; + +DECLARE @leaseView BIGINT; +DECLARE @leaseAdd BIGINT; +DECLARE @leaseEdit BIGINT; +DECLARE @leaseDelete BIGINT; +select @leaseView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'lease-view'; +select @leaseAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'lease-add'; +select @leaseEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'lease-edit'; +select @leaseDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'lease-delete'; + +DECLARE @researchView BIGINT; +DECLARE @researchAdd BIGINT; +DECLARE @researchEdit BIGINT; +DECLARE @researchDelete BIGINT; +select @researchView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'researchfile-view'; +select @researchAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'researchfile-add'; +select @researchEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'researchfile-edit'; +select @researchDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'researchfile-delete'; + +DECLARE @propertyView BIGINT; +DECLARE @propertyAdd BIGINT; +DECLARE @propertyEdit BIGINT; +DECLARE @propertyDelete BIGINT; +select @propertyView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'property-view'; +select @propertyAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'property-add'; +select @propertyEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'property-edit'; +select @propertyDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'property-delete'; + +DECLARE @contactView BIGINT; +DECLARE @contactAdd BIGINT; +DECLARE @contactEdit BIGINT; +DECLARE @contactDelete BIGINT; +select @contactView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'contact-view'; +select @contactAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'contact-add'; +select @contactEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'contact-edit'; +select @contactDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'contact-delete'; + +DECLARE @rolePimsR BIGINT; +select @rolePimsR = CLAIM_ID FROM PIMS_CLAIM where NAME = 'ROLE_PIMS_R'; + +DECLARE @adminUsers BIGINT; +DECLARE @adminProjects BIGINT; +DECLARE @adminProperties BIGINT; +DECLARE @systemAdministrator BIGINT; +select @adminUsers = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'admin-users'; +select @adminProjects = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'admin-projects'; +select @adminProperties = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'admin-properties'; +select @systemAdministrator = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'system-administrator'; + +DECLARE @acquisitionView BIGINT; +DECLARE @acquisitionAdd BIGINT; +DECLARE @acquisitionEdit BIGINT; +DECLARE @acquisitionDelete BIGINT; +select @acquisitionView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'acquisitionfile-view'; +select @acquisitionAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'acquisitionfile-add'; +select @acquisitionEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'acquisitionfile-edit'; +select @acquisitionDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'acquisitionfile-delete'; + +DECLARE @noteView BIGINT; +DECLARE @noteAdd BIGINT; +DECLARE @noteEdit BIGINT; +DECLARE @noteDelete BIGINT; +SELECT @noteView = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-view'; +SELECT @noteAdd = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-add'; +SELECT @noteEdit = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-edit'; +SELECT @noteDelete = CLAIM_ID FROM PIMS_CLAIM WHERE NAME = 'note-delete'; + +/* Finance */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@finance, @leaseView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +/* Administrator */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @adminUsers, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @adminProjects, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @adminProperties, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @systemAdministrator, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @leaseView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @leaseEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @leaseAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @leaseDelete, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @researchView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @researchEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @researchAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @researchDelete, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @propertyView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @propertyEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @propertyAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @propertyDelete, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @rolePimsR, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @contactView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @contactEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @contactDelete, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @contactAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @acquisitionView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @acquisitionEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @acquisitionAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@admin, @acquisitionDelete, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@admin, @noteView, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@admin, @noteEdit, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@admin, @noteAdd, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@admin, @noteDelete, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +/* Functional */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @leaseView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @leaseEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @leaseAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @leaseDelete, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @researchView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @researchEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @researchAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @propertyView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @propertyEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @propertyAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @rolePimsR, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @contactView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @contactEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @contactDelete, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @contactAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @acquisitionView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @acquisitionEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@functional, @acquisitionAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@functional, @noteView, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@functional, @noteEdit, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@functional, @noteAdd, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +/* Functional Restricted */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @leaseView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @leaseEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @leaseAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @researchView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @researchEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @propertyView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @propertyEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @propertyAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @rolePimsR, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @contactView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @contactEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @contactDelete, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @contactAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @acquisitionView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @acquisitionEdit, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@restricted, @acquisitionAdd, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@restricted, @noteView, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@restricted, @noteEdit, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@restricted, @noteAdd, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') + +/* Read Only */ +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@readOnly, @leaseView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@readOnly, @researchView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@readOnly, @propertyView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@readOnly, @rolePimsR, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@readOnly, @contactView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES (@readOnly, @acquisitionView, 0, 1, CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED', CAST(N'2021-11-10T02:17:49.920' AS DateTime), N'SEED') + +INSERT [dbo].[PIMS_ROLE_CLAIM] ([ROLE_ID], [CLAIM_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) +VALUES (@readOnly, @noteView, 0, 1, CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', NULL, N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED', CAST(N'2022-07-15T02:17:49.920' AS DateTime), N'SEED') +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/76_DML_PIMS_ORGANIZATION.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/76_DML_PIMS_ORGANIZATION.sql new file mode 100644 index 0000000000..6b8bd60adc --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/76_DML_PIMS_ORGANIZATION.sql @@ -0,0 +1,36 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ORGANIZATION table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ORGANIZATION +GO + +INSERT INTO PIMS_ORGANIZATION ( + ORGANIZATION_IDENTIFIER + , ORGANIZATION_NAME + , ORGANIZATION_TYPE_CODE + , ORG_IDENTIFIER_TYPE_CODE + , IS_DISABLED + , APP_CREATE_TIMESTAMP + , APP_CREATE_USERID + , APP_CREATE_USER_DIRECTORY + , APP_LAST_UPDATE_TIMESTAMP + , APP_LAST_UPDATE_USERID + , APP_LAST_UPDATE_USER_DIRECTORY) +VALUES ( + N'MOTI2' + , N'Ministry of Transportation and Infrastructure' + , N'BCMIN' + , N'GOV' + , 0 + , CURRENT_TIMESTAMP + , N'Seed Data' + , N'Seed Data' + , CURRENT_TIMESTAMP + , N'Seed Data' + , N'Seed Data'); + diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/77_DML_PIMS_TENANT.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/77_DML_PIMS_TENANT.sql new file mode 100644 index 0000000000..9ee87be48b --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/77_DML_PIMS_TENANT.sql @@ -0,0 +1,13 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_TENANT table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_TENANT +GO + +INSERT INTO dbo.PIMS_TENANT (CODE, NAME, SETTINGS) +VALUES (N'MOTI', N'Ministry of Transportation & Infrastructure', N'{ "HelpDeskEmail": "pims@gov.bc.ca" }'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/78_DML_PIMS_PROPERTY_ANOMALY_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/78_DML_PIMS_PROPERTY_ANOMALY_TYPE.sql new file mode 100644 index 0000000000..6e5a16ec02 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/78_DML_PIMS_PROPERTY_ANOMALY_TYPE.sql @@ -0,0 +1,27 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LEASE_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_ANOMALY_TYPE +GO + +INSERT INTO PIMS_PROPERTY_ANOMALY_TYPE (PROPERTY_ANOMALY_TYPE_CODE, DESCRIPTION, IS_DISABLED) +VALUES + (N'ACCESS', N'Access', CONVERT([bit],(0))), + (N'BIZLOSS', N'Potential for business loss claims', CONVERT([bit],(0))), + (N'EFCLAUSE', N'E&F clause', CONVERT([bit],(0))), + (N'BLDGLIENS', N'Building liens', CONVERT([bit],(0))), + (N'DISTURB', N'Disturbance', CONVERT([bit],(0))), + (N'DUPTITLE', N'Duplicate title', CONVERT([bit],(0))), + (N'ASSGNRENT', N'Assignment of rent', CONVERT([bit],(0))), + (N'MORTSECINT', N'Mortgage/security interests', CONVERT([bit],(0))), + (N'CHRGCROWN', N'Charge to the Crown', CONVERT([bit],(0))), + (N'CERTPNDLIT', N'Certification of pending litigation', CONVERT([bit],(0))), + (N'CHGHOLDGEN', N'Charge holders in general', CONVERT([bit],(0))), + (N'LGLNOT', N'Legal notations', CONVERT([bit],(0))), + (N'OTHER', N'Other', CONVERT([bit],(0))); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/79_DML_PIMS_PROPERTY_ROAD_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/79_DML_PIMS_PROPERTY_ROAD_TYPE.sql new file mode 100644 index 0000000000..8d7856cb67 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/79_DML_PIMS_PROPERTY_ROAD_TYPE.sql @@ -0,0 +1,33 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_ROAD_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_ROAD_TYPE +GO + +INSERT INTO PIMS_PROPERTY_ROAD_TYPE (PROPERTY_ROAD_TYPE_CODE, DESCRIPTION) +VALUES + (N'GAZSURVD', N'Gazetted (Surveyed)'), + (N'GAZUNSURVD', N'Gazetted (Unsurveyed)'), + (N'GAZMOTI', N'Gazetted (MoTI Plan)'), + (N'CRWNDEL', N'Crown grant deletion'), + (N'SUBDIV', N'Subdivision'), + (N'107REF', N'107 Reference Plan'), + (N'107EXP', N'107 Explanatory Plan'), + (N'S42', N'S.42 (Court declared)'), + (N'S56', N'S.56 (2) Highway'), + (N'SRWPLAN', N'SRW plan (with no gazette)'), + (N'UNTEN', N'Untenured (no dedicated highway)'), + (N'MUNI', N'Municipal'), + (N'FSR', N'Forest Service Road'), + (N'PUBRD', N'Public Road (FLNRORD Juridiction)'), + (N'OIC', N'Order in Council (OIC)'), + (N'CTRLACC', N'Controlled Access'), + (N'ARTERIAL', N'Arterial'), + (N'FEDERAL', N'Federal'), + (N'OTHER', N'Other'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/80_DML_PIMS_PROPERTY_ADJACENT_LAND_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/80_DML_PIMS_PROPERTY_ADJACENT_LAND_TYPE.sql new file mode 100644 index 0000000000..96ce036bed --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/80_DML_PIMS_PROPERTY_ADJACENT_LAND_TYPE.sql @@ -0,0 +1,24 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROPERTY_ADJACENT_LAND_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROPERTY_ADJACENT_LAND_TYPE +GO + +INSERT INTO PIMS_PROPERTY_ADJACENT_LAND_TYPE (PROPERTY_ADJACENT_LAND_TYPE_CODE, DESCRIPTION) +VALUES + (N'MOLBCTFA', N'Ministry owned and leased - BCTFA'), + (N'MOLHMQ', N'Ministry owned and leased - HMQ'), + (N'MONLBCTFA', N'Ministry owned not leases - BCTFA'), + (N'MONLHMQ', N'Ministry owned not leases - HMQ'), + (N'LANDACTR', N'Land Act Reserve (Section 16/17/12/14)'), + (N'INDIANR', N'Indian Reserve (IR)'), + (N'PRIVATE', N'Private (Fee Simple)'), + (N'STATROW', N'Statutory Right of Way (SRW)'), + (N'SPECUSE', N'Special Use Permit (SUP)'), + (N'CROWN', N'Crown'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/81_DML_PIMS_VOLUMETRIC_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/81_DML_PIMS_VOLUMETRIC_TYPE.sql new file mode 100644 index 0000000000..d68edd45df --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/81_DML_PIMS_VOLUMETRIC_TYPE.sql @@ -0,0 +1,16 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_VOLUMETRIC_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_VOLUMETRIC_TYPE +GO + +INSERT INTO PIMS_VOLUMETRIC_TYPE (VOLUMETRIC_TYPE_CODE, DESCRIPTION) +VALUES + (N'AIRSPACE', N'Airspace'), + (N'SUBSURF', N'Sub-surface'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/82_DML_PIMS_VOLUME_UNIT_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/82_DML_PIMS_VOLUME_UNIT_TYPE.sql new file mode 100644 index 0000000000..1bc456bae9 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/82_DML_PIMS_VOLUME_UNIT_TYPE.sql @@ -0,0 +1,16 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_VOLUME_UNIT_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_VOLUME_UNIT_TYPE +GO + +INSERT INTO PIMS_VOLUME_UNIT_TYPE (VOLUME_UNIT_TYPE_CODE, DESCRIPTION) +VALUES + (N'M3', N'Cubic Meters'), + (N'F3', N'Cubic Feet'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/83_DML_PIMS_RESEARCH_FILE_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/83_DML_PIMS_RESEARCH_FILE_STATUS_TYPE.sql new file mode 100644 index 0000000000..e896d4047a --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/83_DML_PIMS_RESEARCH_FILE_STATUS_TYPE.sql @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_RESEARCH_FILE_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_RESEARCH_FILE_STATUS_TYPE +GO + +INSERT INTO PIMS_RESEARCH_FILE_STATUS_TYPE (RESEARCH_FILE_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'ACTIVE', N'Active'), + (N'INACTIVE', N'Inactive'), + (N'CLOSED', N'Closed'), + (N'ARCHIVED', N'Archived'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/84_DML_PIMS_REQUEST_SOURCE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/84_DML_PIMS_REQUEST_SOURCE_TYPE.sql new file mode 100644 index 0000000000..3a5739ae4f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/84_DML_PIMS_REQUEST_SOURCE_TYPE.sql @@ -0,0 +1,24 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_REQUEST_SOURCE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_REQUEST_SOURCE_TYPE +GO + +INSERT INTO PIMS_REQUEST_SOURCE_TYPE (REQUEST_SOURCE_TYPE_CODE, DESCRIPTION) +VALUES + (N'PROJECT', N'Project'), + (N'NONFOI', N'Public Enquiry (non-FOI)'), + (N'FOI', N'Freedom Of Information (FOI)'), + (N'DISTRICT', N'District'), + (N'REGION', N'Region'), + (N'HQ', N'Headquarters (HQ)'), + (N'OTHERMIN', N'Other Ministry'), + (N'EXTRQST', N'External Request'), + (N'SURVEYOR', N'Surveyor'), + (N'INTLGL', N'Legal Counsel (Internal)'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/85_DML_PIMS_RESEARCH_PURPOSE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/85_DML_PIMS_RESEARCH_PURPOSE_TYPE.sql new file mode 100644 index 0000000000..b1313a2163 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/85_DML_PIMS_RESEARCH_PURPOSE_TYPE.sql @@ -0,0 +1,19 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_RESEARCH_PURPOSE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_RESEARCH_PURPOSE_TYPE +GO + +INSERT INTO PIMS_RESEARCH_PURPOSE_TYPE (RESEARCH_PURPOSE_TYPE_CODE, DESCRIPTION) +VALUES + (N'ACQUIRE', N'Acquisition'), + (N'TENCLEAN', N'Tenure Clean-Up'), + (N'MGMT', N'Management'), + (N'DISPOSE', N'Disposition'), + (N'GENENQ', N'General Enquiry'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/86_DML_PIMS_PROP_RESEARCH_PURPOSE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/86_DML_PIMS_PROP_RESEARCH_PURPOSE_TYPE.sql new file mode 100644 index 0000000000..d6d194e0a0 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/86_DML_PIMS_PROP_RESEARCH_PURPOSE_TYPE.sql @@ -0,0 +1,36 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PROP_RESEARCH_PURPOSE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PROP_RESEARCH_PURPOSE_TYPE +GO + +INSERT INTO PIMS_PROP_RESEARCH_PURPOSE_TYPE (PROP_RESEARCH_PURPOSE_TYPE_CODE, DESCRIPTION) +VALUES + (N'RDCLOSE', N'Road Closure'), + (N'ACQUIRE', N'Acquisition'), + (N'DISPOSE', N'Disposition'), + (N'LICLEASE', N'License/Lease'), + (N'FNTREATY', N'FN/Treaty'), + (N'LNDXCHG', N'Land Exchange'), + (N'INQUIRY', N'Inquiry'), + (N'FORM12', N'Form 12'), + (N'FOI', N'FOI'), + (N'RESEARCH', N'Research'), + (N'DOTHER', N'District Other'), + (N'OTHER', N'Other'), + (N'ISSUE', N'Issue'), + (N'CLASS', N'Classification'), + (N'LEGAL', N'Legal'), + (N'LISSUE', N'Land Issue'), + (N'TAC', N'TAC'), + (N'REGINT', N'Registered Interest'), + (N'UNREGINT', N'Unregistered Interest'), + (N'MOTIOWND', N'MoTI Owned'), + (N'HWY', N'Highway'), + (N'UNKNOWN', N'Unknown'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/87_DML_PIMS_PPH_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/87_DML_PIMS_PPH_STATUS_TYPE.sql new file mode 100644 index 0000000000..576623f41f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/87_DML_PIMS_PPH_STATUS_TYPE.sql @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_PPH_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_PPH_STATUS_TYPE +GO + +INSERT INTO PIMS_PPH_STATUS_TYPE (PPH_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'PPH', N'Provincial Public Highway (PPH)'), + (N'NONPPH', N'Non-Provincial Public Highway (Non-PPH)'), + (N'COMBO', N'Combination (PPH & Non-PPH)'), + (N'UNKNOWN', N'Unknown'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/88_DML_PIMS_DOCUMENT_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/88_DML_PIMS_DOCUMENT_STATUS_TYPE.sql new file mode 100644 index 0000000000..cb56d4606f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/88_DML_PIMS_DOCUMENT_STATUS_TYPE.sql @@ -0,0 +1,24 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_DOCUMENT_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_DOCUMENT_STATUS_TYPE +GO + +INSERT INTO PIMS_DOCUMENT_STATUS_TYPE (DOCUMENT_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'NONE', N'None'), + (N'DRAFT', N'Draft'), + (N'APPROVD', N'Approved'), + (N'SENT', N'Sent'), + (N'SIGND', N'Signed'), + (N'AMENDD', N'Amended'), + (N'FINAL', N'Final'), + (N'RGSTRD', N'Registered'), + (N'UNREGD', N'Unregistered'), + (N'CNCLD', N'Cancelled'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/89_DML_PIMS_ACQUISITION_FILE_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/89_DML_PIMS_ACQUISITION_FILE_STATUS_TYPE.sql new file mode 100644 index 0000000000..dc10b754dd --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/89_DML_PIMS_ACQUISITION_FILE_STATUS_TYPE.sql @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQUISITION_FILE_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQUISITION_FILE_STATUS_TYPE +GO + +INSERT INTO PIMS_ACQUISITION_FILE_STATUS_TYPE (ACQUISITION_FILE_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'ACTIVE', N'Active'), + (N'CANCEL', N'Cancelled'), + (N'CLOSED', N'Closed'), + (N'ARCHIV', N'Archived'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/90_DML_PIMS_ACQUISITION_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/90_DML_PIMS_ACQUISITION_TYPE.sql new file mode 100644 index 0000000000..0da500bfe6 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/90_DML_PIMS_ACQUISITION_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQUISITION_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQUISITION_TYPE +GO + +INSERT INTO PIMS_ACQUISITION_TYPE (ACQUISITION_TYPE_CODE, DESCRIPTION) +VALUES + (N'CONSEN', N'Consensual Agreement'), + (N'SECTN3', N'Section 3 Agreement'), + (N'SECTN6', N'Section 6 Expropriation'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/91_DML_PIMS_ACQUISITION_FUNDING_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/91_DML_PIMS_ACQUISITION_FUNDING_TYPE.sql new file mode 100644 index 0000000000..feb1cb4f34 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/91_DML_PIMS_ACQUISITION_FUNDING_TYPE.sql @@ -0,0 +1,25 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQUISITION_FUNDING_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQUISITION_FUNDING_TYPE; +GO + +INSERT INTO PIMS_ACQUISITION_FUNDING_TYPE (ACQUISITION_FUNDING_TYPE_CODE, DESCRIPTION) +VALUES + (N'MOTIDST', N'MoTI District'), + (N'MOTIREG', N'MoTI Region'), + (N'DFAA', N'DFAA (Disaster Financial Assistance Arrangement)'), + (N'REHAB', N'Rehab & Maintenance'), + (N'CAPITAL', N'Capital Program'), + (N'BCTFA', N'BCTFA'), + (N'TICORP', N'TI Corp'), + (N'MAJORPR', N'Major Projects'), + (N'FEDERAL', N'Federal'), + (N'EVERGRN', N'Evergreen'), + (N'OTHER', N'Other'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/92_DML_PIMS_ACQ_PHYS_FILE_STATUS_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/92_DML_PIMS_ACQ_PHYS_FILE_STATUS_TYPE.sql new file mode 100644 index 0000000000..b559cd24c9 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/92_DML_PIMS_ACQ_PHYS_FILE_STATUS_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQ_PHYS_FILE_STATUS_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQ_PHYS_FILE_STATUS_TYPE +GO + +INSERT INTO PIMS_ACQ_PHYS_FILE_STATUS_TYPE (ACQ_PHYS_FILE_STATUS_TYPE_CODE, DESCRIPTION) +VALUES + (N'ACTIVE', N'Active'), + (N'PENDING', N'Pending Litigation'), + (N'ARCHIVE', N'Archive - Offsite'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/93_DML_PIMS_ACQ_FL_PERSON_PROFILE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/93_DML_PIMS_ACQ_FL_PERSON_PROFILE_TYPE.sql new file mode 100644 index 0000000000..13f5786e19 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/93_DML_PIMS_ACQ_FL_PERSON_PROFILE_TYPE.sql @@ -0,0 +1,18 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACQ_FL_PERSON_PROFILE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACQ_FL_PERSON_PROFILE_TYPE +GO + +INSERT INTO PIMS_ACQ_FL_PERSON_PROFILE_TYPE (ACQ_FL_PERSON_PROFILE_TYPE_CODE, DESCRIPTION) +VALUES + (N'NEGOTAGENT', N'Negotiation agent'), + (N'PROPCOORD', N'Property Coordinator'), + (N'EXPRAGENT', N'Expropriation agent'), + (N'PROPAGENT', N'Property agent'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/94_DML_PIMS_ACTIVITY_TEMPLATE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/94_DML_PIMS_ACTIVITY_TEMPLATE_TYPE.sql new file mode 100644 index 0000000000..6d8dea628f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/94_DML_PIMS_ACTIVITY_TEMPLATE_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_ACTIVITY_TEMPLATE_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_ACTIVITY_TEMPLATE_TYPE +GO + +INSERT INTO PIMS_ACTIVITY_TEMPLATE_TYPE (ACTIVITY_TEMPLATE_TYPE_CODE, DESCRIPTION) +VALUES + (N'GENERAL', N'General'), + (N'SURVEY', N'Survey'), + (N'SITEVIS', N'Site Visit'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/95_DML_PIMS_SURVEY_PLAN_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/95_DML_PIMS_SURVEY_PLAN_TYPE.sql new file mode 100644 index 0000000000..72a0b89855 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/95_DML_PIMS_SURVEY_PLAN_TYPE.sql @@ -0,0 +1,44 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_SURVEY_PLAN_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_SURVEY_PLAN_TYPE +GO + +INSERT INTO PIMS_SURVEY_PLAN_TYPE (SURVEY_PLAN_TYPE_CODE, DESCRIPTION) +VALUES + (N'S107REFART', N'S.107 Reference – arterial'), + (N'S107EXPLNART', N'S.107 Explanatory – arterial'), + (N'S107REFNART', N'S.107 Reference – not arterial'), + (N'S107EXPLNNART', N'S.107 Explanatory – not arterial'), + (N'S113REFHWYX', N'S.113 Reference SRW – Highway closure'), + (N'S113REFFRM12', N'S.113 Reference SRW – Form 12'), + (N'S113REFSRW', N'S.113 Reference SRW – SRW'), + (N'S99EXPLNTRY', N'S.99(1)(e) Explanatory – SRW'), + (N'S99SUB4TRAN', N'S.99(1)(h)(i) Reference – Subdivision for tran purpose'), + (N'S107S27TFAX', N'S.107LTA/s.27(3)(b) TA/s.6 EA ref – BCTFA Expropriation'), + (N'S107S10MOTX', N'S.107 LTA/ s.10 TA/ s.6 EA ref – MoTI Expropriation'), + (N'S113S10MOTX', N'S.113 LTA/ s.10 TA/s.6 EA ref – MoTI Expropriation SRW'), + (N'S113S27TFAX', N'S.113 LTA/s.27(3)(b) TA/s.6 EA ref – BCTFA expropriation SRW'), + (N'LNDACTPLCRW', N'Land Act Plan – Crown grant'), + (N'SKETCHSITEP', N'Sketch/site plan'), + (N'S1001BLTACP', N'S.100(1)(b) LTA – Consolidation plan'), + (N'S109REFHWYX', N'S.109 reference plan-hwy closure'), + (N'S109SUBHWYX', N'S.109 subdivision plan – hwy closure'), + (N'S219LTARCOV', N'S.219 LTA reference – Covenant'), + (N'S219LTAXCOV', N'S.219 LTA explanatory – Covenant'), + (N'S991EESMNT', N'S.99(1)(e) – easement'), + (N'S67LTASUBD', N'S.67LTA – subdivision'), + (N'BLKOTLNPST', N'Block Outline reference'), + (N'S69LTABLKO', N'S.69LTA – Block Outline Posting'), + (N'S68POSTING', N'S.68 – Posting'), + (N'AIRSPACE', N'Airspace'), + (N'S1001AREF', N'S.100(1)(a) reference'), + (N'S16MAPRSRV', N'S.16 Map Reserve'), + (N'S17MAPRSRV', N'S.17 Map Reserve'), + (N'OTHER', N'Other'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/96_DML_PIMS_LAND_SURVEYOR_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/96_DML_PIMS_LAND_SURVEYOR_TYPE.sql new file mode 100644 index 0000000000..93b98fbe4b --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Build/96_DML_PIMS_LAND_SURVEYOR_TYPE.sql @@ -0,0 +1,17 @@ +/* ----------------------------------------------------------------------------- +Delete all data from the PIMS_LAND_SURVEYOR_TYPE table and repopulate. +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-24 Initial version +----------------------------------------------------------------------------- */ + +DELETE FROM PIMS_LAND_SURVEYOR_TYPE +GO + +INSERT INTO PIMS_LAND_SURVEYOR_TYPE (LAND_SURVEYOR_TYPE_CODE, DESCRIPTION) +VALUES + (N'CLS', N'CLS (Canada Land Surveyor)'), + (N'BCLS', N'BCLS (BC Land Surveyor)'), + (N'OTHER', N'Other'); +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Drop/01_PSP_PIMS_S32_00_Drop.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Drop/01_PSP_PIMS_S32_00_Drop.sql new file mode 100644 index 0000000000..29472d0f68 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Drop/01_PSP_PIMS_S32_00_Drop.sql @@ -0,0 +1,11934 @@ +/* ---------------------------------------------------------------------- */ +/* Script generated with: DeZign for Databases 13.0.1 */ +/* Target DBMS: MS SQL Server 2017 */ +/* Project file: PIMS S32.00.dez */ +/* Project name: MoTI Property Services Project */ +/* Author: Doug Filteau */ +/* Script type: Database drop script */ +/* Created on: 2022-07-06 13:09 */ +/* ---------------------------------------------------------------------- */ + + +/* ---------------------------------------------------------------------- */ +/* Drop triggers */ +/* ---------------------------------------------------------------------- */ + +DROP TRIGGER [dbo].[PIMS_SCDPHL_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SCDPHL_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SCDPHL_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SCDPRH_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SCDPRH_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SCDPRH_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRANOM_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRANOM_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPSTS_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPSTS_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRROAD_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRROAD_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRADJL_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRADJL_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRVOLT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRVOLT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRRT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRRT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRAT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRAT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPALT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPALT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_VOLUTY_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_VOLUTY_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRTT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRTT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RESRCH_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RESRCH_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RESRCH_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RSRCHS_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RSRCHS_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRSCRC_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRSCRC_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRSCRC_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRTY_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRTY_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRTY_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPSVC_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPSVC_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPSVC_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USER_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USER_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USER_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPTYP_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPTYP_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADDRSS_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADDRSS_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADDRSS_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DSTRCT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DSTRCT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_REGION_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_REGION_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PROVNC_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PROVNC_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CNTRY_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CNTRY_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORG_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORG_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORG_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USRORG_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USRORG_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USRORG_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CLMTYP_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CLMTYP_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CLMTYP_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ROLCLM_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ROLCLM_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ROLCLM_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERSON_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERSON_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERSON_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERORG_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERORG_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERORG_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORGTYP_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORGTYP_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACRQST_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACRQST_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACRQST_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACRQOR_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACRQOR_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACRQOR_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ARQSTT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ARQSTT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRSVFT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRSVFT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ROLE_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ROLE_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ROLE_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USERRL_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USERRL_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_USERRL_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRSF_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRSF_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPRSF_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPCLT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPCLT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CNTMTH_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CNTMTH_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CNTMTH_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CNTMTT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_CNTMTT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPORG_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPORG_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPORG_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPTNR_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPTNR_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ARUNIT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ARUNIT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPEVL_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPEVL_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPEVL_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PIDSRT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PIDSRT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORGIDT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORGIDT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LEASE_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LEASE_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LEASE_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSCATT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSCATT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PROPLS_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PROPLS_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PROPLS_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPMTF_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPMTF_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPRGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPRGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_TENANT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_TENANT_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_TENANT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSSRTY_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSSRTY_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPRTY_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPRTY_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LELIST_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LELIST_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_INSRNC_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_INSRNC_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_INSRNC_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_INSPYT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_INSPYT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SECDEP_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SECDEP_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SECDEP_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SECDPT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SECDPT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LPRPTY_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LPRPTY_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPTAX_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPTAX_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRPTAX_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PTRMTT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PTRMTT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SPDCLT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SPDCLT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PIMPRV_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PIMPRV_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PIMPRV_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PIMPRT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PIMPRT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SDRTRN_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SDRTRN_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_SDRTRN_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LINITT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LINITT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LRESPT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LRESPT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSTERM_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSTERM_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSTERM_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LTRMST_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LTRMST_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPMMT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPMMT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPYMT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPYMT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSPYMT_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LPSTST_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LPSTST_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_STAVBL_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_STAVBL_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_STAVBL_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERADD_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERADD_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PERADD_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORGADD_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORGADD_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ORGADD_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSSTYP_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_LSSTYP_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_TENNTX_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_TENNTX_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RQSRCT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RQSRCT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RSHPRT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RSHPRT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RSFLPR_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RSFLPR_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RSFLPR_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RRESPT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RRESPT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRSPRP_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PRSPRP_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PPHSTT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_PPHSTT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RGNUSR_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RGNUSR_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_RGNUSR_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_NOTE_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_NOTE_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_NOTE_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DOCTYP_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DOCTYP_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DOCTYP_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DOCMNT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DOCMNT_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DOCMNT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DOCSTY_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_DOCSTY_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTINS_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTINS_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTINS_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTINN_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTINN_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTINN_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTDOC_A_S_IUD_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTDOC_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ACTDOC_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_I_TR] +GO + + +DROP TRIGGER [dbo].[PIMS_ADUSGT_I_S_U_TR] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop views */ +/* ---------------------------------------------------------------------- */ + +DROP VIEW [dbo].[PIMS_PERSON_CONTACT_VW] +GO + + +DROP VIEW [dbo].[PIMS_PROPERTY_BOUNDARY_VW] +GO + + +DROP VIEW [dbo].[PIMS_CONTACT_MGR_VW] +GO + + +DROP VIEW [dbo].[PIMS_PROPERTY_LOCATION_VW] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop foreign key constraints */ +/* ---------------------------------------------------------------------- */ + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [PIM_SECDEP_PIM_SCDPHL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [PIM_ORG_PIM_SCDPHL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [PIM_PERSON_PIM_SCDPHL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [PIM_SDRTRN_PIM_SCDPRH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [PIM_PERSON_PIM_SCDPRH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [PIM_ORG_PIM_SCDPRH_FK] +GO + + +ALTER TABLE [dbo].[BCA_ASSESSMENT_AREA] DROP CONSTRAINT [PIM_BCDADV_PIM_BCASAR_FK] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION] DROP CONSTRAINT [PIM_BCASAR_PIM_BCAJUR_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_RECORD] DROP CONSTRAINT [PIM_BCAJUR_PIM_BCAFOR_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_ADDRESS] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCFADR_FK] +GO + + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCAOWG_FK] +GO + + +ALTER TABLE [dbo].[BCA_OWNER] DROP CONSTRAINT [PIM_BCAOWG_PIM_BCAOWN_FK] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE] DROP CONSTRAINT [PIM_BCDADV_PIM_BCDGNV_FK] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE] DROP CONSTRAINT [PIM_BCDADV_PIM_BCDTRV_FK] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE] DROP CONSTRAINT [PIM_BCDADV_PIM_BCDSCV_FK] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] DROP CONSTRAINT [PIM_BCAJUR_PIM_BCJAMD_FK] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_DELETE] DROP CONSTRAINT [PIM_BCAJUR_PIM_BCJDEL_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCAFLD_FK] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_DELETE] DROP CONSTRAINT [PIM_BCDADV_PIM_BCDDEL_FK] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] DROP CONSTRAINT [PIM_BCDADV_PIM_BCDAMD_FK] +GO + + +ALTER TABLE [dbo].[BCA_AREA_DELETE] DROP CONSTRAINT [PIM_BCASAR_PIM_BCADEL_FK] +GO + + +ALTER TABLE [dbo].[BCA_AREA_AMENDMENT] DROP CONSTRAINT [PIM_BCASAR_PIM_BCAAMD_FK] +GO + + +ALTER TABLE [dbo].[BCA_AREA_GENERAL_VALUE] DROP CONSTRAINT [PIM_BCASAR_PIM_BCAGNV_FK] +GO + + +ALTER TABLE [dbo].[BCA_AREA_BCTRANSIT_VALUE] DROP CONSTRAINT [PIM_BCASAR_PIM_BCATRV_FK] +GO + + +ALTER TABLE [dbo].[BCA_AREA_SCHOOL_VALUE] DROP CONSTRAINT [PIM_BCASAR_PIM_BCASCV_FK] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_GENERAL_VALUE] DROP CONSTRAINT [PIM_BCAJUR_PIM_BCJGNV_FK] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_SCHOOL_VALUE] DROP CONSTRAINT [PIM_BCAJUR_PIM_BCJSCV_FK] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE] DROP CONSTRAINT [PIM_BCAJUR_PIM_BCJTRV_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_DESCRIPTION] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCAFDE_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_SALES] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCAFSA_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_GENERAL_VALUE] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCFGNV_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_BCTRANSIT_VALUE] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCFTRV_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_SCHOOL_VALUE] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCFSCV_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_VALUATION] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCAVAL_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_AMENDMENT] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCAFAM_FK] +GO + + +ALTER TABLE [dbo].[BCA_MINOR_TAXING] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCMNTX_FK] +GO + + +ALTER TABLE [dbo].[BCA_ELECTORAL_AREA] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCELCT_FK] +GO + + +ALTER TABLE [dbo].[BCA_SERVICE_AREA] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCSVCA_FK] +GO + + +ALTER TABLE [dbo].[BCA_DEFINED] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCADFN_FK] +GO + + +ALTER TABLE [dbo].[BCA_SPECIFIED_REGIONAL] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCSPRG_FK] +GO + + +ALTER TABLE [dbo].[BCA_SPECIFIED_MUNICIPAL] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCSPMU_FK] +GO + + +ALTER TABLE [dbo].[BCA_LOCAL_AREA] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCLCLA_FK] +GO + + +ALTER TABLE [dbo].[BCA_GENERAL_SERVICE] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCGSVC_FK] +GO + + +ALTER TABLE [dbo].[BCA_IMPROVEMENT_DISTRICT] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCIMPD_FK] +GO + + +ALTER TABLE [dbo].[BCA_ISLANDS_TRUST] DROP CONSTRAINT [PIM_BCMNTX_PIM_BCISLT_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_FARM] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCFARM_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_MANUFACTURED_HOME] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCMANH_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_MANAGED_FOREST] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCMFOR_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_OIL_AND_GAS] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCOILG_FK] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC] DROP CONSTRAINT [PIM_BCAFOR_PIM_BCLCHR_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRPRRT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PIM_PRROAD_PIM_PRPRRT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRPRAT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PIM_PRANOM_PIM_PRPRAT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRPALT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PIM_PRADJL_PIM_PRPALT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRPRTT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PIM_PRPTNR_PIM_PRPRTT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [PIM_RSRCHS_PIM_RESRCH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [PIM_RQSRCT_PIM_RESRCH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [PIM_PERSON_PIM_RESRCH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [PIM_ORG_PIM_RESRCH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRSCRC_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PIM_RESRCH_PIM_PRSCRC_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_SPDCLT_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_PRPSTS_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_VOLUTY_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_PRVOLT_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_PRPTYP_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_ADDRSS_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_REGION_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_DSTRCT_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_PRPCLT_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_ARUNIT_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_PIDSRT_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_PERSON_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_ORG_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PIM_PPHSTT_PIM_PRPRTY_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PIM_PRSVFT_PIM_PRPSVC_FK] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [PIM_PERSON_PIM_USER_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [PIM_DSTRCT_PIM_ADDRSS_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [PIM_REGION_PIM_ADDRSS_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [PIM_PROVNC_PIM_ADDRSS_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [PIM_CNTRY_PIM_ADDRSS_FK] +GO + + +ALTER TABLE [dbo].[PIMS_DISTRICT] DROP CONSTRAINT [PIM_REGION_PIM_DSTRCT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] DROP CONSTRAINT [PIM_CNTRY_PIM_PROVNC_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [PIM_ORGTYP_PIM_ORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [PIM_ORG_PIM_PRNT_ORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [PIM_DSTRCT_PIM_ORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [PIM_REGION_PIM_ORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [PIM_ORGIDT_PIM_ORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [PIM_USER_PIM_USRORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [PIM_ORG_PIM_USRORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [PIM_ROLE_PIM_USRORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [PIM_CLMTYP_PIM_ROLCLM_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [PIM_ROLE_PIM_ROLCLM_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PIM_PERSON_PIM_PERORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PIM_ORG_PIM_PERORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [PIM_USER_PIM_ACRQST_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [PIM_ARQSTT_PIM_ACRQST_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [PIM_ROLE_PIM_ACRQST_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [PIM_REGION_PIM_ACRQST_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [PIM_ORG_PIM_ACRQOR_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [PIM_ACRQST_PIM_ACRQOR_FK] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [PIM_USER_PIM_USERRL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [PIM_ROLE_PIM_USERRL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRPRSF_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PIM_PRPSVC_PIM_PRPRSF_FK] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [PIM_CNTMTT_PIM_CNTMTH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [PIM_PERSON_PIM_CNTMTH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [PIM_ORG_PIM_CNTMTH_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRPORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PIM_ORG_PIM_PRPORG_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRPEVL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_REGION_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_LSPRGT_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_LELIST_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_LSPRTY_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_LSCATT_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_LPRPTY_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_LINITT_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_LRESPT_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [PIM_LSSTYP_PIM_LEASE_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PIM_PRPRTY_PIM_PROPLS_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PIM_LEASE_PIM_PROPLS_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PIM_ARUNIT_PIM_PROPLS_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [PIM_LSSRTY_PIM_TENANT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [PIM_LEASE_PIM_TENANT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [PIM_ORG_PIM_TENANT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [PIM_PERSON_PIM_TENANT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [PIM_PERSON_PIM_PRIMARY_CONTACT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [PIM_LEASE_PIM_INSRNC_FK] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [PIM_INSPYT_PIM_INSRNC_FK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [PIM_LEASE_PIM_SECDEP_FK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [PIM_SECDPT_PIM_SECDEP_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PIM_PTRMTT_PIM_PRPTAX_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRPTAX_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIM_PIMPRT_PIM_PIMPRV_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIM_LEASE_PIM_PIMPRV_FK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [PIM_SECDEP_PIM_SDRTRN_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [PIM_LSPMTF_PIM_LSTERM_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [PIM_LEASE_PIM_LSTERM_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [PIM_LTRMST_PIM_LSTERM_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [PIM_LPSTST_PIM_LSPYMT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [PIM_LSTERM_PIM_LSPYMT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [PIM_LSPMMT_PIM_LSPYMT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PIM_ADUSGT_PIM_PERADD_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PIM_PERSON_PIM_PERADD_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PIM_ADDRSS_PIM_PERADD_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [PIM_ADUSGT_PIM_ORGADD_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [PIM_ORG_PIM_ORGADD_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [PIM_ADDRSS_PIM_ORGADD_FK] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [PIM_RESRCH_PIM_RSFLPR_FK] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [PIM_RSHPRT_PIM_RSFLPR_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PIM_RRESPT_PIM_PRSPRP_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PIM_PRSCRC_PIM_PRSPRP_FK] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [PIM_REGION_PIM_RGNUSR_FK] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [PIM_USER_PIM_RGNUSR_FK] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [PIM_DOCTYP_PIM_DOCMNT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [PIM_DOCSTY_PIM_DOCMNT_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [PIM_ACTTMP_PIM_ACTINS_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [PIM_NOTE_PIM_ACTINN_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [PIM_ACTINS_PIM_ACTINN_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [PIM_DOCMNT_PIM_ACTDOC_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [PIM_ACTINS_PIM_ACTDOC_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [PIM_ACQFST_PIM_ACQNFL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [PIM_ACQTYP_PIM_ACQNFL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [PIM_ACQFTY_PIM_ACQNFL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [PIM_ACQPFS_PIM_ACQNFL_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PIM_ACQNFL_PIM_PRACQF_FK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PIM_PRPRTY_PIM_PRACQF_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [PIM_ACQNFL_PIM_ACQOWN_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [PIM_ACQNFL_PIM_ACQPER_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [PIM_PERSON_PIM_ACQPER_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [PIM_AQFPPT_PIM_ACQPER_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [PIM_ACTTTY_PIM_ACTTMP_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [PIM_ACQNFL_PIM_ACQAIN_FK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [PIM_ACTINS_PIM_ACQAIN_FK] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_PRF_PROP_RESEARCH_PURPOSE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [PRSPRP_PROP_PURPOSE_TUC] +GO + + +DROP TABLE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_RESEARCH_FILE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_PROPERTY_RESEARCH_FILE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] DROP CONSTRAINT [PRSCRC_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_RESEARCH_FILE', 'COLUMN', N'PROPERTY_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_RESEARCH_FILE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_RESEARCH_FILE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_RESEARCH_FILE', 'COLUMN', N'IS_LEGAL_OPINION_REQUIRED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_RESEARCH_FILE', 'COLUMN', N'IS_LEGAL_OPINION_OBTAINED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_RESEARCH_FILE', 'COLUMN', N'DOCUMENT_REFERENCE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_RESEARCH_FILE', 'COLUMN', N'RESEARCH_SUMMARY' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_RESEARCH_FILE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_RESEARCH_FILE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROP_PROP_TENURE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_PROP_PROP_TENURE_TYPE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_PROPERTY_TENURE_TYPE_CODE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] DROP CONSTRAINT [PRPRTT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_PROP_TENURE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROP_PROP_TENURE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROP_PROP_ADJACENT_LAND_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_PROP_PROP_ADJACENT_LAND_TYPE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRPALT_PROP_ADJACENT_LAND_TYPE_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_PROP_ADJACENT_LAND_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROP_PROP_ANOMALY_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_PROP_PROP_ANOMALY_TYPE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] DROP CONSTRAINT [PRPRAT_PROP_ANOMALY_TYPE_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_PROP_ANOMALY_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROP_PROP_ROAD_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_PROP_PROP_ROAD_TYPE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] DROP CONSTRAINT [PRPRRT_PROP_ROAD_TYPE_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_PROP_ROAD_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROP_PROP_ROAD_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_ACQUISITION_FILE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_PROPERTY_ACQUISITION_FILE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] DROP CONSTRAINT [PRACQF_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ACQUISITION_FILE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ACQUISITION_FILE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_TAX" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_PROPERTY_TAX_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX] DROP CONSTRAINT [PRPTAX_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_TAX', 'COLUMN', N'TAX_FOLIO_NO' +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_TAX] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_LEASE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_PROPERTY_LEASE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_LEASE] DROP CONSTRAINT [PROPLS_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_LEASE', 'COLUMN', N'LEASE_AREA' +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_LEASE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_EVALUATION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_PROPERTY_EVALUATION_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_EVALUATION] DROP CONSTRAINT [PRPEVL_PK] +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_EVALUATION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_ORGANIZATION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_PROPERTY_ORGANIZATION_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] DROP CONSTRAINT [PRPORG_PROPERTY_ORGANIZATION_TUC] +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_ORGANIZATION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_PROPERTY_SERVICE_FILE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_PROPERTY_PROPERTY_SERVICE_FILE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPRSF_PROPERTY_SERVICE_FILE_TUC] +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_PROPERTY_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_IS_VOLUMETRIC_PARCEL_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_IS_OWNED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_IS_PROPERTY_OF_INTEREST_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_IS_VISIBLE_TO_OTHER_AGENCIES_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_IS_SENSITIVE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_IS_RWY_BELT_DOM_PATENT_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY] DROP CONSTRAINT [PRPRTY_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'PROPERTY_DATA_SOURCE_EFFECTIVE_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'PID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'PIN' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'FILE_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'FILE_NUMBER_SUFFIX' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'LAND_AREA' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'LAND_LEGAL_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'BOUNDARY' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'LOCATION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'ENCUMBRANCE_REASON' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'SURPLUS_DECLARATION_COMMENT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'SURPLUS_DECLARATION_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'NOTES' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'MUNICIPAL_ZONING' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'IS_VOLUMETRIC_PARCEL' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'VOLUMETRIC_MEASUREMENT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'IS_OWNED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'IS_PROPERTY_OF_INTEREST' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'IS_VISIBLE_TO_OTHER_AGENCIES' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'IS_SENSITIVE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'IS_PROVINCIAL_PUBLIC_HWY' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'PPH_STATUS_UPDATE_USERID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'PPH_STATUS_UPDATE_TIMESTAMP' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'PPH_STATUS_UPDATE_USER_GUID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'IS_RWY_BELT_DOM_PATENT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'ZONING' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY', 'COLUMN', N'ZONING_POTENTIAL' +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQUISITION_ACTIVITY_INSTANCE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_ACQUISITION_ACTIVITY_INSTANCE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACQAIN_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_ACTIVITY_INSTANCE', 'COLUMN', N'IS_DISABLED' +GO + + +DROP TABLE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACTIVITY_INSTANCE_DOCUMENT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_ACTIVITY_INSTANCE_DOCUMENT_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] DROP CONSTRAINT [ACTDOC_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_INSTANCE_DOCUMENT', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_INSTANCE_DOCUMENT', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACTIVITY_INSTANCE_NOTE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_PIMS_ACTIVITY_INSTANCE_NOTE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] DROP CONSTRAINT [ACTINN_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_INSTANCE_NOTE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_INSTANCE_NOTE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACTIVITY_INSTANCE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_ACTIVITY_INSTANCE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_ACTIVITY_DATA_JSON_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] DROP CONSTRAINT [ACTINS_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_INSTANCE', 'COLUMN', N'ACTIVITY_DATA_JSON' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_INSTANCE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACTIVITY_INSTANCE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_RESEARCH_FILE_PURPOSE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_RESEARCH_FILE_PURPOSE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_RESEARCH_PURPOSE_TYPE_CODE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] DROP CONSTRAINT [RSFLPR_PK] +GO + + +DROP TABLE [dbo].[PIMS_RESEARCH_FILE_PURPOSE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ORGANIZATION_ADDRESS" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_ORGANIZATION_ADDRESS_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_PK] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] DROP CONSTRAINT [ORGADD_UNQ_ADDR_TYPE_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ORGANIZATION_ADDRESS', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ORGANIZATION_ADDRESS] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PERSON_ADDRESS" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_PERSON_ADDRESS_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ADDRESS] DROP CONSTRAINT [PERADD_UNQ_ADDR_TYPE_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PERSON_ADDRESS', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PERSON_ADDRESS] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ADDRESS" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_ADDRESS_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS] DROP CONSTRAINT [ADDRSS_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ADDRESS', 'COLUMN', N'OTHER_COUNTRY' +GO + + +DROP TABLE [dbo].[PIMS_ADDRESS] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_RESEARCH_FILE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_RESEARCH_FILE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_RESEARCH_FILE_STATUS_TYPE_CODE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_RFILE_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE] DROP CONSTRAINT [RESRCH_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'REQUESTOR_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'REQUESTOR_ORGANIZATION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'RFILE_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'REQUEST_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'ROAD_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'ROAD_ALIAS' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'REQUEST_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'RESEARCH_RESULT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'IS_EXPROPRIATION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'EXPROPRIATION_NOTES' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', 'COLUMN', N'RESEARCH_COMPLETION_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_RESEARCH_FILE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_SECURITY_DEPOSIT_RETURN_HOLDER" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_SECURITY_DEPOSIT_RETURN_HOLDER_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_PK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_ONE_HOLDER_ONLY_TCC] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] DROP CONSTRAINT [SCDPRH_SECURITY_DEPOSIT_RETURN_ID_TUC] +GO + + +DROP TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_SECURITY_DEPOSIT_HOLDER" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_SECURITY_DEPOSIT_HOLDER_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_PK] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_ONE_HOLDER_ONLY_TCC] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] DROP CONSTRAINT [SCDPHL_SECURITY_DEPOSIT_ID_TUC] +GO + + +DROP TABLE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACTIVITY_TEMPLATE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_ACTIVITY_TEMPLATE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_ACTIVITY_TEMPLATE_JSON_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] DROP CONSTRAINT [ACTTMP_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_TEMPLATE', 'COLUMN', N'ACTIVITY_TEMPLATE_JSON' +GO + + +DROP TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQUISITION_FILE_PERSON" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_ACQUISITION_FILE_PERSON_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_PK] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] DROP CONSTRAINT [ACQPER_PERSON_PROFILE_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE_PERSON', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE_PERSON', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACQUISITION_FILE_PERSON] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQUISITION_OWNER" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_ACQUISITION_OWNER_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_OWNER_NAME_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_OWNER] DROP CONSTRAINT [ACQOWN_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_OWNER', 'COLUMN', N'OWNER_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_OWNER', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACQUISITION_OWNER] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQUISITION_FILE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_ACQUISITION_FILE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_REGION_CODE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_ASSIGNED_DATE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE] DROP CONSTRAINT [ACQNFL_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'MINISTRY_PROJECT_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'MINISTRY_PROJECT_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'CPS_PRODUCT_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'FILE_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'FILE_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'REGION_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'FUNDING_OTHER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'ASSIGNED_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', 'COLUMN', N'DELIVERY_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACQUISITION_FILE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_DOCUMENT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_DOCUMENT_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_FILE_NAME_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_MAYAN_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT] DROP CONSTRAINT [DOCMNT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT', 'COLUMN', N'FILE_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT', 'COLUMN', N'MAYAN_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_DOCUMENT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_REGION_USER" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_REGION_USER_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_REGION_CODE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_PK] +GO + + +ALTER TABLE [dbo].[PIMS_REGION_USER] DROP CONSTRAINT [RGNUSR_REGION_USER_TUC] +GO + + +DROP TABLE [dbo].[PIMS_REGION_USER] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_PAYMENT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_LEASE_PAYMENT_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT] DROP CONSTRAINT [LSPYMT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT', 'COLUMN', N'PAYMENT_RECEIVED_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT', 'COLUMN', N'PAYMENT_AMOUNT_PRE_TAX' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT', 'COLUMN', N'PAYMENT_AMOUNT_PST' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT', 'COLUMN', N'PAYMENT_AMOUNT_GST' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT', 'COLUMN', N'PAYMENT_AMOUNT_TOTAL' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT', 'COLUMN', N'NOTE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_PAYMENT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_TERM" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_LEASE_TERM_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM] DROP CONSTRAINT [LSTERM_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'LEASE_PMT_FREQ_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'TERM_START_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'TERM_EXPIRY_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'TERM_RENEWAL_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'PAYMENT AMOUNT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'PAYMENT_DUE_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'PAYMENT_NOTE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'IS_GST_ELIGIBLE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'GST_AMOUNT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', 'COLUMN', N'IS_TERM_EXERCISED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_TERM] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_SECURITY_DEPOSIT_RETURN" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_SECURITY_DEPOSIT_RETURN_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] DROP CONSTRAINT [SDRTRN_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT_RETURN', 'COLUMN', N'TERMINATION_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT_RETURN', 'COLUMN', N'CLAIMS_AGAINST' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT_RETURN', 'COLUMN', N'RETURN_AMOUNT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT_RETURN', 'COLUMN', N'RETURN_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT_RETURN', 'COLUMN', N'INTEREST_PAID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT_RETURN', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_IMPROVEMENT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_PROPERTY_IMPROVEMENT_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] DROP CONSTRAINT [PIMPRV_LEASE_IMPROVEMENT_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_IMPROVEMENT', 'COLUMN', N'IMPROVEMENT_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_IMPROVEMENT', 'COLUMN', N'STRUCTURE_SIZE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_IMPROVEMENT', 'COLUMN', N'ADDRESS' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_IMPROVEMENT', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_SECURITY_DEPOSIT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_SECURITY_DEPOSIT_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT] DROP CONSTRAINT [SECDEP_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT', 'COLUMN', N'OTHER_DEPOSIT_TYPE_DESC' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT', 'COLUMN', N'AMOUNT_PAID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT', 'COLUMN', N'DEPOSIT_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SECURITY_DEPOSIT', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_SECURITY_DEPOSIT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_INSURANCE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_INSURANCE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_COVERAGE_LIMIT_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_IS_INSURANCE_IN_PLACE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE] DROP CONSTRAINT [INSRNC_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_INSURANCE', 'COLUMN', N'OTHER_INSURANCE_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_INSURANCE', 'COLUMN', N'COVERAGE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_INSURANCE', 'COLUMN', N'COVERAGE_LIMIT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_INSURANCE', 'COLUMN', N'IS_INSURANCE_IN_PLACE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_INSURANCE', 'COLUMN', N'EXPIRY_DATE' +GO + + +DROP TABLE [dbo].[PIMS_INSURANCE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_TENANT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_LEASE_TENANT_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TENANT] DROP CONSTRAINT [TENANT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TENANT', 'COLUMN', N'NOTE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TENANT', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_TENANT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_LEASE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_IS_SUBJECT_TO_RTA_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_IS_COMM_BLDG_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_IS_OTHER_IMPROVEMENT_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_EXPIRED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE] DROP CONSTRAINT [LEASE_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'REGION_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'L_FILE_NO' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'TFA_FILE_NO' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'PS_FILE_NO' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'LEASE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'LEASE_CATEGORY_OTHER_DESC' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'LEASE_PURPOSE_OTHER_DESC' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'LEASE_NOTES' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'MOTI_CONTACT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'DOCUMENTATION_REFERENCE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'RETURN_NOTES' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'OTHER_LEASE_PROGRAM_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'OTHER_LEASE_LICENSE_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'OTHER_LEASE_PURPOSE_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'ORIG_START_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'ORIG_EXPIRY_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'LEASE_AMOUNT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'RESPONSIBILITY_EFFECTIVE_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'INSPECTION_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'INSPECTION_NOTES' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'IS_SUBJECT_TO_RTA' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'IS_COMM_BLDG' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'IS_OTHER_IMPROVEMENT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'IS_EXPIRED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'HAS_PHYSICAL_FILE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'HAS_DIGITAL_FILE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'HAS_PHYSICIAL_LICENSE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', 'COLUMN', N'HAS_DIGITAL_LICENSE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_CONTACT_METHOD" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_CONTACT_METHOD_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_IS_PREFERRED_METHOD_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD] DROP CONSTRAINT [CNTMTH_PK] +GO + + +DROP TABLE [dbo].[PIMS_CONTACT_METHOD] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_USER_ROLE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_USER_ROLE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_PK] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ROLE] DROP CONSTRAINT [USERRL_USER_ROLE_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER_ROLE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER_ROLE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_USER_ROLE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACCESS_REQUEST_ORGANIZATION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_ACCESS_REQUEST_ORGANIZATION_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_PK] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] DROP CONSTRAINT [ACRQOR_ORGANIZATION_ACCESS_REQUEST_TUC] +GO + + +DROP TABLE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACCESS_REQUEST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_ACCESS_REQUEST_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_REGION_CODE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST] DROP CONSTRAINT [ACRQST_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACCESS_REQUEST', 'COLUMN', N'NOTE' +GO + + +DROP TABLE [dbo].[PIMS_ACCESS_REQUEST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PERSON_ORGANIZATION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_PERSON_ORGANIZATION_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_PK] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON_ORGANIZATION] DROP CONSTRAINT [PERORG_PERSON_ORGANIZATION_TUC] +GO + + +DROP TABLE [dbo].[PIMS_PERSON_ORGANIZATION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ROLE_CLAIM" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_ROLE_CLAIM_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_PK] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE_CLAIM] DROP CONSTRAINT [ROLCLM_ROLE_CLAIM_TUC] +GO + + +DROP TABLE [dbo].[PIMS_ROLE_CLAIM] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_USER_ORGANIZATION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_USER_ORGANIZATION_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_PK] +GO + + +ALTER TABLE [dbo].[PIMS_USER_ORGANIZATION] DROP CONSTRAINT [USRORG_USER_ROLE_ORGANIZATION_TUC] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER_ORGANIZATION', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER_ORGANIZATION', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_USER_ORGANIZATION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ORGANIZATION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_ORGANIZATION_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION] DROP CONSTRAINT [ORG_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ORGANIZATION', 'COLUMN', N'INCORPORATION_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ORGANIZATION', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ORGANIZATION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROVINCE_STATE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] DROP CONSTRAINT [PROVNC_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] DROP CONSTRAINT [PROVNC_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] DROP CONSTRAINT [PROVNC_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] DROP CONSTRAINT [PROVNC_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] DROP CONSTRAINT [PROVNC_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] DROP CONSTRAINT [PROVNC_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROVINCE_STATE] DROP CONSTRAINT [PROVNC_PK] +GO + + +DROP TABLE [dbo].[PIMS_PROVINCE_STATE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_DISTRICT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_DISTRICT] DROP CONSTRAINT [DSTRCT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DISTRICT] DROP CONSTRAINT [DSTRCT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DISTRICT] DROP CONSTRAINT [DSTRCT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DISTRICT] DROP CONSTRAINT [DSTRCT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DISTRICT] DROP CONSTRAINT [DSTRCT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DISTRICT] DROP CONSTRAINT [DSTRCT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DISTRICT] DROP CONSTRAINT [DSTRCT_PK] +GO + + +DROP TABLE [dbo].[PIMS_DISTRICT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_USER" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_USER_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_USER] DROP CONSTRAINT [USER_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'BUSINESS_IDENTIFIER_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'GUID_IDENTIFIER_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'POSITION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'NOTE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'LAST_LOGIN' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'APPROVED_BY_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'ISSUE_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'EXPIRY_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_USER', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_USER] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_SERVICE_FILE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_PROPERTY_SERVICE_FILE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] DROP CONSTRAINT [PRPSVC_PK] +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LAND_SURVEYOR_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] DROP CONSTRAINT [LNSRVT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] DROP CONSTRAINT [LNSRVT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] DROP CONSTRAINT [LNSRVT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] DROP CONSTRAINT [LNSRVT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] DROP CONSTRAINT [LNSRVT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] DROP CONSTRAINT [LNSRVT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] DROP CONSTRAINT [LNSRVT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LAND_SURVEYOR_TYPE', 'COLUMN', N'LAND_SURVEYOR_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LAND_SURVEYOR_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LAND_SURVEYOR_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LAND_SURVEYOR_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LAND_SURVEYOR_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LAND_SURVEYOR_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_SURVEY_PLAN_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] DROP CONSTRAINT [SRVPLT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] DROP CONSTRAINT [SRVPLT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] DROP CONSTRAINT [SRVPLT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] DROP CONSTRAINT [SRVPLT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] DROP CONSTRAINT [SRVPLT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] DROP CONSTRAINT [SRVPLT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] DROP CONSTRAINT [SRVPLT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURVEY_PLAN_TYPE', 'COLUMN', N'SURVEY_PLAN_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURVEY_PLAN_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURVEY_PLAN_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURVEY_PLAN_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURVEY_PLAN_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_SURVEY_PLAN_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACTIVITY_TEMPLATE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] DROP CONSTRAINT [ACTTTY_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] DROP CONSTRAINT [ACTTTY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] DROP CONSTRAINT [ACTTTY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] DROP CONSTRAINT [ACTTTY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] DROP CONSTRAINT [ACTTTY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] DROP CONSTRAINT [ACTTTY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] DROP CONSTRAINT [ACTTTY_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_TEMPLATE_TYPE', 'COLUMN', N'ACTIVITY_TEMPLATE_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_TEMPLATE_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_TEMPLATE_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_TEMPLATE_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACTIVITY_TEMPLATE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACTIVITY_TEMPLATE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQ_FL_PERSON_PROFILE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] DROP CONSTRAINT [AQFPPT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] DROP CONSTRAINT [AQFPPT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] DROP CONSTRAINT [AQFPPT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] DROP CONSTRAINT [AQFPPT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] DROP CONSTRAINT [AQFPPT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] DROP CONSTRAINT [AQFPPT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] DROP CONSTRAINT [AQFPPT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', 'COLUMN', N'ACQ_FL_PERSON_PROFILE_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_FL_PERSON_PROFILE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACQ_FL_PERSON_PROFILE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQ_PHYS_FILE_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQPFS_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQPFS_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQPFS_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQPFS_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQPFS_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQPFS_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQPFS_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', 'COLUMN', N'ACQ_PHYS_FILE_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQ_PHYS_FILE_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACQ_PHYS_FILE_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQUISITION_FUNDING_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] DROP CONSTRAINT [ACQFTY_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] DROP CONSTRAINT [ACQFTY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] DROP CONSTRAINT [ACQFTY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] DROP CONSTRAINT [ACQFTY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] DROP CONSTRAINT [ACQFTY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] DROP CONSTRAINT [ACQFTY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] DROP CONSTRAINT [ACQFTY_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FUNDING_TYPE', 'COLUMN', N'ACQUISITION_FUNDING_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FUNDING_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FUNDING_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FUNDING_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FUNDING_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACQUISITION_FUNDING_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQUISITION_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQUISITION_TYPE] DROP CONSTRAINT [ACQTYP_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_TYPE] DROP CONSTRAINT [ACQTYP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_TYPE] DROP CONSTRAINT [ACQTYP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_TYPE] DROP CONSTRAINT [ACQTYP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_TYPE] DROP CONSTRAINT [ACQTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_TYPE] DROP CONSTRAINT [ACQTYP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_TYPE] DROP CONSTRAINT [ACQTYP_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_TYPE', 'COLUMN', N'ACQUISITION_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACQUISITION_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACQUISITION_FILE_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQFST_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQFST_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQFST_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQFST_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQFST_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQFST_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] DROP CONSTRAINT [ACQFST_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE_STATUS_TYPE', 'COLUMN', N'ACQUISITION_FILE_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE_STATUS_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE_STATUS_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_ACQUISITION_FILE_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_ACQUISITION_FILE_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACTIVITY_INSTANCE_NOTE_HIST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_HIST] DROP CONSTRAINT [DF__PIMS_ACTI___ACTI__6A50C1DA] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_HIST] DROP CONSTRAINT [DF__PIMS_ACTI__EFFEC__6B44E613] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_HIST] DROP CONSTRAINT [PIMS_ACTINN_H_PK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_HIST] DROP CONSTRAINT [PIMS_ACTINN_H_UK] +GO + + +DROP TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_HIST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACTIVITY_INSTANCE_HIST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] DROP CONSTRAINT [DF__PIMS_ACTI___ACTI__49E3F248] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] DROP CONSTRAINT [DF__PIMS_ACTI__EFFEC__4AD81681] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] DROP CONSTRAINT [PIMS_ACTINS_H_PK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] DROP CONSTRAINT [PIMS_ACTINS_H_UK] +GO + + +DROP TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_HIST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST] DROP CONSTRAINT [DF__PIMS_ACTI___ACTI__46136164] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST] DROP CONSTRAINT [DF__PIMS_ACTI__EFFEC__4707859D] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST] DROP CONSTRAINT [PIMS_ACTDOC_H_PK] +GO + + +ALTER TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST] DROP CONSTRAINT [PIMS_ACTDOC_H_UK] +GO + + +DROP TABLE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_HIST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_DOCUMENT_TYP_HIST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP_HIST] DROP CONSTRAINT [DF__PIMS_DOCU___DOCU__48BAC3E5] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP_HIST] DROP CONSTRAINT [DF__PIMS_DOCU__EFFEC__49AEE81E] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP_HIST] DROP CONSTRAINT [PIMS_DOCTYP_H_PK] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP_HIST] DROP CONSTRAINT [PIMS_DOCTYP_H_UK] +GO + + +DROP TABLE [dbo].[PIMS_DOCUMENT_TYP_HIST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_NOTE_HIST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_NOTE_HIST] DROP CONSTRAINT [DF__PIMS_NOTE___NOTE__12E8C319] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE_HIST] DROP CONSTRAINT [DF__PIMS_NOTE__EFFEC__13DCE752] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE_HIST] DROP CONSTRAINT [PIMS_NOTE_H_PK] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE_HIST] DROP CONSTRAINT [PIMS_NOTE_H_UK] +GO + + +DROP TABLE [dbo].[PIMS_NOTE_HIST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_DOCUMENT_HIST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_DOCUMENT_HIST] DROP CONSTRAINT [DF__PIMS_DOCU___DOCU__44EA3301] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_HIST] DROP CONSTRAINT [DF__PIMS_DOCU__EFFEC__45DE573A] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_HIST] DROP CONSTRAINT [PIMS_DOCMNT_H_PK] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_HIST] DROP CONSTRAINT [PIMS_DOCMNT_H_UK] +GO + + +DROP TABLE [dbo].[PIMS_DOCUMENT_HIST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_DOCUMENT_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] DROP CONSTRAINT [DOCSTY_DOCUMENT_STATUS_TYPE_CODE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] DROP CONSTRAINT [DOCSTY_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] DROP CONSTRAINT [DOCSTY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] DROP CONSTRAINT [DOCSTY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] DROP CONSTRAINT [DOCSTY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] DROP CONSTRAINT [DOCSTY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] DROP CONSTRAINT [DOCSTY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] DROP CONSTRAINT [DOCSTY_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT_STATUS_TYPE', 'COLUMN', N'DOCUMENT_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT_STATUS_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT_STATUS_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_DOCUMENT_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_DOCUMENT_TYP" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_DOCUMENT_TYPE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_MAYAN_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_DOCUMENT_TYPE_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DOCUMENT_TYP] DROP CONSTRAINT [DOCTYP_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT_TYP', 'COLUMN', N'MAYAN_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT_TYP', 'COLUMN', N'DOCUMENT_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DOCUMENT_TYP', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_DOCUMENT_TYP] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_NOTE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_NOTE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_NOTE_TXT_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_NOTE] DROP CONSTRAINT [NOTE_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_NOTE', 'COLUMN', N'NOTE_TXT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_NOTE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_NOTE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PPH_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PPH_STATUS_TYPE] DROP CONSTRAINT [PPHSTT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PPH_STATUS_TYPE] DROP CONSTRAINT [PPHSTT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PPH_STATUS_TYPE] DROP CONSTRAINT [PPHSTT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PPH_STATUS_TYPE] DROP CONSTRAINT [PPHSTT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PPH_STATUS_TYPE] DROP CONSTRAINT [PPHSTT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PPH_STATUS_TYPE] DROP CONSTRAINT [PPHSTT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PPH_STATUS_TYPE] DROP CONSTRAINT [PPHSTT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PPH_STATUS_TYPE', 'COLUMN', N'PPH_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PPH_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PPH_STATUS_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PPH_STATUS_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PPH_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PPH_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROP_RESEARCH_PURPOSE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RRESPT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RRESPT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RRESPT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RRESPT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RRESPT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RRESPT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RRESPT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', 'COLUMN', N'PROP_RESEARCH_PURPOSE_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROP_RESEARCH_PURPOSE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROP_RESEARCH_PURPOSE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_RESEARCH_PURPOSE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RSHPRT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RSHPRT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RSHPRT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RSHPRT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RSHPRT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RSHPRT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] DROP CONSTRAINT [RSHPRT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_PURPOSE_TYPE', 'COLUMN', N'RESEARCH_PURPOSE_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_PURPOSE_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_PURPOSE_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_PURPOSE_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_PURPOSE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_RESEARCH_PURPOSE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_REQUEST_SOURCE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] DROP CONSTRAINT [RQSRCT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] DROP CONSTRAINT [RQSRCT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] DROP CONSTRAINT [RQSRCT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] DROP CONSTRAINT [RQSRCT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] DROP CONSTRAINT [RQSRCT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] DROP CONSTRAINT [RQSRCT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] DROP CONSTRAINT [RQSRCT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_REQUEST_SOURCE_TYPE', 'COLUMN', N'REQUEST_SOURCE_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_REQUEST_SOURCE_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_REQUEST_SOURCE_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_REQUEST_SOURCE_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_REQUEST_SOURCE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_REQUEST_SOURCE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_TENANT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_TENANT] DROP CONSTRAINT [TENNTX_TENANT_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_TENANT] DROP CONSTRAINT [TENNTX_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_TENANT] DROP CONSTRAINT [TENNTX_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_TENANT] DROP CONSTRAINT [TENNTX_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_TENANT] DROP CONSTRAINT [TENNTX_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_TENANT] DROP CONSTRAINT [TENNTX_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_TENANT] DROP CONSTRAINT [TENNTX_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_TENANT', 'COLUMN', N'TENANT_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_TENANT', 'COLUMN', N'CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_TENANT', 'COLUMN', N'NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_TENANT', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_TENANT', 'COLUMN', N'SETTINGS' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_TENANT', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_TENANT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] DROP CONSTRAINT [LSSTYP_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] DROP CONSTRAINT [LSSTYP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] DROP CONSTRAINT [LSSTYP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] DROP CONSTRAINT [LSSTYP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] DROP CONSTRAINT [LSSTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] DROP CONSTRAINT [LSSTYP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] DROP CONSTRAINT [LSSTYP_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_STATUS_TYPE', 'COLUMN', N'LEASE_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_STATIC_VARIABLE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_APP_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_APP_CREATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_APP_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_APP_LAST_UPDATE_USER_DIRECTORY_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_STATIC_VARIABLE] DROP CONSTRAINT [STAVBL_PK] +GO + + +DROP TABLE [dbo].[PIMS_STATIC_VARIABLE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_PAYMENT_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] DROP CONSTRAINT [LPSTST_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] DROP CONSTRAINT [LPSTST_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] DROP CONSTRAINT [LPSTST_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] DROP CONSTRAINT [LPSTST_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] DROP CONSTRAINT [LPSTST_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] DROP CONSTRAINT [LPSTST_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] DROP CONSTRAINT [LPSTST_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_STATUS_TYPE', 'COLUMN', N'LEASE_PAYMENT_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_STATUS_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_STATUS_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_PAYMENT_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_PAYMENT_METHOD_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] DROP CONSTRAINT [LSPMMT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] DROP CONSTRAINT [LSPMMT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] DROP CONSTRAINT [LSPMMT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] DROP CONSTRAINT [LSPMMT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] DROP CONSTRAINT [LSPMMT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] DROP CONSTRAINT [LSPMMT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] DROP CONSTRAINT [LSPMMT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_METHOD_TYPE', 'COLUMN', N'LEASE_PAYMENT_METHOD_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_METHOD_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_METHOD_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_METHOD_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PAYMENT_METHOD_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_PAYMENT_METHOD_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_TERM_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] DROP CONSTRAINT [LTRMST_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] DROP CONSTRAINT [LTRMST_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] DROP CONSTRAINT [LTRMST_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] DROP CONSTRAINT [LTRMST_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] DROP CONSTRAINT [LTRMST_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] DROP CONSTRAINT [LTRMST_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] DROP CONSTRAINT [LTRMST_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM_STATUS_TYPE', 'COLUMN', N'LEASE_TERM_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_TERM_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_TERM_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_RESPONSIBILITY_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] DROP CONSTRAINT [LRESPT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] DROP CONSTRAINT [LRESPT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] DROP CONSTRAINT [LRESPT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] DROP CONSTRAINT [LRESPT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] DROP CONSTRAINT [LRESPT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] DROP CONSTRAINT [LRESPT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] DROP CONSTRAINT [LRESPT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_RESPONSIBILITY_TYPE', 'COLUMN', N'LEASE_RESPONSIBILITY_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_RESPONSIBILITY_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_RESPONSIBILITY_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_RESPONSIBILITY_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_INITIATOR_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] DROP CONSTRAINT [LINITT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] DROP CONSTRAINT [LINITT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] DROP CONSTRAINT [LINITT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] DROP CONSTRAINT [LINITT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] DROP CONSTRAINT [LINITT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] DROP CONSTRAINT [LINITT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] DROP CONSTRAINT [LINITT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_INITIATOR_TYPE', 'COLUMN', N'LEASE_INITIATOR_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_INITIATOR_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_INITIATOR_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_INITIATOR_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_IMPROVEMENT_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] DROP CONSTRAINT [PIMPRT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] DROP CONSTRAINT [PIMPRT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] DROP CONSTRAINT [PIMPRT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] DROP CONSTRAINT [PIMPRT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] DROP CONSTRAINT [PIMPRT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] DROP CONSTRAINT [PIMPRT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] DROP CONSTRAINT [PIMPRT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_IMPROVEMENT_TYPE', 'COLUMN', N'PROPERTY_IMPROVEMENT_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_IMPROVEMENT_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_IMPROVEMENT_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_IMPROVEMENT_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_IMPROVEMENT_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_SURPLUS_DECLARATION_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] DROP CONSTRAINT [SPDCLT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] DROP CONSTRAINT [SPDCLT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] DROP CONSTRAINT [SPDCLT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] DROP CONSTRAINT [SPDCLT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] DROP CONSTRAINT [SPDCLT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] DROP CONSTRAINT [SPDCLT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] DROP CONSTRAINT [SPDCLT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURPLUS_DECLARATION_TYPE', 'COLUMN', N'SURPLUS_DECLARATION_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURPLUS_DECLARATION_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURPLUS_DECLARATION_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_SURPLUS_DECLARATION_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_SURPLUS_DECLARATION_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_TAX_REMIT_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] DROP CONSTRAINT [PTRMTT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] DROP CONSTRAINT [PTRMTT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] DROP CONSTRAINT [PTRMTT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] DROP CONSTRAINT [PTRMTT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] DROP CONSTRAINT [PTRMTT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] DROP CONSTRAINT [PTRMTT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] DROP CONSTRAINT [PTRMTT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_TAX_REMIT_TYPE', 'COLUMN', N'PROPERTY_TAX_REMIT_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_TAX_REMIT_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_TAX_REMIT_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_TAX_REMIT_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_TAX_REMIT_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_PURPOSE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] DROP CONSTRAINT [LPRPTY_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] DROP CONSTRAINT [LPRPTY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] DROP CONSTRAINT [LPRPTY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] DROP CONSTRAINT [LPRPTY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] DROP CONSTRAINT [LPRPTY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] DROP CONSTRAINT [LPRPTY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] DROP CONSTRAINT [LPRPTY_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PURPOSE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_PURPOSE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_SECURITY_DEPOSIT_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] DROP CONSTRAINT [SECDPT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] DROP CONSTRAINT [SECDPT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] DROP CONSTRAINT [SECDPT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] DROP CONSTRAINT [SECDPT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] DROP CONSTRAINT [SECDPT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] DROP CONSTRAINT [SECDPT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] DROP CONSTRAINT [SECDPT_PK] +GO + + +DROP TABLE [dbo].[PIMS_SECURITY_DEPOSIT_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_INSURANCE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_INSURANCE_TYPE] DROP CONSTRAINT [INSPYT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE_TYPE] DROP CONSTRAINT [INSPYT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE_TYPE] DROP CONSTRAINT [INSPYT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE_TYPE] DROP CONSTRAINT [INSPYT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE_TYPE] DROP CONSTRAINT [INSPYT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE_TYPE] DROP CONSTRAINT [INSPYT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_INSURANCE_TYPE] DROP CONSTRAINT [INSPYT_PK] +GO + + +DROP TABLE [dbo].[PIMS_INSURANCE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_LICENSE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] DROP CONSTRAINT [LELIST_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] DROP CONSTRAINT [LELIST_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] DROP CONSTRAINT [LELIST_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] DROP CONSTRAINT [LELIST_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] DROP CONSTRAINT [LELIST_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] DROP CONSTRAINT [LELIST_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] DROP CONSTRAINT [LELIST_PK] +GO + + +DROP TABLE [dbo].[PIMS_LEASE_LICENSE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_PAY_RVBL_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] DROP CONSTRAINT [LSPRTY_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] DROP CONSTRAINT [LSPRTY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] DROP CONSTRAINT [LSPRTY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] DROP CONSTRAINT [LSPRTY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] DROP CONSTRAINT [LSPRTY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] DROP CONSTRAINT [LSPRTY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] DROP CONSTRAINT [LSPRTY_PK] +GO + + +DROP TABLE [dbo].[PIMS_LEASE_PAY_RVBL_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LESSOR_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LESSOR_TYPE] DROP CONSTRAINT [LSSRTY_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LESSOR_TYPE] DROP CONSTRAINT [LSSRTY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LESSOR_TYPE] DROP CONSTRAINT [LSSRTY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LESSOR_TYPE] DROP CONSTRAINT [LSSRTY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LESSOR_TYPE] DROP CONSTRAINT [LSSRTY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LESSOR_TYPE] DROP CONSTRAINT [LSSRTY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LESSOR_TYPE] DROP CONSTRAINT [LSSRTY_PK] +GO + + +DROP TABLE [dbo].[PIMS_LESSOR_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_PROGRAM_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] DROP CONSTRAINT [LSPRGT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] DROP CONSTRAINT [LSPRGT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] DROP CONSTRAINT [LSPRGT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] DROP CONSTRAINT [LSPRGT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] DROP CONSTRAINT [LSPRGT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] DROP CONSTRAINT [LSPRGT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] DROP CONSTRAINT [LSPRGT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PROGRAM_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_PROGRAM_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_PMT_FREQ_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] DROP CONSTRAINT [LSPMTF_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] DROP CONSTRAINT [LSPMTF_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] DROP CONSTRAINT [LSPMTF_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] DROP CONSTRAINT [LSPMTF_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] DROP CONSTRAINT [LSPMTF_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] DROP CONSTRAINT [LSPMTF_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] DROP CONSTRAINT [LSPMTF_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PMT_FREQ_TYPE', 'COLUMN', N'LEASE_PMT_FREQ_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PMT_FREQ_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_LEASE_PMT_FREQ_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_LEASE_PMT_FREQ_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_LEASE_CATEGORY_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] DROP CONSTRAINT [LSCATT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] DROP CONSTRAINT [LSCATT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] DROP CONSTRAINT [LSCATT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] DROP CONSTRAINT [LSCATT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] DROP CONSTRAINT [LSCATT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] DROP CONSTRAINT [LSCATT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] DROP CONSTRAINT [LSCATT_PK] +GO + + +DROP TABLE [dbo].[PIMS_LEASE_CATEGORY_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMSX_TableDefinitions" */ +/* ---------------------------------------------------------------------- */ + +DROP TABLE [dbo].[PIMSX_TableDefinitions] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ORG_IDENTIFIER_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] DROP CONSTRAINT [ORGIDT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] DROP CONSTRAINT [ORGIDT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] DROP CONSTRAINT [ORGIDT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] DROP CONSTRAINT [ORGIDT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] DROP CONSTRAINT [ORGIDT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] DROP CONSTRAINT [ORGIDT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] DROP CONSTRAINT [ORGIDT_PK] +GO + + +DROP TABLE [dbo].[PIMS_ORG_IDENTIFIER_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_DATA_SOURCE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] DROP CONSTRAINT [PIDSRT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] DROP CONSTRAINT [PIDSRT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] DROP CONSTRAINT [PIDSRT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] DROP CONSTRAINT [PIDSRT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] DROP CONSTRAINT [PIDSRT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] DROP CONSTRAINT [PIDSRT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] DROP CONSTRAINT [PIDSRT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', 'COLUMN', N'DATA_SOURCE_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_DATA_SOURCE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_DATA_SOURCE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.__EFMigrationsHistory" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[__EFMigrationsHistory] DROP CONSTRAINT [MIGHIS_PK] +GO + + +DROP TABLE [dbo].[__EFMigrationsHistory] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_AREA_UNIT_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_AREA_UNIT_TYPE] DROP CONSTRAINT [ARUNIT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_AREA_UNIT_TYPE] DROP CONSTRAINT [ARUNIT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_AREA_UNIT_TYPE] DROP CONSTRAINT [ARUNIT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_AREA_UNIT_TYPE] DROP CONSTRAINT [ARUNIT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_AREA_UNIT_TYPE] DROP CONSTRAINT [ARUNIT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_AREA_UNIT_TYPE] DROP CONSTRAINT [ARUNIT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_AREA_UNIT_TYPE] DROP CONSTRAINT [ARUNIT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_AREA_UNIT_TYPE', 'COLUMN', N'AREA_UNIT_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_AREA_UNIT_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_AREA_UNIT_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_AREA_UNIT_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_AREA_UNIT_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_AREA_UNIT_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_TENURE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] DROP CONSTRAINT [PRPTNR_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] DROP CONSTRAINT [PRPTNR_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] DROP CONSTRAINT [PRPTNR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] DROP CONSTRAINT [PRPTNR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] DROP CONSTRAINT [PRPTNR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] DROP CONSTRAINT [PRPTNR_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] DROP CONSTRAINT [PRPTNR_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_TENURE_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_TENURE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_CONTACT_METHOD_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] DROP CONSTRAINT [CNTMTT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] DROP CONSTRAINT [CNTMTT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] DROP CONSTRAINT [CNTMTT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] DROP CONSTRAINT [CNTMTT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] DROP CONSTRAINT [CNTMTT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] DROP CONSTRAINT [CNTMTT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] DROP CONSTRAINT [CNTMTT_PK] +GO + + +DROP TABLE [dbo].[PIMS_CONTACT_METHOD_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_CLASSIFICATION_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] DROP CONSTRAINT [PRPCLT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] DROP CONSTRAINT [PRPCLT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] DROP CONSTRAINT [PRPCLT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] DROP CONSTRAINT [PRPCLT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] DROP CONSTRAINT [PRPCLT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] DROP CONSTRAINT [PRPCLT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] DROP CONSTRAINT [PRPCLT_PK] +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_CLASSIFICATION_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ROLE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_ROLE_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_IS_PUBLIC_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ROLE] DROP CONSTRAINT [ROLE_PK] +GO + + +DROP TABLE [dbo].[PIMS_ROLE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_SERVICE_FILE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] DROP CONSTRAINT [PRSVFT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] DROP CONSTRAINT [PRSVFT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] DROP CONSTRAINT [PRSVFT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] DROP CONSTRAINT [PRSVFT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] DROP CONSTRAINT [PRSVFT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] DROP CONSTRAINT [PRSVFT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] DROP CONSTRAINT [PRSVFT_PK] +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_SERVICE_FILE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ACCESS_REQUEST_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] DROP CONSTRAINT [ARQSTT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] DROP CONSTRAINT [ARQSTT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] DROP CONSTRAINT [ARQSTT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] DROP CONSTRAINT [ARQSTT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] DROP CONSTRAINT [ARQSTT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] DROP CONSTRAINT [ARQSTT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] DROP CONSTRAINT [ARQSTT_PK] +GO + + +DROP TABLE [dbo].[PIMS_ACCESS_REQUEST_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ORGANIZATION_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_TYPE] DROP CONSTRAINT [ORGTYP_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_TYPE] DROP CONSTRAINT [ORGTYP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_TYPE] DROP CONSTRAINT [ORGTYP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_TYPE] DROP CONSTRAINT [ORGTYP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_TYPE] DROP CONSTRAINT [ORGTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_TYPE] DROP CONSTRAINT [ORGTYP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ORGANIZATION_TYPE] DROP CONSTRAINT [ORGTYP_PK] +GO + + +DROP TABLE [dbo].[PIMS_ORGANIZATION_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PERSON" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_PERSON_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_USE_ORGANIZATION_ADDRESS_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PERSON] DROP CONSTRAINT [PERSON_PK] +GO + + +DROP TABLE [dbo].[PIMS_PERSON] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_CLAIM" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_CLAIM_ID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_APP_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_APP_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_CLAIM] DROP CONSTRAINT [CLMTYP_PK] +GO + + +DROP TABLE [dbo].[PIMS_CLAIM] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_ADDRESS_USAGE_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] DROP CONSTRAINT [ADUSGT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] DROP CONSTRAINT [ADUSGT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] DROP CONSTRAINT [ADUSGT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] DROP CONSTRAINT [ADUSGT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] DROP CONSTRAINT [ADUSGT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] DROP CONSTRAINT [ADUSGT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] DROP CONSTRAINT [ADUSGT_PK] +GO + + +DROP TABLE [dbo].[PIMS_ADDRESS_USAGE_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_COUNTRY" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_COUNTRY] DROP CONSTRAINT [CNTRY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_COUNTRY] DROP CONSTRAINT [CNTRY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_COUNTRY] DROP CONSTRAINT [CNTRY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_COUNTRY] DROP CONSTRAINT [CNTRY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_COUNTRY] DROP CONSTRAINT [CNTRY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_COUNTRY] DROP CONSTRAINT [CNTRY_PK] +GO + + +DROP TABLE [dbo].[PIMS_COUNTRY] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_REGION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_REGION] DROP CONSTRAINT [REGION_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION] DROP CONSTRAINT [REGION_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION] DROP CONSTRAINT [REGION_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION] DROP CONSTRAINT [REGION_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION] DROP CONSTRAINT [REGION_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION] DROP CONSTRAINT [REGION_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_REGION] DROP CONSTRAINT [REGION_PK] +GO + + +DROP TABLE [dbo].[PIMS_REGION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_TYPE] DROP CONSTRAINT [PRPTYP_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TYPE] DROP CONSTRAINT [PRPTYP_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TYPE] DROP CONSTRAINT [PRPTYP_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TYPE] DROP CONSTRAINT [PRPTYP_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TYPE] DROP CONSTRAINT [PRPTYP_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TYPE] DROP CONSTRAINT [PRPTYP_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_TYPE] DROP CONSTRAINT [PRPTYP_PK] +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_RESEARCH_FILE_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] DROP CONSTRAINT [RSRCHS_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] DROP CONSTRAINT [RSRCHS_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] DROP CONSTRAINT [RSRCHS_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] DROP CONSTRAINT [RSRCHS_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] DROP CONSTRAINT [RSRCHS_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] DROP CONSTRAINT [RSRCHS_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] DROP CONSTRAINT [RSRCHS_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE_STATUS_TYPE', 'COLUMN', N'RESEARCH_FILE_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE_STATUS_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE_STATUS_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_RESEARCH_FILE_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_RESEARCH_FILE_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_VOLUME_UNIT_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] DROP CONSTRAINT [VOLUTY_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] DROP CONSTRAINT [VOLUTY_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] DROP CONSTRAINT [VOLUTY_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] DROP CONSTRAINT [VOLUTY_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] DROP CONSTRAINT [VOLUTY_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] DROP CONSTRAINT [VOLUTY_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] DROP CONSTRAINT [VOLUTY_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUME_UNIT_TYPE', 'COLUMN', N'VOLUME_UNIT_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUME_UNIT_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUME_UNIT_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUME_UNIT_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUME_UNIT_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_VOLUME_UNIT_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_VOLUMETRIC_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] DROP CONSTRAINT [PRVOLT_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] DROP CONSTRAINT [PRVOLT_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] DROP CONSTRAINT [PRVOLT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] DROP CONSTRAINT [PRVOLT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] DROP CONSTRAINT [PRVOLT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] DROP CONSTRAINT [PRVOLT_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] DROP CONSTRAINT [PRVOLT_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUMETRIC_TYPE', 'COLUMN', N'VOLUMETRIC_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUMETRIC_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUMETRIC_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUMETRIC_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_VOLUMETRIC_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_VOLUMETRIC_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_ADJACENT_LAND_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRADJL_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRADJL_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRADJL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRADJL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRADJL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRADJL_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] DROP CONSTRAINT [PRADJL_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', 'COLUMN', N'PROPERTY_ADJACENT_LAND_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ADJACENT_LAND_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_ADJACENT_LAND_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_ROAD_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] DROP CONSTRAINT [PRROAD_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] DROP CONSTRAINT [PRROAD_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] DROP CONSTRAINT [PRROAD_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] DROP CONSTRAINT [PRROAD_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] DROP CONSTRAINT [PRROAD_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] DROP CONSTRAINT [PRROAD_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] DROP CONSTRAINT [PRROAD_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ROAD_TYPE', 'COLUMN', N'PROPERTY_ROAD_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ROAD_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ROAD_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ROAD_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ROAD_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_ROAD_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_STATUS_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] DROP CONSTRAINT [PRPSTS_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] DROP CONSTRAINT [PRPSTS_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] DROP CONSTRAINT [PRPSTS_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] DROP CONSTRAINT [PRPSTS_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] DROP CONSTRAINT [PRPSTS_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] DROP CONSTRAINT [PRPSTS_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] DROP CONSTRAINT [PRPSTS_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_STATUS_TYPE', 'COLUMN', N'PROPERTY_STATUS_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_STATUS_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_STATUS_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_STATUS_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_STATUS_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_STATUS_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.PIMS_PROPERTY_ANOMALY_TYPE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] DROP CONSTRAINT [PRANOM_IS_DISABLED_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] DROP CONSTRAINT [PRANOM_CONCURRENCY_CONTROL_NUMBER_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] DROP CONSTRAINT [PRANOM_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] DROP CONSTRAINT [PRANOM_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] DROP CONSTRAINT [PRANOM_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] DROP CONSTRAINT [PRANOM_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] DROP CONSTRAINT [PRANOM_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ANOMALY_TYPE', 'COLUMN', N'PROPERTY_ANOMALY_TYPE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ANOMALY_TYPE', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ANOMALY_TYPE', 'COLUMN', N'IS_DISABLED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ANOMALY_TYPE', 'COLUMN', N'DISPLAY_ORDER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'PIMS_PROPERTY_ANOMALY_TYPE', NULL, NULL +GO + + +DROP TABLE [dbo].[PIMS_PROPERTY_ANOMALY_TYPE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_LAND_CHARACTERISTIC" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC] DROP CONSTRAINT [BCLCHR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC] DROP CONSTRAINT [BCLCHR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC] DROP CONSTRAINT [BCLCHR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC] DROP CONSTRAINT [BCLCHR_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LAND_CHARACTERISTIC', 'COLUMN', N'LAND_CHARACTERISTIC_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LAND_CHARACTERISTIC', 'COLUMN', N'LAND_CHARACTERISTIC_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LAND_CHARACTERISTIC', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_LAND_CHARACTERISTIC] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_OIL_AND_GAS" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_OIL_AND_GAS] DROP CONSTRAINT [BCOILG_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_OIL_AND_GAS] DROP CONSTRAINT [BCOILG_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_OIL_AND_GAS] DROP CONSTRAINT [BCOILG_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_OIL_AND_GAS] DROP CONSTRAINT [BCOILG_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_OIL_AND_GAS', 'COLUMN', N'FARM_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_OIL_AND_GAS', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_OIL_AND_GAS] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_MANAGED_FOREST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_MANAGED_FOREST] DROP CONSTRAINT [BCMFOR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_MANAGED_FOREST] DROP CONSTRAINT [BCMFOR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_MANAGED_FOREST] DROP CONSTRAINT [BCMFOR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_MANAGED_FOREST] DROP CONSTRAINT [BCMFOR_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_MANAGED_FOREST', 'COLUMN', N'FARM_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_MANAGED_FOREST', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_MANAGED_FOREST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_MANUFACTURED_HOME" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_MANUFACTURED_HOME] DROP CONSTRAINT [BCMANH_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_MANUFACTURED_HOME] DROP CONSTRAINT [BCMANH_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_MANUFACTURED_HOME] DROP CONSTRAINT [BCMANH_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_MANUFACTURED_HOME] DROP CONSTRAINT [BCMANH_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_MANUFACTURED_HOME', 'COLUMN', N'MH_REGISTRY_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_MANUFACTURED_HOME', 'COLUMN', N'MH_BAY_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_MANUFACTURED_HOME', 'COLUMN', N'MH_PARK' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_MANUFACTURED_HOME', 'COLUMN', N'MH_PARK_ROLL_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_MANUFACTURED_HOME', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_MANUFACTURED_HOME] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_FARM" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_FARM] DROP CONSTRAINT [BCFARM_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_FARM] DROP CONSTRAINT [BCFARM_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_FARM] DROP CONSTRAINT [BCFARM_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_FARM] DROP CONSTRAINT [BCFARM_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_FARM', 'COLUMN', N'FARM_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_FARM', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_FARM] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_ISLANDS_TRUST" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_ISLANDS_TRUST] DROP CONSTRAINT [BCISLT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ISLANDS_TRUST] DROP CONSTRAINT [BCISLT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ISLANDS_TRUST] DROP CONSTRAINT [BCISLT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ISLANDS_TRUST] DROP CONSTRAINT [BCISLT_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ISLANDS_TRUST', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ISLANDS_TRUST', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ISLANDS_TRUST', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ISLANDS_TRUST', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_ISLANDS_TRUST] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_IMPROVEMENT_DISTRICT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_IMPROVEMENT_DISTRICT] DROP CONSTRAINT [BCIMPD_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_IMPROVEMENT_DISTRICT] DROP CONSTRAINT [BCIMPD_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_IMPROVEMENT_DISTRICT] DROP CONSTRAINT [BCIMPD_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_IMPROVEMENT_DISTRICT] DROP CONSTRAINT [BCIMPD_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_IMPROVEMENT_DISTRICT', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_IMPROVEMENT_DISTRICT', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_IMPROVEMENT_DISTRICT', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_IMPROVEMENT_DISTRICT', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_IMPROVEMENT_DISTRICT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_GENERAL_SERVICE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_GENERAL_SERVICE] DROP CONSTRAINT [BCGSVC_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_GENERAL_SERVICE] DROP CONSTRAINT [BCGSVC_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_GENERAL_SERVICE] DROP CONSTRAINT [BCGSVC_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_GENERAL_SERVICE] DROP CONSTRAINT [BCGSVC_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_GENERAL_SERVICE', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_GENERAL_SERVICE', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_GENERAL_SERVICE', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_GENERAL_SERVICE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_GENERAL_SERVICE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_LOCAL_AREA" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_LOCAL_AREA] DROP CONSTRAINT [BCLCLA_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_LOCAL_AREA] DROP CONSTRAINT [BCLCLA_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_LOCAL_AREA] DROP CONSTRAINT [BCLCLA_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_LOCAL_AREA] DROP CONSTRAINT [BCLCLA_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_LOCAL_AREA', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_LOCAL_AREA', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_LOCAL_AREA', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_LOCAL_AREA', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_LOCAL_AREA] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_SPECIFIED_MUNICIPAL" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_SPECIFIED_MUNICIPAL] DROP CONSTRAINT [BCSPMU_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SPECIFIED_MUNICIPAL] DROP CONSTRAINT [BCSPMU_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SPECIFIED_MUNICIPAL] DROP CONSTRAINT [BCSPMU_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SPECIFIED_MUNICIPAL] DROP CONSTRAINT [BCSPMU_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SPECIFIED_MUNICIPAL', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SPECIFIED_MUNICIPAL', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SPECIFIED_MUNICIPAL', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SPECIFIED_MUNICIPAL', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_SPECIFIED_MUNICIPAL] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_SPECIFIED_REGIONAL" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_SPECIFIED_REGIONAL] DROP CONSTRAINT [BCSPRG_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SPECIFIED_REGIONAL] DROP CONSTRAINT [BCSPRG_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SPECIFIED_REGIONAL] DROP CONSTRAINT [BCSPRG_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SPECIFIED_REGIONAL] DROP CONSTRAINT [BCSPRG_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SPECIFIED_REGIONAL', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SPECIFIED_REGIONAL', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SPECIFIED_REGIONAL', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SPECIFIED_REGIONAL', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_SPECIFIED_REGIONAL] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_DEFINED" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_DEFINED] DROP CONSTRAINT [BCADFN_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DEFINED] DROP CONSTRAINT [BCADFN_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DEFINED] DROP CONSTRAINT [BCADFN_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DEFINED] DROP CONSTRAINT [BCADFN_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DEFINED', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DEFINED', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DEFINED', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DEFINED', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_DEFINED] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_SERVICE_AREA" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_SERVICE_AREA] DROP CONSTRAINT [BCSVCA_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SERVICE_AREA] DROP CONSTRAINT [BCSVCA_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SERVICE_AREA] DROP CONSTRAINT [BCSVCA_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_SERVICE_AREA] DROP CONSTRAINT [BCSVCA_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SERVICE_AREA', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SERVICE_AREA', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SERVICE_AREA', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_SERVICE_AREA', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_SERVICE_AREA] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_ELECTORAL_AREA" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_ELECTORAL_AREA] DROP CONSTRAINT [BCELCT_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ELECTORAL_AREA] DROP CONSTRAINT [BCELCT_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ELECTORAL_AREA] DROP CONSTRAINT [BCELCT_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ELECTORAL_AREA] DROP CONSTRAINT [BCELCT_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ELECTORAL_AREA', 'COLUMN', N'MINOR_TAXING_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ELECTORAL_AREA', 'COLUMN', N'MINOR_TAXING_CODE_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ELECTORAL_AREA', 'COLUMN', N'MINOR_TAXING_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ELECTORAL_AREA', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_ELECTORAL_AREA] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_MINOR_TAXING" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_MINOR_TAXING] DROP CONSTRAINT [BCMNTX_MINOR_TAXING_ID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_MINOR_TAXING] DROP CONSTRAINT [BCMNTX_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_MINOR_TAXING] DROP CONSTRAINT [BCMNTX_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_MINOR_TAXING] DROP CONSTRAINT [BCMNTX_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_MINOR_TAXING] DROP CONSTRAINT [BCMNTX_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_MINOR_TAXING] DROP CONSTRAINT [BCMNTX_PK] +GO + + +DROP TABLE [dbo].[BCA_MINOR_TAXING] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_AMENDMENT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_AMENDMENT] DROP CONSTRAINT [BCAFAM_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_AMENDMENT] DROP CONSTRAINT [BCAFAM_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_AMENDMENT] DROP CONSTRAINT [BCAFAM_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_AMENDMENT] DROP CONSTRAINT [BCAFAM_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_AMENDMENT', 'COLUMN', N'AMENDMENT_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_AMENDMENT', 'COLUMN', N'AMENDMENT_TYPE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_AMENDMENT', 'COLUMN', N'AMENDMENT_REASON_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_AMENDMENT', 'COLUMN', N'AMENDMENT_REASON_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_AMENDMENT', 'COLUMN', N'SUPP_OCCUPANCY_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_AMENDMENT', 'COLUMN', N'SUPP_OCCUPANCY_CODE' +GO + + +DROP TABLE [dbo].[BCA_FOLIO_AMENDMENT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_VALUATION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_VALUATION] DROP CONSTRAINT [BCAVAL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_VALUATION] DROP CONSTRAINT [BCAVAL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_VALUATION] DROP CONSTRAINT [BCAVAL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_VALUATION] DROP CONSTRAINT [BCAVAL_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_VALUATION', 'COLUMN', N'TAX_EXEMPT_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_VALUATION', 'COLUMN', N'TAX_EXEMPT_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_VALUATION', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_VALUATION', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_VALUATION', 'COLUMN', N'LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_VALUATION', 'COLUMN', N'IMPROVEMENT_VALUE' +GO + + +DROP TABLE [dbo].[BCA_FOLIO_VALUATION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_SCHOOL_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_SCHOOL_VALUE] DROP CONSTRAINT [BCFSCV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_SCHOOL_VALUE] DROP CONSTRAINT [BCFSCV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_SCHOOL_VALUE] DROP CONSTRAINT [BCFSCV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_SCHOOL_VALUE] DROP CONSTRAINT [BCFSCV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SCHOOL_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_SCHOOL_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_BCTRANSIT_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_BCTRANSIT_VALUE] DROP CONSTRAINT [BCFTRV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_BCTRANSIT_VALUE] DROP CONSTRAINT [BCFTRV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_BCTRANSIT_VALUE] DROP CONSTRAINT [BCFTRV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_BCTRANSIT_VALUE] DROP CONSTRAINT [BCFTRV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_BCTRANSIT_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_BCTRANSIT_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_GENERAL_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_GENERAL_VALUE] DROP CONSTRAINT [BCFGNV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_GENERAL_VALUE] DROP CONSTRAINT [BCFGNV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_GENERAL_VALUE] DROP CONSTRAINT [BCFGNV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_GENERAL_VALUE] DROP CONSTRAINT [BCFGNV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_GENERAL_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_GENERAL_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_SALES" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_SALES] DROP CONSTRAINT [BCAFSA_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_SALES] DROP CONSTRAINT [BCAFSA_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_SALES] DROP CONSTRAINT [BCAFSA_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_SALES] DROP CONSTRAINT [BCAFSA_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'DOCUMENT_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'SALE_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'SALE_PRICE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'SALE_STATUS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'SALE_STATUS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'CONVEYANCE_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'CONVEYANCE_PRICE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'CONVEYANCE_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'CONVEYANCE_TYPE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'REJECT_REASON_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_SALES', 'COLUMN', N'REJECT_REASON_DESCRIPTION' +GO + + +DROP TABLE [dbo].[BCA_FOLIO_SALES] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_DESCRIPTION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_DESCRIPTION] DROP CONSTRAINT [BCAFDE_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_DESCRIPTION] DROP CONSTRAINT [BCAFDE_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_DESCRIPTION] DROP CONSTRAINT [BCAFDE_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_DESCRIPTION] DROP CONSTRAINT [BCAFDE_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'NEIGHBOURHOOD_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'NEIGHBOURHOOD_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'ACTUAL_USE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'ACTUAL_USE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'VACANT_FLAG' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'BCTRANSIT_FLAG' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'POLICE_TAX_FLAG' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'ADD_SCHOOL_TAX_3M_TO_4M_FLAG' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'ADD_SCHOOL_TAX_GREATER_4M_FLAG' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'CANDIDATE_FOR_SPEC_TAX_FLAG' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'ALR_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'ALR_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'TENURE_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'TENURE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'PARKING_AREA' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'LAND_DIMENSION_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'LAND_DIMENSION_TYPE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'LAND_DIMENSION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'LAND_WIDTH' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'LAND_DEPTH' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'SCHOOL_DISTRICT_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'SCHOOL_DISTRICT_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'REGIONAL_DISTRICT_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'REGIONAL_DISTRICT_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'REGIONAL_HOSPITAL_DISTRICT_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'REGIONAL_HOSPITAL_DISTRICT_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'PREDOMINANT_MANUAL_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'PREDOMINANT_MANUAL_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', 'COLUMN', N'PREDOMINANT_PERCENT_DEVIATION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_DESCRIPTION', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_DESCRIPTION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_JURISDICTION_BCTRANSIT_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE] DROP CONSTRAINT [BCJTRV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE] DROP CONSTRAINT [BCJTRV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE] DROP CONSTRAINT [BCJTRV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE] DROP CONSTRAINT [BCJTRV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_BCTRANSIT_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_JURISDICTION_BCTRANSIT_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_JURISDICTION_SCHOOL_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_JURISDICTION_SCHOOL_VALUE] DROP CONSTRAINT [BCJSCV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_SCHOOL_VALUE] DROP CONSTRAINT [BCJSCV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_SCHOOL_VALUE] DROP CONSTRAINT [BCJSCV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_SCHOOL_VALUE] DROP CONSTRAINT [BCJSCV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_SCHOOL_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_JURISDICTION_SCHOOL_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_JURISDICTION_GENERAL_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_JURISDICTION_GENERAL_VALUE] DROP CONSTRAINT [BCJGNV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_GENERAL_VALUE] DROP CONSTRAINT [BCJGNV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_GENERAL_VALUE] DROP CONSTRAINT [BCJGNV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_GENERAL_VALUE] DROP CONSTRAINT [BCJGNV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_GENERAL_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_JURISDICTION_GENERAL_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_AREA_SCHOOL_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_AREA_SCHOOL_VALUE] DROP CONSTRAINT [BCASCV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_SCHOOL_VALUE] DROP CONSTRAINT [BCASCV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_SCHOOL_VALUE] DROP CONSTRAINT [BCASCV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_SCHOOL_VALUE] DROP CONSTRAINT [BCASCV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_SCHOOL_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_AREA_SCHOOL_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_AREA_BCTRANSIT_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_AREA_BCTRANSIT_VALUE] DROP CONSTRAINT [BCATRV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_BCTRANSIT_VALUE] DROP CONSTRAINT [BCATRV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_BCTRANSIT_VALUE] DROP CONSTRAINT [BCATRV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_BCTRANSIT_VALUE] DROP CONSTRAINT [BCATRV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_BCTRANSIT_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_AREA_BCTRANSIT_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_AREA_GENERAL_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_AREA_GENERAL_VALUE] DROP CONSTRAINT [BCAGNV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_GENERAL_VALUE] DROP CONSTRAINT [BCAGNV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_GENERAL_VALUE] DROP CONSTRAINT [BCAGNV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_GENERAL_VALUE] DROP CONSTRAINT [BCAGNV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_GENERAL_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_AREA_GENERAL_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_AREA_AMENDMENT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_AREA_AMENDMENT] DROP CONSTRAINT [BCAAMD_FOLIO_COUNT_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_AMENDMENT] DROP CONSTRAINT [BCAAMD_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_AMENDMENT] DROP CONSTRAINT [BCAAMD_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_AMENDMENT] DROP CONSTRAINT [BCAAMD_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_AMENDMENT] DROP CONSTRAINT [BCAAMD_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_AMENDMENT', 'COLUMN', N'AMENDMENT_REASON_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_AMENDMENT', 'COLUMN', N'AMENDMENT_REASON_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_AMENDMENT', 'COLUMN', N'FOLIO_COUNT' +GO + + +DROP TABLE [dbo].[BCA_AREA_AMENDMENT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_AREA_DELETE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_AREA_DELETE] DROP CONSTRAINT [BCADEL_DELETE_REASON_CODE_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_DELETE] DROP CONSTRAINT [BCADEL_FOLIO_COUNT_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_DELETE] DROP CONSTRAINT [BCADEL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_DELETE] DROP CONSTRAINT [BCADEL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_DELETE] DROP CONSTRAINT [BCADEL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_AREA_DELETE] DROP CONSTRAINT [BCADEL_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_DELETE', 'COLUMN', N'DELETE_REASON_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_DELETE', 'COLUMN', N'DELETE_REASON_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_AREA_DELETE', 'COLUMN', N'FOLIO_COUNT' +GO + + +DROP TABLE [dbo].[BCA_AREA_DELETE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_DATA_ADVICE_AMENDMENT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] DROP CONSTRAINT [BCDAMD_FOLIO_COUNT_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] DROP CONSTRAINT [BCDAMD_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] DROP CONSTRAINT [BCDAMD_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] DROP CONSTRAINT [BCDAMD_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] DROP CONSTRAINT [BCDAMD_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_AMENDMENT', 'COLUMN', N'AMENDMENT_REASON_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_AMENDMENT', 'COLUMN', N'AMENDMENT_REASON_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_AMENDMENT', 'COLUMN', N'FOLIO_COUNT' +GO + + +DROP TABLE [dbo].[BCA_DATA_ADVICE_AMENDMENT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_DATA_ADVICE_DELETE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_DELETE] DROP CONSTRAINT [BCDDEL_DELETE_REASON_CODE_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_DELETE] DROP CONSTRAINT [BCDDEL_FOLIO_COUNT_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_DELETE] DROP CONSTRAINT [BCDDEL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_DELETE] DROP CONSTRAINT [BCDDEL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_DELETE] DROP CONSTRAINT [BCDDEL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_DELETE] DROP CONSTRAINT [BCDDEL_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_DELETE', 'COLUMN', N'DELETE_REASON_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_DELETE', 'COLUMN', N'DELETE_REASON_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_DELETE', 'COLUMN', N'FOLIO_COUNT' +GO + + +DROP TABLE [dbo].[BCA_DATA_ADVICE_DELETE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_LEGAL_DESCRIPTION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION] DROP CONSTRAINT [BCAFLD_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION] DROP CONSTRAINT [BCAFLD_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION] DROP CONSTRAINT [BCAFLD_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION] DROP CONSTRAINT [BCAFLD_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'FORMATTED_LEGAL_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'PID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'LOT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'STRATA_LOT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'PARCEL' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'BLOCK' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'SUB_BLOCK' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'PLAN_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'SUB_LOT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'PART_1' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'PART_2' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'PART_3' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'PART_4' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'DISTRICT_LOT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'LEGAL_SUBDIVISION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'SECTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'TOWNSHIP' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'RANGE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'MERIDIAN' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'MERIDIAN_SHORT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'BCA_GROUP' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'LAND_DISTRICT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'LAND_DISTRICT_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'PORTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'EXCEPT_PLAN' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'FIRST_NATION_RESERVE_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'FIRST_NATION_RESERVE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'LEASE_LICENSE_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'LAND_BRANCH_FILE_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'AIR_SPACE_PARCEL_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'NTS_LOCATION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_LEGAL_DESCRIPTION', 'COLUMN', N'LEGAL_TEXT' +GO + + +DROP TABLE [dbo].[BCA_FOLIO_LEGAL_DESCRIPTION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_JURISDICTION_DELETE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_JURISDICTION_DELETE] DROP CONSTRAINT [BCJDEL_DELETE_REASON_CODE_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_DELETE] DROP CONSTRAINT [BCJDEL_FOLIO_COUNT_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_DELETE] DROP CONSTRAINT [BCJDEL_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_DELETE] DROP CONSTRAINT [BCJDEL_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_DELETE] DROP CONSTRAINT [BCJDEL_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_DELETE] DROP CONSTRAINT [BCJDEL_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_DELETE', 'COLUMN', N'DELETE_REASON_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_DELETE', 'COLUMN', N'DELETE_REASON_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_DELETE', 'COLUMN', N'FOLIO_COUNT' +GO + + +DROP TABLE [dbo].[BCA_JURISDICTION_DELETE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_JURISDICTION_AMENDMENT" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] DROP CONSTRAINT [BCJAMD_FOLIO_COUNT_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] DROP CONSTRAINT [BCJAMD_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] DROP CONSTRAINT [BCJAMD_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] DROP CONSTRAINT [BCJAMD_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] DROP CONSTRAINT [BCJAMD_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_AMENDMENT', 'COLUMN', N'AMENDMENT_REASON_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_AMENDMENT', 'COLUMN', N'AMENDMENT_REASON_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION_AMENDMENT', 'COLUMN', N'FOLIO_COUNT' +GO + + +DROP TABLE [dbo].[BCA_JURISDICTION_AMENDMENT] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_DATA_ADVICE_SCHOOL_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE] DROP CONSTRAINT [BCDSCV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE] DROP CONSTRAINT [BCDSCV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE] DROP CONSTRAINT [BCDSCV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE] DROP CONSTRAINT [BCDSCV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_SCHOOL_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_DATA_ADVICE_SCHOOL_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_DATA_ADVICE_BCTRANSIT_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE] DROP CONSTRAINT [BCDTRV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE] DROP CONSTRAINT [BCDTRV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE] DROP CONSTRAINT [BCDTRV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE] DROP CONSTRAINT [BCDTRV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_BCTRANSIT_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_DATA_ADVICE_BCTRANSIT_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_DATA_ADVICE_GENERAL_VALUE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE] DROP CONSTRAINT [BCDGNV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE] DROP CONSTRAINT [BCDGNV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE] DROP CONSTRAINT [BCDGNV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE] DROP CONSTRAINT [BCDGNV_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'PROPERTY_CLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'PROPERTY_CLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'PROPERTY_SUBCLASS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', 'COLUMN', N'NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE_GENERAL_VALUE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_DATA_ADVICE_GENERAL_VALUE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_OWNER" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_OWNER] DROP CONSTRAINT [BCAOWN_OWNER_ID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNER] DROP CONSTRAINT [BCAOWN_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNER] DROP CONSTRAINT [BCAOWN_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNER] DROP CONSTRAINT [BCAOWN_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNER] DROP CONSTRAINT [BCAOWN_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNER] DROP CONSTRAINT [BCAOWN_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNER', 'COLUMN', N'FIRST_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNER', 'COLUMN', N'MIDDLE_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNER', 'COLUMN', N'MIDDLE_INITIAL' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNER', 'COLUMN', N'COMPANY_OR_LAST_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNER', 'COLUMN', N'OWNER_SEQUENCE_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNER', 'COLUMN', N'EQUITY_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNER', 'COLUMN', N'EQUITY_TYPE_DESCRIPTION' +GO + + +DROP TABLE [dbo].[BCA_OWNER] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_OWNERSHIP_GROUP" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] DROP CONSTRAINT [BCAOWG_ASSESSMENT_NOTICE_RETURNED_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] DROP CONSTRAINT [BCAOWG_ASSESSMENT_NOTICE_SUPPRESSED_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] DROP CONSTRAINT [BCAOWG_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] DROP CONSTRAINT [BCAOWG_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] DROP CONSTRAINT [BCAOWG_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] DROP CONSTRAINT [BCAOWG_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_OWNERSHIP_GROUP] DROP CONSTRAINT [BCAOWG_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'OWNERSHIP_GROUP_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'ASSESSMENT_NOTICE_RETURNED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'ASSESSMENT_NOTICE_SUPPRESSED' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'CHANGE_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'CHANGE_TYPE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'CHANGE_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'FORMATTED_MAILING_ADDR_LINE_1' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'FORMATTED_MAILING_ADDR_LINE_2' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'FORMATTED_MAILING_ADDR_LINE_3' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'FORMATTED_MAILING_ADDR_LINE_4' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'FORMATTED_MAILING_ADDR_LINE_5' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'FORMATTED_MAILING_ADDR_LINE_6' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_ATTENTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_CARE_OF' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_FLOOR' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_UNIT_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_STREET_DIRECTION_PREFIX' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_STREET_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_STREET_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_STREET_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_STREET_DIRECTION_SUFFIX' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_CITY' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_PROVINCE_STATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_COUNTRY' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_POSTAL_ZIP' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_FREE_FORM' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_COMPARTMENT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_DELIVERY_INSTALLATION_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_MODE_OF_DELIVERY' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_MODE_OF_DELIVERY_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_SITE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'MAILING_ADDR_BULK_MAIL_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'CHANGE_SOURCE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', 'COLUMN', N'CHANGE_SOURCE_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_OWNERSHIP_GROUP', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_OWNERSHIP_GROUP] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_ADDRESS" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_ADDRESS] DROP CONSTRAINT [BCFADR_PRIMARY_FLAG_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_ADDRESS] DROP CONSTRAINT [BCFADR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_ADDRESS] DROP CONSTRAINT [BCFADR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_ADDRESS] DROP CONSTRAINT [BCFADR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_ADDRESS] DROP CONSTRAINT [BCFADR_DB_LAST_UPDATE_USERID_DEF] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'ADDRESS_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'PRIMARY_FLAG' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'UNIT_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'STREET_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'STREET_DIRECTION_PREFIX' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'STREET_NAME' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'STREET_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'STREET_DIRECTION_SUFFIX' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'CITY' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'PROVINCE_STATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'POSTAL_ZIP' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_ADDRESS', 'COLUMN', N'MAP_REFERENCE_NUMBER' +GO + + +DROP TABLE [dbo].[BCA_FOLIO_ADDRESS] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_FOLIO_RECORD" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_FOLIO_RECORD] DROP CONSTRAINT [BCAFOR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_RECORD] DROP CONSTRAINT [BCAFOR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_RECORD] DROP CONSTRAINT [BCAFOR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_RECORD] DROP CONSTRAINT [BCAFOR_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_FOLIO_RECORD] DROP CONSTRAINT [BCAFOR_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_RECORD', 'COLUMN', N'ROLL_NUMBER' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_RECORD', 'COLUMN', N'FOLIO_STATUS' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_RECORD', 'COLUMN', N'FOLIO_STATUS_DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_RECORD', 'COLUMN', N'ACTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_FOLIO_RECORD', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_FOLIO_RECORD] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_JURISDICTION" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_JURISDICTION] DROP CONSTRAINT [BCAJUR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION] DROP CONSTRAINT [BCAJUR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION] DROP CONSTRAINT [BCAJUR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION] DROP CONSTRAINT [BCAJUR_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_JURISDICTION] DROP CONSTRAINT [BCAJUR_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION', 'COLUMN', N'JURISDICTION_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_JURISDICTION', 'COLUMN', N'DESCRIPTION' +GO + + +DROP TABLE [dbo].[BCA_JURISDICTION] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_ASSESSMENT_AREA" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_ASSESSMENT_AREA] DROP CONSTRAINT [BCASAR_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ASSESSMENT_AREA] DROP CONSTRAINT [BCASAR_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ASSESSMENT_AREA] DROP CONSTRAINT [BCASAR_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ASSESSMENT_AREA] DROP CONSTRAINT [BCASAR_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_ASSESSMENT_AREA] DROP CONSTRAINT [BCASAR_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ASSESSMENT_AREA', 'COLUMN', N'AREA_CODE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ASSESSMENT_AREA', 'COLUMN', N'DESCRIPTION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_ASSESSMENT_AREA', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_ASSESSMENT_AREA] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop table "dbo.BCA_DATA_ADVICE" */ +/* ---------------------------------------------------------------------- */ + +/* Drop constraints */ + +ALTER TABLE [dbo].[BCA_DATA_ADVICE] DROP CONSTRAINT [BCDADV_DATA_ADVICE_ID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE] DROP CONSTRAINT [BCDADV_DB_CREATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE] DROP CONSTRAINT [BCDADV_DB_CREATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE] DROP CONSTRAINT [BCDADV_DB_LAST_UPDATE_TIMESTAMP_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE] DROP CONSTRAINT [BCDADV_DB_LAST_UPDATE_USERID_DEF] +GO + + +ALTER TABLE [dbo].[BCA_DATA_ADVICE] DROP CONSTRAINT [BCDADV_PK] +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'DATA_ADVICE_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'ROLL_YEAR' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'OWNERSHIP_YEAR' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'RUN_TYPE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'START_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'END_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TOTAL_FOLIO_COUNT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TAXABLE_FOLIO_COUNT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TAX_EXEMPT_FOLIO_COUNT' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TOTAL_GROSS_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TOTAL_GROSS_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TOTAL_TAX_EXEMPT_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TOTAL_TAX_EXEMPT_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TOTAL_NET_LAND_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'TOTAL_NET_IMPROVEMENT_VALUE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'VERSION' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'REQUEST_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'ORDER_ID' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', 'COLUMN', N'RUN_DATE' +GO + + +EXECUTE sp_dropextendedproperty N'MS_Description', 'SCHEMA', N'dbo', 'TABLE', N'BCA_DATA_ADVICE', NULL, NULL +GO + + +DROP TABLE [dbo].[BCA_DATA_ADVICE] +GO + + +/* ---------------------------------------------------------------------- */ +/* Drop sequences */ +/* ---------------------------------------------------------------------- */ + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_DOCUMENT_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_NOTE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_NOTE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_DOCUMENT_TYPE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_DOCUMENT_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_DOCUMENT_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_NOTE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_DOCUMENT_TYP_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[BCA_DATA_ADVICE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_REGION_USER_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_REGION_USER_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[BCA_OWNER_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[BCA_MINOR_TAXING_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROP_PROP_ROAD_TYPE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROP_PROP_ANOMALY_TYPE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROP_PROP_ADJACENT_LAND_TYPE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROP_PROP_TENURE_TYPE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_RESEARCH_FILE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_RESEARCH_FILE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_RFILE_NUMBER_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_RESEARCH_FILE_PURPOSE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PRF_PROP_RESEARCH_PURPOSE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_RESEARCH_FILE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_RESEARCH_FILE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_RESEARCH_FILE_PURPOSE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_HOLDER_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_STATIC_VARIABLE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_TENANT_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ORGANIZATION_ADDRESS_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PERSON_ADDRESS_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PERSON_ADDRESS_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ORGANIZATION_ADDRESS_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_TERM_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_FORECAST_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_PERIOD_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_TERM_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_TENANT_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_PERIOD_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_INSURANCE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_TAX_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_IMPROVEMENT_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_TAX_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_INSURANCE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_TENANT_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_IMPROVEMENT_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_TASK_TEMPLATE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_USER_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_MODEL_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_USER_ORGANIZATION_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ADDRESS_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_USER_ROLE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_CLAIM_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_WORKFLOW_MODEL_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_CONTACT_METHOD_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ORGANIZATION_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PERSON_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PERSON_ORGANIZATION_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_NOTE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_PROPERTY_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_WORKFLOW_MODEL_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_ACTIVITY_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_EVALUATION_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_ORGANIZATION_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_SERVICE_FILE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ROLE_CLAIM_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ROLE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_TASK_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACCESS_REQUEST_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_TASK_TEMPLATE_ACTIVITY_MODEL_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_PAYMENT_FORECAST_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_ACTIVITY_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_ACTIVITY_PERIOD_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_LEASE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_L_FILE_NO_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_LEASE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_LEASE_H_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_INSTANCE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_WORKFLOW_MODEL_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_TASK_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_MODEL_TASK_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_TASK_TEMPLATE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_SERVICE_FILE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_TASK_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_USER_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_PROPERTY_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_WORKFLOW_MODEL_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_ACTIVITY_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_USER_TASK_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ORGANIZATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PERSON_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PERSON_ORGANIZATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACCESS_REQUEST_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACCESS_REQUEST_ORGANIZATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_NOTE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_MODEL_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ADDRESS_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_USER_ORGANIZATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ROLE_CLAIM_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ROLE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_USER_ROLE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_CLAIM_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_NUMBER_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_TASK_TEMPLATE_ACTIVITY_MODEL_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_CONTACT_METHOD_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROJECT_ORGANIZATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_PROPERTY_SERVICE_FILE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_ORGANIZATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_STRUCTURE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ASSET_EVALUATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_EVALUATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_STRUCTURE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_BUILDING_CONSTRUCTION_TYPE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_BUILDING_OCCUPANT_TYPE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_BUILDING_PREDOMINATE_USE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_BUILDING_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_BUILDING_EVALUATION_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_BUILDING_FISCAL_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_SERVICE_FILE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_PROPERTY_ACQUISITION_FILE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACQUISITION_OWNER_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_PERSON_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACQUISITION_FILE_NUMBER_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACTIVITY_TEMPLATE_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACQUISITION_ACTIVITY_ID_SEQ] +GO + + +DROP SEQUENCE [dbo].[PIMS_ACQUISITION_ACTIVITY_INSTANCE_ID_SEQ] +GO + diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/PIMS PDM S32.00.png b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/PIMS PDM S32.00.png new file mode 100644 index 0000000000..193aa76dc4 Binary files /dev/null and b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/PIMS PDM S32.00.png differ diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/PIMS S32.00 Change Log.txt b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/PIMS S32.00 Change Log.txt new file mode 100644 index 0000000000..121603d64b --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/PIMS S32.00 Change Log.txt @@ -0,0 +1,649 @@ +PSP_PIMS S32.00 Sprint 32 2022-Jul-07 +- Added tables: + - PIMS_ACQUISITION_ACTIVITY_INSTANCE + - PIMS_ACQUISITION_ACTIVITY_INSTANCE_HIST + - PIMS_ACQUISITION_FILE + - PIMS_ACQUISITION_FILE_HIST + - PIMS_ACQUISITION_FILE_PERSON + - PIMS_ACQUISITION_FILE_PERSON_HIST + - PIMS_ACQUISITION_OWNER + - PIMS_ACQUISITION_OWNER_HIST + - PIMS_ACQUISITION_FILE_STATUS_TYPE + - PIMS_ACQUISITION_FUNDING_TYPE + - PIMS_ACQUISITION_TYPE + - PIMS_ACQ_FL_PERSON_PROFILE_TYPE + - PIMS_ACQ_PHYS_FILE_STATUS_TYPE + - PIMS_ACTIVITY_TEMPLATE + - PIMS_ACTIVITY_TEMPLATE_HIST + - PIMS_ACTIVITY_TEMPLATE_TYPE + - PIMS_LAND_SURVEYOR_TYPE + - PIMS_PROPERTY_ACQUISITION_FILE + - PIMS_PROPERTY_ACQUISITION_FILE_HIST + - PIMS_SURVEY_PLAN_TYPE +- Added seed scripts: + - 88_DML_PIMS_DOCUMENT_STATUS_TYPE.sql + - 90_DML_PIMS_ACQUISITION_TYPE.sql + - 91_DML_PIMS_ACQUISITION_FUNDING_TYPE.sql + - 92_DML_PIMS_ACQ_PHYS_FILE_STATUS_TYPE.sql + - 93_DML_PIMS_ACQ_FL_PERSON_PROFILE_TYPE.sql + - 94_DML_PIMS_ACTIVITY_TEMPLATE_TYPE.sql + - 95_DML_PIMS_SURVEY_PLAN_TYPE.sql + - 96_DML_PIMS_LAND_SURVEYOR_TYPE.sql +- Requires additional metadata to meet standards + +PSP_PIMS S31.01 Sprint 31 2022-Jun-27 +- Added tables: + - PIMS_ACTIVITY_INSTANCE + - PIMS_ACTIVITY_INSTANCE_DOCUMENT + - PIMS_ACTIVITY_INSTANCE_NOTE +- Dropped tables: + - PIMS_PROJECT + - PIMS_PROJECT_WORKFLOW_MODEL_HIST + - PIMS_PROJECT_STATUS_TYPE + - PIMS_PROJECT_TIER_TYPE + - PIMS_ACTIVITY + - PIMS_ACTIVITY + - PIMS_ACTIVITY_HIST + - PIMS_PROJECT_NOTE + - PIMS_WORKFLOW_MODEL + - PIMS_PROJECT_PROPERTY + - PIMS_PROJECT_TYPE + - PIMS_PROJECT_PROPERTY_HIST + - PIMS_WORKFLOW_MODEL_TYPE + - PIMS_WORKFLOW_MODEL_HIST + - PIMS_PROJECT_HIST + - PIMS_TASK + - PIMS_TASK_TEMPLATE_ACTIVITY_MODEL + - PIMS_TASK_TEMPLATE + - PIMS_PROJECT_WORKFLOW_MODEL + - PIMS_PROJECT_RISK_TYPE + - PIMS_ACTIVITY_MODEL + - PIMS_TASK_HIST + - PIMS_PROPERTY_ACTIVITY_HIST + - PIMS_TASK_TEMPLATE_ACTIVITY_MODEL_HIST + - PIMS_ACTIVITY_MODEL_HIST + - PIMS_PROPERTY_ACTIVITY + - PIMS_TASK_TEMPLATE_TYPE + - PIMS_TASK_TEMPLATE_HIST +- Requires additional metadata to meet standards + +PSP_PIMS S31.00 Sprint 30 2022-Jun-21 +- Added tables: + - PIMS_NOTE + - PIMS_DOCUMENT + - PIMS_DOCUMENT_STATUS_TYPE + - PIMS_DOCUMENT_TYP +- Altered tables: + - PIMS_PROPERTY + - Added column FILE_NUMBER + - Added column FILE_NUMBER_SUFFIX +- Added seed scripts: + - 88_DML_PIMS_DOCUMENT_STATUS_TYPE.sql +- Requires additional metadata to meet standards + +PSP_PIMS S30.00 Sprint 29 2022-Jun-06 +- Altered tables: + - PIMS_PROPERTY + - Added column PPH_STATUS_UPDATE_USER_GUID +- Added script: + - 00_PSP_PIMS_PMBC_Build.sql added to Alter Up and Build + - PMBC schema and table was added to support ParcelMapBC property data integration into PIMS. +- Requires additional metadata to meet standards + +PSP_PIMS S29.01 Sprint 29 2022-Jun-06 +- Altered tables: + - PIMS_INSURANCE + - Dropped unique constraint INSRNC_LEASE_INSURANCE_TYPE_TUC +- Requires additional metadata to meet standards + +PSP_PIMS S28.00 Sprint 28 2022-May-12 +- Seed data table changes: + - PIMS_REGION + - Added 4: Cannot determine + - PIMS_DISTRICT + - Added 12: Cannot determine +- Requires additional metadata to meet standards + +PSP_PIMS S29.00 Sprint 28 2022-May-17 +- Altered tables: + - PIMS_ACCESS_REQUEST + - Added column REGION_CODE +- Added tables: + - PIMS_REGION_USER +- Requires additional metadata to meet standards + +PSP_PIMS S28.00 Sprint 28 2022-May-12 +- Seed data table changes: + - PIMS_REGION + - Added 4: Cannot determine + - PIMS_DISTRICT + - Added 12: Cannot determine +- Requires additional metadata to meet standards + +PSP_PIMS S27.00 Sprint 26 2022-Apr-25 +- Altered tables: + - PIMS_LEASE + - PIMS_LEASE_HIST + - PIMS_LEASE_TENANT + - PIMS_LEASE_TENANT_HIST + - PIMS_SECURITY_DEPOSIT_RETURN + - PIMS_SECURITY_DEPOSIT_RETURN_HIST + - PIMS_RESEARCH_FILE_PURPOSE + - PIMS_RESEARCH_FILE_PURPOSE_HIST +- Requires additional metadata to meet standards + +PSP_PIMS S26.00 Sprint 26 2022-Apr-13 +- Added tables + - PIMS_PROP_RESEARCH_PURPOSE_TYPE + - PIMS_PRF_PROP_RESEARCH_PURPOSE_TYPE + - PIMS_PPH_STATUS_TYPE +- Altered tables: + - PIMS_PROPERTY + - PIMS_PROPERTY_HIST + - PIMS_PROPERTY_RESEARCH_FILE + - PIMS_PROPERTY_RESEARCH_FILE_HIST +- Seed data table changes: + - PIMS_PROPERTY_CLASSIFICATION_TYPE + - Added 'UNKNOWN' + - PIMS_DATA_SOURCE_TYPE + - Added 'PMBC' +- Requires additional metadata to meet standards + +PSP_PIMS S25.01 Sprint 25 2022-Apr-04 +- Altered tables: + - PIMS_PROPERTY + - Set ADDRESS_ID to nullable +- Requires additional metadata to meet standards + +PSP_PIMS S25.00 Sprint 25 2022-Mar-31 +- Added tables + - PIMS_REQUEST_SOURCE_TYPE + - PIMS_RESEARCH_PURPOSE_TYPE + - PIMS_RESEARCH_FILE_PURPOSE + - PIMS_RESEARCH_FILE_PURPOSE_HIST +- Altered tables: + - PIMS_RESEARCH_FILE + - PIMS_PROPERTY_RESEARCH_FILE +- Requires additional metadata to meet standards + +PSP_PIMS S24.00 Sprint 24 2022-Mar-17 +- Added tables: + - PIMS_PROP_PROP_ADJACENT_LAND_TYPE + - PIMS_PROP_PROP_ANOMALY_TYPE + - PIMS_PROP_PROP_ROAD_TYPE + - PIMS_PROP_PROP_TENURE_TYPE + - PIMS_VOLUME_UNIT_TYPE + - PIMS_RESEARCH_FILE + - PIMS_RESEARCH_FILE_STATUS_TYPE + - PIMS_PROPERTY_RESEARCH_FILE +- Altered tables: + - PIMS_PROPERTY + - Set PROPERTY_AREA_UNIT_TYPE_CODE to nullable + - BCA_FOLIO_ADDRESS + - Add column ADDRESS_ID + - BCA*VALUE tables + - DESCRIPTION columns increased from 16 to 255 bytes +- Altered views: + - PIMS_CONTACT_MGR_VW + - Added the subquery to the PERSON portion of the view +- Requires additional metadata to meet standards + +PSP_PIMS S23.01 Sprint 23 2022-Mar-10 +- Added tables: + - BCA_AREA_AMENDMENT + - BCA_AREA_BCTRANSIT_VALUE + - BCA_AREA_DELETE + - BCA_AREA_GENERAL_VALUE + - BCA_AREA_SCHOOL_VALUE + - BCA_ASSESSMENT_AREA + - BCA_DATA_ADVICE + - BCA_DATA_ADVICE_AMENDMENT + - BCA_DATA_ADVICE_BCTRANSIT_VALUE + - BCA_DATA_ADVICE_DELETE + - BCA_DATA_ADVICE_GENERAL_VALUE + - BCA_DATA_ADVICE_SCHOOL_VALUE + - BCA_DEFINED + - BCA_ELECTORAL_AREA + - BCA_FOLIO_ADDRESS + - BCA_FOLIO_AMENDMENT + - BCA_FOLIO_BCTRANSIT_VALUE + - BCA_FOLIO_DESCRIPTION + - BCA_FOLIO_FARM + - BCA_FOLIO_GENERAL_VALUE + - BCA_FOLIO_LAND_CHARACTERISTIC + - BCA_FOLIO_LEGAL_DESCRIPTION + - BCA_FOLIO_MANAGED_FOREST + - BCA_FOLIO_MANUFACTURED_HOME + - BCA_FOLIO_OIL_AND_GAS + - BCA_FOLIO_RECORD + - BCA_FOLIO_SALES + - BCA_FOLIO_SCHOOL_VALUE + - BCA_FOLIO_VALUATION + - BCA_GENERAL_SERVICE + - BCA_IMPROVEMENT_DISTRICT + - BCA_ISLANDS_TRUST + - BCA_JURISDICTION + - BCA_JURISDICTION_AMENDMENT + - BCA_JURISDICTION_BCTRANSIT_VALUE + - BCA_JURISDICTION_DELETE + - BCA_JURISDICTION_GENERAL_VALUE + - BCA_JURISDICTION_SCHOOL_VALUE + - BCA_LOCAL_AREA + - BCA_MINOR_TAXING + - BCA_OWNER + - BCA_OWNERSHIP_GROUP + - BCA_SERVICE_AREA + - BCA_SPECIFIED_MUNICIPAL + - BCA_SPECIFIED_REGIONAL +- Requires additional metadata to meet standards + +PSP_PIMS S21.00 Sprint 21 2022-Feb-11 +- Altered tables: + - PIMS_SECURITY_DEPOSIT_HOLDER + - Add constraint to restrict security deposit holder to single person OR organization + - Add constraint to restrict holder as person OR organization (exclusively) + - PIMS_SECURITY_DEPOSIT_RETURN_HOLDER + - Add constraint to restrict security deposit holder to single person OR organization + - Add constraint to restrict holder as person OR organization (exclusively) + - PIMS_SECURITY_DEPOSIT_RETURN + - Delete PAYEE_NAME + - Delete PAYEE_ADDRESS + - Delete FK to PIMS_LEASE.LEASE_ID + - Delete FK to PIMS_SECURITY_DEPOSIT_TYPE + - PIMS_ORGANIZATION + - Alter ORGANIZATION_TYPE_CODE to nullable + - Alter ORG_IDENTIFIER_TYPE_CODE to nullable + - PIMS_PERSON + - Add USE_ORGANIZATION_ADDRESS +- Altered views: + - PIMS_PERSON_CONTACT_VW + - Top contact method for each contact method type returned is ordered by the following: + - PIMS_PERSON_CONTACT_VW (Descending order) + - DB_LAST_UPDATE_TIMESTAMP (Descending order) + - PIMS_CONTACT_MGR_VW + - Altered to show organization name and ID if a person has an associated organization. +- Modified seed script contents: + - PIMS_LEASE_STATUS_TYPE + - Set EXPIRED code type to disabled. + - Ensure DISCARD code is present and enabled. +- Requires additional metadata to meet standards + +PSP_PIMS S20.00 Sprint 20 2022-Jan-28 +- Added table: + - PIMS_STATIC_VARIABLE_HIST +- Altered table: + - PIMS_STATIC_VARIABLE +- Added view: + - PIMS_PERSON_CONTACT_VW +- Altered view: + - PIMS_CONTACT_MANAGER_VW +- Modified seed script contents + - 70_DML_PIMS_LEASE_PAYMENT_STATUS_TYPE.sql +- Requires additional metadata to meet standards + +PSP_PIMS S19.00 Sprint 19 2022-Jan-11 +- Added tables: + - PIMS_SECURITY_DEPOSIT_HOLDER + - PIMS_SECURITY_DEPOSIT_RETURN_HOLDER +- Altered tables: + - PIMS_LEASE + - PIMS_LEASE_TERM + - PIMS_LEASE_PAYMENT + - PIMS_SECURITY_DEPOSIT + - PIMS_SECURITY_DEPOSIT_RETURN +- Dropped tables: + - PIMS_LEASE_PAYMENT_FORECAST + - PIMS_LEASE_PAYMENT_PERIOD + - PIMS_SEC_DEP_HOLDER_TYPE +- Modified seed script contents + - 64_DML_PIMS_SECURITY_DEPOSIT_TYPE.sql + - 73_DML_PIMS_LEASE_STATUS_TYPE.sql + - 74_DML_PIMS_CLAIM.sql + - 75_DML_PIMS_ROLE_CLAIM.sql +- Requires additional metadata to meet standards + +PSP_PIMS S17.00 Sprint 17 2021-Dec-06 +- Altered tables: + - PIMS_LEASE + - Added ADDRESS_COMMENT + - PIMS_PERSON + - LEASE_CATEGORY_TYPE_CODE made nullable + - LEASE_RESPONSIBILITY_TYPE_CODE made nullable + - LEASE_PMT_FREQ_TYPE_CODE made nullable + - PIMS_PROPERTY + - PID made nullable + - PIN made nullable + - PIMS_INSURANCE + - Added IS_INSURANCE_IN_PLACE + - Dropped FK INSURER_ORG_ID + - Dropped FK INSURER_CONTACT_ID + - Dropped FK MOTI_RISK_MGMT_CONTACT_ID + - Dropped FK BCTFA_RISK_MGMT_CONTACT_ID + - Dropped FK INSURANCE_PAYEE_TYPE_CODE + - Dropped INSURED_VALUE + - Dropped START_DATE + - Dropped RISK ASSESSMENT_COMPLETED_DATE + - PIMS_LEASE_PAYMENT + - PAYMENT_AMOUNT_PST made nullable + - PIMS_LEASE_PAYMENT_FORECAST + - FORECAST_PAYMENT_PST made nullable + - PIMS_PROPERTY_IMPROVEMENT + - IMPROVEMENT_DESCRIPTION made nullable + - ADDRESS renamed to UNIT +- Dropped tables: + - PIMS_INSURANCE_PAYEE_TYPE +- Requires additional metadata to meet standards + +PSP_PIMS S16.01 Sprint 16 2021-Dec-03 +- Added tables: + - PIMS_TENANT +- Added seed data tables: + - 51_DML_PIMS_ROLE.sql + - 73_DML_PIMS_LEASE_STATUS_TYPE.sql + - 74_DML_PIMS_CLAIM.sql + - 75_DML_PIMS_ROLE_CLAIM.sql + - 76_DML_PIMS_ORGANIZATION.sql + - 77_DML_PIMS_TENANT.sql +- Requires additional metadata to meet standards + +PSP_PIMS S16.00 Sprint 16 2021-Nov-23 +- ETL schema objects are now removed from the PSP build scripts. ETL entities will be managed by a separate script. +- Added views: + - PIMS_CONTACT_MGR_VW +- Added tables: + - PIMS_LEASE_STATUS_TYPE +- Altered tables: + - PIMS_LEASE (PIMS_PROPERTY_IMPROVEMENT now directly referenced from PIMS_LEASE) + - Added column PIMS_PROPERTY_LEASE.AREA_UNIT_TYPE_CODE (FK) + - Added column PIMS_PROPERTY_LEASE.LEASE_AREA + - Added column PIMS_ADDRESS.OTHER_COUNTRY + - Added column PIMS_ORGANIZATION.INCORPORATION_NUMBER + - Added column PIMS_LEASE.LEASE_PURPOSE_OTHER_DESC + - Added column PIMS_LEASE.DOCUMENTATION_REFERENCE + - Added column PIMS_LEASE.OTHER_LEASE_PURPOSE_TYPE + - Added column PIMS_LEASE.LEASE_STATUS_TYPE_CODE + - Moved column PIMS_SECURITY_DEPOSIT_RETURN.TERMINATION_NOTE to PIMS_LEASE.RETURN_NOTES + - Dropped column PIMS_LEASE.IS_ORIG_EXPIRY_REQUIRED + - Dropped column PIMS_LEASE.INCLUDED_RENEWALS + - Dropped column PIMS_LEASE.RENEWAL_COUNT + - Dropped column PIMS_LEASE.RENEWAL_TERM_MONTHS + - Altered column PIMS_LEASE.LEASE_DESCRIPTION to NVARCHAR(max) + - Altered column PIMS_LEASE.LEASE_NOTES to NVARCHAR(max) + - Altered column PIMS_LEASE.RETURN_NOTES To NVARCHAR(max) + - Altered column PIMS_LEASE.INSPECTION_NOTES To NVARCHAR(max) + - Added sequence etl.ETL_DATA_SOURCE_TRACE_ID_SEQ +- Requires additional metadata to meet standards + +PSP_PIMS S15.00 Sprint 15 2021-Nov-12 +- Added tables: + - PIMS_ORGANIZATION_ADDRESS + - PIMS_PERSON_ADDRESS + - ETL_OPERATIONAL_SS_LOAD +- Altered tables: + - PIMS_ADDRESS +- Altered views to exclude properties with null geometry values: + - PIMS_PROPERTY_BOUNDARY_VW + - PIMS_PROPERTY_LOCATION_VW +- Added seed data tables: + - 72_DML_PIMS_INSURANCE_TYPE.sql +- Requires additional metadata to meet standards + +PSP_PIMS S13.00 Sprint 13 2021-Oct-22 +- Altered tables: + - ETL_CONTACT_METHOD_LOG + - ETL_INTEREST_HOLDER_PERSON_ORG_LOG + - PIMS_ADDRESS + - PIMS_ADDRESS_HIST + - PIMS_LEASE_TENANT + - PIMS_LEASE_TENANT_HIST + - PIMS_PROPERTY_IMPROVEMENT + - PIMS_PROPERTY_IMPROVEMENT_HIST + - PIMS_LEASE + - PIMS_LEASE_HIST + - PIMS_PROJECT + - PIMS_PERSON + - PIMS_PERSON_HIST + - PIMS_ORGANIZATION + - PIMS_ORGANIZATION_HIST +- Added tables: + - ETL_ERROR_LOG + - ETL_PROPERTY_ERROR_LOG + - PMBC_PARCEL_POLYGON_FABRIC + - PIMS_LEASE_PAYMENT_PERIOD + - PIMS_LEASE_PAYMENT_PERIOD_HIST + - PIMS_LEASE_TERM + - PIMS_LEASE_TERM_HIST + - PIMS_STATIC_VARIABLE + - PIMS_LEASE_INITIATOR_TYPE + - PIMS_LEASE_RESPONSIBILITY_TYPE + - PIMS_LEASE_PAYMENT_METHOD_TYPE + - PIMS_LEASE_PAYMENT_STATUS_TYPE + - PIMS_LEASE_TERM_STATUS_TYPE + - PIMS_LEASE_PAYMENT_FORECAST + - PIMS_LEASE_PAYMENT_FORECAST_HIST + - PIMS_LEASE_PAYMENT + - PIMS_LEASE_PAYMENT_HIST +- Dropped tables: + - PIMS_PROPERTY_IMPROVEMENT_UOM_TYPE +- Added seed data tables: + - 67_DML_PIMS_LEASE_INITIATOR_TYPE.sql + - 68_DML_PIMS_LEASE_RESPONSIBILITY_TYPE.sql + - 69_DML_PIMS_LEASE_TERM_STATUS_TYPE.sql + - 69_DML_PIMS_STATIC_VARIABLE.sql + - 70_DML_PIMS_LEASE_PAYMENT_STATUS_TYPE.sql + - 71_DML_PIMS_LEASE_PAYMENT_METHOD_TYPE.sql +- Dropped seed data tables: + - 63_DML_PIMS_PROPERTY_IMPROVEMENT_UOM_TYPE.sql +- Requires additional metadata to meet standards + +PSP_PIMS S11.01 Sprint 12 2021-Oct-05 +- Added tables: + - ETL_INTEREST_HOLDER_PERSON_ORG_LOG +- Added 66_DML_PIMS_LESSOR_TYPE.sql to populate the PIMS_LESSOR_TYPE table +- Requires additional metadata to meet standards + +PSP_PIMS S11.00 Sprint 11 2021-Sep-29 +- Dropped tables: + - PIMS_LEASE_SUBTYPE + - PIMS_LEASE_ACTIVITY_HIST + - PIMS_LEASE_ACTIVITY_PERIOD_HIST + - PIMS_LEASE_ACTIVITY_PERIOD + - PIMS_EXPECTED_AMOUNT_HIST + - PIMS_LEASE_STATUS_TYPE + - PIMS_EXPECTED_AMOUNT + - PIMS_LEASE_ACTIVITY + - PIMS_LEASE_TYPE + - PIMS_LEASE_PURPOSE_SUBTYPE +- Altered tables: + - PIMS_CLAIM + - PIMS_TASK_TEMPLATE + - PIMS_LEASE_PROGRAM_TYPE + - PIMS_ROLE + - PIMS_USER + - PIMS_PROPERTY_HIST + - PIMS_LEASE + - PIMS_LEASE_HIST + - PIMS_LEASE_PURPOSE_TYPE + - PIMS_PROPERTY + - PIMS_TASK_TEMPLATE_TYPE + - PIMS_TASK_TEMPLATE_HIST + - PIMS_LEASE_PMT_FREQ_TYPE +- Added tables: + - PIMS_PROPERTY_TAX_REMIT_TYPE + - PIMS_PROPERTY_TAX + - PIMS_PROPERTY_IMPROVEMENT + - PIMS_INSURANCE_PAYEE_TYPE + - PIMS_SECURITY_DEPOSIT_TYPE + - PIMS_SECURITY_DEPOSIT_HIST + - PIMS_INSURANCE + - PIMS_LEASE_LICENSE_TYPE + - PIMS_LEASE_TENANT + - PIMS_LEASE_TENANT_HIST + - PIMS_INSURANCE_HIST + - PIMS_SECURITY_DEPOSIT_RETURN_HIST + - PIMS_INSURANCE_TYPE + - PIMS_SECURITY_DEPOSIT + - PIMS_PROPERTY_IMPROVEMENT_HIST + - PIMS_PROPERTY_IMPROVEMENT_TYPE + - PIMS_LEASE_PAY_RVBL_TYPE + - PIMS_PROPERTY_IMPROVEMENT_UOM_TYPE + - PIMS_SURPLUS_DECLARATION_TYPE + - PIMS_LEASE_CATEGORY_TYPE + - PIMS_LESSOR_TYPE + - PIMS_SECURITY_DEPOSIT_RETURN + - PIMS_SEC_DEP_HOLDER_TYPE + - PIMS_PROPERTY_TAX_HIST +- Added DML Files + - 53_DML_PIMS_LEASE_PAY_RVBL_TYPE.sql + - 54_DML_PIMS_LEASE_LICENSE_TYPE.sql + - 55_DML_PIMS_LEASE_CATEGORY_TYPE.sql + - 56_DML_PIMS_LEASE_PURPOSE_TYPE.sql + - 57_DML_PIMS_LEASE_PROGRAM_TYPE.sql + - 58_DML_PIMS_LEASE_PMT_FREQ_TYPE.sql + - 59_DML_PIMS_PROPERTY_TAX_REMIT_TYPE.sql + - 60_DML_PIMS_INSURANCE_PAYEE_TYPE.sql + - 61_DML_PIMS_SURPLUS_DECLARATION_TYPE.sql + - 62_DML_PIMS_PROPERTY_IMPROVEMENT_TYPE.sql + - 63_DML_PIMS_PROPERTY_IMPROVEMENT_UOM_TYPE.sql + - 64_DML_PIMS_SECURITY_DEPOSIT_TYPE.sql + - 65_DML_PIMS_SEC_DEP_HOLDER_TYPE.sql +- Deleted DML Files + - 53_DML_PIMS_LEASE_PMT_FREQ_TYPE.sql + - 54_DML_PIMS_LEASE_PURPOSE_TYPE.sql + - 55_DML_PIMS_LEASE_PURPOSE_SUBTYPE.sql + - 56_DML_PIMS_LEASE_STATUS_TYPE.sql + - 57_DML_PIMS_LEASE_TYPE.sql + - 58_DML_PIMS_LEASE_SUBTYPE.sql + - 59_DML_PIMS_LEASE_PROGRAM_TYPE.sql +- Requires additional metadata to meet standards + +PSP_PIMS S10.02 Sprint 10 2021-Sep-22 +- Changed '//' comments in all scripts to '--' +- Requires additional metadata to meet standards + +PSP_PIMS S10.01 Sprint 10 2021-Sep-17 +- Moved test data insertion SQL to "Test Data" folder +- Requires additional metadata to meet standards + +PSP_PIMS S10.00 Sprint 10 2021-Sep-02 +- Added tables: + - PIMS_LEASE + - PIMS_LEASE_ACTIVITIES + - PIMS_LEASE_ACTIVITY_PERIOD + - PIMS_LEASE_PMT_FREQ_TYPE + - PIMS_LEASE_PURPOSE_SUBTYPE + - PIMS_LEASE_PURPOSE_TYPE + - PIMS_LEASE_STATUS_TYPE + - PIMS_LEASE_SUBTYPE + - PIMS_LEASE_TYPE + - PIMS_EXPECTED_AMOUNT + - PIMS_PROPERTY_LEASE + - PIMS_LEASE_PROGRAM_TYPE +- Requires additional metadata to meet standards + +PSP_PIMS S09.01 Sprint 9 2021-Sep-01 +- Added views: + - PIMS_PROPERTY_BOUNDARY_VW + - PIMS_PROPERTY_LOCATION_VW +- Requires additional metadata to meet standards + +PSP_PIMS S09.00 Sprint 9 2021-Aug-19 +- Altered PIMS_PROPERTY + - BOUNDARY altered from GEOGRAPHY to GEOMETRY + - LOCATION altered from GEOGRAPHY to GEOMETRY + - LOCATION altered from NOT NULL to NULL +- Altered PIMS_ACCESS_REQUEST + - Added NOTE column +- Altered PIMS_USER + - Added POSITION column + - Added NOTE column + - Added LAST_LOGIN column +- Added 52_DML_PIMS_PROPERTY_STATUS_TYPE build script +- Requires additional metadata to meet standards + +PSP_PIMS S08.01 Sprint 8 2021-Aug-17 +- Added PIMSX_TableDefinitions table +- Added generated triggers +- Added generated history tables +- Requires additional metadata to meet standards + +PSP_PIMS S08.00 Sprint 8 2021-Aug-17 +- Altered PIMS_ADDRESS + - Column MUNICIPALITY_NAME length increased from 20 to 200 bytes + _ Partial metadata addedd to the following tables: + - PIMS_AREA_UNIT_TYPE + - PIMS_PROPERTY_TENURE_TYPE +- Requires additional metadata to meet standards +- Triggers remain to be generated +- History tables remain to be generated + +PSP_PIMS S07.00 Sprint 7 2021-Aug-04 +- Added numerous indices to enforce uniqueness and support foreign keys +- Altered PIMS_ADDRESS + - Column STREET_ADDRESS renamed to STREET_ADDRESS_1 + - Column UNIT_NUMBER renamed to STREET_ADDRESS_2 + - Column STREET_ADDRESS_3 added +- Altered PIMS_PROPERTY + - Column PROPERTY_STATUS_TYPE_CODE added + - Column PROPERTY_DATA_SOURCE_TYPE_CODE added + - Column PROPERTY_DATA_SOURCE_EFFECTIVE_DATE added + - Column IS_PROPERTY_OF_INTEREST added +- Altered PIMS_ORGANIZATION + - Column ORG_IDENTIFIER_TYPE_CODE added + - Column ORGANIZATION_IDENTIFIER added +- Added the following tables + - __EFMigrationsHistory + - PIMS_PROPERTY_DATA_SOURCE_TYPE + - PIMS_PROPERTY_STATUS_TYPE + - PIMS_ORG_IDENTIFIER_TYPE + - PIMS_PROPERTY_EVALUATION +- Requires additional metadata to meet standards +- Triggers remain to be generated +- History tables remain to be generated + +PSP_PIMS V02.01 Sprint 6 2021-Jul-21 +- Model was refactored to meet MoTI business requirements. + - Model now conforms to the PSP Conceptual Data Model +- Triggers remain to be generated +- History tables remain to be generated +- Added the following tables: + - PIMS_PROPERTY_ORGANIZATION + - PIMS_AREA_UNIT_TYPE + - PIMS_PROPERTY_TENURE_TYPE +- Altered the following tables: + - PIMS_REGION + - REGION_CODE now SMALLINT + - PIMS_DISTRICT + - DISTRICT_CODE now SMALLINT + - REGION_CODE now SMALLINT + - PIMS_ADDRESS + - DISTRICT_CODE now SMALLINT + - REGION_CODE now SMALLINT + - PROVINCE_STATE_ID now SMALLINT + - COUNTRY_ID now SMALLINT + - PIMS_COUNTRY + - COUNTRY_ID now SMALLINT + - PIMS_PROVINCE_STATE + - PROVINCE_STATE_ID now SMALLINT + - COUNTRY_ID now SMALLINT + - PIMS_ORGANIZATION + - DISTRICT_CODE now SMALLINT + - REGION_CODE now SMALLINT + - PIMS_PROPERTY + - DISTRICT_CODE now SMALLINT + - REGION_CODE now SMALLINT + - PIMS_PROJECT_STATUS_TYPE + - Added column CODE_GROUP + - Added column TEXT + - Added column IS_MILESTONE + - Added column IS_TERMINAL +- Requires additional metadata to meet standards + +PSP_PIMS V01.00 (Pre-Release) Sprint 4 2021-Jun-15 +- Initial release +- Compliant with MoTI standards +- Requires additional metadata to meet standards + +PSP_PIMS 0.1 (Pre-Release) Sprint F 2021-Apr-08 +- Initial release +- Requires additional metadata to meet standards diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/03_DML_LEASE_TESTING.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/03_DML_LEASE_TESTING.sql new file mode 100644 index 0000000000..f371968867 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/03_DML_LEASE_TESTING.sql @@ -0,0 +1,72 @@ +/* ----------------------------------------------------------------------------- +Insert lease data for testing +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-19 Initial version +----------------------------------------------------------------------------- */ + +-- Insert addresses +INSERT INTO PIMS_ADDRESS (STREET_ADDRESS_1, STREET_ADDRESS_2, STREET_ADDRESS_3, MUNICIPALITY_NAME, POSTAL_CODE, PROVINCE_STATE_ID, COUNTRY_ID, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + (N'45 - 904 Hollywood Crescent', N'Living in a van', N'Down by the River', N'Hollywood North', N'M4T F0L', 1, 1, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (N'PO Box 2', N'Stealth Camping', N'Walmart Parking Lot', N'South Podunk', N'H1I B0B', 1, 1, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (N'123 Main Street', N'PO Box 123', N'Next to the Dairy Queen', N'East Podunk', N'I4M B0B', 1, 1, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (N'456 Souris Street', N'PO Box 250', N'A Hoot and a holler from the A&W', N'North Podunk', N'IH8 B0B', 1, 1, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'); + +-- Insert organizations +INSERT INTO PIMS_ORGANIZATION (ORGANIZATION_IDENTIFIER, ORGANIZATION_NAME, ORGANIZATION_TYPE_CODE, ORG_IDENTIFIER_TYPE_CODE, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + (N'LILMOUSE', N'French Mouse Property Management', N'REALTOR', N'OTHINCORPNO', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + (N'DQ4EVA', N'Dairy Queen Forever! Property Management', N'REALTOR', N'OTHINCORPNO', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + (N'DAKATZ', N'Pussycat Property Management', N'REALTOR', N'OTHINCORPNO', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + (N'BOB123', N'Bob''s Property Management', N'REALTOR', N'OTHINCORPNO', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'); + +-- Insert organization addresses +INSERT INTO PIMS_ORGANIZATION_ADDRESS(ADDRESS_ID, ORGANIZATION_ID, ADDRESS_USAGE_TYPE_CODE, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + ((SELECT ADDRESS_ID FROM PIMS_ADDRESS WHERE STREET_ADDRESS_1 LIKE '%Hollywood%'), (SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER LIKE '%LILMOUSE%'), 'MAILADDR', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ADDRESS_ID FROM PIMS_ADDRESS WHERE STREET_ADDRESS_1 LIKE 'PO Box%'), (SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER LIKE 'DQ4EVA%'),'MAILADDR', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ADDRESS_ID FROM PIMS_ADDRESS WHERE STREET_ADDRESS_1 LIKE '123 Main%'), (SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER LIKE 'DAKATZ%'),'MAILADDR', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ADDRESS_ID FROM PIMS_ADDRESS WHERE STREET_ADDRESS_1 LIKE '%Souris%'), (SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER LIKE 'BOB123%'),'MAILADDR', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'); + +-- Insert people +INSERT INTO PIMS_PERSON (SURNAME, FIRST_NAME, MIDDLE_NAMES, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + (N'Smith', N'Bob', N'Billy', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + (N'Wilson', N'Volley', N'Ball', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + (N'Cheese', N'Stinky', N'', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + (N'Mouse', N'Minnie', N'Nacho Cheese', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'); + +--Insert person addresses +INSERT INTO PIMS_PERSON_ADDRESS(ADDRESS_ID, PERSON_ID, ADDRESS_USAGE_TYPE_CODE, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + ((SELECT ADDRESS_ID FROM PIMS_ADDRESS WHERE STREET_ADDRESS_1 LIKE '%Hollywood%'), (SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME LIKE '%Smith%'), 'MAILADDR', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ADDRESS_ID FROM PIMS_ADDRESS WHERE STREET_ADDRESS_1 LIKE 'PO Box%'), (SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME LIKE 'Wilson%'), 'MAILADDR', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ADDRESS_ID FROM PIMS_ADDRESS WHERE STREET_ADDRESS_1 LIKE '123 Main%'), (SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME LIKE 'Cheese%'), 'MAILADDR', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ADDRESS_ID FROM PIMS_ADDRESS WHERE STREET_ADDRESS_1 LIKE '%Souris%'), (SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME LIKE 'Mouse%'), 'MAILADDR', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'); + + +-- Insert contact information for people +INSERT INTO PIMS_CONTACT_METHOD (PERSON_ID, CONTACT_METHOD_TYPE_CODE, CONTACT_METHOD_VALUE, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + ((SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Smith'), N'PERSPHONE', N'6049934251', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Wilson'), N'PERSPHONE', N'2509977251', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Cheese'), N'PERSPHONE', N'6049983251', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Mouse'), N'PERSPHONE', N'7785761234', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'); + +-- Insert contact information for organizations +INSERT INTO PIMS_CONTACT_METHOD (ORGANIZATION_ID, CONTACT_METHOD_TYPE_CODE, CONTACT_METHOD_VALUE, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + ((SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER = 'BOB123'), N'WORKPHONE', N'6049934251', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER = 'DAKATZ'), N'WORKPHONE', N'2509977251', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER = 'DQ4EVA'), N'WORKPHONE', N'6049983251', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER = 'LILMOUSE'), N'WORKPHONE', N'7785761234', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'); + +-- Associate person with organization +INSERT INTO PIMS_PERSON_ORGANIZATION (PERSON_ID, ORGANIZATION_ID, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + ((SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Smith'), (SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER = 'BOB123'), CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Wilson'), (SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER = 'DAKATZ'), CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Cheese'), (SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER = 'DQ4EVA'), CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'), + ((SELECT PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Mouse'), (SELECT ORGANIZATION_ID FROM PIMS_ORGANIZATION WHERE ORGANIZATION_IDENTIFIER = 'LILMOUSE'), CURRENT_TIMESTAMP, N'Lease Seed Data', N'Leasse Seed Data', CURRENT_TIMESTAMP, N'Leasse Seed Data', N'Leasse Seed Data'); diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/04_DML_LEASE_LOAD.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/04_DML_LEASE_LOAD.sql new file mode 100644 index 0000000000..2e2cb63d82 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/04_DML_LEASE_LOAD.sql @@ -0,0 +1,196 @@ +/* -----------------------------------------------------------------------------'LSREG', 'COMM' +Insert leases for testing +. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . +Author Date Comment +------------ ----------- ----------------------------------------------------- +Doug Filteau 2021-Aug-19 Initial version +----------------------------------------------------------------------------- */ + +-- Insert the lease data + +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',390, NULL, NULL, NULL, '', '', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',390, NULL, NULL, NULL, NULL, NULL, NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',418, '7129', '20060401 00:00:00.0', 0.00, '', 'SEE SUB FILE 000', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',503, NULL, NULL, 1.00, '', 'Lease Rental Payment Due Date: 01/10/2001', NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',390, NULL, '20230201 00:00:00.0', NULL, '', 'TFA to approve access plans and specifications. +Access for 1 residential site only +CRD Parks Use Permit required. +Assignment from Tchvdjian in February 2005', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',277, '1684B', NULL, 1200.00, '', 'Extension put in place August 2005 therefore increase in rent retroactive. + +April 2006, Creditor Waiver in place - Notify creditor when license is terminated or in default.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',495, '9447', '20020330 00:00:00.0', 1.00, '', 'Lease Rental Payment Due Date: 01/04/2002Tenant contact- Paul Usher (604) 592-0029', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',183, NULL, '20030401 00:00:00.0', 1800.00, '', 'Notice Given as of July 31, 2005 - vacant possession November 30/05. Design will try to provide alternate site for sign. Property vacant lease expired Finning International no longer leases the property. ', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1312, '101043', '20130901 00:00:00.0', 750.00, ' ', ' LUMP SUM PAYMENT RECEIVED of $1500 +$75 for GST). FOR THE TERM SEPT/13 TO AUG 31/2023.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1083, '103101', '20130718 00:00:00.0', NULL, '', 'lICENCE REQUIRED TO ENTER UPON THE PROPERTY FOR THE PURPOSE OF A LICENCED PATIO.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1368, '60234', NULL, NULL, '', 'ANNUAL PAYMENT BROKEN DOWN AS FOLLOWS: ALP $350.00 + 24.50 GST = 374.50', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',504, NULL, NULL, NULL, '', 'MSA vacated site March 31, 2006. GCL is the road construction firm contracted by the City of Abbotsford to construct the Mt Lehman I/C Project. The Ministry and the City share project costs (60/40 respectively) therefore assessing a rental fee is not cost effective. +I have authorized MSA, the former occupier, to return to the site after GCL completes their occupancy requirements to salvage and remove select fixtures. +There is no insurance on the buildings because the buildings are slated for demolition +I will be updating Martin Mosley (Urban Systems) so that he can proceed with his site servicing plan. +Phil and Jim Switzer are aware of the interim occupancy agreement to ensure this does not interfere with property development. +Site inspection photos are posted in LIS 504', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',222, '40769-12 S1791', NULL, NULL, '', 'Issued for $500 one-time payment in 1983.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1312, '701749', '20080918 00:00:00.0', NULL, '', 'R/W LICENSED FOR SPORT FIELD/SCHOOL GROUND FOR THE ADJACENT PROPERTY OWNED BY SCHOOL DISTRICT NO. 27. ', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1296, '60229', '20121101 00:00:00.0', NULL, '', 'PAYMENT AMOUNT $356.68+ 5% GST $17.83= $374.51 RECEIVED. ', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',544, 'PS100008', '20051201 00:00:00.0', 1860.00, ' ', 'A portion (143.4 sqm) of the Wheaton leased property was required by the City of Coquitlam for widening of King Edward Street at Woolridge Street, xref 544-001. +Lease terminated Jun 1, 2007 +Craig to ammend lease and negotiate a let down for curb access on Woolridge Street.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',599, NULL, NULL, NULL, '', 'Permit No. 01-003-22940, issued by Courtenay Area Office.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1368, '25432 (L2)', '20120501 00:00:00.0', NULL, '', 'THAT PART OF ROAD ALLOWANCE LYING SOUTH EAST OF LOT 3 PLAN 7835; COMPRISED OF .83 ACRES +/-. ALP $1,400 INCLUDES TAX IMPOSED. YEAR 2010/11 INCLUDES PART GST AND HST. FOLLOWING YEARS HST ONLY.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1312, NULL, NULL, NULL, '', '', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',390, '6730', NULL, NULL, '', 'Security Deposit, $10,000', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1315, NULL, NULL, NULL, '', 'MONTHLY LEASE PAYMENT $2,500., FOR PAYMENTS RECEIVED APR 1, 2005 TO AUG 1, 2007 SEE SUB FILE 1315-000 EXPIRED LEASE.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1368, '60234', '20111101 00:00:00.0', NULL, '', 'Annual Licence Payment $356.67 + (5% GST) 17.83 = $374.50. Licence renewed payment $374.50 + 12% HST = $419.44.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',662, NULL, NULL, NULL, '', 'Blanket sewer Statutory Right of Way provided for 156th Street/Hwy 1 Underpass project.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',521, NULL, NULL, NULL, '', 'xref: 521-002 +Transportation Investment Corporation (TI Corp) grants permission to KFGP for stockpiling purposes. Contact John Peebles, (DR Coles), 250-882-9003 or Gary Webster, TIC representative for information regarding use, terms, and extension. ', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',521, NULL, NULL, NULL, '', 'xref: 521-001 +Transportation Investment Corporation (TI Corp) grants permission to KFGP for stockpiling purposes. Contact John Peebles, (DR Coles), 250-882-9003 or Gary Webster, TIC representative for information regarding use, terms, and extension. ', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1312, '701571', NULL, NULL, '', 'See Assignment and Assumption Agreement on file. See Licence File No. 701571(A).', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',390, NULL, NULL, NULL, '', 'BC Hydro distribution line to serve Tom White, 2753 Sooke River Road, Section 49, ', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1192, NULL, NULL, NULL, '', 'FEE: $1,500. plus 12% HST for the Term.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',529, '13191', NULL, NULL, '', 'For tourism info center', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1312, '701298', NULL, NULL, '', 'LUMP SUM PAYMENT $1,500. PLUS 5% GST. 10YR LICENCE. ', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',498, NULL, NULL, NULL, NULL, NULL, NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM','BCFERRIES','RCVBL',446, NULL, NULL, 0.00, '', '', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',390, NULL, NULL, 0.00, '', 'CRD water main located here under license. Expires 3001', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',390, '6730', NULL, NULL, '', 'CRD sublease to Metchosin Farmers Institute', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',90, NULL, NULL, 0.00, '', '', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',90, NULL, '20020601 00:00:00.0', 150.00, '', 'Lease Rental Payment Due Date: 01/09/2002', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',446, NULL, NULL, 0.00, '', 'CSRD phoned on Aug 16, 2008 (Beth Rees) to indicate that they are interested in maintaining this area for public use and will be in contact with us near the expiry of the lease in April, 2008.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',503, NULL, NULL, 1.00, '', 'Lease Rental Payment Due Date: 01/10/2001', NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL', 126, NULL, NULL, 500.00, '', 'NOTE +May 12, 2005 - Glenn Callander in consultation with Border Infrastructure Program recommend 5 year term with 1 year early termination clause. + +DATE: MAY 9 2004 SEE BELOW +R/W TO CITY OF ABBOTSFORD FOR SAN SEWER. OVER PORTION OF 1661 SUMAS WAY. NEW LICENCE AGREEMENT BETWEEN BCTFA AND CITY OF ABBOTSFORD; COMMENCING AUG 1, 2006. FULL PAYMENT RECEIVED FOR THE TWO YEAR TERM. 2 X $500. +Invoice 95.019 July 3, 2014-$525.00 received for Aug 2014- July 2015 rent from City of Abbotsford', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',399, NULL, NULL, 0.00, '', 'Lease Rental Payment Due Date: 02/11/2001. New Licence Agreement dated Oct 4th, 2004. For Consideration see Sub File 002.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',286, NULL, NULL, 0.00, '', ' LEASE AMOUNT $125 - SEE SUB FILE 286-000', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',230, NULL, NULL, 150.00, '', 'Lease Rental Payment Due Date: 01/08/2002', NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',504, NULL, NULL, 1.00, '', 'Extended to June 28/05 +Extended to March 31/06. CHEQUE IN THE AMOUNT OF $2945. 67 RECEIVED JULY 13, 2006 FOR THEIR PORTION OF THE 2006 PROPERTY TAXES RE: 3 MONTHS.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',185, NULL, '20060404 00:00:00.0', 730.00, '', 'Lease Rental Payment Due Date: 01/03/2001', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1312, '26859', NULL, NULL, '', 'ANNUAL AMOUNT $5,000. + GST 6% $300. = $5,300.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',399, NULL, NULL, 0.00, '', 'Lease Rental Payment Due Date: 02/11/2001. New Licence Agreement dated Oct 4th, 2004. For Consideration see Sub File 002.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',399, NULL, '20131101 00:00:00.0', 0.00, '', 'Lease Rental Payment Due Date: 02/11/200. New Licence Agreement dated Oct 4th, 2004. For Consideration see Sub File 002. LICENCE RENEWAL COMMENCING NOV 1, 2007 $150. ANNUALLY. Licence Renewed Nov.2013 -2017 $154 +GST annually.', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',223, '40769-08 ', '20070601 00:00:00.0', 2550.00, ' ', ' 4.25 ACRES', NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',223, '40769-04 S03503 ', '20060701 00:00:00.0', 2150.00, ' ', '84-18-W6M SW 14', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',223, '40769-05 S03334 ', '20030331 00:00:00.0', 3600.00, ' ', ' 084-18-W6M S13, S14', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',223, '40769-06 S03138 ', '20040320 00:00:00.0', 3500.00, ' ', ' 12.30 ACRES for wellsite & access road. Lease also includes part of LIS 1421under LTO document #X35801', '$3,500', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',223, '40769-07 S03618 ', '20090331 00:00:00.0', 400.00, ' ', ' 25 YRS 7.8 ACRES', NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',223, '40769-08 S01176 ', '20101201 00:00:00.0', 2850.00, ' ', ' ', NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',223, '40769-09 S03151 ', '20220731 00:00:00.0', 2480.00, ' ', ' 5/17 ACRES - 84-18-W6M S13', NULL, CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO +INSERT INTO [dbo].[PIMS_LEASE]([LEASE_STATUS_TYPE_CODE], [LEASE_PURPOSE_TYPE_CODE], [ORIG_START_DATE], [MOTI_CONTACT], [LEASE_RESPONSIBILITY_TYPE_CODE], [LEASE_INITIATOR_TYPE_CODE], [LEASE_LICENSE_TYPE_CODE], [LEASE_CATEGORY_TYPE_CODE], [LEASE_PROGRAM_TYPE_CODE], [LEASE_PAY_RVBL_TYPE_CODE], [TFA_FILE_NO], [PS_FILE_NO], [ORIG_EXPIRY_DATE], [LEASE_AMOUNT], [INSPECTION_DATE], [INSPECTION_NOTES], [LEASE_NOTES], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES('ACTIVE', 'other','20060930 00:00:00.0',1, 'HQ', 'HQ', 'LSREG', 'COMM', 'BCFERRIES','RCVBL',1312, NULL, '20090115 00:00:00.0', NULL, '', 'April 2012 licence payment $374.50 plus 12% HST. +Cheque received March 17, 2014 in the amount of $812.67 represeting rent for the term January 15, 2013 to January 14, 2015', '', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data', CURRENT_TIMESTAMP, N'Lease Seed Data', N'Lease Seed Data') +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/05_DML_LEASE_PROPERTY.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/05_DML_LEASE_PROPERTY.sql new file mode 100644 index 0000000000..ed2a219980 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/05_DML_LEASE_PROPERTY.sql @@ -0,0 +1,882 @@ +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7723385, 90069930, 1, NULL, 0xBD0B00000104090000000AF241CF02332C41D8CEF773539D30418A1F63EEFB322C4148AA60F4509D30410CF2414FFF322C4130189594A69D3041A1CDAACFFF322C41082AA973B19D3041FA3A704E11332C4198051294A59D3041E0718A4E5A332C41E0CEF773749D304113F241CF46332C41F0D781136D9D3041961F63AE0F332C41A433A254589D30410AF241CF02332C41D8CEF773539D304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C790AB1A91C332C416CCBFCE97C9D3041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.333' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.333' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'UNKNOWN', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11041404, 90072652, 1, NULL, 0xBD0B000001040E000000E23D79582D642941E885C9541C3C3041A1CDAA4FD7632941BC9DEF47243C3041E2718A0EAD6329413C1AC0FB293C3041C27493D865642941A0F1D20D233C3041B4EC9E3C646429410C68226C183C3041E23D79582D642941E885C9541C3C30414ABF7D1DBD63294130E4831E1C3C3041ECC03923D763294198EFA7261E3C3041520C026B2B64294154BF7D5D163C3041B830996A63642941CC12F261123C3041A045B63362642941044D848D043C3041EA73B5D5A4632941841D38A70B3C30411E97FF90A96329410CAC1CBA153C30414ABF7D1DBD63294130E4831E1C3C3041020000000200000000020600000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010C5F7AEC1E0B642941496C9B54153C3041, NULL, N'Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia curae; Vestibulum tempus iaculis ex eget semper. Etiam eget sollicitudin mauris. Mauris nec ligula eu massa faucibus ullamcorper in a dui. Donec ut arcu lacinia libero vehicula convallis vel tempus orci. Integer erat turpis, rhoncus et auctor rhoncus, blandit at elit. In elit lectus, finibus non interdum ut, sodales nec leo. In orci odio, finibus in mi et, rhoncus blandit ligula.', CAST(N'2022-03-04T13:10:39.860' AS DateTime), 0, 0, 0, 0, NULL, NULL, 4, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.370' AS DateTime), N'dbo', CAST(N'2022-03-04T21:10:39.860' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'NO', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083736, 14745541, 1, NULL, 0xBD0B00000104050000009B89B0A19B6E2B41D43B4EF18F64314101098A9F876E2B41806ABC149064314109F2418F886E2B41B468008FB4643141D476BE9F9C6E2B41589FAB6DB46431419B89B0A19B6E2B41D43B4EF18F64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9C1F371C926E2B416119D842A2643141, NULL, N'Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia curae; Vestibulum tempus iaculis ex eget semper. Etiam eget sollicitudin mauris. Mauris nec ligula eu massa faucibus ullamcorper in a dui. Donec ut arcu lacinia libero vehicula convallis vel tempus orci. Integer erat turpis, rhoncus et auctor rhoncus, blandit at elit. In elit lectus, finibus non interdum ut, sodales nec leo. In orci odio, finibus in mi et, rhoncus blandit ligula.', CAST(N'2022-03-04T13:10:39.890' AS DateTime), 0, 0, 0, 0, NULL, NULL, 4, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.380' AS DateTime), N'dbo', CAST(N'2022-03-04T21:10:39.890' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4082664, NULL, 1, NULL, 0xBD0B0000010405000000AFB662DF59CC334130CD3B4EE9971C4150840DEF32CD3341C0D32BE51C981C41E8D9ACDACCCC33414054522745971C41A145B6935ECC334180923A0181961C41AFB662DF59CC334130CD3B4EE9971C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C300D1E8DA5CC3341BD2ED2E47F971C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.407' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.407' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15937437, NULL, 1, NULL, 0xBD0B00000104050000000CAC1CDA128332419889B061994A2E4160984C1513833241803F355E8F4A2E4158C1A84409833241C832C4B1854A2E4156302A0909833241403411B68F4A2E410CAC1CDA128332419889B061994A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C10FA370F0E8332412E55DE898F4A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.417' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.417' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10459189, 17743571, 1, NULL, 0xBD0B0000010405000000000000809582324130B072A8AB4A2E41BA270F8B9782324138BA490C4A4A2E41418B6CC78C82324170E7FB693F4A2E415939B4888A82324150355EBAAA4A2E41000000809582324130B072A8AB4A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6FEBD9009182324134CF56EA774A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.427' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.427' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13821202, NULL, 1, NULL, 0xBD0B00000104130000002E90A0D82B86334100AAF1D2F8DC1B413A4ED1112C863341B0B88D06DEDC1B4123F46C162C863341B05296E1B6DC1B41DC1B7C812B863341000456CE8FDC1B41D5D781532A863341307C61F268DC1B41A211A58D288633411033337342DC1B417BE09C3126863341C0C5DC751CDC1B419E89B04123863341A0BFEC1EF7DB1B4189B0E14906863341509D80A6ABDA1B41BB96908FDF853341D07EFB3AA3DA1B41896CE7BBE385334160A301BC3DDB1B41489D8026E48533417036ABBE59DB1B4191B96BE9E3853341F0CBEEC975DB1B41BED32B05E385334190F6069F91DB1B41341AC07BE185334120C9E5FFACDB1B419BBB9650DF853341604469AFC7DB1B4144598688DC853341F0A0F871E1DB1B41AA79C729D98533419096210EFADB1B412E90A0D82B86334100AAF1D2F8DC1B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C04E465B202863341F4C844DBB9DB1B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.440' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.440' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 18414885, NULL, 1, NULL, 0xBD0B000001040800000021EBE276919A394180204171B0C71F4138D6C5AD9C9A394190AACFD57AC71F41C74B37499D9A39418069DEF16EC71F4134DF4F6DA29A3941E03F355E0AC71F41F20DBE50A19A3941809A771C06C71F41DAACFABC889A39414076E01C5AC71F41C84B3789799A3941D0F97EEA82C71F4121EBE276919A394180204171B0C71F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C76EFCF87919A39419621BBDA67C71F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.450' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.450' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8750858, NULL, 1, NULL, 0xBD0B000001040A000000FB7E6A3C9E92304150D0445898DA1C41B32E6E739B9230418095434BADDA1C416719E2B898923041609A775CC2DA1C41D0CCCC0C9692304120CC5D8BD7DA1C41840D4F6F9392304170AB3ED7ECDA1C41FE4C84EDA4923041C0F75363EBDA1C41FA5C6DE5A192304130E4831E89DA1C41D4D781B3A0923041F0703D4A8EDA1C4132431C7B9F923041002DB25D93DA1C41FB7E6A3C9E92304150D0445898DA1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD58A06DF9D9230419BE793F2C8DA1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.463' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.463' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13995570, 29845241, 1, NULL, 0xBD0B00000104050000003F355E7A50772B41F831E60EC0643141201FF46C3C772B41F40FE937C0643141509D80263D772B414CE3A53BDD6431414C6B9A3751772B41440E2D12DD6431413F355E7A50772B41F831E60EC064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C45DC57D146772B413AAF9AA5CE643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 4, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.473' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.473' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083663, NULL, 1, NULL, 0xBD0B00000104050000009C2C435C4C6E2B4168711B0DB06431410EFBCB6E606E2B41E4D24DC2B4643141CDDEE08B5F6E2B4158EA045490643141F2FDD4784B6E2B410460766F906431419C2C435C4C6E2B4168711B0DB064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C7D2B9C30566E2B4197E10F67A1643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.487' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.487' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14413001, NULL, 1, NULL, 0xBD0B0000010405000000EEB050EBB68A32415079582847EB1B4190A982B1B78A3241100BB526FEEA1B411C0DE0CDA08A3241003480B7FAEA1B410C12147F9E8A324110DBF97E43EB1B41EEB050EBB68A32415079582847EB1B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C25524B78AB8A3241C222304621EB1B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.497' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.497' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2833913, NULL, 1, NULL, 0xBD0B000001040500000014D0441830B932415074931873B01C41DAE76AEB14B93241102428FEE2AF1C41FE088A7FF5B83241001C7CE13AB01C41F05A42FE0DB93241300EBE30D4B01C4114D0441830B932415074931873B01C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6051814B12B932417DC6E06E5AB01C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.510' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.510' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14116111, NULL, 1, NULL, 0xBD0B0000010408000000CC073DFB7CEF3241907F483F2F851C41194850FC9CEF3241E0FC8774EF841C41F4A7C64BB7EF32418054C1A8CF841C41095F982CFAEF3241E04F8D97BF841C4170787A65C7EF324170DE710AB6841C41E5D9ACFA95EF3241B0A52CC3AC841C4166DE71CA7BEF3241208104C5A7841C41CC073DFB7CEF3241907F483F2F851C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1A32FF1F9DEF3241BC9C4D85D4841C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.523' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.523' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11893613, NULL, 1, NULL, 0xBD0B000001040400000084B0E1498561334160976E923B5B1C41745F070E856133411020D26F505B1C41C27D1D188D613341200000003D5B1C4184B0E1498561334160976E923B5B1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3E2F02D087613341303DC000435B1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.540' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.540' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5764068, NULL, 1, NULL, 0xBD0B00000104080000003B3CBDB2842F3241606E120394941741CAC342CD8A2F3241F06F5F0783941741184850DC902F32414083C0CA71941741F9DBD7E1882F3241300AD72307941741DD9C1105702F3241100BB5A6249417410BC58F717A2F324150DC4603B0941741221FF48C7E2F3241B011A5BDA49417413B3CBDB2842F3241606E12039494174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC945F589802F3241BE973C8554941741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.553' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.553' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8270333, NULL, 1, NULL, 0xBD0B000001040A000000F185C9F484B03241D0749318F9771C41A43C2C3484B0324140E7FBA9F9771C41621058B95BB03241E04B370918781C41348941E048B032418070CE8826781C41A43E575B45B032411075021A29781C41812F4C0659B032416027A08992781C41F697DD736CB0324100840DCF83781C4106AC1C1A68B03241C04B378927781C41E573B51586B0324180B96B0911781C41F185C9F484B03241D0749318F9771C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE1F9A0EC60B03241711BED0243781C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.567' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.567' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7487983, NULL, 1, NULL, 0xBD0B00000104050000002DBB27AFA97E30413090A07804051D41A33C2C94A97E3041D0BE0E9C16051D4125A08910C97E3041D0E1E99506051D411D6C783AC97E3041A0B43778EA041D412DBB27AFA97E30413090A07804051D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C77B9A185BA7E304176D24E4702051D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.583' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.583' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2833948, NULL, 1, NULL, 0xBD0B00000104050000000CF9A0474BB93241907CD03303B11C4114D0441830B932415074931873B01C41F05A42FE0DB93241300EBE30D4B01C41FF9908DB26B9324130F2B0D06EB11C410CF9A0474BB93241907CD03303B11C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5C831C2D2CB93241A9507E71EFB01C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.597' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.597' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8988374, NULL, 1, NULL, 0xBD0B00000104060000008C976EB2DED6324140840DCF7FA61C414E05A31216D73241F096218EE4A51C4102D5786917D73241009F3CAC78A51C41A7605412E2D63241F004341171A51C41A957CAD2E0D6324130E17A14C9A51C418C976EB2DED6324140840DCF7FA61C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEEA0B79EF7D63241841D30DAD8A51C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.607' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.607' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8829381, 36481921, 1, NULL, 0xBD0B000001040B000000FDFFFFBFE4B23341A0B96B89F4141D416C3D0A97E2B23341B07BF270ED141D41383CBD62E0B23341F03B4E91E6141D41B02E6E23DEB23341801E85EBDF141D4146B6F33DADB23341C021FDF699151D41A7F1D20DBBB23341D0A59BC4C4151D417958A8B5E9B23341302EFFA10E151D41E8263188E8B23341F09E3CEC07151D418EE4F24FE7B233413006815501151D41ED8C280DE6B233417088D2DEFA141D41FDFFFFBFE4B23341A0B96B89F4141D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAE8F9F02CCB233413A8F5A2A53151D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.623' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.623' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 25542371, NULL, 1, NULL, 0xBD0B0000010417000000EE7C3F95B8AA3241F044D8F0E74A1C41DE5817E7C1AA3241D06E8184DD4A1C41FC088A4FCBAA324180B3EA73D44A1C41927571CBD4AA324180B740C2CC4A1C41526B9A57DEAA3241F0D71272C64A1C41F6A06743E5AA32419067B32AC14A1C41A93E570BECAA324130136183B94A1C4193976EA2F2AA324150BADA8AAF4A1C41B915FBFBF8AA3241003D2C54A34A1C415EC3D30BFFAA324140EBE2F6944A1C41FC4A59C604AB3241903A708E844A1C41DE2D90200AAB324130355E3A724A1C41735F074E25AB3241A0D712720D4A1C4196BB963026AB324160DAACFAB9491C414AC8079D26AB3241C04DF30E92491C41B369DEB15AAA324170B20C716F491C41EDFDD4385AAA3241D087855A97491C418541600556AA3241E03FA4DFF94A1C41638FC25564AA3241F03311B6414B1C412FE6AE4565AA32412066F764464B1C41BC64AA406AAA3241203945475F4B1C41D909686292AA324150E5D0A2154B1C41EE7C3F95B8AA3241F044D8F0E74A1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C743617AEAFAA32416D92C56C384A1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.633' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.633' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12572039, 13415961, 1, NULL, 0xBD0B0000010405000000BA7D1D382420224160E9267114FA2D41FE088A1F1E202241083B704EC8F92D41704F1ED6FF1F2241C06B09B9CAF92D41C8B12EEE05202241802BF6D716FA2D41BA7D1D382420224160E9267114FA2D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C01521E0712202241713B2E94EFF92D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.647' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.647' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10204610, 4462301, 1, NULL, 0xBD0B0000010407000000C6DCB5E48581324158BB274FB3492E413C575B31848132419826C246F7492E41EC1648D097813241E0B12E2EF9492E41F8A9F1729881324160D3BCA3E3492E4165B3EA3399813241F02A8716CA492E41D4CEF7B397813241E0361A00B5492E41C6DCB5E48581324158BB274FB3492E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C12342AC48E8132411F303297D6492E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.660' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.660' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11756896, 90069993, 1, NULL, 0xBD0B000001040C0000009DE61DA766632941FCCBEEE9D83A3041DD5F764F1664294144F6971DD33A3041A82C431C14642941BC25E443C23A3041D6CCCC0CD8632941EC096862BA3A304143F1630CA2632941B8DA8AFDAA3A3041B4EA737587632941F05A423E9F3A30412E1AC09B70632941F43845A7913A3041EA285C4F6463294164226C38883A3041C41726D359632941CCB6623F7E3A3041666666265C632941243333B3813A3041EE7C3F35626329418C6CE77BB93A30419DE61DA766632941FCCBEEE9D83A304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4D0DA4E5A36329417F1874B1BD3A3041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.673' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.673' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 23915803, NULL, 1, NULL, 0xBD0B00000104060000001CC05B8090AB324160333333EF631C4124E483DE98AB3241D0B88D86CF631C41153FC65C88AB3241602D211F75631C41B4FC877473AB3241C0B0E1E9C3631C410C5F986C83AB3241E00E9CB320641C411CC05B8090AB324160333333EF631C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5549780F86AB32418E6BCC89CA631C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.683' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.683' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13997998, 23688351, 1, NULL, 0xBD0B000001040500000066D5E7EA82792B41140DE08DD8643141FE907EFB96792B4154CA3264D86431411CF46C1696792B412C3CBD72BE643141DE141D0982792B41FC87F49BBE64314166D5E7EA82792B41140DE08DD864314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C910E78818C792B4185098C80CB643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.697' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.697' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083698, 14745381, 1, NULL, 0xBD0B00000104060000000EFBCB6E606E2B41E4D24DC2B4643141B2D85FB6606E2B4150FC18D3B464314197ED7C7F746E2B4184E09CB1B46431418A635D9C736E2B4134AB3E3790643141CDDEE08B5F6E2B4158EA0454906431410EFBCB6E606E2B41E4D24DC2B464314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CCFC687056A6E2B41E7080A84A2643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.707' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.707' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5868530, NULL, 1, NULL, 0xBD0B0000010404000000BED32B658E283241406744E9229617415127A089A52832411019735732961741199E5E09A2283241703480B70D961741BED32B658E283241406744E92296174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C0D330EA89C283241EBE667FD20961741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.720' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.720' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10459294, 5676141, 1, NULL, 0xBD0B000001040500000013C7BA98CF82324140BF7D1DAA492E4112143F26D3823241B02E6EA3BE492E4104F9A007FA823241F0915C7EC2492E414650FC98FA82324100C364EAAD492E4113C7BA98CF82324140BF7D1DAA492E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C02977FE7E5823241D8B6B51FB6492E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.733' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.733' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11097710, NULL, 1, NULL, 0xBD0B0000010407000000C732C4917166354110AAF15216AE2341CF6F5F4772663541E044D830F6AD23414BD8F0345E663541701D38A700AE2341BEF528FC5C66354158AF94E529AE23414C696F106766354100E17A5437AE2341C454C1887066354168C8073D45AE2341C732C4917166354110AAF15216AE234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CCCA8628A68663541EAB1B8E019AE2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.747' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.747' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15494772, NULL, 1, NULL, 0xBD0B00000104570000003CCF6695EE27394138E6AE65D0D620414CBF7D1DF127394140E17A54D7D62041580E2D82F227394198AF0347DAD620417A711BDDF3273941C01E854BDDD62041BAD1002EF5273941B8529661E0D620410E4FAF74F627394160029A88E3D620412C5305D3F6273941305EBA89E7D62041A0D6346FF72739410068226CEBD620411DEBE246F8273941D0240621EFD62041A4CFD556F9273941E8E2369AF2D6204172CE8812FA27394178348017F9D6204133014D14FB273941A8DFBE6EFFD62041A2703D5AFC273941903C2C9405D72041482EFFE1FD273941007F6A7C0BD7204186C0CA81FF273941A0A3703DF1D620415F29CB5011283941A8FD6577D1D52041EEFDD438FC273941782F4C6650D520415DC3D3EBF327394120D26F9F1DD5204129D49AE6A627394130780B644ED52041907571FBA2273941A0ADD89F50D520414B9D80869C273941785F074E54D52041666666C69F27394160BF7D1D63D5204136F8C224A1273941203108EC6AD5204144696F40A1273941084D846D71D520418C3A010DA1273941F8CCCCEC77D52041B147E18AA0273941B010C75A7ED5204136234ABB9F273941F81DA7A884D52041BA847C90A1273941681058198CD520413A894140A3273941D88C28AD93D52041413EE8C9A4273941504013619BD52041AD03E72CA6273941500E2D32A3D5204102780B04A727394198923A41B3D52041E66A2BF6A627394150E6AE65BBD520415E29CB30A6273941C8293AD2C3D52041AC9DEF07A727394118AE47E1D3D520416EA3011CA827394198BDC157D7D5204199D40918A9273941F0C264EADAD52041EFB050FBA9273941F061A196DED52041C0D32BC5AA2739416807CE59E2D520410E9C33E2AC27394158302A69E9D52041AE946528AF2739410055C1E8F8D5204165226C98AF27394188613255FCD5204188F4DBF7AF27394188B96BC9FFD520416C469446B027394188CA324403D620418E537484B027394130014DC406D62041915CFE33B127394100B37BD20CD62041E3BE0E3CB2273941609FABAD12D6204170F90F99B3273941586EA34118D62041F54A5946B527394140234A7B1DD62041201FF4BCB6273941986E126320D620416D787A25B827394128DD246623D620416844697FB92739419865888326D620411A8C4ACABA27394188900FBA29D62041842F4CA6BB273941B86054722DD620416EE7FB99BC273941904E401331D62041826ABCA4BD273941A8506B9A34D62041F253E3C5BE27394100CBA10538D62041FEFFFFEFBE273941E08F31173CD62041107A365BBF27394160C6DC1540D6204146C6DC05C027394170A982F143D6204158A835EDC0273941B0506B9A47D62041BAD100CEC1273941283CBD524BD6204156F5B9BAC2273941B8B662FF4ED62041E8C039B3C32739414892CB9F52D6204113E258B7C427394128A1673356D62041D6CEF7F3C6273941C830998A5AD62041ECAE2524C92739419010C7FA5ED6204109F9A047CB273941204A7B8363D620410624285ECD273941E8AE252468D6204170B5155BCF273941C839234A6FD62041C2E3147DD1273941587DAE367FD62041B27BF270D2273941B015FB4B84D620419FEFA756D3273941083A926B89D620414E96212ED4273941E885C9948ED6204134992AA8D5273941087C617291D6204164CC5D2BD727394150D1913C94D62041703480B7D8273941608EE4F296D62041D2D5564CDA273941E8BCE39499D620416D348077DB273941303CBDF29BD62041E9C039B3DC273941E07A142E9ED62041B5C876FEDD27394168810445A0D620419FB43758DF27394128FDF635A2D620414F499DA0E1273941506744E9A8D62041B6847C90E427394140014D84B8D62041DE718A8EE62739419067B3AABFD62041F085C9B4EB273941D0F97E2ACCD620413CCF6695EE27394138E6AE65D0D6204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C0E7A8D5DDE2739412546D8F5E6D52041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.760' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.760' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12648337, NULL, 1, NULL, 0xBD0B00000104070000000634113611FF2541C837F8C2CFCE2F41004D84CD3DFE254118B072A879CF2F415A07CED96EFE2541B015FB8BA0CF2F41B4CFD51620FF25412818951412CF2F41742D211FAAFF2541E85F76CF32CF2F41D40968E2080026415011367C0ACF2F410634113611FF2541C837F8C2CFCE2F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB5A913DC0DFF2541DEA96CFD24CF2F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.773' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.773' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5484022, NULL, 1, NULL, 0xBD0B0000010470000000AB35CDFBCAAD3241B067B3EAC3E51C41DAA3707DD0AD324120EA95B2C3E51C415DFE43FAD5AD324100D34DE2C1E51C41D7F0F46ADBAD3241F0907E7BBEE51C410BF016C8E0AD3241C06E1283B9E51C4141575B71E1AD324120A7E8C8B8E51C41C2172693FAAD3241C0081B1EF9E51C41AD1C5AE402AE324110B684FC31E61C4121166A8D0BAE3241F0019A086AE61C4178711B8D14AE324170105839A1E61C41BA490CE21DAE32414094F686D7E61C417D9ECD8A27AE3241B08BDBE80CE71C41676FF08531AE3241703D0A5741E71C4190A0F8D13BAE324150F085C974E71C41C7C3426D46AE3241C034EF38A7E71C41CCA1455651AE3241B0E3149DD8E71C415ECC5D8B5CAE3241406900EF08E81C417E9ECD0A68AE32415054522738E81C4131772D2168AE32413025068138E81C41E6AE25848AAE324150F38ED3D4E81C4184B0E129EAAE3241B0FC87F42AEA1C412ACB10678FAF3241E0B0506B7AEC1C412A0F0B15FCAF324180635D5C30EE1C416207CE1913B0324140DE02091FEE1C414A50FCB837B03241800E2D3281ED1C412EFF21DD4BB0324170B81E052AED1C413BF8C24426B0324100917EFBA2EC1C41C7293A32C3AF3241506132D593EB1C41F73A702E64AF3241500D4FAF3FEA1C418DED7C3F35AF3241D061A1D697E91C41F30DBED034AF32414083C04A96E91C413E1361C334AF3241602CD41A96E91C4166666646F3AE3241A07FD9BDABE81C41ABE8486EACAE324180105839AEE71C415ACA328458AE324140D8F0F481E61C410F363C5D4CAE324120FF217D3EE61C4150F38E131EAE3241E0073D1B9DE51C41B2506BBA21AE3241F0B6627F8CE51C41B6DA8ABDFEAD3241202497FF12E51C41EC38454713AE3241A09CA223B6E41C41F25A425E11AE324120158CCAA7E41C41B41E852B11AE324160A7574AA6E41C4158423EA80BAE3241805EBAC97AE41C416F567DEE06AE3241103D9B5552E41C4115AE478106AE3241E02A87964EE41C41F60FE9B701AE3241105AD3BC21E41C4138234ABB00AE3241806891ED17E41C4179C7291AFDAD3241C0E61D27F1E31C41EFEBC0D9F9AD3241308716D9C9E31C41A53E57FBF6AD3241002A3A12A2E31C4191E4F27FF4AD324170F7E4E179E31C4100E78C68F2AD32414019735751E31C418E1804B6F0AD324180B7408228E31C413470CE68EFAD3241A0D71272FFE21C41C37493B8F0AD3241A0D556ECE3E21C41D49AE6DDF3AD3241F078E926A8E21C41F2384567F7AD3241707EFBBA6CE21C4172CE8852FBAD324170A757CA31E21C411071ACEBFEAD3241F0839E4D01E21C41CA54C18803AE3241305A643BC8E11C412ACB108708AE3241403108AC8FE11C41E29387E50DAE3241A079C7A957E11C41CDF753A313AE32412080483F20E11C41C87F48BF19AE3241F06A2B76E9E01C41F5065F3820AE3241803E7958B3E01C41B2FA5C0D27AE324180FB3AF07DE01C41A15E298B2EAE3241C0A59B4447E01C41E61DA7C810AE3241205AD33CDCDF1C4183C0CA61D8AD3241E0D100DED6E01C4138894120B3AD324140355E3A7CE11C41DCE995D2B5AD32412000000026E21C41CCE53FE4B6AD3241401058396AE21C4158A835CDB6AD324150A835CD97E21C413308AC1CB7AD3241B01A2F5DC5E21C41E3E995D2B7AD324150D122DBF2E21C41C0A8A4EEB8AD3241A0EB513820E31C4196BB9670BAAD3241F041CF664DE31C41F90FE957BCAD3241406210587AE31C41945CFEA3BEAD3241002428FEA6E31C419F3C2C54C1AD3241D0F0F44AD3E31C412CC28667C4AD3241F09F8930FFE31C412CFF21DDC7AD324190772DA12AE41C4167B3EAB3CBAD3241604DF38E55E41C41F31FD28FCEAD324190B662FF72E41C41FB75E0BCCEAD32418066666674E41C41E10B93A9D3AD32411003090AA3E41C419E3C2CF4D8AD32413070CE08D1E41C4157EC2F9BDEAD324120AB3E57FEE41C4134AB3EF7DEAD32419075711B01E51C41EC1648F0D6AD3241D0270F8B1EE51C41A9DFBEAECCAD324160E4F21F24E51C412EC4B1DEC7AD3241A02A181523E51C418FED7C1FC3AD3241C05A42BE1FE51C41DFE99582BEAD32410030BB271AE51C4101DE0219BAAD324150C1176612E51C41F5A9F1F2B5AD3241A0E1E99508E51C415B5BB11FB2AD3241403E57DBFCE41C410A5F986C41AD324150C5FE3275E31C41FA6C56BD2CAD324100E25817D1E31C41B2FA5CEDE6AC3241A00F7AB6E0E21C41E573B535E1AC324100000080FAE21C41DBCEF7D397AD3241C042AD6975E51C411648503C9CAD324150C1A8A483E51C419F8026E2A0AD324160E2C79890E51C415B5BB1BFA5AD3241207D3F359CE51C412FC4B1CEAAAD324100B1506BA6E51C41E41DA708B0AD3241007B142EAFE51C41DA78E966B5AD3241D0B27B72B6E51C4195779CE2BAAD324150C4B12EBCE51C41ED85C974C0AD32410088F45BC0E51C41CCA14516C6AD324150D8F0F4C2E51C41AB35CDFBCAAD3241B067B3EAC3E51C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA9147BA0AAAE3241ADE64124B7E71C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.787' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.787' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2518911, NULL, 1, NULL, 0xBD0B0000010408000000DE02096A76AE324170F4DB5755701C410B560E6DA5AE324100575B31E0701C4153A60AE6E5AE3241C07A142ED86F1C41B91E854BCAAE3241506DC5FEB46F1C41EFF44A39C2AE3241B0D71272AA6F1C410D61C3739FAE3241D045B6F337701C414F27A0A989AE324100651962FA6F1C41DE02096A76AE324170F4DB5755701C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3E905219ADAE32414CFC3F103F701C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.800' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.800' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13601709, NULL, 1, NULL, 0xBD0B00000104050000005AEC2F9BF38E3241408C4A6AB2261D4109B5A6B9FD8E3241703F35DEB3261D417458A8D5FE8E3241D0DEE00B31261D41BBAF03C7F48E324180BE9F9A2F261D415AEC2F9BF38E3241408C4A6AB2261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CCB263B3CF98E324160C5D9CC71261D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.813' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.813' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15937551, NULL, 1, NULL, 0xBD0B00000104090000009DB437783A833241F8EEC983B04A2E41D6ACFA1C3A83324110E02D10C04A2E41ABF1D2ED43833241B023B9BCC94A2E41E826316844833241608B6CA7B44A2E4161E5D0624583324120B29D6F894A2E416ABC74933B83324150EE5AC27F4A2E41C30E9C933A83324180BC74D3AB4A2E4197779CC23B833241903A010DB14A2E419DB437783A833241F8EEC983B04A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CCE064FC63F833241B350E0B3A44A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.823' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.823' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15937534, NULL, 1, NULL, 0xBD0B000001040A0000009DB437783A833241F8EEC983B04A2E41EF2FBB873083324180F7E461AC4A2E412731084C30833241A0416065B64A2E41D6ACFA1C3A83324110E02D10C04A2E419DB437783A833241F8EEC983B04A2E41AED85F7631833241F82A8796834A2E41C30E9C933A83324180BC74D3AB4A2E416ABC74933B83324150EE5AC27F4A2E4139014DC43183324198180416764A2E41AED85F7631833241F82A8796834A2E41020000000200000000020500000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010CB243B3BA368332414ADD1450984A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.847' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.847' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'YES', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4735153, NULL, 1, NULL, 0xBD0B0000010408000000EE8E53D476533141B0E53F2476D01C41CE22DBF97E53314100D7A37050D01C4173E7FB699053314130234A7B4BD01C41C87F489F9053314130B072E826D01C4122F46CF69053314140F90FE9EACF1C41CE19517A77533141B0ADD85FDFCF1C41D4ACFA5C77533141008AB0E1FBCF1C41EE8E53D476533141B0E53F2476D01C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9D44C51683533141024749691DD01C41, NULL, NULL, CAST(N'2022-03-04T13:10:39.667' AS DateTime), 0, 0, 0, 0, NULL, NULL, 4, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.860' AS DateTime), N'dbo', CAST(N'2022-03-04T21:10:39.783' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4300017, NULL, 1, NULL, 0xBD0B0000010405000000A157CA7293822C4148EE5AC287E8224128ED0DFE79822C41E86C563DDCE8224195416065AE822C41186C783ADCE82241146A4D73D1822C41284A7BC35FE82241A157CA7293822C4148EE5AC287E8224101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C08479015A5822C418982D2AEA7E82241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.873' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.873' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13908332, NULL, 1, NULL, 0xBD0B000001040800000075E7FBE937512B41305305A3FD6031410EE02D5040512B4110E9B7AF036131412B3A928B40512B41581058D903613141EBDBD7C13F512B41403108ACE7603141BC8F31B72B512B4130DD24C6E760314176B5153B2C512B41DCE76ACBF46031417FC729BA2F512B41B02E6E83F760314175E7FBE937512B41305305A3FD60314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1BFA254C37512B419597DE84F2603141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.887' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.887' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13869591, NULL, 1, NULL, 0xBD0B0000010408000000B31C5A2492A23241E0E76AAB53F01C41C5293A12CBA232414075029AE6F01C41177C61D2CFA23241101AC0DBF2F01C41780B2488D7A23241601283C006F11C41306EA30148A332410076E09C98F01C419F8026A248A3324150B4C8F660F01C4172F085A99BA23241D0ACFA5C54F01C41B31C5A2492A23241E0E76AAB53F01C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C27E66FFDEFA2324186535D8B97F01C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.897' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.897' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9659790, 3246951, 1, NULL, 0xBD0B00000104060000005BC1A824D2813541D822DBB9AA682541BE172653F3813541F085C95491682541BD42ADA9F9813541C017265381682541DCC798BBF4813541906ABCB46868254159C1A8A4CB8135412863EE5A8A6825415BC1A824D2813541D822DBB9AA68254101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C69F7BE1DE381354157953A0B8A682541, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.907' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.907' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7482876, NULL, 1, NULL, 0xBD0B00000104050000004382E287497D304130F46C56ED021D4161FE431A337D3041405DDC46CB021D41124FAFD44B7D30418048BFFD46031D418538D6454C7D3041A098BB16FB021D414382E287497D304130F46C56ED021D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C77659AA8437D3041D9EE767501031D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.920' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.920' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226291, 90073096, 1, NULL, 0xBD0B000001040A000000DF68006F622E2C41DCD781D374A1304130BB274F182E2C41D00E9C5375A130416C9A775C182E2C41901C5A8478A13041A201BC051D2E2C4124EBE2C679A13041240456CE212E2C4154158CEA7AA130412D3333B3262E2C419CFF90EE7BA13041AA7BF2B02B2E2C41CC293AD27CA13041EE8E53F45B2E2C41183FC67C7CA1304112B7D180622E2C4120E9B70F79A13041DF68006F622E2C41DCD781D374A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CCD31FA033F2E2C4174CCDDA278A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.930' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.930' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 16264436, NULL, 1, NULL, 0xBD0B00000104040000008048BFBD7CBC32416082E2C74F461D41192653A582BC324170F2B0D021461D414872F94F7ABC3241602041F147461D418048BFBD7CBC32416082E2C74F461D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF64A59E67DBC3241BB319CD83D461D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.940' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.940' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12912727, NULL, 1, NULL, 0xBD0B000001040A00000023C05BA0F8F726415491EDFC19B03241E6CEF7D313F826419C6E12C318B03241A211A5FD0EF8264124FDF6D5FDAF32417A16D94ED0F726414C27A0A900B03241DDFBA9F1BAF72641D06D34A001B032417636AB3EC8F72641442CD4DA05B032413590A018D5F72641E0F0F46A0AB032416F3D0A77E1F726417068914D0FB0324100C58F51EDF726418CB6627F14B0324123C05BA0F8F726415491EDFC19B0324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA022AFD4F3F726416AC3453C0AB03241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.970' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.970' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13997971, 23688191, 1, NULL, 0xBD0B0000010405000000849ECD2ABE792B41B4ADD81FBE643141E1AE2524AA792B4194F08549BE6431412D4CA60AAB792B410863EE3AD864314166AA6014BF792B413C575B11D8643141849ECD2ABE792B41B4ADD81FBE64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDA9F839BB4792B414AD2BE2DCB643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.987' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.987' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5608481, NULL, 1, NULL, 0xBD0B000001040600000072CE8892E6EB324130E258174CA82A41C98F31F7DCEB324138BD52D69CA92A41172FDD84CDEC32410062A156B3A92A419D5E292BCFEC32412038678479A92A41C554C128D7EC3241B069DE7161A82A4172CE8892E6EB324130E258174CA82A4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C50834B1F5AEC324189E31C6FFFA82A41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:13.997' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:13.997' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13843389, 90073173, 1, NULL, 0xBD0B00000104060000006C9CA2A36C512B41CCC64B57206131412BF6975D6D512B41FC2FBBC720613141BD6B09F976512B41E4D9AC5A266131411DFDF6757D512B4118F697FD29613141026F81047D512B41A0779C42206131416C9CA2A36C512B41CCC64B572061314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD24719AE77512B41780A318C23613141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.010' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.010' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12917320, 1050611, 1, NULL, 0xBD0B000001040E00000025E4831E9AE02641C0506B5A579E3241043B704E9BE02641F8B27BF2569E3241606DC5BEA9E02641B8490C02529E324100DE02C9BAE0264134D6C52D4C9E324146EC2FBBCDE026417405A3B2459E3241F6088A5FC2E02641ACFD65573D9E324101B37B72B0E0264134FF217D439E3241811F63AEA2E026417458A835489E32411483C00A90E0264170F085A94E9E3241CADEE04B8DE02641B8270F8B4F9E32418EC2F5E890E026411085EB51519E32415FDC464394E026416C226C38539E32411BF46C5697E0264158DA1B3C559E324125E4831E9AE02641C0506B5A579E324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDB33CF13AEE0264144539C644A9E3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.030' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.030' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083612, NULL, 1, NULL, 0xBD0B00000104050000007E3F351EF16E2B41E034EF588F6431419A11A5BDEB6E2B4158EE5A628F64314163E5D0E2EC6E2B41500C02EBB36431416CB5153B016F2B411CFAEDCBB36431417E3F351EF16E2B41E034EF588F64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C670DB594F36E2B4116FE7226A5643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.060' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.060' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226231, 35711721, 1, NULL, 0xBD0B0000010405000000C09F1AEF172E2C41CC0E9C1366A130416D4DF30E622E2C41C00E9C7365A130410032E6EE612E2C4170BC74D35DA130412ABB27CF172E2C41D4D781735EA13041C09F1AEF172E2C41CC0E9C1366A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF8C211EF3C2E2C4133CE8BF361A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.090' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.090' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12648302, NULL, 1, NULL, 0xBD0B000001040C000000611058F9D9FE2541105305638BCF2F41742D211FAAFF2541E85F76CF32CF2F41B4CFD51620FF25412818951412CF2F415A07CED96EFE2541B015FB8BA0CF2F4133A2B43778FE2541504772F9A7CF2F411E7C61F274FE25415827A0C9C2CF2F41EBCD19D178FE2541603BDFCFC4CF2F4118D26FFF8AFE254128D8F054B7CF2F41DCD022DB9DFE2541A8B20CD1AACF2F41E0581757B1FE2541B003E74C9FCF2F417E38D665C5FE254148696FD094CF2F41611058F9D9FE2541105305638BCF2F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEBA97AD202FF254128162C735BCF2F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.117' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.117' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11929090, NULL, 1, NULL, 0xBD0B000001040A000000D266D5A74AB13241A0B6627F2B7E1C41B8B88DE644B1324180C5FEB2597D1C413C2CD41A51B13241A096210E637C1C4194B20CD149B13241401B9E5E717C1C411E5A643B1AB1324150F38ED3CE7C1C41205A649B24B13241B0DA8AFD127D1C4100780BA42EB13241406B9AF7577D1C41EE8E535438B13241D0D9ACBA9D7D1C41CA073DAB41B13241A024973FE47D1C41D266D5A74AB13241A0B6627F2B7E1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF9695C1C3AB13241DAD3DFCD127D1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.130' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.130' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11471409, NULL, 1, NULL, 0xBD0B000001040500000001917EFBCBBA3241203B70CE9A4C1D41AF506B3AE0BA3241907D1D38924C1D41A4DFBEAEE1BA32418044FA6D0D4C1D417E6ABC14CDBA3241F022DB79364C1D4101917EFBCBBA3241203B70CE9A4C1D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9172AE37D7BA3241054D20A85B4C1D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.140' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.140' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10012044, NULL, 1, NULL, 0xBD0B000001042C00000006A392FA0E683541B096908F5F1F1F41078195832F683541108A1F631F1F1F41588638964C6835414050FC18E61E1F41FE2A87565668354110E17A94CD1E1F4106F9A00761683541505530AAB91E1F4162C3D3EB64683541900A4625AD1E1F41AE7268316568354150DA1BFCA01E1F41DC3D791869683541E09387050F1E1F4150F38EC360683541503BDF0F201E1F41AB72688158683541E0B0E1A9311E1F419A779C5250683541906054D2431E1F41AABDC13748683541604BC887561E1F4192976ED2E1673541B0A9F1D2401F1F4187855A83D86735417088D29E541F1F41750B24E8CE6735418036ABFE651F1F41432CD40AC5673541108941E0741F1F415C8FC2F5BA673541A0EA0434811F1F41996588B3B067354120E8D9EC8A1F1F4141A4DF4EA667354110B7D100921F1F41CB20B0D29B67354140795868961F1F416FE7FB4991673541A088D21E981F1F413792CBBF86673541E0408222971F1F4130BB273F7C673541F08E5374931F1F41926E12D37167354170075F188D1F1F414B9D808667673541B0F3FD14841F1F410E5839645D673541E0B3EA73781F1F41625DDC7653673541E05B20416A1F1F413470CEC8496735412071AC8B591F1F4164E5D02228673541B011A5BD211F1F41D834EF985765354120E17A94B21B1F417F9ECD4A6465354170A4DF3E511C1F41976588A32D66354110C7BAB8CA1D1F41C09F1AEF3F663541E0B27BF2EC1D1F411CC05BE03C673541D0043411C71F1F41F8285C7F42673541C0C3422DD11F1F41EBF21F3248673541C0F21F92DA1F1F414F7424F74D673541006D563DE31F1F41201FF4CC53673541607AA52CEB1F1F41D344D8906D673541A0BB9690FC1F1F41BD9F1A6F8E67354130E3A51B0A201F41016F8144A5673541E052052306201F41C88F31B7CF67354130423EE8D61F1F41D16F5F87F1673541300C712CA01F1F4106A392FA0E683541B096908F5F1F1F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF5E9AD7BE16635414DD76850571E1F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.150' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.150' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14215225, NULL, 1, NULL, 0xBD0B00000104160000004E4013612C5E35415807CED9CB1A244104F9A0072E5E3541B8E4F25FE81A2441DC7A146E2F5E3541A07CD0F3041B244146D8F094305E35411873D792211B24416EA3017C315E354158EC2F3B3E1B2441B937F822325E3541500C02EB5A1B24414F8D97AE325E354198976ED28E1B24419B802662335E354198DE71CA991C244188D2DEA04C5E3541A01726D39D1C24412F4CA68A725E3541B064AAE0A31C2441624BC847935E3541409B551F7C192441B28BDB682B5E3541983B4E916B192441910F7A56045E35419019E2586519244138DF4F4D165E354100F775A0EA192441480C02EB195E354150302A69061A244184A7574A1D5E35417817B751221A24414403786B205E3541F061A1563E1A2441C6BAB84D235E35413022FD765A1A2441B27268F1255E354198C420B0761A2441CDAACF55285E3541385BB1FF921A244137234A7B2A5E354158D3BC63AF1A24414E4013612C5E35415807CED9CB1A244101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB16C14D5545E354139C786E6CF1A2441, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.163' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.163' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15885844, NULL, 1, NULL, 0xBD0B0000010415000000B2B6625F099E3841D80DBE30220E20418A855A33E99D3841805E29CB1F0E204136B4C836CD9D384198703D0A200E20414E6B9AD7BC9D3841804AEA44230E204100F775A0AC9D384190A1D674290E204138234A1BA29D384160CD3BCE330E2041FA6C56DD9C9D3841407958283E0E204166AA60F48E9D384180F4DBD7600E2041BE9F1AAF8A9D3841D0847C50730E204170CE88B2829D3841186A4D33AC0E2041923177CD7E9D3841E0FBA9B1CA0E20416819E2787C9D3841D00434D1E90E2041905374247B9D384188E61D672D0F2041204A7BE3829D384170F90F69720F2041FF87F4BB869D3841401361C3880F2041CC6D34008C9D3841C07F48BFBA0F2041FC65F704629E384178226CF8F00F20410B560E6D619E3841C878E966E00F20414E05A3D2509E3841B8D2DEA00D0F2041ABCFD536269E3841F8F44AD9220E2041B2B6625F099E3841D80DBE30220E204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6F7BE9BAEA9D3841E51E0B8F0A0F2041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.177' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.177' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14508567, NULL, 1, NULL, 0xBD0B0000010405000000BD7D1DF88D2E334150D5E7EA0F951C413408AC3CA42E334190B12E6E25951C41AB825189AB2E3341E0907EFBBC941C41A8C64B57952E3341E07CD0B3A8941C41BD7D1DF88D2E334150D5E7EA0F951C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB35A49C99C2E334147C7B0D5E6941C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.190' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.190' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12190616, 90052919, 1, NULL, 0xBD0B000001040A0000005296216E6FE83241B06B09B9505B2A41CE3B4E116CE83241086C783A8C5B2A41068A1F036BE83241F81EF42CAD5B2A412B6519C262E83241184ED191415C2A415205A3B2F9E8324180567D2E465C2A4162DC46C3E8E83241A8D32B656E5B2A41C6C3422DE7E8324178992AD85E5B2A41F64A592676E8324108D04418DA5A2A41885AD37C72E8324178D5E7EA1A5B2A415296216E6FE83241B06B09B9505B2A4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C871B86F7A8E83241804B0935B45B2A41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.200' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.200' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13978063, 23695671, 1, NULL, 0xBD0B000001040500000092B0E1A9A8792B41A442AD8992643141964160E5A7792B41384ED1517B643141463EE8D993792B41906CE77B7B6431410E1B9E9E94792B418C8EE4B29264314192B0E1A9A8792B41A442AD899264314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1FE101429E792B4188BC8C0287643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.213' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.213' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13769634, NULL, 1, NULL, 0xBD0B00000104040000004FAF94C5D42C3341308B6C6737131C41B71E85CBD32C3341A08D06F0A1131C412A1895140C2D3341F029A9133E131C414FAF94C5D42C3341308B6C6737131C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C65F7E4E1E62C33414016B4235D131C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.230' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.230' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9680411, NULL, 1, NULL, 0xBD0B000001040600000084DB68407BA53241E054C12807881C412D992A587AA53241F086A7D75D881C41E258171793A53241B06D3480A2881C415D764FDE93A5324180FC87744B881C41E2E995528AA5324100FED4F830881C4184DB68407BA53241E054C12807881C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5D216D2387A53241FB8811C754881C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.243' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.243' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15302113, NULL, 1, NULL, 0xBD0B0000010407000000EA8C284D58CC3641384ED1110E7F2441A33C2CF455CC364110B37B723D7F2441FD2A87F653CC36410064CC9D657F2441EE16485063CC364168B29DAF687F24416A6FF08566CC3641C8AE2524287F2441FEF6756067CC364110CCEEC9167F2441EA8C284D58CC3641384ED1110E7F244101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEE63FCA75DCC3641C7760DC13C7F2441, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.260' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.260' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7487991, NULL, 1, NULL, 0xBD0B000001040500000075711BCDE67E3041D04F8D17D2041D411D6C783AC97E3041A0B43778EA041D4125A08910C97E3041D0E1E99506051D41F07C3F95E67E30413072F98FF7041D4175711BCDE67E3041D04F8D17D2041D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF2AD239FD87E3041DEC68735EE041D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.270' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.270' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226151, 90073093, 1, NULL, 0xBD0B000001040500000014E9B7EF602E2C41A445B6B337A13041E368002F312E2C4164F38E1338A13041604469AF252E2C412CF38ED33FA13041BA9F1A2F612E2C41D8D781533FA1304114E9B7EF602E2C41A445B6B337A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5E069420462E2C41512179DF3BA13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.293' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.293' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977920, 23708861, 1, NULL, 0xBD0B00000104050000006EF90F693A772B4124A91350806431412F08AC5C26772B4148477279806431418BA0F8F126772B41985CFEA391643141865AD3FC3A772B4188BE9F7A916431416EF90F693A772B4124A913508064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C7EBD20AD30772B41C3F5ECF988643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.320' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.320' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6205861, NULL, 1, NULL, 0xBD0B00000104070000003B8941C082413141D0ADD85FFCE61C41ECD9ACDA3F413141F009682205E71C416819E2583C41314150CD3B4E05E71C41109C3322414131411096438B39E71C41D088D25E4B413141C09F1A2F76E71C418026C2E682413141E07A832F63E71C413B8941C082413141D0ADD85FFCE61C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA336890762413141B88FEF1C35E71C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.340' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.340' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 1342177, NULL, 1, NULL, 0xBD0B0000010405000000F64A59866EBC3241B045B673BE461D41BA490CA275BC3241A09AE61D87461D41AD9DEF4770BC324150F46CD675461D418EE4F23F66BC324150EC2FBBA3461D41F64A59866EBC3241B045B673BE461D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3EECA25D6EBC3241B8371D9899461D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.350' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.350' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13602039, NULL, 1, NULL, 0xBD0B00000104050000000E363CDDE08E3241E06A2BF617261D4157A835EDEA8E3241C0C2D3AB19261D41647FD95DEC8E32418095430B92251D411C0DE04DE28E3241003D9B5590251D410E363CDDE08E3241E06A2BF617261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB8DA8A9DE68E32410780B700D5251D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.360' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.360' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5649293, 761811, 1, NULL, 0xBD0B00000104070000000E83C04AB0D1314190FEB2FBD8F01941E9FBA91194D1314190AC8BDBA5F019414ED1919C90D1314110BADA0A6BF21941826132558FD13141C0779CA212F31941E595B20CB0D13141E05B8F4217F31941D488D21EB0D1314150B20C716FF219410E83C04AB0D1314190FEB2FBD8F0194101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA73345B1A0D1314161D607FDF0F11941, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.370' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.370' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226134, 90073092, 1, NULL, 0xBD0B000001040600000014E9B7EF602E2C41A445B6B337A130410BF241CF602E2C41E0E00BF331A13041DE68006F3B2E2C41DCD7813332A13041DC6800AF392E2C4168BC743332A13041E368002F312E2C4164F38E1338A1304114E9B7EF602E2C41A445B6B337A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4A61BC0C4B2E2C41BD4CB21435A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.380' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.380' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083523, 14745671, 1, NULL, 0xBD0B000001040500000014E9B7AFB06E2B413CFAED4BB4643141161DC9A5AF6E2B410C4D84CD8F6431419B89B0A19B6E2B41D43B4EF18F643141D476BE9F9C6E2B41589FAB6DB464314114E9B7AFB06E2B413CFAED4BB464314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9EB7E125A66E2B41F0FEE51FA2643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.407' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.407' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083701, 14745411, 1, NULL, 0xBD0B000001040500000009F2418F886E2B41B468008FB464314101098A9F876E2B41806ABC14906431418A635D9C736E2B4134AB3E379064314197ED7C7F746E2B4184E09CB1B464314109F2418F886E2B41B468008FB464314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB998B5127E6E2B41EF470F65A2643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.420' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.420' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14297744, NULL, 1, NULL, 0xBD0B000001040600000008C58FD19A913241B01E85EB5E0D1D41DF0B93A97F913241308B6CE75B0D1D41BC5B20217E9132415010E937F00D1D419E923A41889132414061C353F10D1D41E24603F899913241F0BFEC1EAF0D1D4108C58FD19A913241B01E85EB5E0D1D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD847953A8B913241283383C19E0D1D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.430' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.430' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14346036, NULL, 1, NULL, 0xBD0B0000010419000000569FABAD78BC3541F8285C0FD2A72341733D0A9788BC354140014D04DCA72341C1EC9E1C8DBC354188AEB6A2E0A7234169AA60549DBC3541B0DCB504F2A72341E0581717A4BC3541B89999D9FAA7234156302AA9BEBC3541000681551DA82341F575E05CC5BC354168F7E4A124A823416DAC8BBBDCBC354168CC5DCB38A82341E29C11E5DFBC3541383333333BA8234172128320E8BC3541E82553456DA72341DFA59B04E6BC354120ADFA1C6CA72341FA6C56FDE5BC354108BE30196CA72341C37D1D3847BC354120AC1C1A14A723413CF8C2E4DDBB354168DE71CA01A723416A2BF637DBBB3541F0BE0E5C37A72341B2B662DFEFBB3541507424174BA723418B8EE4B2FABB35413041F16354A7234108F016481FBC354180EE5A0270A7234146696F1027BC354198A223F975A723411E4A7B2345BC35419857CA7291A723411A1DC9C54CBC3541F865F7E497A7234156D3BCE367BC354100D578A9B6A7234188B0E1A96CBC35411073D752BBA72341AE1C5AC474BC354100CAC342CBA72341569FABAD78BC3541F8285C0FD2A7234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2C388C8179BC35411A74A23981A72341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.440' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.440' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7482965, NULL, 1, NULL, 0xBD0B000001040E000000CB6D3440A47D3041A0749398C4041D414260E550A47D3041C08BDBE899041D41E651B8BE9C7D3041B0559FEB7F041D41B0B6628F957D304110C8983B64041D41FDDD02C98E7D304150C420F046041D41D03B4E71887D3041C09B332228041D414F499D40807D3041C02FBB27FF031D41D98173C67A7D304140D122DB31041D41F3FDD4D8807D304120C8983B50041D4147D8F094877D304170499D0070041D41B22E6EC38E7D304140C3642A8E041D41C5B12E5E967D3041509B559FAA041D41EB51B85E9E7D3041E0CA1047C5041D41CB6D3440A47D3041A0749398C4041D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2D92549A8F7D304191E0E5976A041D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.463' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.463' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090083, 35720151, 1, NULL, 0xBD0B0000010409000000704DF34E362E2C410C61C3B3EFA0304151840D0F032E2C4100A16793DCA0304135BB270FFB2D2C41887CD093D9A03041BE9F1AEFF12D2C41B0D781B3DFA0304110F241CFFA2D2C411461C313E3A030418616D90E062E2C41E8D78133E7A0304133BB270F2F2E2C41C40E9C73F6A030419B5E29CB332E2C4180B0E1C9EFA03041704DF34E362E2C410C61C3B3EFA0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD4362E0E142E2C41E85341B6E7A03041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.473' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.473' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13998056, 23688771, 1, NULL, 0xBD0B000001040500000047E8D9AC32792B411C583934D964314174A301BC46792B4144158C0AD9643141FEF675E045792B4190C64B17BF643141332AA9D331792B41E4361A40BF64314147E8D9AC32792B411C583934D964314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C45CC32473C792B4139C2CC25CC643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.483' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.483' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083582, 14745961, 1, NULL, 0xBD0B000001040500000063E5D0E2EC6E2B41500C02EBB36431419A11A5BDEB6E2B4158EE5A628F643141CE56ECAFD76E2B41100BB5868F643141AC7268D1D86E2B41C030990AB464314163E5D0E2EC6E2B41500C02EBB364314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1109AF48E26E2B4194D333B8A1643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.500' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.500' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 17839149, 90056931, 1, NULL, 0xBD0B00000104050000008FF6065F4BF22641A43C2C54B2AD32418D3A014DB8F22641204FAF14ADAD324111F2418FB6F226411CB4C816A4AD32412CCB108744F226413C0AD7438FAD32418FF6065F4BF22641A43C2C54B2AD324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3C2DD8B174F226419E2024ECA3AD3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.513' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.513' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9325611, NULL, 1, NULL, 0xBD0B000001040700000013F241EF413A324160BC05922B841741F1164870403A3241C0CFD5562A8417418D0F7A363F3A324130C954C1358417416C226C583C3A3241A0B7408250841741D8F97E8A273A324110151D491285174198DD9307293A3241A09318841385174113F241EF413A324160BC05922B84174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB4236ABE343A324191E104DD9E841741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.530' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.530' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7894678, NULL, 1, NULL, 0xBD0B0000010405000000B61E850BD61C3041302FDD64084021413FC6DC95D51C304120431CEBA740214186DB68C0071D3041805149DDA74021411B7C6112081D3041A02C431C08402141B61E850BD61C3041302FDD640840214101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9D698FDEEE1C304183F3E31B58402141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.543' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.543' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090199, 35721061, 1, NULL, 0xBD0B0000010405000000840D4FAFA92D2C41D4D781B310A13041E46800AFA02D2C41ECA067D316A13041FF3A70CEDD2D2C41F0A067932DA130410AF241CFE62D2C414CF38E7327A13041840D4FAFA92D2C41D4D781B310A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C24C814BFC32D2C4101577E231FA13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.557' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.557' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8442827, NULL, 1, NULL, 0xBD0B000001040500000065CC5D0BC6522B41B03E571B14522341CA22DB79C8522B4100D578E956522341702BF6D7E6522B41A822DBB955522341A479C769E4522B41D0D781F31252234165CC5D0BC6522B41B03E571B1452234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4F1B7271D6522B418D0D8DEC34522341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.570' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.570' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13995561, 29843841, 1, NULL, 0xBD0B0000010405000000F126314865772B41307958E8DC64314114022B8764772B41706FF0E5BF6431413F355E7A50772B41F831E60EC06431414C6B9A3751772B41440E2D12DD643141F126314865772B41307958E8DC64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C88D64BE05A772B4151B74C7CCE643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.583' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.583' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8779074, NULL, 1, NULL, 0xBD0B000001040900000078E09C718C17334150DA1B7C16A21C4194D409C883173341F043FA6D19A21C41FEB27B927C17334180F90FE932A21C41E80434B17817334120F2B0507DA21C4144AD695E9B173341001FF4EC83A21C41769318C49C173341508FC27510A21C41FB770B5497173341F0D0B39912A21C41343333E3911733412051DA9B14A21C4178E09C718C17334150DA1B7C16A21C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA393AF548C17334160947D554DA21C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.593' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.593' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13602047, NULL, 1, NULL, 0xBD0B00000104050000000E363CDDE08E3241E06A2BF617261D411C0DE04DE28E3241003D9B5590251D415F7FD93DD88E324160E4F29F8E251D4156A835CDD68E32418012834016261D410E363CDDE08E3241E06A2BF617261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB7DA8A8DDC8E3241AA270F4BD3251D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.607' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.607' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9126279, NULL, 1, NULL, 0xBD0B000001040900000004AC1C3A92393241E065F7E40F8A1741E461A1369539324140AF25E4028A174148D8F02498393241E0C420B0F5891741172FDD049B393241905EBA49E889174131A2B4178C3932417019E2D8DA891741DA8173A6813932419069DE71D18917410946253577393241704CA60AC8891741BF1726937239324160F8C264F389174104AC1C3A92393241E065F7E40F8A174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6BED8BDA8539324198AF0181EC891741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.630' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.630' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 886874, NULL, 1, NULL, 0xBD0B00000104100000005F5DDCE638B03241508941E0E5771C41A43E575B45B032411075021A29781C41348941E048B032418070CE8826781C41621058B95BB03241E04B370918781C41B372687159B032412090A078C5771C416EF0852957B0324190D409E872771C41779CA2A355B03241E0ADD8DF3B771C4153499D3054B032415060E5D046771C4111D0443852B03241C0D1005E50771C419ED634CF4FB032410053052358771C4132C4B10E4DB0324170A8A4CE5D771C414CF38E134AB03241A00A462561771C4149C807FD46B032418093180462771C41470378EB43B0324170F7E46160771C413E13610347B03241504BC807D0771C415F5DDCE638B03241508941E0E5771C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC69A95B04DB0324126B57B7FC6771C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.640' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.640' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6914781, NULL, 1, NULL, 0xBD0B000001041700000030B29D4FCE6D31418075711BA3F719419231776DA96D3141B0BCE39499F719412085EB91F66D3141106A4DF31BF819418CEB5138006E3141005C8F422CF81941E4141DC9006E3141105EBA49B5F7194130B29D4FCE6D31418075711BA3F719413BCD3B2EA06D3141C07D1DB83FF81941B815FBAB976D3141203945C734F8194123FDF6D5916D314160D0B35941F81941D188D25E916D3141E0D7123244F819410E7A36FB906D3141E046033847F81941361136AC906D3141208A1F634AF81941CA20B072906D3141E03099AA4DF81941B99690EF8F6D3141F0891F63A7F819416FA3019CE26D314180703D0AC4F81941FF9908DBD26D314190E4F29F9FF81941D222DB99CB6D314180D0B3D98FF81941536B9A57C46D3141C0EBC0B980F8194122F46C16BD6D31418082514972F819412EA2B4D7B56D314130295C8F64F81941C0F5289CAE6D3141804DF38E57F81941B125E463A76D3141D0CB7F484BF819413BCD3B2EA06D3141C07D1DB83FF81941020000000200000000020600000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010C120E506BC76D31411A62A6DD2FF81941, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.653' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.653' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10318658, NULL, 1, NULL, 0xBD0B00000104050000007A0B240886F233417C5E29EB3291334106C58FB146F23341E44603782E913341A2703D4A39F2334148158C4AED91334185DB68A078F23341B811A5BDF19133417A0B240886F233417C5E29EB3291334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF43918A95FF23341F702BD1A90913341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.663' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.663' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12787540, NULL, 1, NULL, 0xBD0B00000104070000003BAB3ED725B13241409FAB2D267C1C413DBD529608B132410042CF66D97B1C4130FF21FDEEB0324150158C4ACE7B1C411E5A643B1AB1324150F38ED3CE7C1C4194B20CD149B13241401B9E5E717C1C41C29F1A2F4FB1324130B9FC07067C1C413BAB3ED725B13241409FAB2D267C1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4A5EC03321B1324180FC3A4B497C1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.673' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.673' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3780899, NULL, 1, NULL, 0xBD0B0000010405000000E4F97E2AB2822C41785305E347E82241A2C420F0C6822C4120287E8CFEE72241CCC56D3492822C416005A392EFE72241840D4F6F7D822C41E01DA7E838E82241E4F97E2AB2822C41785305E347E8224101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9554A32FA2822C4182FAABBA1BE82241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.687' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.687' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977580, 29839701, 1, NULL, 0xBD0B0000010405000000849ECDAAAF7A2B41D012F221D66431419F01BCC5AE7A2B41C0847C30BC643141D222DBB99A7A2B4198900F5ABC643141752D219F9B7A2B41CC1E854BD6643141849ECDAAAF7A2B41D012F221D664314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C29436132A57A2B41AF2AFB3DC9643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.697' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.697' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977865, 23695411, 1, NULL, 0xBD0B000001040500000070348037857A2B4154E3A5BB9064314145136143997A2B41F8FBA991906431410E83C08A987A2B41345A645B79643141DFB5847C847A2B41F05C6D857964314170348037857A2B4154E3A5BB9064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEF6488E08E7A2B41DA334E0B85643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.710' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.710' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11212527, NULL, 1, NULL, 0xBD0B0000010405000000ECB0504B95AB324100E78CA897641C4187A757EAA5AB3241908CB9EB58641C415340136194AB32410087A75702641C413980B76086AB3241C051B81E37641C41ECB0504B95AB324100E78CA897641C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C679E1CB995AB3241A61D8BD24B641C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.720' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.720' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11472031, NULL, 1, NULL, 0xBD0B0000010405000000871F632E52BC324120287E8CFF461D417E2F4C2648BC324170D712722D471D41FD87F49B52BC324120E9B72F4F471D41303333F35CBC324140166A4D22471D41871F632E52BC324120287E8CFF461D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEF6C497F52BC3241672E658227471D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.733' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.733' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083566, 14745831, 1, NULL, 0xBD0B0000010405000000118C4AAAC36E2B41B442ADA98F6431416A1283C0C46E2B4130431C2BB4643141AC7268D1D86E2B41C030990AB4643141CE56ECAFD76E2B41100BB5868F643141118C4AAAC36E2B41B442ADA98F64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC872333BCE6E2B41D87638DBA1643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.743' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.743' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13873695, NULL, 1, NULL, 0xBD0B00000104060000003889410062F23241809A771CAF831C41F9A0677363F23241F0CFB3D93C831C41F3065FB864F2324130516B9AD9821C4160C3D30B53F23241502CD41AD6821C41E10209CAD1F13241F05AD33C94831C413889410062F23241809A771CAF831C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF2DE7D4932F23241EF7A0F0857831C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.753' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.753' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5056144, NULL, 1, NULL, 0xBD0B0000010409000000E04F8D578E523141D07E6ABC60D21C419406F0F69A5231419074931843D21C41E8D9ACDAA252314100AF946531D21C414A94F6E6B4523141F0EB2FBB08D21C4177931804B7523141608FC2F503D21C4152621058B752314110EEEB4003D21C4156B1BF0CCA52314100759318D6D11C416BF7E4C182523141B03767C422D21C41E04F8D578E523141D07E6ABC60D21C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C513205B59E5231410326D47F1DD21C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.773' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.773' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14042231, NULL, 1, NULL, 0xBD0B0000010410000000F4C9C302EA993341E0DF2D10F24F1C41986E1203E1993341A0C64BB7D64F1C415EEE5A22D8993341E01114BFBA4F1C4133772D61CF993341B079C7299E4F1C4100F775C0C6993341604772F9804F1C41BB64AA40BE99334120C52030634F1C41285C8FE2B599334190F2B0D0444F1C41F241CFA6AD993341808863DD254F1C41FF43FA8DA5993341D03D7958064F1C410EC7BA989D993341905CFE43E64E1C415C4BC8C795993341A02E6EA3C54E1C41B21C5A448C993341F061A1569C4E1C4163A1D6D4C699334100780BA48B501C41A52C435CFC993341E0D022DB26501C413A80B720F3993341E0A679C70C501C41F4C9C302EA993341E0DF2D10F24F1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C26216C62C5993341A94C750BD04F1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.783' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.783' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8803277, NULL, 1, NULL, 0xBD0B00000104060000007C734634AA8C3141806DC5FECD4D1C41FA97DD13968C314100014D04D04D1C41F8CBEE69918C3141F0DE4F8D364E1C41848EE452908C3141006F81844E4E1C41CE915CDEA48C3141708EE472424E1C417C734634AA8C3141806DC5FECD4D1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFABCA63A9D8C31413498D7C50B4E1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.810' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.810' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3862747, NULL, 1, NULL, 0xBD0B0000010410000000FCC2646AA3AD3241D0891F63206E1C410E9C33E2A5AD324180734694156E1C41792497FFA6AD324130EA95B2106E1C41FAA067D3A8AD324160A0F8B1086E1C41703480F7C0AD324120917EFB9E6D1C4194FF905EBBAD3241502FDD24826D1C416B88637DA8AD324160F38ED3D46D1C41A5ADD81F96AD3241200BB5A6936D1C41BCD100BE92AD324180AEB662A26D1C412AED0DDE8CAD3241B047E1FABB6D1C41FEFFFFBF8BAD3241608716D9C06D1C419CDD934789AD3241709A779CCB6D1C41140DE0BD8FAD324160795828E16D1C4129A0894096AD324150226C78F66D1C41674469CF9CAD3241804C158C0B6E1C41FCC2646AA3AD3241D0891F63206E1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF262DC4FA3AD324168DD5BF4D06D1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.833' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.833' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14413027, NULL, 1, NULL, 0xBD0B0000010405000000C5293A729B8A324130302A298CEB1B4185416065988A324180855AD3D4EB1B41E6482E5FB58A324180C3D32BD9EB1B4150B81E25B68A324110E7FB2990EB1B41C5293A729B8A324130302A298CEB1B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF8D2A5D3A78A324172FBAE13B3EB1B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.847' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.847' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13772341, NULL, 1, NULL, 0xBD0B00000104050000006D8A8E84BBBA324160FE437AD9EB1C41EA043431AABA3241F0156ACD0EEC1C4138D6C50DBCBA324130AB3ED736EC1C41CA073D7BC5BA324150CDAACFEFEB1C416D8A8E84BBBA324160FE437AD9EB1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2294B12DB9BA3241777EACAC06EC1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.857' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.857' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2344700, NULL, 1, NULL, 0xBD0B00000104050000001DF46C365CBC3241E05452A7D1461D41871F632E52BC324120287E8CFF461D41303333F35CBC324140166A4D22471D419D703D4A67BC3241F067226CF5461D411DF46C365CBC3241E05452A7D1461D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C96E1B1AE5CBC32415B5D951FFA461D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.863' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.863' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6934510, 4034261, 1, NULL, 0xBD0B00000104080000000A8195A31F4B3441D02A1815057A1F41FC3A706EED4A3441206519E23F791F4121F46C969C4A344130E63F24EF7A1F413290A0F8A04A344180029A08037B1F41B147E1DAE74A3441A0E09C91407C1F4104E78CA8134B344140CC5D4B2F7B1F41EF8E53143A4B34412075029A3F7A1F410A8195A31F4B3441D02A1815057A1F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C7CA25022EA4A3441DA7ECBBAB67A1F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.873' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.873' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3842894, NULL, 1, NULL, 0xBD0B0000010410000000B68D06101D51354148C807BDA99A2341A43C2C1436513541D0EEC903B39A23411504569E2A51354150C6DCF5AC9A234143CF66051F513541F0B19D0FA89A23416129CB501351354140211F54A49A234198D40988075135415838D6C5A19A2341CB20B0B2FB503541E04A5966A09A234188EB51D8EF503541C0469436A09A234197BB9600E4503541E861A136A19A2341E0E00B33D85035417038D665A39A2341F0384577CC503541A000DEC2A69A234162A1D6D4C05035416003784BAB9A2341C620B0F2BC50354138FF21FDAD9A2341226C783AAC503541D041CFA6B79A2341B059F599B6503541181B9EDEBC9A2341B68D06101D51354148C807BDA99A234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5C525603E45035414A17E6AAAC9A2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.890' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.890' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13252984, 35753961, 1, NULL, 0xBD0B0000010405000000F14A5946CF2E2C41E87A148EE0A03041AFF3FD54CF2E2C4118FBCBCED8A03041CA2B6519932E2C4158C8071DD9A0304180D93D39872E2C410C2428DEE0A03041F14A5946CF2E2C41E87A148EE0A0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CED61752DAE2E2C4179E99CF3DCA03041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.900' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.900' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10319310, 4876801, 1, NULL, 0xBD0B000001040A000000A7F1D2ADF1B83241C0ADD85F22592B41BDD32B05ECB8324108EBE2366B582B41D9D781B3EAB83241F865F7A431582B415C17B73192B8324190D6346F44582B4182D0B319A0B83241704694F6595A2B41FC21FD16A2B8324180C954415A5A2B41E1C7985BC6B83241B07346945F5A2B41E293878500B93241D87F48FF8A5A2B41B1726831F5B83241F03D791894592B41A7F1D2ADF1B83241C0ADD85F22592B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4AD8C2A2C7B83241A95B2D2C56592B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.913' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.913' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12909599, 1050901, 1, NULL, 0xBD0B00000104090000009A18045639E12641F08AFDA5B49E32413EBD52D666E1264118197337A59E3241328716995BE12641DCD022DB9C9E3241FB5C6D4533E1264144795888AA9E3241FE5C6D0532E12641ACFC87F4AA9E324197923A6134E1264134CF6645AD9E3241AA1C5A6436E126418C9ECDAAAF9E32410E31080C38E12641E01B7C21B29E32419A18045639E12641F08AFDA5B49E324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA08F87B84BE12641E89F376BA89E3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.923' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.923' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13995588, 29846571, 1, NULL, 0xBD0B0000010405000000201FF46C3C772B41F40FE937C06431413689416028772B4120F77560C064314126F46C1629772B41D8A59B64DD643141509D80263D772B414CE3A53BDD643141201FF46C3C772B41F40FE937C064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C77C085C232772B4136C590CECE643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.933' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.933' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9742522, NULL, 1, NULL, 0xBD0B00000104070000002A1895F41EF83241C0DCB584E2DD1C41DE7A14CE50F8324110EE7C3FECDD1C4175029AE84FF8324180F1D2CDDFDD1C41E44F8D7748F832416082E2477EDD1C41FCA9F1D247F83241901A2FDD75DD1C41CDD5568C1CF8324150401361D2DD1C412A1895F41EF83241C0DCB584E2DD1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C02A00BD43AF832418DBD2D5DC0DD1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.947' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.947' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14116103, NULL, 1, NULL, 0xBD0B0000010406000000C20E9CD3BBEE3241E06C56FD6D861C41EE1FD2EF14EF3241F07D1DB8F1851C415B204151CFEE3241F0073D9BE3851C41D066D50773EE324120B150EBD0851C41482EFFC16FEE324140A91350EB861C41C20E9CD3BBEE3241E06C56FD6D861C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C845366F7A6EE32418DFF34F237861C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.967' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.967' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13601717, NULL, 1, NULL, 0xBD0B000001040600000009B5A6B9FD8E3241703F35DEB3261D41A73E57DB078F3241B0550E2DB5261D418D5374E4088F32411024287E32261D4121EBE296048F3241506519E231261D417458A8D5FE8E3241D0DEE00B31261D4109B5A6B9FD8E3241703F35DEB3261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C10385C53038F3241E451EF3973261D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:14.980' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:14.980' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12457701, NULL, 1, NULL, 0xBD0B0000010409000000E62631083B2C3641C80E9CF3E2D1204160EE5A82442C3641709318A4EDD12041802F4C164E2C3641D05817F7F7D1204153FC18C3572C36411871ACEB01D220414082E287612C364150B7D1800BD22041E2361AA07B2C3641D0FBA9F1DFD12041B3EA73D5612C3641582EFF61A2D120418F4AEAC4612C364140355E3AA2D12041E62631083B2C3641C80E9CF3E2D1204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3C52B2575D2C3641B8E9E2AEDAD12041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.000' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.000' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12916421, 90084130, 1, NULL, 0xBD0B00000104040000009128ED8D4BFD2E41E0E995F2C7442F4106F7756045FD2E411841F163C3442F41B90E9CF348FD2E411024287EC9442F419128ED8D4BFD2E41E0E995F2C7442F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC564AAA048FD2E4103C58FF1C6442F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.010' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.010' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9987088, 90054577, 1, NULL, 0xBD0B000001040D000000199E5E6985F63041E80B93E992EE2F41EA51B8BE68F63041D066D5A790EE2F41D3F7538364F6304120136183EBEF2F41A6A44E8064F6304110363C7DECEF2F416E3480D763F63041E882518922F02F41F041CF0673F63041B8F3FDD444F02F41F56C56CD76F6304130FBCBEE1AF02F410E363C0D7AF6304110C898DBF0EF2F41D78AFDC57CF63041B0490CA2C6EF2F414F7424F77EF63041F8DD02499CEF2F41D14D62A080F6304190C64BD771EF2F41FBE461C181F63041202AA95347EF2F41199E5E6985F63041E80B93E992EE2F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4F18085173F63041C043071D55EF2F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.020' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.020' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10475915, 4691881, 1, NULL, 0xBD0B0000010405000000F575E05C9AD43241101AC05B6B0F2B41D15D4B0898D4324120B5A679C10F2B416B19E29849D5324108E02D90D20F2B41C0F5289C5CD5324160F5B9DA7B0F2B41F575E05C9AD43241101AC05B6B0F2B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD33FEF99F6D43241025CCC359E0F2B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.047' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.047' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3314448, NULL, 1, NULL, 0xBD0B00000104050000000DE02DD0EABC3241E0FBA9718CC41C412C08AC5CECBC3241904ED111F8C31C414AB6F33DD8BC324140C4B1AEF4C31C4186B0E1E9D6BC324160B20CF173C41C410DE02DD0EABC3241E0FBA9718CC41C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE8DC92D6E1BC3241C50B63763BC41C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.063' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.063' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10806121, NULL, 1, NULL, 0xBD0B0000010407000000738A8E44D57C32415005A3120C7D1C418F180456D47C3241C08251C9727D1C4106F9A067D37C3241E06A2B76D97D1C4194976ED23B7D3241D0E76AAB517C1C41B3BFEC9E3C7D324130DBF97EFA7B1C4199B20C71D87C324140C4B12EAE7B1C41738A8E44D57C32415005A3120C7D1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD76D20A6FC7C3241B194E71A887C1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.087' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.087' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10465677, 36303491, 1, NULL, 0xBD0B000001049A000000A82C437C036B34415807CE79D4C73241CBB12E4E026B3441F4DBD751D8C732412B0F0B25016B344160CC5D2BDCC7324188D2DE00006B34416C666606E0C73241880D4F8FFE6A3441240AD723E5C73241DAA3709DFD6A3441CCDEE07BE7C732416B006FD1FC6A3441F8DBD7E1E9C732414CDA1B2CFC6A34411C6A4D53ECC73241E17A14AEFB6A3441200DE0CDEEC7324108F9A017FC6A3441144FAFC4F2C732410DF2418FFC6A344104CCEEB9F6C732414AD8F014FD6A34415C8863ADFAC732415A39B4A8FD6A3441B4BFEC9EFEC73241CE2B6559FF6A34411085EB3109C83241E7263188016B3441C4BAB8AD13C83241F997DD33046B3441B80C710C1EC83241D7F0F45A076B34419CEB514828C832411071ACFB0A6B34411C3A925B32C83241D9CEF7130F6B3441E42D90403CC83241C84B3739116B344138E6AE5541C832417468914D136B344170C0CA7146C83241AE7BF250156B3441144FAF944BC83241E7C03943176B34410C2428BE50C832410022FD76186B34414482E2E753C83241A033A294226B3441780E2DB254C832416791EDFCE86B34417CD7123264C83241A7A44ED0EA6B34417017B7015BC83241AE2E6E93EC6B3441783F35CE51C8324142BD5246EE6B3441FCF8A09748C8324190C2F5E8EF6B34419C081B5E3FC83241AE9465E8F26B344178E09C1125C832418151497DF56B3441CC22DBB90AC83241703480A7F76B3441E03D7958F0C73241A5CFD566F96B3441EC482EEFD5C73241CE073DBBFA6B3441C43FA47FBBC732414F621068FB6B3441B442AD79ADC73241D6F97EFAFB6B3441BC4082729FC73241265C8F72FC6B3441ECC2646A91C7324185FB3AD0FC6B3441BC1B7C6183C73241457B830FFD6B3441102FDD546DC7324126C286C7FC6B34414079584857C732418AEB51F8FB6B344124BB273F41C73241B6490CA2FA6B34414CD1913C2BC7324182FB3A10FA6B3441C4DCB5E421C732412AC28687F96B34411448508C18C73241B09DEF07F96B3441F4A067330FC7324126C286C7F86B34415CA60AE609C7324131A2B4D7F56B3441701283C001C73241895AD30CF36B344128ED0D8EF9C63241E2581767F06B3441840D4F4FF1C632410E0BB5E6ED6B3441984AEA04E9C632414872F96FEB6B3441ECFDD468E1C63241A1A22389E86B3441D8DCB5F4D9C63241104FAF34E56B3441704DF3AED2C6324128068175E16B3441587FD99DCBC63241CC073D2BDE6B344140840DBFC6C632417ABE9FAADA6B344138B4C806C2C63241894160F5D66B3441D46F5F77BDC63241AEFA5C0DD36B3441D0172613B9C632418A416065CA6B3441A8ADD80FB0C6324136234A6BC16B34411C04565EA7C632412C651922B86B3441C01B7C019FC632411C1FF48CAE6B344160DA1BFC96C6324154840DAFA46B3441907BF2508FC63241E995B2EC976B3441AC1A2F8D85C632416ABC74E38A6B344128A7E8287CC63241073411967D6B3441704F1E2673C63241418B6C07706B34417826C2866AC632414CC8079D656B3441EC53E37564C632416A91EDEC5A6B3441F8A067E35EC6324130FF21FD4F6B344194976ED259C6324156D3BCD3446B3441C8AACF4555C63241FE21FD76396B344144A9134051C63241805149ED2D6B3441F8D781C34DC63241C2E3143D226B3441F4BB05D24AC632417F51496D186B3441E4B050EB48C632416B6666860E6B34415432559047C6324112E02D90046B3441E0F21FC246C63241FBB27B92FA6A3441A8C9548146C632418AA7571AF66A344164BA49BC46C63241E6839EADF16A3441F80FE96747C63241CE6F5F57ED6A344174CE888248C6324146257522E96A3441109E5E094AC6324160EE5A82E36A3441F07C3FA54CC632410CA5BD21DE6A3441441AC0BB4FC6324171B5150BD96A34416494F64653C63241E9263148D46A344198E4F23F57C63241D14D6270CE6A344158BC74035DC6324152621008C96A34410800003063C63241BBB88D16C46A344160A835BD69C6324197779CA2BF6A3441A08026A270C63241E80434A1BC6A3441D87E6A1C76C63241FA065F38BA6A34415C5227E07BC632410812146FB86A344134E8D9DC81C63241F6C2644AB76A34417CC9540188C63241E7839ECDB66A344140FAED3B8EC632417AC729FAB66A3441C810C77A94C63241784F1EC6B76A34414C17B7319CC63241CCDCB5F4B86A3441A415FBDBA3C632413BEF3885BA6A3441E0A59B74ABC63241E961A176BC6A3441C498BBF6B2C63241A367B32ABD6A344120C05B90B5C632415EEE5AE2BD6A344100DE0229B8C6324127F6979DBE6A3441C864AAC0BAC63241B8AF0307C06A3441EC3FA4FFBEC63241676666C6C16A34415896211EC3C632411FA7E8D8C36A344194416015C7C632416CB5153BC66A3441DC88D2DECAC632414FA60A76C86A34414CC28647CEC632418E3A01ADCA6A34411C73D7B2D1C632418EE4F2DFCC6A34416880B720D5C632416C666666CF6A34411041F173D9C63241E5C03993D16A3441C0CFD5F6DDC63241F8A9F162D36A3441540E2DA2E2C632415005A3D2D46A3441043B706EE7C632413A234A0BD66A3441A01E855BECC6324158A8352DD76A3441745F074EF1C632413E795838D86A3441FC938745F6C63241085F982CD96A3441206EA341FBC63241432CD42ADA6A34414003782B00C73241E61DA758DB6A34411083C00A05C73241C4CAA1B5DC6A34417C11A5DD09C7324118AE4741DE6A3441C00968A20EC7324197C42020E06A3441C832C43113C732413FAD696EE26A3441C003E78C17C73241BAB88D26E56A3441BC4B37A91BC732416CF7E441E86A34419C23B97C1FC73241BFD32BA5EA6A344188FB3A2022C7324100B37B12ED6A344158158CBA24C73241BF42AD89EF6A34415003784B27C73241314CA60AF26A3441708EE4D229C7324126C286E7F56A3441242653C52DC732419206F076F96A3441509621FE31C732412241F1B3FC6A3441B06F5F7736C73241B059F599FF6A3441889ECD2A3BC73241F4EBC049046B34414CE3A59B43C73241E76A2B86086B3441ACABAD484CC7324178832F4C0C6B34410871AC2B55C73241A0A223990F6B3441B8915C3E5EC73241D956EC5F116B3441BC47E1EA64C7324100B37BA2126B3441047D3FB56BC73241F831E65E136B34413433339372C73241C2051294136B3441C0506B7A79C732412EDD2456136B3441D4C3428D81C73241686666C6126B34412431089C89C73241BCF3FDE4116B3441D0D781A391C73241A86054B2106B344184DB68A099C732412363EE9A0F6B3441B476BE4FA0C73241FDD478790E6B34411C166AFDA6C732416D5F074E0D6B34411C9E5EA9ADC7324195E61D670B6B3441BCB6627FB7C7324116AE4721096B344128772D41C1C73241FB6C567D066B34419C5E29EBCAC73241A82C437C036B34415807CE79D4C7324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9009376D6A6B3441AC1DD65A56C73241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.097' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.097' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977890, 906671, 1, NULL, 0xBD0B000001040500000070C5FE329F772B41CCF97EAA90643141852F4CA69E772B41BC9BC4807F6431419487859A8A772B414C158CAA7F6431417F7AA52C8B772B410498DDD39064314170C5FE329F772B41CCF97EAA9064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8C5923E894772B41C8D8072A88643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.107' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.107' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14411784, NULL, 1, NULL, 0xBD0B0000010408000000FC770B448E273441F0B359752F001E41B2E1E99585273441F0B35975CAFF1D4138234ADB7B2734416020417159FF1D415B8638D64D27344130F2414F19FE1D41E324060142273441A0B4377820FE1D41C0D32BA531273441805AD33C52FE1D414CD191DC7B273441C054C1A8CFFF1D41FC770B448E273441F0B359752F001E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C955FD8945D2734413C23E53BE9FE1D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.113' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.113' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10459171, 17743441, 1, NULL, 0xBD0B0000010405000000000000809582324130B072A8AB4A2E4137674429A0823241803BDF8FAC4A2E4181C0CA01A2823241B01C5A64544A2E41BA270F8B9782324138BA490C4A4A2E41000000809582324130B072A8AB4A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C098DA1B69B8232411913029E7D4A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.123' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.123' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5246881, 35362191, 1, NULL, 0xBD0B000001040E000000663BDF0F4A0E2E411C7E8C59A31430411963EEFA300E2E41F40DBE80A51430413B2575C2170E2E41E0051234A71430418616D96EFE0D2E414C1CEB72A814304197CB7F08E50D2E416091ED3CA914304177BC7453CD0D2E4138E17A54AB1430413D60E5D0B30D2E416CA1D694AD14304142B6F37D3A0D2E41B83E571BAE143041C20E9C73900C2E4138F697DDBC1430417DC954C11D0C2E41B425E44399143041AB946548220C2E41DC56ECAF4A153041F1B9DACA3A0D2E41FC94D46949153041244A7B434A0E2E41BCE8482E48153041663BDF0F4A0E2E411C7E8C59A314304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC601E9F9360D2E41DD32DB83FB143041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.133' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.133' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226177, 90073094, 1, NULL, 0xBD0B0000010405000000604469AF252E2C412CF38ED33FA1304155840D4F1A2E2C418C855A7347A130412DBB274F612E2C41302AA9F346A13041BA9F1A2F612E2C41D8D781533FA13041604469AF252E2C412CF38ED33FA1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C367B539A402E2C415B953B8043A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.143' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.143' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977776, 23694761, 1, NULL, 0xBD0B0000010405000000E5ACFA1CF8792B417C9ECDAA7A643141DF1B7CE1F8792B4180B740E291643141ABFA5CED0C7A2B4128D9CEB7916431417D9ECD2A0C7A2B41AC9BC4807A643141E5ACFA1CF8792B417C9ECDAA7A64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB4EF9E85027A2B4192CC383186643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.153' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.153' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977954, 23708441, 1, NULL, 0xBD0B00000104050000000BA5BD8162772B41805149FD7F6431413CE17A1463772B41BCAF0327916431410FAE472177772B4104363CFD906431414C840D8F76772B41D8D781D37F6431410BA5BD8162772B41805149FD7F64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CCC03A3D16C772B412E6B397D88643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.167' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.167' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3175944, NULL, 1, NULL, 0xBD0B00000104130000004060E57033B13241E0C039A339F21C41714694560AB1324140D26F5F58F21C4171CE8812CAB0324190779CA288F21C4181B740E2A6B03241B0FCF6F5A2F21C41F0F44AD9A6B03241B023B9FCA2F21C41B0B6623FACB03241806891EDD3F21C41BFCAA145ACB0324180B0E1E9D3F21C415A0E2D72C9B03241C0263188C3F21C410444FA0DCAB0324130333333C3F21C418E3A01AD1CB13241203B70CE94F21C41516B9A5720B13241809FABAD92F21C41477B83EF28B13241B0ABADD88EF21C41B9847C9031B132418075719B8CF21C417D58A8353AB13241A021FDF68BF21C41AC506BDA42B1324150FAEDEB8CF21C41A9ADD85F4BB13241C069DE718FF21C4193976EF24AB13241908C4AEA8DF21C414CF38E733EB132415092CBFF60F21C414060E57033B13241E0C039A339F21C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6BB41C37FAB032416114FC6888F21C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.177' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.177' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14297701, NULL, 1, NULL, 0xBD0B0000010406000000ABDFBE4E5B91324100CE1951990E1D4189F4DBB768913241C032C431670E1D4154E3A5BB69913241C019515A060E1D4166F7E4A1559132414055302A040E1D41497B830F54913241B0270F8B980E1D41ABDFBE4E5B91324100CE1951990E1D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDFBD3A415E91324131737D3F480E1D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.187' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.187' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2135469, NULL, 1, NULL, 0xBD0B000001040900000029F6977D77A2334180787AE5FE7B23413CCD3BCEDCA2334158F2B0D01D7C2341CABAB88DD9A23341F031E62EEC7B2341F1D24D42D6A23341E08C28EDB97B2341EEA7C60BA4A23341A801BC05AB7B234149EA04349EA233415096214EAF7B2341B025E4637EA233410868222CA57B23412FBB276F79A23341D88C28ADE57B234129F6977D77A2334180787AE5FE7B234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA94CB1F7AAA23341A99BE10FE07B2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.197' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.197' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14194589, NULL, 1, NULL, 0xBD0B000001040400000088D2DEA04C5E3541A01726D39D1C244101000080665E354148166A4DCC1D24412F4CA68A725E3541B064AAE0A31C244188D2DEA04C5E3541A01726D39D1C244101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3D0AD7E3615E3541338613AB041D2441, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.207' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.207' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10418563, 16707721, 1, NULL, 0xBD0B0000010405000000590E2DD252823241007D3FB5304A2E4137894120528232415839B4484F4A2E4155643B3F7882324100295C8F524A2E4176E926F178823241C847E1FA334A2E41590E2DD252823241007D3FB5304A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6365CF886582324128050FA2414A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.217' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.217' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14880598, NULL, 1, NULL, 0xBD0B0000010407000000CEAACFF5682B38418889B02109C3224198559F4B732B384188F6061F08C32241B8627F39842B384190C2F52894C22241A023B99C5D2B3841E8F97EEA89C22241BCF528BC4F2B3841A067B36AE3C222410E583914552B3841A81726D3F7C22241CEAACFF5682B38418889B02109C3224101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5BD70024692B3841250FB17DC7C22241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.227' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.227' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5726981, NULL, 1, NULL, 0xBD0B0000010404000000E00B93C936363241C06054D27FCD1741D16F5F4736363241A08CB9EB8FCD1741FA31E60E383632417026538582CD1741E00B93C936363241C06054D27FCD174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C398F9D0A3736324145B1751686CD1741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.243' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.243' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10459227, 17743281, 1, NULL, 0xBD0B0000010405000000F9285CEFB68232412885EB11694A2E412D90A078AC823241B047E1BA5E4A2E41CC20B0D2AA82324130B4C876AD4A2E41C0F5287CB5823241983F355EAE4A2E41F9285CEFB68232412885EB11694A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD73FFAD0B0823241832E43D9884A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.257' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.257' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3940934, NULL, 1, NULL, 0xBD0B0000010405000000C810C79A5DC3354100B5A6B9A8A923413680B7C040C33541D088D25E5AA92341ED1FD20F30C33541003D9BD5A3A92341C2A8A48E33C3354140378901AEA92341C810C79A5DC3354100B5A6B9A8A9234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3EA2BE4C44C33541524B0B3090A92341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.267' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.267' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090121, 35720571, 1, NULL, 0xBD0B00000104050000002EBB27CFCD2D2C41A445B633F8A03041C49F1AEF0A2E2C410861C3F30EA1304115FBCBEE132E2C414CBC74D308A130410FE9B7EFD62D2C4150F38E13F2A030412EBB27CFCD2D2C41A445B633F8A0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C303F74E0F02D2C411A5B638100A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.280' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.280' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977636, 29846601, 1, NULL, 0xBD0B00000104050000001A95D4894A7A2B4198E4F2FFBC643141B5C8767E367A2B417CF08529BD64314167E5D062377A2B4114A3921AD7643141C5B12E6E4B7A2B41AC7268F1D66431411A95D4894A7A2B4198E4F2FFBC64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CBB7959F6407A2B4141895C0DCA643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.300' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.300' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8452792, NULL, 1, NULL, 0xBD0B0000010406000000D60968028EBB324160DA1B7CF6B51C41B940822295BB3241A0211FF4DCB51C41F42FBB0797BB3241F01114BFBAB51C41C217261369BB3241001058B9B2B51C41A7BDC17768BB324130F8C2E4EFB51C41D60968028EBB324160DA1B7CF6B51C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C19FF6F867EBB32411A97272CD4B51C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.310' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.310' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12572021, 13415831, 1, NULL, 0xBD0B0000010405000000788104854220224110849E0D12FA2D41FCE68C683C202241905374E4C5F92D41FE088A1F1E202241083B704EC8F92D41BA7D1D382420224160E9267114FA2D41788104854220224110849E0D12FA2D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C78A6955130202241B5C6192DEDF92D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.323' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.323' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 1179217, NULL, 1, NULL, 0xBD0B0000010405000000421CEB027FAB3241804D629055631C41964C150C6FAB32413009F920FE621C41F28E53345EAB32414039B4483E631C419A081BDE6CAB32418069DEF199631C41421CEB027FAB3241804D629055631C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC9FE11616EAB324171EA5B7A4B631C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.333' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.333' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8803293, NULL, 1, NULL, 0xBD0B0000010405000000764F1E76D28C31412046B6F3C94D1C41FB5C6D65C88C3141A0D85FF6CA4D1C41287E8CF9C38C3141E0C876BE2A4E1C4129287E8CCE8C3141A0BB96101F4E1C41764F1E76D28C31412046B6F3C94D1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEC514D3ECB8C3141EF1D8FC1F74D1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.347' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.347' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10912185, NULL, 1, NULL, 0xBD0B0000010449000000C7A14516E6E23241704ED111FDF22A41683BDFCFE1E2324100508DD708F32A41B447E17ADDE23241B064AA6014F32A41E04F8D17D9E23241106822AC1FF32A416B6666A6D4E23241A8A223B92AF32A4198DD9327D0E232413894F68635F32A4174AC8B9BCBE23241004FAF1440F32A4199779C02C7E23241F0E461614AF32A4130FF215DC2E23241A80C716C54F32A41480378ABBDE2324140A1D6345EF32A416F5F07EEB8E2324198C729BA67F32A41C0D32B25B4E2324168EC2FFB70F32A41EB043451AFE2324130A2B4F779F32A4172CE8872AAE2324148C4B1AE82F32A41E20B9389A5E23241E83FA41F8BF32A415A7DAE96A0E23241405EBA4993F32A4160FE439A9BE23241A00C712C9BF32A41A033A29496E2324118CB10C7A2F32A4111143F8691E23241F0BD3019AAF32A4116C05BA089E23241988BDBE8B5F32A41684469AF81E23241E0BE0E5CC1F32A41F997DDB379E23241580E2D72CCF32A410144FAAD71E23241B8F97E2AD7F32A414B2EFF8168E2324160A0F831E3F32A41ED1648505CE23241604469AF11F42A41FE21FDB65DE23241C0FEB27B8FF42A4175832F4C0BE33241E0718A4EB8F22A41DA12F2010FE33241F847503CAEF22A41153FC6FC10E33241C05B20016DF22A41BA15FB6B0DE3324150C0CA217BF22A415A302AC909E3324110CE191189F22A412918951406E33241C84C84CD96F22A41C2A8A44E02E3324158863856A4F22A41516B9A77FEE2324180B0E1A9B1F22A412DB29D8FFAE23241484BC8C7BEF22A41C58F3197F6E2324118FBCBAECBF22A4171567D8EF2E23241E863CC5DD8F22A41AFE1E975EEE23241F00512D4E4F22A41C9BAB84DEAE23241F8164810F1F22A41C7A14516E6E23241704ED111FDF22A41A879C7E9F6E13241D8E3839EC4F42A4184FD6517BEE13241F8065F5844F52A417B36AB9EA2E1324180F4DB1782F52A41365EBA69A2E13241C0A8A48E82F52A4132DD2466A2E13241F805819582F52A41733D0A9700E2324148014D448CF52A412A75025A4AE232410871AC0BC4F42A41A067B3CA47E23241F823283EDEF32A418D4AEAB440E23241001973F7E9F32A4110143F9639E2324170B5159BF5F32A41A4DFBE6E32E2324108DE022901F42A41BBC8763E2BE23241504013A10CF42A41AC72682129E23241C81726D30FF42A413B80B72027E23241E8B0504B13F42A4131C4B13E25E2324148E6AE0517F42A41D7A3707D23E2324118ED0DFE1AF42A4198C420D035E232411011C7FA4FF42A411573D79233E23241008195E353F42A41A9C64B4731E23241489ECDAA57F42A416F5F07EE2EE2324120B29D4F5BF42A4125C286872CE23241C83B4ED15EF42A41384ED1A120E232417009F98072F42A413789412015E23241D82B651987F42A41645452070AE232413005A3929CF42A41C4073D5BFFE13241C01C5AE4B2F42A41A857CA72FBE1324148197317BBF42A41A879C7E9F6E13241D8E3839EC4F42A41F97E6A9C0BE33241F841CF261EF32A41A48251C962E23241F81DA768E8F42A41F3A7C60B25E23241485BB1FF8FF52A4162984CF5F7E232412832E6AEA5F52A413889412009E3324120EF380570F32A41F97E6A9C0BE33241F841CF261EF32A410300000002000000000228000000024300000004000000FFFFFFFF0000000006000000000000000003000000000100000003000000000200000003, 0xBD0B0000010C193657748AE232419622DD51B0F42A41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.357' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.357' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9911413, 11272431, 1, NULL, 0xBD0B0000010409000000CF5D4B4824713641A0C42070B62C234140355E7A19713641C834EF780D2D2341E44F8D575B713641E88C28AD192D2341546210385D7136415814AE07D92C234185A7570A57713641C86F5F87F72B234154F5B99A49713641405EBAC9A72B23416A19E2B82A71364160613215A22B23416F810445257136419887855A8C2C2341CF5D4B4824713641A0C42070B62C234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3F8F72F93E7136414416FC196E2C2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.367' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.367' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8451940, NULL, 1, NULL, 0xBD0B00000104060000008616D9CEEE522B41F8C186A730532341798CB96BD0522B4188F831E631532341C698BBD6D4522B41C0E3145DAB5323416C2D211FE1522B418806F0D6AA532341EFEBC039F3522B411897FF10AA5323418616D9CEEE522B41F8C186A73053234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAD937DD2E1522B416ECF1CFF6D532341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.377' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.377' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14291002, 90073250, 1, NULL, 0xBD0B0000010405000000CDE76A6BB02B224130894120E37F2C4172006F41922B2241905374E4E67F2C412095D409992B224178E2C7581D802C417C7CD033B72B2241302AA99319802C41CDE76A6BB02B224130894120E37F2C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE38F95BAA42B2241C16B4F3C00802C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.387' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.387' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13843095, NULL, 1, NULL, 0xBD0B0000010404000000C76D3400D1502B41ACCDAA4FE360314115FBCBEEC6502B415C204151D7603141549FAB2DC7502B41C4F5285CE3603141C76D3400D1502B41ACCDAA4FE360314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CBB02E45ECA502B41EF4B5C54DF603141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.400' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.400' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13998005, 23688481, 1, NULL, 0xBD0B000001040500000066D5E7EA82792B41140DE08DD8643141DE141D0982792B41FC87F49BBE643141164850FC6D792B41A813D0C4BE6431412D1AC0DB6E792B41586B9AB7D864314166D5E7EA82792B41140DE08DD864314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9A83F97278792B41E4AED1A9CB643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.417' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.417' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9680276, NULL, 1, NULL, 0xBD0B000001040600000084DB68407BA53241E054C12807881C41E2E995528AA5324100FED4F830881C41809543CB94A5324110AAF1D2F4871C41226C785A95A53241903D0AD7C9871C41AB3E577B96A53241C0AACF556A871C4184DB68407BA53241E054C12807881C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5515AABA8BA53241E1E86315DF871C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.427' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.427' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10459316, 5676271, 1, NULL, 0xBD0B000001040700000013C7BA98CF82324140BF7D1DAA492E414650FC98FA82324100C364EAAD492E410E022BE7FA823241B07268D1A2492E41A5605412F7823241A026C2869D492E4123386724F582324170226C7898492E41DCF0F40ACC823241E0065F9895492E4113C7BA98CF82324140BF7D1DAA492E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C896689B4E3823241053B86AEA1492E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.437' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.437' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 16622537, NULL, 1, NULL, 0xBD0B000001040F00000038DF4FED41D43641903480B74AA82441832F4C663BD43641187502DA30A8244117AE47A12AD436414068916D16A82441C56D3480ADD33641985374A404A82441AAF1D26DAAD336414811367C42A82441F63A70EEA5D3364148A1D6F49EA824414DD191BCA0D33641587958680BA924412F4CA68A9CD3364110D578E960A92441FFFFFF1F9AD33641F82553C592A9244160764F1E63D4364100AF25E4BAA92441F08E53346FD4364148B81E0501A924410F022B6765D4364108E63FE4E3A82441517424F75CD43641386C783AC5A82441E53FA47F58D4364130B07228B2A8244138DF4FED41D43641903480B74AA8244101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C114DFAD300D43641C333692FE9A82441, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.447' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.447' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11016906, NULL, 1, NULL, 0xBD0B00000104060000001648507C8DA532412051DA1B9C341D411AAE4701A6A5324120EA043440341D41443789C1ACA5324190B662FF29341D41B2BFECDEAEA53241A0F1414F39331D41550E2DF290A5324100E561A134331D411648507C8DA532412051DA1B9C341D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAD02097F9DA53241C5D5436FCE331D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.457' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.457' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9805699, NULL, 1, NULL, 0xBD0B000001041D000000E3A59B4497863541A8BAB8CDE7062741B68D061090863541F8A2923ADB0627417CE09C1199863541F0A9F112240727410EA5BDE1E586354198F5B9DAC807274123B072C8ED863541E861A1960A082741ED7C3F55F186354160643B1F28082741907EFBBA3287354180A7578A7A0827410FA5BDA140873541D8285C0F8C08274176A52C033A87354148D6C56D7C082741B29DEF8733873541080534916C0827418A0D4F2F2D873541487FD97D5C08274163FE43FA2687354188A0F8314C0827415A39B4E820873541482041B13B0827411F5A64FB1A8735411011C7FA2A082741728A8E04F0863541A02A1895AF072741C7FEB27BEA86354138B4C8F69F072741EC0434D1E4863541A05E298B90072741F853E305DF8635414872F94F81072741403EE819D986354160CB7F4872072741AEFA5C0DD3863541787CD07363072741346EA3E1CC86354190E1E9D55407274120FDF695C686354170B1BF6C46072741767AA52CC086354148EC2F3B380727415AC1A8A4B9863541D05B20412A07274144B6F3FDB2863541C06D34801C07274155F5B93AAC8635411023DBF90E0727412675025AA5863541408D97AE010727417D51495D9E863541E03FA49FF4062741E3A59B4497863541A8BAB8CDE706274101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2C3DC155E28635414779AF38B6072741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.470' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.470' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15102882, NULL, 1, NULL, 0xBD0B000001042C000000C1B359F5231629413CFF215D338430417CD93D7924162941F0B9DA8A35843041DD164870251629412CC4B1AE378430412BA2B4D726162941F8C9C3C2398430417C8CB9AB28162941FCAD47C13B84304184F4DB172C1629416C3255703F843041BC42ADA92F162941646666164384304184D2DE603316294150FC18B3468430417A832FCC3416294110BE30F948843041F0550E2D361629413460E5404B843041244A7B8337162941CC39238A4D843041928EE47237162941B8CFD5964F8430419406F03637162941183CBDA2518430418004C5CF36162941301FF4AC5384304186A52CC33B162941B0D6346F92843041AA4082A252172941EC2D90008D84304172226C7837172941D48173C6F9823041AD847C101E162941206A4D1304833041A64E40D3291629418073469454833041C498BBD6C5152941C000DE8256833041260F0B35C91529412897FF106B833041138C4A2ADA15294108560E6D7B833041C44B3789DF1529415C984C7586833041BFB359F5E7152941D0BCE3749B833041E1A59B84E9152941802D215FAE833041702BF697F315294174C1A8A4BC833041E36A2BF6F415294184613255CD8330417438D645F8152941401CEBA2DA833041D5F97E2AFE1529411CE25857EC833041061214FF0A16294168F90FA90784304192FF90FE191629412C08AC3C14843041D6B359B51C1629415CA4DF1E1D843041666666A61E162941B069DEB11E8430410F4FAFD41F162941CC33A2A42084304116FDF6B520162941E01B7CA12284304103DE024921162941A4EA73A524843041B103E78C21162941084D84AD26843041230F0B3521162941081895842884304126287E0C21162941C8C3425D2A843041A24E401321162941D04A59362C84304198B96B492116294150C4B10E2E8430414FB81E4522162941FCF675D02F84304156302A29231629419041609531843041C1B359F5231629413CFF215D3384304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C27C5F0AEA7162941592163C1C4833041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.480' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.480' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090130, 35720601, 1, NULL, 0xBD0B00000104050000007D16D9CEC42D2C41CC172653FEA030415A4469EF012E2C41CC0E9C1315A13041C49F1AEF0A2E2C410861C3F30EA130412EBB27CFCD2D2C41A445B633F8A030417D16D9CEC42D2C41CC172653FEA0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA89C37DFE72D2C4171E699A306A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.497' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.497' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977903, 23708601, 1, NULL, 0xBD0B000001040500000052AF94E512772B41100DE0CD91643141F616485012772B41D800DEA2806431418B5CFE43FE762B41F49E3CCC80643141ECF44AD9FE762B41C886A7F79164314152AF94E512772B41100DE0CD9164314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC254BF9408772B411EE3284D89643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.510' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.510' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8450919, NULL, 1, NULL, 0xBD0B0000010405000000C217261369BB3241001058B9B2B51C41F42FBB0797BB3241F01114BFBAB51C416A91ED3C99BB3241B0AF03E792B51C4110BE307969BB3241F0DF2D908AB51C41C217261369BB3241001058B9B2B51C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C17A44CB580BB32413C89F39AA2B51C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.520' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.520' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 23730307, NULL, 1, NULL, 0xBD0B000001040B000000297E8CD9FDF0324140BF7D1DE6851C41251895D410F1324110FCA97106861C4136234A1B23F13241505452A72C861C4103BC059234F13241D096FF9058861C412AE4831EF9F032410081954338851C4123FDF655CBF0324110A913D047851C4108560E4DA8F0324190AB3ED769851C41669A773CD7F0324170F2B0D072851C4184C0CA41D6F03241104B5906B8851C41D45D4B48EAF0324100D6C5EDCB851C41297E8CD9FDF0324140BF7D1DE6851C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2AB9C751F4F03241F47656AB9E851C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.530' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.530' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 23730307, NULL, 1, NULL, 0xBD0B000001040B000000297E8CD9FDF0324140BF7D1DE6851C41251895D410F1324110FCA97106861C4136234A1B23F13241505452A72C861C4103BC059234F13241D096FF9058861C412AE4831EF9F032410081954338851C4123FDF655CBF0324110A913D047851C4108560E4DA8F0324190AB3ED769851C41669A773CD7F0324170F2B0D072851C4184C0CA41D6F03241104B5906B8851C41D45D4B48EAF0324100D6C5EDCB851C41297E8CD9FDF0324140BF7D1DE6851C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2AB9C751F4F03241F47656AB9E851C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.540' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.540' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14341239, NULL, 1, NULL, 0xBD0B00000104160000006CD7127286793241704DF38EE3911C410724283E7A793241E075E09CE1911C41C01726133179324180DA1BFCD5911C41DAF0F40A2A793241F03FA4DFD4911C41E30B936928793241505452A797921C41614BC8C7EA793241E0B88D86B6921C41191DC985F379324190B1BFECB7921C41B025E4C3FE793241F0EA73B5B9921C4111143F863B7A3241601AC05BC3921C411CDBF95E3D7A32418051499D00921C412B7E8CF9247A3241301361C3FC911C4138B4C8960C7A3241C03FA4DFF8911C41B737F862007A324120711B0DF7911C4130BB272FF479324140A3923AF5911C416DA301FCE7793241C012F241F3911C4191C2F5C8DB79324130151D49F1911C41B66B0999CF793241F0809543EF911C4156302A69C3793241C0EC0D3EED911C412DA2B437B779324130F46C56EB911C410E143F06AB793241708A8E64E9911C411D4A7BA392793241F0240681E5911C416CD7127286793241704DF38EE3911C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C95984ED3B27932416C4199214C921C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.567' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.567' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13829726, NULL, 1, NULL, 0xBD0B00000104050000005B643B1FA9B832418047E1FAB6F01C41D6CEF7D3A9B83241400AD7A366F01C41E761A1F6A3B83241901D38E765F01C4134DF4F4D8DB83241B024977FB3F01C415B643B1FA9B832418047E1FAB6F01C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8049DAC89FB83241F26A635596F01C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.580' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.580' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9680331, NULL, 1, NULL, 0xBD0B00000104050000002D992A587AA53241F086A7D75D881C41B696906F79A5324120948785B4881C41C97F48DF91A53241B03B4E51F8881C41E258171793A53241B06D3480A2881C412D992A587AA53241F086A7D75D881C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C18D7C92F86A532411D857434AB881C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.590' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.590' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977709, 29852981, 1, NULL, 0xBD0B00000104050000001524283EFB792B419006F096D76431410FAC1C5AFA792B41D09C11A5BD6431414470CE48E6792B41C4E848CEBD643141B269DE31E7792B41DC2D90C0D76431411524283EFB792B419006F096D764314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4A34B0C4F0792B4184B52CB2CA643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.600' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.600' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 26934426, NULL, 1, NULL, 0xBD0B000001041B00000089B0E1C9DD393241B02C439C147D1741A2ABAD78D839324100E56121107D174174A52C239D393241E0C03923DE7C1741811D38A7CD393241402041714B7D17410AD7A3D0DB393241601CEB626E7D1741A435CD3BE9393241C00F7AB6957D17411773D7D2F5393241C00C022BC17D1741BBAF03A7F639324180643BDFC17D1741F31FD20F083A3241504082E2CF7D174162CC5DEB173A3241608863DDDD7D17417ED0B3E9153A324160931844D47D1741A7A44EE0133A3241804AEAC4CA7D17410DF241CF113A3241F0F67560C17D174171F90FF90E3A3241E0C56DF4B47D17416F787A150C3A3241B0C729BAA87D1741C4DCB524093A3241F0E995B29C7D1741469D8026063A324100FDF6F5907D17414DE3A51B033A324100D6C56D857D17411E386704003A3241F02BD41A7A7D1741B09465A8FE39324150257582757D17418DE4F29FFB393241505C8F426B7D1741DAD781B3F53932418011A53D577D1741C7BAB84DF1393241B04E40134A7D1741265C8F82ED393241603480B73E7D1741B837F8E2EA393241503FC6DC367D1741669A779CDF3932414074B515197D174189B0E1C9DD393241B02C439C147D174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1EFE57A1E239324141FFCFC35B7D1741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.610' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.610' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2911230, NULL, 1, NULL, 0xBD0B0000010409000000C520B0324D3932415007CE19048B174169BC74934F393241D0E76A2BEB8A1741FB31E62E3D39324120E17A14DB8A17410A560EAD36393241A01C5A64D58A17411DB0724832393241D07B61B2EF8A174196438B4C2B393241602BF617158B1741674DF3CE26393241B09F1AAF2A8B174182C0CA61273932412051DA1B328B1741C520B0324D3932415007CE19048B174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDC283F2D3B393241C0671814008B1741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.620' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.620' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8992703, NULL, 1, NULL, 0xBD0B0000010409000000F67E6ADCC8353041983E571BA5352041C239239AC3353041C8E53F24B43520417ABE9F3ABE353041809CA203C3352041EF5A42BEB8353041C87493B8D135204115265325B335304190B74042E0352041772D21DF62353041B09F1A6FAD362041EEFDD458DB343041283D9B55BE382041BDF528BCD9343041B06054524A392041F67E6ADCC8353041983E571BA535204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFFB897DA39353041B51F807396372041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.630' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.630' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15937500, NULL, 1, NULL, 0xBD0B0000010409000000AED85F7631833241F82A8796834A2E4139014DC43183324198180416764A2E41C8B12E6E2D83324170840DCF714A2E41AED85F7631833241F82A8796834A2E41EF2FBB873083324180F7E461AC4A2E411BE258B726833241C8A145B6A24A2E4152E3A57B26833241F0EBC0B9AC4A2E412731084C30833241A0416065B64A2E41EF2FBB873083324180F7E461AC4A2E41020000000200000000020400000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010CFCF57A962C833241289BB8C3A04A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.640' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.640' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11726768, NULL, 1, NULL, 0xBD0B0000010404000000632041711CF42E41A869DE311C582F4153A60A461CF42E4190627F19BA572F41ECC9C382E0F32E4120A7E88812582F41632041711CF42E41A869DE311C582F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE1DAAF6808F42E417326C246F8572F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.650' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.650' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226258, 35711851, 1, NULL, 0xBD0B0000010405000000C09F1AEF172E2C41CC0E9C1366A13041C59F1A2F182E2C4178BC74B36DA13041FA31E62E622E2C41382AA9136DA130416D4DF30E622E2C41C00E9C7365A13041C09F1AEF172E2C41CC0E9C1366A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC662F4163D2E2C41553A4F9369A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.660' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.660' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977938, 23708991, 1, NULL, 0xBD0B00000104050000006EF90F693A772B4124A9135080643141865AD3FC3A772B4188BE9F7A91643141DB141D094F772B41D044D8509164314141C6DC754E772B41B8EFA726806431416EF90F693A772B4124A913508064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C50F52DB944772B41A1D883D088643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.670' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.670' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4786068, NULL, 1, NULL, 0xBD0B0000010407000000433EE879012D324150A60A4604BE1841DD141DA9032D3241C02C431C2DBD18415BD3BC03F72C3241B02D211F2BBD1841C0A8A4EEF92C3241702BF69773BD184195C42010FD2C3241801FF4ECBBBD1841760B2468002D3241E099081B04BE1841433EE879012D324150A60A4604BE184101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6AD8BB91FE2C32410ECAB5627ABD1841, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.680' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.680' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13843354, 90073170, 1, NULL, 0xBD0B00000104070000001C63EE1AA5512B41900D4F0F20613141A5CDAA0F91512B412CA7E828206131419FB437B891512B41F40968E2346131411A1FF4EC94512B418004C58F36613141AEA679479F512B41B09465C83B6131412DA2B4F7A5512B4118C3640A3F6131411C63EE1AA5512B41900D4F0F2061314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE5BD21219C512B41E0BD56392D613141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.690' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.690' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13998099, 23689001, 1, NULL, 0xBD0B00000104050000009E1A2F9D1E792B41A4DA8A5DD9643141EB3845C71D792B41089E5E69BF643141B059F5B909792B41344ED191BF643141034D848D0A792B41F4384587D96431419E1A2F9D1E792B41A4DA8A5DD964314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE8D3E82A14792B41E94D4278CC643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.700' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.700' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14341221, NULL, 1, NULL, 0xBD0B0000010426000000F4A9F152317B3241A0DB688020921C41A4BDC137317B3241304A7B8320921C414E4013E1187B3241802F4C2623921C410A1B9E7E177B324190847C5023921C41A11A2F7D007B324110E78CA81F921C4141355E1AE87A3241C013D0C41B921C41250F0BB5CF7A324130F775E017921C41B059F599CF7A32411088F4DB17921C419E89B081C37A324180B0E1E915921C411804564EB77A324180FC18F313921C417DF2B0F09E7A324160C3422D10921C416A8863BD927A3241A03311360E921C41E002098A867A324160A4DF3E0C921C416D8A8E246E7A32410066F76408921C410EA5BDC1557A32411025068104921C419CEFA7A6557A324190B6847C04921C411CDBF95E3D7A32418051499D00921C4111143F863B7A3241601AC05BC3921C41621058B99C7A3241A017B7D1D2921C416D8104C5C97A324120D9CEF7D9921C41E3361AE0C97A324170DA1BFCD9921C41AC35CDBBDA7A3241C07A14AEDC921C4121EBE2D6DA7A3241F0E995B2DC921C41A835CDFBDA7A3241F05886B8DC921C41F1FDD4B8777B324150772DA1F5921C41D8CEF7D3777B3241A00A46A5F5921C4168B3EAF3CB7B32411026E40303931C4152B81EA5CE7B3241209E5EA90F921C416AF7E481AB7B324140D6C56D13921C41C520B012937B324130B81E0516921C41DF4F8DF7927B3241C026310816921C4181D0B3D9867B3241E087F45B17921C411AB7D1A07A7B3241809CA2A318921C41BCCAA1857A7B3241200BB5A618921C418FA98231627B3241205C8F421B921C41AFD85F16627B3241D0CAA1451B921C410D9C33C2497B3241808BDBE81D921C41F4A9F152317B3241A0DB688020921C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8F4A22530C7B3241DE927DE47C921C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.710' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.710' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4682807, NULL, 1, NULL, 0xBD0B00000104050000002E772D610C433541503CBDD2C7A02341243A92ABCC423541F0839E0D10A023414694F626B442354130E258170CA023416591ED3CAD42354188D409E8B7A023412E772D610C433541503CBDD2C7A0234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C40198A68D14235414FFA137378A02341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.723' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.723' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14612429, 11706571, 1, NULL, 0xBD0B0000010405000000B9D1007E2F2F3441848EE4323DE33341905CFE63992D3441BC64AAC01EE333412A287E8C7B2D3441A479C7C9A8E43341EC95B26C132F344114B6F35DC7E43341B9D1007E2F2F3441848EE4323DE3334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C765218F4552E344132E4782BF3E33341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.733' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.733' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13843371, 90073171, 1, NULL, 0xBD0B00000104070000001DFDF6757D512B4118F697FD2961314150B81EC580512B411CD9CED72B6131413080B7C08A512B410C12143F316131419FB437B891512B41F40968E234613141A5CDAA0F91512B412CA7E82820613141026F81047D512B41A0779C42206131411DFDF6757D512B4118F697FD2961314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA16BF08688512B41EB06ED2B28613141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.743' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.743' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11236892, NULL, 1, NULL, 0xBD0B000001040500000014E2583749BF324100A8C6CB41C71C4136234A7B56BF3241A026C28661C71C4106A3921A5ABF324140D9CEF7FCC51C419B559F8B4CBF3241F076BE9FFAC51C4114E2583749BF324100A8C6CB41C71C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C19DEC3AE51BF3241A75FDADCA6C61C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.753' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.753' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13601679, NULL, 1, NULL, 0xBD0B0000010405000000A1D6346FD58E3241D006F016AE261D41D79AE67DDF8E3241F0263188AF261D41355EBAA9E08E3241305986B82C261D41FF99089BD68E3241B0A679472B261D41A1D6346FD58E3241D006F016AE261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C23EF770CDB8E3241CDD9C8676D261D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.763' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.763' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3842878, NULL, 1, NULL, 0xBD0B000001040F000000E9C039A339503541F002090A0A9B2341E27A148E34503541F897DD930D9B23410893A96222503541401E16EA1A9B234112BE30591650354148871659249B23411C2FDD640A50354118211F342E9B2341F2384587FE4F354118B5A679389B23416509F9C0F24F354128B07228439B2341CC20B012E74F354148499D404E9B234124ED0D7EDB4F3541503789C1599B234172C5FE32DE4F3541400C022B5A9B234199BB96F0EC4F3541D8779CA24A9B2341ACADD8DF6C503541384547B2F09A2341777AA54C70503541E80DBE30E19A23411E5A64BB3E50354180CE8892069B2341E9C039A339503541F002090A0A9B234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C40A6EB0235503541308F3A05139B2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.773' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.773' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7488921, NULL, 1, NULL, 0xBD0B0000010412000000AAADD87FDA7D3041F0C876BE0E051D414C72F94FBE7D304170B7AF0312051D41081B9E5EC07D3041A074939819051D41AEE1E915CA7D304190EB51B82A051D41C64B3709D47D304170DE028939051D41CA76BE2FDE7D3041C0A370FD45051D4128A08980E87D3041304CA60A50051D4172CE88F2F27D3041A02FBBA757051D41E0B5847CFD7D3041109621CE5C051D4182613215087E304180A223795F051D412F3333B3127E3041F09C80A65F051D411B2653C5127E3041B0AF03E72E051D41EF0DBE40097E304130E483DE2E051D41575227C0FF7D304150696FB02C051D413A234A4BF67D3041F01A9E5E28051D4188B0E1E9EC7D3041C0438BEC21051D414EF38EA3E37D304100098A5F19051D41AAADD87FDA7D3041F0C876BE0E051D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C97FD26CBED7D3041BF33875C37051D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.783' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.783' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6227481, NULL, 1, NULL, 0xBD0B0000010429000000ECC9C34216182941ACEA7335B78A30419E8026022B18294120CB10E7D78A30414292CBFF30182941703D0AF7068B304101098ADF3018294190D6340F1D8B3041C81726931A18294144287ECC5F8B3041FB088A5F1818294170567DEE748B30411E41F1E31D18294150A52CE3868B30416DF90FA92B182941881804569B8B304101CE19D160182941E0839E4D998B3041FA2A875661182941285C8F428D8B3041B4A44E40691829416407CE59D68A3041AE5B2081FC172941BC2C437C678A30411EE4831EA2172941C0AACF550B8A30417C51491DA4162941A0D6348F148A3041031214FFA6162941403EE8392A8A3041B2ADD81FD6162941D4EBC0793A8A3041EE0434510B17294148302A69498A30415B1058F968172941E4770B845E8A3041907EFB3AC7172941F8891FA37A8A304106C58FF1D71729417CE09C51838A30415E2041F1061829417019E278A78A3041ECC9C34216182941ACEA7335B78A304104CE1911E019294198DD93A78A8B3041920F7AF6A01929412CDD24C6F8893041C4DA8AFD8A18294120D26FDF028A3041643BDF0FA61829419CF831465B8A304145CF6695B41829410466F7D4628A3041B9EC9E1CC2182941782F4CD66A8A30416A348097CE18294164F7E441738A30414E19E2F8D9182941584DF30E7C8A30419A2A1835E418294138014D34858A30417BC95441ED1829411CB072A88E8A304170006F41F5182941489D80C6988A3041DAD022FBFB182941CC7F481FA38A30410EF9A0670119294188CB7FA8AD8A3041366EA38105192941F02FBB57B88A30415E81044508192941A4605422C38A304150840DAF0919294128F697FDCD8A3041CE915CBE09192941D451B8DED88A3041949999193319294130386744918B304104CE1911E019294198DD93A78A8B3041020000000200000000021600000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010C9ACBF675D318294197D365F1AA8A3041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.793' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.793' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13908341, 90073178, 1, NULL, 0xBD0B0000010407000000EBDBD7C13F512B41403108ACE76031412B3A928B40512B41581058D903613141E4F97EEA48512B4170F90FA909613141F0E236DA4C512B4134FAED4B0C613141B394658854512B412C6519420C613141C4BAB8CD53512B411873D792E7603141EBDBD7C13F512B41403108ACE760314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9509AEA14A512B4169D80BC0F8603141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.803' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.803' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10783237, NULL, 1, NULL, 0xBD0B00000104050000006C66662626AE3241701F63EE696F1C419F1A2FDD3BAE3241704160E5A96F1C41644DF3EE56AE32414041F1E31C6F1C4160764FDE3CAE32419088D25EFA6E1C416C66662626AE3241701F63EE696F1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAD9178CB3DAE32417364651D4C6F1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.813' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.813' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14297710, NULL, 1, NULL, 0xBD0B0000010406000000858EE4B27D9132415019E2D8180E1D414CFC18B37D913241705DDCC6180E1D41041214DF7D9132413003788B080E1D4154E3A5BB69913241C019515A060E1D4189F4DBB768913241C032C431670E1D41858EE4B27D9132415019E2D8180E1D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFA79E81071913241B3107A40280E1D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.827' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.827' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14339544, NULL, 1, NULL, 0xBD0B000001040700000044D8F05442B13241703255B032FA1C412FFF219D0BB132415029CB90A2F91C417A2D215F04B132419051499DCFF91C41F1D24D4228B13241100F0B352EFA1C41E795B2AC48B132411030BBA783FA1C41F163CCBD4FB13241C003E70C56FA1C4144D8F05442B13241703255B032FA1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C50FD1D1C2AB132416C20740013FA1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.837' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.837' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11844990, 90054879, 1, NULL, 0xBD0B00000104050000001FC9E53FCB453341A0E61D270F77284188855AF32846334120E4835E19772841024D846D1C46334128D1919CCB76284127287E2CCC453341184BC8C7C27628411FC9E53FCB453341A0E61D270F77284101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C31AB5544F74533411DAE90B8EE762841, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.850' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.850' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11844990, 90054879, 1, NULL, 0xBD0B00000104050000001FC9E53FCB453341A0E61D270F77284188855AF32846334120E4835E19772841024D846D1C46334128D1919CCB76284127287E2CCC453341184BC8C7C27628411FC9E53FCB453341A0E61D270F77284101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C31AB5544F74533411DAE90B8EE762841, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.860' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.860' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8534683, NULL, 1, NULL, 0xBD0B000001040800000036014D441F3B3241C0F1D24D778917418E06F0761F3B324140014D046C8917415C17B7A11F3B324130C7BAB86089174159C1A8C41F3B3241D01E856B558917415A8638661E3B32415054E3A55C8917419C01BC051D3B3241307502DA638917417AA52CA31B3B3241504BC8076B89174136014D441F3B3241C0F1D24D7789174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C27C3523D1E3B3241E5A05AEC67891741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.870' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.870' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13862944, NULL, 1, NULL, 0xBD0B00000104050000009F8026E2DF283341B0469476EA8F1C414D1E164AB428334120621058D08F1C41413EE819B12833411054E3A5D6901C412C97FF30DC283341A04B378915911C419F8026E2DF283341B0469476EA8F1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8D9C2CD7C828334194C8BB346A901C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.880' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.880' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13602021, NULL, 1, NULL, 0xBD0B000001040600000057A835EDEA8E3241C0C2D3AB19261D4112363CFDF48E3241D0AD47611B261D41F45C6D05F58E3241703FC65C18261D41160DE06DF68E32414080B7C093251D41647FD95DEC8E32418095430B92251D4157A835EDEA8E3241C0C2D3AB19261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C583F8AADF08E324119CB42B6D6251D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.890' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.890' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10459251, 17743021, 1, NULL, 0xBD0B000001040500000095900FFAC8823241602497FFE14A2E4190ED7C9FC98232414805A352A94A2E4110363C3DC1823241F0B9DA0AAF4A2E414D96210EC082324198D1911CE14A2E4195900FFAC8823241602497FFE14A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFBB23B0FC58232410339F12DC74A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.900' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.900' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3094294, 6393951, 1, NULL, 0xBD0B0000010404000000CF5D4BC8379B3341F05205A306541C41204A7BC3519B3341F002098A72531C414A3789E1049B3341D079C729C2521C41CF5D4BC8379B3341F05205A306541C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C684AC5792F9B3341E5EFF11C69531C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.907' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.907' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14612119, 11706441, 1, NULL, 0xBD0B000001042200000028287E6C162C344178F90F093DE433413C8941A01C2C34416061321542E43341819543EB222C3441D893870547E43341304CA64A292C3441C4627FD94BE433414DDA1BBC2F2C3441846ABC9450E433416F1B0D40362C344124363C3D55E43341283108EC3C2C3441C02631A859E43341C9A145D6432C34417CC954A15DE433418E4160E54A2C3441E0A2925A61E4334135F8C204522C344194900FFA64E43341E8043431592C344194C9548168E4334157302A69602C3441A86054F26BE43341138C4AAA672C3441E84D62506FE433417AE09CF16E2C34415C7FD99D72E43341CE00DE42762C34418404C5CF75E433410FF241AF7D2C3441F8B9DACA78E43341974C152C852C344160D3BCA37BE43341F2B050AB8C2C3441240F0B757EE43341E12D9020942C3441586B9A5781E4334126E4837E9B2C344140D49A6684E43341C07493B8A22C3441E0C798BB87E43341575227A0A92C3441A4559FAB8BE43341E98C282DB02C3441E09C114590E43341749CA2A3B62C3441641E160A95E4334172F08549BD2C344110ED0D7E99E433417F613255BF2C3441C0BAB8AD9AE433412A287E8C7B2D3441A479C7C9A8E43341905CFE63992D3441BC64AAC01EE3334153840D4F172C344144575BD101E333413AEF38E5002C3441F89D5EC929E43341B837F882042C3441648638162DE433415ECA32640A2C344148A52C8332E43341B4EA7355102C344168A301DC37E4334128287E6C162C344178F90F093DE4334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C454664DAD12C344120C789CDCBE33341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.917' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.917' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7487967, NULL, 1, NULL, 0xBD0B00000104060000002DBB27AFA97E30413090A07804051D4158C1A8649A7E30414011363CED041D4109F9A0678B7E3041D0ACFADCF4041D41823F351E8B7E30413008AC1C26051D41A33C2C94A97E3041D0BE0E9C16051D412DBB27AFA97E30413090A07804051D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6456108D987E304149989E7009051D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.930' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.930' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977792, 23694921, 1, NULL, 0xBD0B00000104050000006C6FF045347A2B41184D842D7A643141A0A22339207A2B41547424577A643141474772F9207A2B41E0FA5C8D916431417D38D605357A2B41D8F75363916431416C6FF045347A2B41184D842D7A64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF6378F9F2A7A2B418EB34CDD85643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.940' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.940' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977598, 29841151, 1, NULL, 0xBD0B000001040500000084855A93877A2B419833A274D6643141752D219F9B7A2B41CC1E854BD6643141D222DBB99A7A2B4198900F5ABC643141569FABAD867A2B41689CA283BC64314184855A93877A2B419833A274D664314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9DBF8726917A2B41C8916A67C9643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.950' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.950' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 19171269, NULL, 1, NULL, 0xBD0B000001040D00000031211F1469C6324120304C2650E01C41E05817F774C6324120E9B72F62E01C410BB5A6F980C632415025758277E01C41DA8AFD658CC63241702041F18EE01C41D934EF7897C6324100D34DE2A8E01C41C07D1D58A3C6324110BC0592C8E01C41FEDD02C9AEC6324160197357EBE01C41D48AFD65CCC63241D012F2414BE11C41C5BAB86DCCC6324110C3642A49E11C41B4AF03A7CCC6324140083D9B39E11C41BB490CC2CCC63241F0B359F531E11C41E29C1105CEC6324160711B8DD6E01C4131211F1469C6324120304C2650E01C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C0C8364B1B3C632413940A961D8E01C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.967' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.967' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 18285121, NULL, 1, NULL, 0xBD0B000001040D0000005A2041311EE232418013F241C4091D4101B37B32FFE13241203199AAF0081D41CC8F3177F2E13241E0907E7BB4081D411695D429E5E1324170B662FFD3081D417EFB3A10EEE132410089D2DEFE081D41190DE02D35E23241904F1E16560A1D41DCBE0E3C39E23241A0764F9E690A1D41F29E3CAC3EE23241B0B0E1E95C0A1D41C976BEFF35E23241A0AEB6E21D0A1D412865198239E23241F0C64B37160A1D41196A4DB331E23241C0F75363DF091D4182AEB6222DE23241803BDFCFC9091D415A2041311EE232418013F241C4091D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C106FF9BD11E23241E528412783091D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.977' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.977' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13602012, NULL, 1, NULL, 0xBD0B000001040700000074832F2C1D8F324130F8C26420261D41381AC03B278F32418007CE9921261D418F4AEA44278F324100295C8F1E261D41C710C79A278F3241103A92CBF0251D4182C0CA41288F324170218EF599251D4179F2B0301E8F3241A036ABBE98251D4174832F2C1D8F324130F8C26420261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAC860FB7228F3241DDE62C2EDD251D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:15.993' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:15.993' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9956727, 5498101, 1, NULL, 0xBD0B000001040A000000102DB2DD15773541F831E66EB23E2C419AB43778F3763541C0CB7F48D4412C41B07BF270DA763541B847E1BA1B442C41F94A592651773541F89F897035442C41D868008F047835416096214E78432C41A86054923B783541E8EC9EFCA0422C417FE2C7F848783541801B0DA021422C41F54A59266B783541E0537464ED3E2C41E2E00BD32977354128FF21FDB53E2C41102DB2DD15773541F831E66EB23E2C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD21A382C9C773541C4DD533455412C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.003' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.003' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10464824, 90054791, 1, NULL, 0xBD0B0000010404000000FFF67560A22033410876E0BCB6CE32416B006FE168203341B0AF0347B3CE324189A757EA8F2033412CA7E8C8D4CE3241FFF67560A22033410876E0BCB6CE324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA6DFBE0E89203341A1999999BFCE3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.017' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.017' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7487959, NULL, 1, NULL, 0xBD0B0000010405000000823F351E8B7E30413008AC1C26051D4109F9A0678B7E3041D0ACFADCF4041D415517B7F16C7E304100F6975D04051D41D05D4BA86C7E304110BF7D9D35051D41823F351E8B7E30413008AC1C26051D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA775F3077C7E30411371303D15051D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.027' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.027' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3780929, NULL, 1, NULL, 0xBD0B0000010406000000714DF38EDA822C41E085C9D43CE822412ACB104719832C41F83A708E14E82241A2C420F0C6822C4120287E8CFEE72241E4F97E2AB2822C41785305E347E8224185A52C03AD822C4140AA60145AE82241714DF38EDA822C41E085C9D43CE8224101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA2212ABED9822C410E70056524E82241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.037' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.037' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13995553, 29842481, 1, NULL, 0xBD0B00000104050000005EAA609478772B41E4B584BCBF64314114022B8764772B41706FF0E5BF643141F126314865772B41307958E8DC643141F5065F5879772B41249B55BFDC6431415EAA609478772B41E4B584BCBF64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDFBE0FEF6E772B41A508E452CE643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.057' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.057' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977997, 23695961, 1, NULL, 0xBD0B0000010405000000B97493981B792B41BCB359757C643141B2F1D28D07792B419CFF909E7C64314182A7574A08792B418C06F0D693643141DD61A1561C792B4140E8D9AC93643141B97493981B792B41BCB359757C64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE24AC9F111792B41D5EA132688643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.070' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.070' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977962, 23708571, 1, NULL, 0xBD0B00000104050000009487859A8A772B414C158CAA7F6431414C840D8F76772B41D8D781D37F6431410FAE472177772B4104363CFD906431417F7AA52C8B772B410498DDD3906431419487859A8A772B414C158CAA7F64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1BC6D5DD80772B41CE64C85388643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.080' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.080' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14412985, NULL, 1, NULL, 0xBD0B0000010405000000EEB0506BA58A324160E7FB2969EA1B41A223B91CA38A3241702041F1B1EA1B41C086A777B88A3241E09C1125B5EA1B4126F6973DB98A3241902E6E236CEA1B41EEB0506BA58A324160E7FB2969EA1B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF289DC8CAE8A32413303C78C8FEA1B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.103' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.103' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13876236, NULL, 1, NULL, 0xBD0B0000010408000000ACFA5CEDF9CB32411067D567D7F31C41C29F1ACF34CC32413041F1632AF41C41CA8F315775CB32415003788BB6F11C416FA301BC6FCB3241D0D9ACFA64F31C418F5CFEE375CB3241A0A3703D63F31C41F4FDD43880CB324150855A5369F31C413611369CBDCB3241E08CB9EB96F31C41ACFA5CEDF9CB32411067D567D7F31C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA3A4A2C9B0CB32413BBA245A08F31C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.113' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.113' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13852558, NULL, 1, NULL, 0xBD0B00000104160000004F499D6004183341C0726891B49E1C41A4C64B370C183341705DDC46A89E1C416991EDBC12183341E05205A3759E1C419DABAD981F18334150006F015E9E1C410B8195431C18334100E561A12F9E1C41A73E577BAA173341E0D022DB199F1C41C410C77AA8173341F0C42030C49F1C41CDF753637E173341801804D61AA01C412A0F0BD57D17334140D49AE6A4A01C41EE8E53F4B4173341802DB29D96A01C4172F90F49B417334120DD240661A01C41428B6CE7BC173341C022DB7936A01C41752D217FBF173341A087855A04A01C41827346D4C917334130FAED6BA89F1C414EAF9485CB173341E0EC9E3C7A9F1C418A38D6C5D1173341100000006B9F1C41FD4C840DDF173341608FC2F5229F1C411573D792E9173341E061A156349F1C4160105859F0173341506DC57E599F1C41B269DE91FE17334140A3013C2B9F1C410E7A366B0218334190E61D27EC9E1C414F499D6004183341C0726891B49E1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C370C54ABC317334189C50ED1819F1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.133' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.133' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14767953, NULL, 1, NULL, 0xBD0B000001040800000078711BED91583441E02FBBA7B0311E413E7958684B583441801B7C6115321E412AA089B012583441F0891FE38A321E4143F1632C9557344140FC18F310331E41285C8FC28B5734416095438B85351E4124ED0D3E6E583441A0A982D1F0321E41286519A297583441B0855A53FB311E4178711BED91583441E02FBBA7B0311E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9B684E88FA57344183C1F3316C331E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.160' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.160' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 17454981, NULL, 1, NULL, 0xBD0B000001046C000000298716D91C413141E05D4BC8FBBE2E4128CB10A71B413141D00B932906BF2E41DD361A601A413141A8A44E8010BF2E41388941001941314158A835CD1ABF2E41A0703D8A174131414003780B25BF2E4160764FFE15413141C8907E3B2FBF2E41206C785A14413141303EE85939BF2E41DB12F2A112413141F0F97E6A43BF2E415B0E2DD21041314198438B6C4DBF2E41D2DEE0EB0E413141D03E575B57BF2E4145696FF00C41314168226C3861BF2E417B36ABDE0A41314160006F016BBF2E418BF4DBB70841314188FD65B774BF2E41E8D9AC7A06413141E019515A7EBF2E41CB54C128044131410879E9E687BF2E415DEE5AC2014131418051495D91BF2E4186416045FF403141301136BC9ABF2E41EE85C9B4FC403141A04AEA04A4BF2E41684DF30EFA40314168EA0434ADBF2E41B2E1E955F74031419815FB4BB6BF2E4176931884F4403141581CEB62BFBF2E41A011A59DF140314140C05B60C8BF2E41430AD7A3EE403141485C8F42D1BF2E41B3D85F96EB403141C8825109DABF2E41784F1E76E8403141283333B3E2BF2E41452EFF41E540314100DCD741EBBF2E41174850FCE1403141B80E9CB3F3BF2E41EED24DA2DE403141785DDC06FCBF2E41C07D1D38DB40314180A3013C04C02E4176BE9FBAD740314130A913500CC02E410F71AC2BD4403141E881734614C02E41B51E858BD04031410888F41B1CC02E4105B5A6D9CC403141A8A8A4CE23C02E411BE25817C9403141B02D90602BC02E41AD1C5A44C54031415817B7D132C02E41A79BC460C1403141B0BFEC1E3AC02E411A0DE06DBD40314120B9FC4741C02E41839ECD6AB94031416096214E48C02E41FA0FE957B5403141D031772D4FC02E410222FD36B1403141106744E955C02E4129CB1007AD40314138FF217D5CC02E41E1141DC9A8403141108C4AEA62C02E4151DA1B7CA4403141200E2D3269C02E412E6EA321A040314198976E526FC02E41E9D9ACBA9B403141A84C154C75C02E416D81044597403141103FC61C7BC02E41905374C492403141A8CAA1C580C02E41567DAE368E403141D0EEC94386C02E41D8ACFA9C8940314188D0B3998BC02E41BF86A7F78440314100B98DC690C02E41B094654880403141E0718ACE95C02E410EE9B78F7B403141603255B09AC02E41EEB050CB76403141C078E9669FC02E4198FF90FE71403141088E06F0A3C02E41C64B37496D40314158666626A8C02E41ABF1D22D68403141D0EEC983ACC02E4136AB3E376340314150287E8CB0C02E41F2EBC0395E403141D878E966B4C02E41FCA067335940314118E25817B8C02E41696666265440314188F4DB97BBC02E417AE09C114F403141E88C28EDBEC02E41C498BBF649403141F0F21F12C2C02E41F4A067D34440314118948705C5C02E4169DE71AA3F40314108151DC9C7C02E4153D1917C3A403141E03FA45FCAC02E4171F90F49354031414082E2C7CCC02E4198BB96103040314148378901CFC02E417E7346D42A403141585F070ED1C02E416AAA609425403141F8D478E9D2C02E4129A9135020403141F898BB96D4C02E41F5CBEE091B40314128068115D6C02E41000000C01540314150416065D7C02E41ABE8486E1040314130B6F37DD8C02E41CE22DB190B403141F8E68C68D9C02E41191DC9C505403141481CEB22DAC02E413C575B7100403141F056ECAFDAC02E419E1A2F1DFB3F31412871AC0BDBC02E417A14AEC7F53F3141E0C7983BDBC02E41D6C56D74F03F3141205A643BDBC02E410693A922EB3F314150840D0FDBC02E419DEFA7C6033E3141F80DBE30BFC02E41881F638EE73D314100C364AABDC02E415F6DC59ED33D3141082B8796BCC02E41F5065FD8723D3141C8F5285CB7C02E411F166AED593D3141E8809503B6C02E41B9408202413D3141480C02ABB4C02E41DE4F8D17283D314108615452B3C02E41757AA52C0F3D314138B5A6F9B1C02E41467B834FF63C314118D578A9B0C02E41FE87F43BC33C3141509FABEDADC02E41799318A4A83C3141B0923A81ACC02E41081B9EDEDF3A31415083C0CA93C02E4107C58FD1DF3A3141C015FB0B98C02E41A0D6348FDF3A314100CAC342ACC02E41E093874525413141307FD97D04C12E410122FD763E413141706666E6B4BA2E4152DA1B5C33413141004E6250B4BA2E4129287EEC23413141E088D21E8ABE2E410612147F2341314130C6DCB59CBE2E418DED7C1F2341314138D26F5FA7BE2E415939B4A82241314128B81E05B2BE2E417ED0B3192241314178787AA5BCBE2E41DACEF77321413141F87E6A3CC7BE2E41012B87B62041314140BB27CFD1BE2E41D812F2E11F413141701AC05BDCBE2E418F1804F61E413141B8F528DCE6BE2E416ECE88F21D413141D886A757F1BE2E41298716D91C413141E05D4BC8FBBE2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1CB5C177BE3F314159C18EF213C02E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.170' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.170' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13369792, NULL, 1, NULL, 0xBD0B000001044D00000036F8C2E435BA334158E3A51B2AD8234134CD3BAE36BA334158D191DC2ED82341E4D0227B37BA334180E2C79833D82341CEDEE04B38BA3341F0A9F15238D8234123C9E51F39BA3341E8B9DA0A3DD82341ACBDC1F739BA334150499DC041D82341F9A9F1D23ABA334100A1677346D82341FC65F7843BBA3341B8FC87344AD823410CBE30393CBA3341303333F34DD82341D856ECEF3CBA334110A089B051D82341E61DA7A83DBA334178559F6B55D82341C7EEC9633EBA3341E89C112559D82341C25B20213FBA3341605149DD5CD82341C264AAE03FBA3341C8E00B9360D82341482575A240BA3341B0A6794764D82341D881736641BA3341307E8CF967D823411F1FF42C42BA3341308C4AAA6BD823415D984CF542BA3341C87493586FD823413A8941C043BA3341C013D00473D8234178711B8D44BA3341900D4FAF76D82341FA7E6A5C45BA3341C07493587AD82341599FAB2D46BA3341B8B662FF7DD8234167006F0147BA334100780BA481D823414C7424D747BA3341E84A594685D82341F6285CAF48BA3341881D38E788D82341FFD4788949BA3341A801BC858CD823418538D6654ABA3341902EFF2190D8234156C1A8444BBA3341785AD3BC93D8234172787A254CBA334168984C5597D8234155423E084DBA3341C01E85EB9AD823418F3177ED4DBA3341C8B6627F9ED82341124FAFD44EBA33410097FF10A2D82341D4915CBE4FBA334110C05BA0A5D8234171E7FBA950BA334190B12E2EA9D82341E24F8D9751BA334108FED4B8ACD8234106F9A08752BA3341D8802642B0D8234106B5A67953BA3341D8141DC9B3D823419228ED6D54BA3341A803E74CB7D8234158CA326455BA3341280456CEBAD82341C1EC9E5C56BA33410004564EBED823410222FD5657BA33418015FBCBC1D823416BB3EA5358BA3341B801BC45C5D8234172CE885259BA334138B6F3BDC8D82341162FDD645ABA3341805AD33CCCD823410D363C7D8EBA334198DFBE8E2FD9234152B81EE5D7BA334140E17AD476D923418EA98291E2BA33415096210E1AD82341283A928BAFBA3341A0F7536313D82341EDF44A193FBA3341B0141D4903D823416229CB903BBA3341D8703DCA02D8234128ED0DBE2FBA334140C1A82401D8234100917E1B30BA3341E83A70CE03D8234121B9FCC730BA334108098A9F08D82341DE46037831BA334180567D6E0DD82341CFDEE02B32BA3341105A643B12D823412A5305E332BA334128A60A0617D823412BED0D9E33BA3341B09690CF1BD8234151D1915C34BA33419018049620D8234197F6061F35BA3341081A515A25D8234136F8C2E435BA334158E3A51B2AD823413208AC7CEBB93341D80968A2F7D72341DCF0F40AD1B93341A833A2F4F3D72341897CD05390B93341402AA953ECD723415639B46853B93341885374E4E5D723411E4A7BE34DB93341C8B9DA4AA9D823413F60E51048B93341209A775C77D9234134AB3EF73FB93341D8CDAA0F96DA2341C78F31973AB9334118287E4C54DB2341A23C2C946DB93341180F0BB558DB23417E1D38276DBA3341D01C5AE46FDB2341A813D0246FBA3341D88BDB686ADB2341B6D1005E85BA33414890A0382DDB2341B86B09F99EBA3341E022DBB9E6DA234173F0852958BA3341D8C264EA2CDA2341246519A22FBA3341106F818490D9234198FF903EFBB9334198BE0E5CC6D823413208AC7CEBB93341D80968A2F7D72341020000000200000000023C00000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010C6AB114F4EAB9334118AED225B4D92341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.180' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.180' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12909611, 1050161, 1, NULL, 0xBD0B000001040A0000004C9FAB2DE4E02641183A924B569E32412FBB270FCBE0264110E6AEE55E9E32415AD3BC23BEE0264108B37B52639E324111AC1C9AB2E02641D48AFD45679E324130F8C2E4A7E02641D444D8F06A9E3241DF61A1D6B3E02641A089B021739E3241D0E53FA4BDE02641B437F8C26F9E32414AFC18B3C6E02641606FF0A56C9E32411E386784EFE026410C5B429E5E9E32414C9FAB2DE4E02641183A924B569E324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C79863FD1CBE02641F3D430C0649E3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.190' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.190' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12072877, 889181, 1, NULL, 0xBD0B0000010405000000913A010DC8622B41642BF6170E6C31416B931844C7622B41848CB98BF36B31414A5BB13F64622B41781F63CE0E6C3141B5B662FFC7622B41586210180E6C3141913A010DC8622B41642BF6170E6C314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDD109985A6622B41C80D5C7B056C3141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.200' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.200' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8926042, 31243481, 1, NULL, 0xBD0B0000010405000000B2946528A5EC3241305EBA4962891C41B359F579DCEC3241407C613216891C41238E7511B8EC3241E03B4ED111891C419DF83126A6EC3241F0C342AD0F891C41B2946528A5EC3241305EBA4962891C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C39D8B4EDB7EC3241EEF750622D891C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.210' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.210' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13676687, 20622141, 1, NULL, 0xBD0B00000104040000003880B7A0626133415096218EC3541C412597FF30756133411022FD76DF541C4166006FE1676133416027A089AD541C413880B7A0626133415096218EC3541C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C96B20C916A613341954AEA84C5541C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.220' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.220' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10496653, 36339931, 1, NULL, 0xBD0B00000104060000001AC05BA09327344170416045A84233414AEA04F49627344170C5FE927A423341723D0AB78427344100D5788979423341C130996A84273441A025E48379423341CE88D21E812734413CAD693EA74233411AC05BA09327344170416045A842334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD48C55078C273441671139E590423341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.230' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.230' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977563, 29838341, 1, NULL, 0xBD0B00000104050000003B0378CBC27A2B41B8AF0307BC6431419F01BCC5AE7A2B41C0847C30BC643141849ECDAAAF7A2B41D012F221D6643141753480B7C37A2B41F4065FF8D56431413B0378CBC27A2B41B8AF0307BC64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6970E63CB97A2B4161B83415C9643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.240' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.240' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10418547, 16707301, 1, NULL, 0xBD0B0000010405000000E07A146E51823241F007ACDC6D4A2E41866CE7BB50823241100EBE708C4A2E412163EEDA76823241A8C64BB78F4A2E4109560E8D77823241D8F75323714A2E41E07A146E51823241F007ACDC6D4A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C824D7B24648232416C0C03CA7E4A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.250' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.250' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9126210, NULL, 1, NULL, 0xBD0B00000104080000006E567DAEAD39324140EA953285891741BDEC9EBCAF393241F07936AB7889174111E9B7BFB1393241F06F5F076C8917417514AEB7B339324100A779475F8917411E3867A4B539324190D5566C528917416DE7FB099D393241808104453C8917412241F1639739324190E4F21F718917416E567DAEAD39324140EA95328589174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA022FC06A63932415838FDDB60891741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.260' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.260' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15127125, NULL, 1, NULL, 0xBD0B0000010408000000E83FA4DF33A1384170E4F21F9FD21D41E8D9AC3A20A13841201DC9E565D21D417824977F0FA13841D0C56DB4C1D41D41CC4D62B009A1384160F54AD996D51D4154F38E93FAA03841B00968A215D81D4164BC74537FA1384160D5E7EA53D81D41E8C039831CA13841A0E2589778D51D41E83FA4DF33A1384170E4F21F9FD21D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C616284472AA13841EA02A39F74D61D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.277' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.277' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13852752, NULL, 1, NULL, 0xBD0B00000104040000006F4694366BBA3241005C8FC29EF11C410FD0445876BA3241A02C431C4AF11C41F17C3FF55CBA3241B0D5566C81F11C416F4694366BBA3241005C8FC29EF11C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2531082C6ABA3241C574B8C378F11C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.287' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.287' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4682742, NULL, 1, NULL, 0xBD0B000001040E00000014022BA71C433541B07D1DF8F6A02341C876BE3F1B43354108B4C8B6F2A0234124D26F9FAB423541B802090AE0A0234144696F90A7423541E8C039E344A123418EED7C5FA7423541909BC4E049A12341AA4E40F3A5423541A05E290B6FA12341B047E1DAA4423541D0CEF7538AA1234161DC46E3E7423541486B9AB768A123416E4DF36E36433541702A185541A123415FDC46C32F433541B0CFD5162EA123411748503C2B43354120B9FC0721A12341E0E99592244335413872F9CF0DA12341A6E8488E24433541B825E4C30DA1234114022BA71C433541B07D1DF8F6A0234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9B5194A2E1423541E440FE672CA12341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.297' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.297' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15357473, NULL, 1, NULL, 0xBD0B0000010407000000BD9F1A2FC68B3241E00C712C55011C41A25E294BB88B3241F0770B2453011C415BA8358D0B8B3241401AC0DB39011C41B42E6E43248B3241E0D7817348021C41DAACFA7C698B3241E0E76AABF3011C41FF088A1F988B324140D6C5EDA3011C41BD9F1A2FC68B3241E00C712C55011C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFC3934D7538B324147539BCDA0011C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.307' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.307' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8395080, NULL, 1, NULL, 0xBD0B00000104130000009C923AE11B843041B01726D347FA1C4155522760E8833041D0E8482E2AFB1C41760B2408F9833041D0915C7E29FB1C41283108EC248430412054E3A568FA1C41BA847CF02D843041F0FD657789FA1C410DE02D403584304170B4C87667FA1C4116FBCB0E3C84304170855AD343FA1C414A9D80564284304150FAEDAB1EFA1C41AF69DE114884304100522720F8F91C41B715FB3B4D843041A0043451D0F91C4144696FD05184304140AE4761A7F91C4103917E5B46843041F0D781F395F91C41FCDD020939843041C072681195F91C41204A7B33358430417086C954B5F91C41BB847CF030843041601058B9D4F91C41C21726432C843041B0D40928F3F91C416A4DF32E27843041B039238A10FA1C4106F9A0B721843041C03923CA2CFA1C419C923AE11B843041B01726D347FA1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C7593242626843041F88562FB49FA1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.317' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.317' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10449213, 17746331, 1, NULL, 0xBD0B000001040500000012022B47CD8232412031082C524A2E4110363C3DD782324158B81E055C4A2E417B9CA2A3D882324170E5D022194A2E41A41A2F7DCE82324198EFA746184A2E4112022B47CD8232412031082C524A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C85D13608D3823241576FFDF6374A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.330' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.330' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7489293, NULL, 1, NULL, 0xBD0B000001040E0000002F3333B3127E3041F09C80A65F051D417CD93DD9167E3041A003E70C5F051D4195081BFE1A7E30411085EB115E051D4115AE47211F7E3041B058A8B55C051D419F802642237E304190B437F85A051D41FA7E6ABC2F7E3041E0E3839E54051D41161DC905307E3041D0643B5F23051D418F5CFE43277E3041E0CEF7D327051D4102D578C9217E3041D0BDC1972A051D41DBF0F40A1E7E304110C3642A2C051D416ADE714A1A7E3041F01DA7682D051D41B2946588167E3041A0293A522E051D411B2653C5127E3041B0AF03E72E051D412F3333B3127E3041F09C80A65F051D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAC8F4D54217E3041F0268EA542051D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.350' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.350' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13997980, 23688221, 1, NULL, 0xBD0B00000104050000001CF46C1696792B412C3CBD72BE643141FE907EFB96792B4154CA3264D86431412D4CA60AAB792B410863EE3AD8643141E1AE2524AA792B4194F08549BE6431411CF46C1696792B412C3CBD72BE64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3F972E90A0792B41EAB00057CB643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.360' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.360' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12043087, NULL, 1, NULL, 0xBD0B00000104040000004EB81E45496E334170AC8B5B697E1B41C11726734A6E33415008AC9C697E1B41A3923A414B6E334180FDF675307E1B414EB81E45496E334170AC8B5B697E1B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3B762A534A6E3341C0900F7A567E1B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.370' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.370' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13786121, NULL, 1, NULL, 0xBD0B000001040500000065006F4110A632414047727930A51C41649A777CFEA53241A06588E323A51C4170AC8BFBF1A53241B0BDC1975AA51C411873D752FDA5324120F1634C83A51C4165006F4110A632414047727930A51C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB4C1110200A632411579AF784DA51C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.383' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.383' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11062274, 90069991, 1, NULL, 0xBD0B000001040600000080ED7C7F1A7F294130F9A007492B304140DF4F0D707F2941C419511A552B30419328ED0D6F7F2941801F632E422B3041FDDF2D106C7F2941F4285C0F052B3041FE3C9B15177F2941B4726811062B304180ED7C7F1A7F294130F9A007492B304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1521B0AC447F29416E8247632A2B3041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.400' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.400' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2172232, NULL, 1, NULL, 0xBD0B00000104050000004313618325AE3241E0D6A370DB6E1C4121B0724812AE3241F0AF72682F6F1C416C66662626AE3241701F63EE696F1C4160764FDE3CAE32419088D25EFA6E1C414313618325AE3241E0D6A370DB6E1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2B32F50227AE3241481B5F571D6F1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.413' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.413' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10919473, NULL, 1, NULL, 0xBD0B0000010407000000DA9AE6FDE24834417046943691AC2341DBACFABCDF4834419058A87577AC2341959999B9CE483441D063CC1DEFAB2341152653C5AC483441A0C8767EFDAB2341DF0B9329BE48344140EA04F4ADAC23410AF016E8E0483441784DF3CE92AC2341DA9AE6FDE24834417046943691AC234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C51AAED21C74834414974BCBA4CAC2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.423' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.423' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2848406, NULL, 1, NULL, 0xBD0B000001041C000000E86A2BD60A523541681B0D2026CC2341BC408292095235411071ACEB33CC2341E70434B108523541588FC2D541CC2341421CEB320852354178855AD34FCC23414E62101808523541D02B65D95DCC2341669A775C16523541E8FBA97158CC2341BCC117E617523541A82C43DC57CC2341663BDF6F19523541084B594657CC2341E4B584DC2652354180FB3A3052CC234141FAED4B3552354188B0E1E961CC2341B6627FB95252354170EB51F881CC23416A6666C66252354160EA047493CC2341F4A067D372523541E80DBEF0A4CC2341DC2D90E082523541C0FA5C6DB6CC23415B9FABED9252354158302AE9C7CC2341CE22DBB9B3523541400AD7A3EBCC234133E6AE05B9523541009A081BD9CC23415AA8352DE952354128F6979D0DCD23418B855A53FB523541004D840DCECC23418B5AD3DCFF52354120B07228BECC234110E9B72FFD523541C8915C3EBBCC2341B4F3FD341E523541A04AEA84C8CB2341AB6054F219523541486B9AB7D8CB23412CA089001652354190B0E169E7CB2341394ED18112523541784DF38EF6CB2341199E5E790F5235413090A01806CC2341DC0209EA0C523541D07493F815CC2341E86A2BD60A523541681B0D2026CC234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C36D2DA6F7C523541FD71D2A26ECC2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.437' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.437' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2848392, NULL, 1, NULL, 0xBD0B000001041C000000E86A2BD60A523541681B0D2026CC2341BC408292095235411071ACEB33CC2341E70434B108523541588FC2D541CC2341421CEB320852354178855AD34FCC23414E62101808523541D02B65D95DCC2341669A775C16523541E8FBA97158CC2341BCC117E617523541A82C43DC57CC2341663BDF6F19523541084B594657CC2341E4B584DC2652354180FB3A3052CC234141FAED4B3552354188B0E1E961CC2341B6627FB95252354170EB51F881CC23416A6666C66252354160EA047493CC2341F4A067D372523541E80DBEF0A4CC2341DC2D90E082523541C0FA5C6DB6CC23415B9FABED9252354158302AE9C7CC2341CE22DBB9B3523541400AD7A3EBCC234133E6AE05B9523541009A081BD9CC23415AA8352DE952354128F6979D0DCD23418B855A53FB523541004D840DCECC23418B5AD3DCFF52354120B07228BECC234110E9B72FFD523541C8915C3EBBCC2341B4F3FD341E523541A04AEA84C8CB2341AB6054F219523541486B9AB7D8CB23412CA089001652354190B0E169E7CB2341394ED18112523541784DF38EF6CB2341199E5E790F5235413090A01806CC2341DC0209EA0C523541D07493F815CC2341E86A2BD60A523541681B0D2026CC234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C36D2DA6F7C523541FD71D2A26ECC2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.450' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.450' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15392317, NULL, 1, NULL, 0xBD0B000001040E00000081B74042CBA72D41E0E76A8BE12330416DC5FE72CBA72D41BC9DEF07F22330412EEF388591AA2D41D4BCE374E6233041870D4F2F8FAA2D41F4012B876B233041A3EFA7068FAA2D410C1973B763233041E49C11258DAA2D41580E2D526B233041E99E3C6C81AA2D41103FC61C6A2330410632E62E40A82D4100CE19D12D233041E2E995F23EA82D4198D634CF30233041C1D32B25C9A72D4140772D8124233041C3CAA145CAA72D41600E2D727A2330412D992A58CBA72D41E032C411CC2330417409F960CBA72D4198ABADB8CE23304181B74042CBA72D41E0E76A8BE123304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC36892A40FA92D416659865F98233041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.463' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.463' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090105, NULL, 1, NULL, 0xBD0B0000010405000000E06800EF252E2C41EC60C393FCA03041A1D634EFFC2D2C41382AA953EDA03041624469EFF32D2C4164F38E73F3A03041A3D634EF1C2E2C4150EA04B402A13041E06800EF252E2C41EC60C393FCA0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C065654EF0C2E2C414F7FCD03F8A03041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.473' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.473' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090164, 35720861, 1, NULL, 0xBD0B00000104050000000CF241CFF82D2C41286A4D331BA1304132BB27CFBB2D2C4170BC747304A13041DC6800AFB22D2C41B80E9C930AA13041704DF3CEEF2D2C412C2AA95321A130410CF241CFF82D2C41286A4D331BA1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C485097C0D52D2C4178B05AE112A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.490' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.490' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10128239, 35362221, 1, NULL, 0xBD0B000001041200000074A3017CBC272C411873D7F29BAE30411D0681D5DF262C41BCF1D2CD9CAE30418CA0F831E4262C4188B0E1E970AF3041CDE53FA4ED262C41F01648B06CAF304101A3923AF7262C41F4B0508B68AF3041CBC56DF400272C411C5A647B64AF30416329CBD00A272C4184D2DE8060AF304132BB27CF14272C411C51DA9B5CAF30412FC4B1EE1E272C413CE8D9CC58AF304129C4B12E29272C41E0CEF71355AF3041FE3A708E33272C417CE09C7151AF30418B3A010D3E272C41706FF0E54DAF30419E79C7A948272C41C03B4E714AAF30412641F16353272C41887CD01347AF3041D110C73A5E272C41A8F1D2CD43AF30416991ED3CBF272C415420411127AF3041EFD24D22BF272C4170F2B0D021AF304174A3017CBC272C411873D7F29BAE304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1D33B55E48272C417D92B600F4AE3041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.513' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.513' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977652, 29850321, 1, NULL, 0xBD0B00000104050000002395D4490F7A2B4144D6C56DD7643141DF61A156237A2B41E0AE2544D76431419E57CA72227A2B41D020B052BD6431415E5452670E7A2B414048507CBD6431412395D4490F7A2B4144D6C56DD764314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C0718A6DE187A2B41CAB85F60CA643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.530' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.530' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9939679, NULL, 1, NULL, 0xBD0B0000010405000000767AA5EC3DE53241384BC887AA2F2B4124166A8D3CE5324108AC1C9AE02F2B414CEA041459E5324140E09C91CA2F2B4159B1BFEC59E5324148BA494CAD2F2B41767AA5EC3DE53241384BC887AA2F2B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA9DD4DF749E5324145DB3336C12F2B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.540' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.540' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10596518, 1559831, 1, NULL, 0xBD0B00000104070000000244FA2D0C5329411855306AC5B82E41722F4CA6E353294100C28627CFB82E41E4BE0E5CD4532941585BB13FB1B82E41E268002FE6532941B8A67907AFB72E41A423B9BCE1522941084D840D6BB72E4139D8F0745B522941C09387855CB82E410244FA2D0C5329411855306AC5B82E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA3B23EC138532941DD0DD77F27B82E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.550' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.550' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13843125, 29721481, 1, NULL, 0xBD0B000001040600000013B7D1408A502B4144F8C204BF6031413DA4DFFE8A502B41E49387A5E36031415196210E9F502B41FC8C288DE3603141BC96904F9E502B41243A92EBBE6031418A1804968D502B410CF77500BF60314113B7D1408A502B4144F8C204BF60314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C53D361A794502B410A38CD48D1603141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.563' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.563' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977628, 29845371, 1, NULL, 0xBD0B000001040500000043355E7A5F7A2B41604BC8C7D6643141FF2A87965E7A2B413CB4C8D6BC6431411A95D4894A7A2B4198E4F2FFBC643141C5B12E6E4B7A2B41AC7268F1D664314143355E7A5F7A2B41604BC8C7D664314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA7073202557A2B412774EDE3C9643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.577' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.577' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977857, 23695381, 1, NULL, 0xBD0B0000010405000000819ECD2A717A2B4120EF38E59064314170348037857A2B4154E3A5BB90643141DFB5847C847A2B41F05C6D857964314199D6346F707A2B41684469AF79643141819ECD2A717A2B4120EF38E59064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C35CF88D37A7A2B4184D05D3585643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.587' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.587' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3576825, NULL, 1, NULL, 0xBD0B000001040400000082AEB6222DE23241803BDFCFC9091D4101B37B32FFE13241203199AAF0081D415A2041311EE232418013F241C4091D4182AEB6222DE23241803BDFCFC9091D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF4D57BD718E232410B8023947F091D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.620' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.620' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14612445, 11706601, 1, NULL, 0xBD0B0000010405000000EC95B26C132F344114B6F35DC7E43341536B9AF7A2303441088E7551E5E433416429CB90BC30344138D6C5ED5AE33341B9D1007E2F2F3441848EE4323DE33341EC95B26C132F344114B6F35DC7E4334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFCA7FF99E82F3441F3C5456811E43341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.640' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.640' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 1827391, 34861341, 1, NULL, 0xBD0B000001041800000008F9A00765273441B0D1005E213126416688636D6927344178BC74932531264198B20CE16D27344150B1BF8C29312641F8DBD7617227344160302A492D312641FB31E6EE7627344100B9FCC730312641B19465883F2834415839B448C43126415BC1A8D44528344108917E1BC9312641C064AA104C28344118000040CE3126411E5A643B5228344128CF66B5D3312641887CD05358283441B810C77AD9312641B159F5B981283441D0E76A6B9D3126418738D6E58528344128143F068C302641C432C4D171283441285A64BB8D30264132B29DCF2B273441688FC275A9302641BC6B09592C273441F061A116BB302641EAD0220B3127344170401381C930264181B740323627344100B9FC47D7302641AD8BDBC83B273441D0B5845CE430264191C2F5C84127344100D7A3B0F0302641E4BE0E2C48273441D8581737FC302641F2B050EB4E273441A82E6EE306312641DA5F76FF55273441B0703DAA1031264188D2DE605D27344108EEEB801931264108F9A00765273441B0D1005E2131264101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4E15A5B2FC273441C3C496BE10312641, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.650' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.650' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13601695, NULL, 1, NULL, 0xBD0B000001040500000099438B8CE98E324180D93DF9B0261D415AEC2F9BF38E3241408C4A6AB2261D41BBAF03C7F48E324180BE9F9A2F261D41F8065FB8EA8E3241D00B93292E261D4199438B8CE98E324180D93DF9B0261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAA79C729EF8E324102CCEE4970261D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.660' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.660' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13508466, NULL, 1, NULL, 0xBD0B000001040F000000A56054D2C9A43441F04A59C63D89274176F2B010F0A43441D0E00B53438927412141F183EEA43441A087855A2689274185635DDCEFA434418095434BE888274102098A1FEFA43441F0E99532DC882741E9F21F72E8A43441185839749F8827416C09F900E8A43441B830996A6B882741FFFFFF1FB9A43441A8F3FD9464882741A6ADD8BFBFA4344170CDAA4F3C892741A56054D2C9A43441F04A59C63D89274141CF661594A43441B0847C505F88274186855AB3E8A3344178855A5346882741066822CCE0A33441D032C4F11B892741F11FD22F98A43441E86800AF3689274141CF661594A43441B0847C505F882741020000000200000000020A00000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010CE9D0F0B15DA43441839E9BECC3882741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.670' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.670' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226193, 90073095, 1, NULL, 0xBD0B000001040600000032B29D6F172E2C41C8D781334FA130416F4DF38E612E2C4168BC74934EA130412DBB274F612E2C41302AA9F346A1304155840D4F1A2E2C418C855A7347A130410EF2414F172E2C410C61C39349A1304132B29D6F172E2C41C8D781334FA1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C557E01833C2E2C41142964114BA13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.680' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.680' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12648388, NULL, 1, NULL, 0xBD0B0000010407000000735F074ECBFC25410898DD930FD22F417AC95421C7FC2541909ECD0A09D22F41FAEF16A8C2FC2541004625B502D22F4126F8C2E4BDFC254188D85F96FCD12F411C7502DAB8FC254178A0F8B1F6D12F412CD49AE6B7FC254140F38E93F6D12F41735F074ECBFC25410898DD930FD22F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE9BB5BBAC0FC254100FBF53801D22F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.693' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.693' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977822, 23695121, 1, NULL, 0xBD0B0000010405000000DAF21F12497A2B417019E23891643141B5BFEC1E5D7A2B4104F2410F91643141E11B7C615C7A2B414C4772D9796431410861C353487A2B41FC497B037A643141DAF21F12497A2B417019E2389164314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC0B799B9527A2B41C3442D8985643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.703' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.703' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6091407, NULL, 1, NULL, 0xBD0B000001040700000079711B2DA98F3141404CA68A04351C41BC0E9CB3AC8F3141A089B0E1B5341C416A88637DAB8F3141D0BCE394B5341C412E3333F3A48F314120FDF6F5B3341C41EA61A176A28F314100DCD78154351C41334CA6EAA78F3141101AC0DB55351C4179711B2DA98F3141404CA68A04351C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3BD147D7A68F314146CFCFEAFF341C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.713' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.713' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14073676, NULL, 1, NULL, 0xBD0B0000010419000000DF4F8D77FE29344160D6C5ED460A1E414A477219F7293441C0DF2D903E0C1E411C7C61B2892A3441707DAEB6100E1E41C94B37698F2A3441F0187357F30D1E412DC4B10E9B2A344170128340B60D1E41EA61A1B6A12A3441603EE8D9960D1E418ADB6840A52A344130FDF6F5820D1E41489D8006A92A344110C139A3690D1E41867CD053AB2A3441C03D79D8540D1E411AFBCBEEAC2A3441D01726533D0D1E4108F016E8AE2A3441C00C712C260D1E415327A0C9AE2A3441B0BDC1170D0D1E41F341CFA6AD2A3441B09F1AAFF40C1E41B2BFEC1EAA2A3441E0B5157BD00C1E418AC95421A72A3441C0EA7335B00C1E412F08ACFCA42A344110B5A6F9970C1E410C5F98CCA22A3441C0240681870C1E41FF6E81E4822A344150BF7D1D0C0C1E41462EFF01672A344130D7A370770B1E4192A982E1522A3441E01E85EB330B1E41BA96905F3E2A344170B74042F20A1E413FA4DF7E292A3441A011A57DB20A1E4137454742142A3441B0C117A6740A1E41085F98ACFE293441D05CFEC3380A1E41DF4F8D77FE29344160D6C5ED460A1E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C70E909984C2A3441243CC32E3C0C1E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.727' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.727' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 24777188, NULL, 1, NULL, 0xBD0B000001040500000021D26F7FC83932418038D645928517412D90A0F8BF393241301136BC8A8517417D6ABC34BB39324190C729BABB8517412D55302AC3393241D0012B87C285174121D26F7FC83932418038D6459285174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB4E4A9BCC1393241C4F9C685A6851741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.737' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.737' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8192294, NULL, 1, NULL, 0xBD0B00000104070000005427A0696839324150EF38C5198A17418541602564393241E0D6A3F0158A1741B2506BDA62393241E09F1A2F238A17418395438B5639324190CCCC4CA18A1741D088D27E5F393241300F0B35A98A174191CB7F6860393241706B9A77A78A17415427A0696839324150EF38C5198A174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C18B80D2360393241446458DF678A1741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.747' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.747' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083647, NULL, 1, NULL, 0xBD0B00000104050000008626C246386E2B414C3EE859AB6431419C2C435C4C6E2B4168711B0DB0643141F2FDD4784B6E2B410460766F906431418E416065376E2B41D8F97E8A906431418626C246386E2B414C3EE859AB64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9198E026426E2B413BAE0C1C9F643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.757' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.757' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13978055, 23696581, 1, NULL, 0xBD0B0000010405000000463EE8D993792B41906CE77B7B6431414C840DCF7F792B4148B81EA57B643141BB293A9280792B414CD191DC926431410E1B9E9E94792B418C8EE4B292643141463EE8D993792B41906CE77B7B64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5D836C368A792B410C83452C87643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.767' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.767' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13998111, 23689131, 1, NULL, 0xBD0B0000010405000000B059F5B909792B41344ED191BF643141EA9E3CACF5782B4184BE9FBABF643141CAA3707DF6782B412497FFB0D9643141034D848D0A792B41F4384587D9643141B059F5B909792B41344ED191BF64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC0EF3C1C00792B413F676FA1CC643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.777' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.777' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13978012, 23696161, 1, NULL, 0xBD0B0000010405000000CA09686230792B41E4C0398393643141A5E8486E44792B412C7E8C5993643141891F63AE43792B41482EFF217C6431418F6588A32F792B418895434B7C643141CA09686230792B41E4C039839364314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C668DA0083A792B4185EF9BD287643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.787' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.787' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9096426, 90072570, 1, NULL, 0xBD0B0000010405000000B4FEB27BE8F226418C0D4F0FC9AD32419FF831A6CBF22641287A364BB2AD324115F241CFD2F22641F8088A5FD7AD3241DCA59B04EBF2264180734634D6AD3241B4FEB27BE8F226418C0D4F0FC9AD324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4F493362DAF226418675EB5FC9AD3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.797' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.797' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15937461, NULL, 1, NULL, 0xBD0B00000104050000001BE258B726833241C8A145B6A24A2E41D58173E61C83324120DE0209994A2E41460C02AB1C83324120DF4F0DA34A2E4152E3A57B26833241F0EBC0B9AC4A2E411BE258B726833241C8A145B6A24A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C92A111B121833241B80C85E1A24A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.823' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.823' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13253000, 35754031, 1, NULL, 0xBD0B0000010406000000B6D85F76CD2E2C413895D409D1A03041D422DBB99E2E2C41649A775CD1A03041CA2B6519932E2C4158C8071DD9A03041AFF3FD54CF2E2C4118FBCBCED8A03041F0482E3FCF2E2C41D402090AD1A03041B6D85F76CD2E2C413895D409D1A0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C1C27C10DB42E2C4154229937D5A03041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.860' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.860' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226223, 35711691, 1, NULL, 0xBD0B0000010405000000E06800AF612E2C41B40E9C3356A130412CBB278F172E2C41282AA9D356A130412ABB27CF172E2C41D4D781735EA130410032E6EE612E2C4170BC74D35DA13041E06800AF612E2C41B40E9C3356A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA0540DBF3C2E2C4129BA8E535AA13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.873' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.873' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 18289886, 90056932, 1, NULL, 0xBD0B000001040C0100004D7DAE762CFD2941245F980CF60331412187161921FD2941A8EFA786EC0331417C0B242817FD2941109C33E2E4033141411CEBE20EFD294188764FFEDC033141F5482E7F08FD29419401BC65D7033141061214BF04FD2941D0DCB504D3033141B9BAB8CD01FD2941E4E00B33CE03314166D3BC6301FD2941186A4D53C903314140136183FFFC294150AF9425C2033141928785DAFEFC2941904C156CB5033141BE8F31B7FCFC29414C4DF32EA603314162545267FBFC2941502041B1A003314187AEB6A2FBFC294164621078990331417CA7570AFBFC2941303EE879920331410AF241CFF9FC2941B81726F388033141535986B8F8FC2941607FD91D81033141733D0A17F8FC2941FCA067B379033141D412F2C1F9FC29418C9999796F033141E79C1125FBFC2941807346F4660331414E9D8026FBFC2941F80FE917580331412E1AC01BFBFC29419CCFD5B6430331412DCB1087FAFC2941647FD9BD36033141C7B12EAEF9FC2941C854C1482D03314189438B2CF6FC2941744F1E3620033141626DC53EEFFC2941248716591103314141674469E2FC294178EE5A22FD0231412A6EA301D5FC2941703BDF6FEC02314107E78CA8C6FC294140795808E00231410AC7BA78BDFC294184C0CA61D502314114B5A6F9B5FC2941789ECDAACC02314180FB3A70AEFC2941FCDD0209C60231411A41F1E39AFC2941AC7BF270B702314197A0F8F18AFC294140454732AA0231412D7E8C3963FC2941709A777C93023141A0EFA7C64BFC2941F861A1B687023141C066D5E734FC29419C28ED0D7B02314194A982112AFC2941349FAB0D7402314171787AE51DFC2941E064AAC06C02314184FD65B703FC29413C70CE885D023141120F0BB5E9FB294108075FD84F02314146575BF1D3FB2941B0923A6143023141142428BECCFB2941D402092A3E02314195DFBE4EBAFB29411826536532023141A03C2CD4ABFB2941DC10C71A2A02314185832FCC9EFB2941F83A70EE220231413055306A8CFB2941B0CFD5561A02314105917E3B86FB2941FC9908DB16023141566B9AB77BFB29418831770D11023141322AA91377FB294180C954C10D023141F71648D063FB2941580E2D1205023141BB5B20C152FB29411071ACABFC013141EA41CFA643FB2941443EE839F4013141F616481027FB2941D010C7DAE301314162BA490C18FB29415C1B0DE0D9013141549D80A60CFB2941085A64FBD30131419CE848EE05FB2941DCBAB84DCF013141D0E53FA4FBFA29418875719BC90131415505A352F4FA294140E4831EC80131415DB1BF6CF0FA2941A415FB6BC801314101000080EBFA29419C9999F9C901314176A301FCE6FA2941F0361AD0CB013141F3C48FF1E2FA29411CC7BAE8CD01314116E9B76FDFFA294150E3A53BD0013141A9AF0367E0FA294148696FF0D3013141FDAB1C1AE0FA2941F0EDEBA0DA01314120166A8DDEFA2941D0073D7BDF0131412AFF213DDEFA2941A8CDAA0FE6013141ECA7C68BDDFA294148840D4FED01314180B740C2DCFA29412C2CD4FAF5013141C73B4E51DCFA294118D6C52D00023141B003E70CDBFA2941047A36CB05023141DA0B9369DCFA29416CD712920B023141628FC275DCFA294194537444110231413D72F90FDCFA2941C8ACFADC16023141DAD781F3DCFA2941C0FEB2BB1E02314172F90F29DBFA2941AC1C5AE4250231410E3FC6DCD9FA294144FC18B32D0231418A635DDCD9FA294198081B5E35023141A0EFA746DBFA294120C7BA78430231413F6210D8DAFA294148E17A344B0231412BAB3E97DAFA2941BCDEE0EB4F023141D27F48FFD8FA2941685DDC865E02314185C7293AD7FA2941684BC8E765023141D2BCE394D6FA294168CE88B26D023141B1DCB504D6FA2941888EE45271023141083D9BD5D5FA294138E9B76F79023141D5B359F5D1FA2941F4E461418402314165EE5A82D0FA29419C2A18D58C02314154FE433ACFFA29414070CE4892023141C5E3141DCEFA294194DB68209702314193CB7F48CCFA29411490A0389B023141C7293AD2CCFA29419CC42090A10231416F029AC8C9FA294124B9FC67A902314123D26FDFCAFA29410432E6AEB302314104363CBDCBFA2941A09BC400C3023141D0073D9BCBFA2941DCAE2524C9023141E41B7CE1CCFA294134D6C54DCB0231416C2BF657CBFA294118D26FBFCD0231413CFC18B3CBFA29415C9FAB0DD70231412095D449CAFA2941F49E3C8CDD023141D49AE6DDCAFA2941A4900F7AE90231412DC4B1EEC8FA2941A0081B5EEC02314140CF6655C9FA294154621038F6023141CC54C128C9FA29410CD7A370FE02314180A7570ACAFA29419C01BCA5150331410624287EC8FA29419C779CC223033141A433A2B4C9FA29417816D94E2A0331410FB5A679C8FA2941F487F45B300331414CD1911CC7FA2941B003E78C3C0331411E31082CC5FA29410463EE7A440331414594F646C6FA294130E4837E510331410EBE3099C6FA2941F01873D7570331417B832FCCC2FA2941D44B37896303314186B20C71C1FA2941EC2FBBC76F0331412ADD2406C1FA294124B072287503314194CB7F88BFFA2941C03B4ED17F0331411FA08930C0FA294190900F1A8A03314124287E4CBFFA2941F8065FB89603314151EA04F4BDFA29412863EEFA9D0331412C3A928BBDFA2941D4B584FCA5033141626DC5BEBEFA294188711B6DAC0331411A75029ABEFA2941207E8CF9B4033141FCD47829BFFA294190A7572ABE03314164643BDFC0FA2941FC065F78C50331411E431CABC2FA2941487958E8D2033141766FF085C4FA29419475717BDE033141FF3A70CEC5FA2941308B6CE7E503314146D6C5EDC3FA29411C6A4D73E90331413E0C026BC2FA2941082428BEEE033141F5EBC079C3FA2941740D4F0FF6033141C35B2041C6FA294154643B1FFD033141ED73B555CAFA294198711BAD060431415E764FDECDFA2941004D84ED0E0431417E1D38A7D1FA294158E3A5FB140431410710E9B7D4FA29419CC2F5481A043141510C02ABD9FA2941106822AC1E043141E0AE2564DDFA2941A0B20C7121043141128C4A2AE1FA29413C5305632704314198FD6537E7FA294150BF7D7D2E043141FE11147FECFA2941C49F1A2F340431415B19E298F3FA29414CFC18D33A043141E0938705FDFA2941B8847CB0450431415EA1D6B402FB294144F1630C4B0431418CFF90BE0CFB29416C4F1E76550431413CE17A5413FB2941E02D90205B043141DA2406411CFB294174FD65B7620431414DC1A86427FB2941C8F21FB26A0431411C85EB9133FB29412CF775A074043141C48173863CFB2941E4B9DA8A7C043141DF2D902048FB294110AB3ED784043141D466D5274FFB2941E4C7989B8A04314193635D1C5AFB2941181FF48C950431413DD6C5ED6AFB294158A835EDA7043141B08251C97DFB2941A4DD9307B304314135696FF08FFB29417CF08509BE043141124850BCA3FB2941F0285C6FCA0431410288F41BB3FB29418C1D3887D3043141746891ADC4FB2941904C15CCDC04314109E9B72FD4FB294154B81E65E5043141943A018DE3FB294194C95461EE04314198E8482E01FC29413C1CEBA2FD0431410E0BB56612FC2941A864AA6005053141208E75F12FFC29416C2BF697130531417109F9A04DFC2941184850FC200531412A89416062FC2941C87D1DB82B053141D06F5FC795FC2941FCB27BF2420531418F438B2CB3FC2941E04603784F05314119D26FDFC6FC2941ECAE252458053141C26B0939DBFC29410C4D84CD600531412E3333B3E6FC294154B1BF0C6505314175810445F9FC2941848638766A053141F2FDD47805FD294100BC05926F05314136CB108716FD2941C486A7577505314188AEB6222FFD2941180EBED07C053141F2C039E345FD29414070CE888505314180FB3AB04EFD294180976E128905314168006F415DFD2941E48C28CD8D053141568D976E63FD2941780B24A88E0531416B5F078E69FD2941BCFEB27B9105314142DF4F4D73FD2941F8EDEBE095053141BAE53F8475FD29410075023A97053141E0065F1878FD2941A0CFD56698053141E1BE0EFC7AFD294170E926619905314190E4F21F7EFD2941E0EEC9239A053141496B9A3782FD2941D40968229C0531419B4E40D393FD29415CCC5D0BA30531415ABA490CA0FD294124D26F5FA80531413E92CB3FB9FD2941BC6054B2B10531413FE8D9ACC6FD2941244CA6CAB505314130575BB1CFFD294188855A53B90531415C19E218E3FD29412C772D21C105314168469476F3FD294190506B7AC6053141B237F84205FE2941C0FC8754CD05314187E2C75818FE2941C89690EFD30531417AD0B3592CFE2941C81E85CBDA053141112DB25D41FE2941D45D4B08E105314137575BF158FE294120F2412FE9053141432CD49A6FFE2941704469CFF0053141A457CA7283FE2941CCB35915F60531414060E5908EFE2941DC293AB2F8053141948EE43294FE294120189554FA053141ADEA737596FE294198CDAA8FF60531412F55306A9BFE294198438B4CF0053141FB5E984CA2FE294130D26FDFE7053141828CB9EBA9FE2941E0946528DE0531410FE9B72FB2FE2941F40FE917D2053141FE331136B8FE2941ACA22379C9053141CDA3703DBDFE29411CF2410FC40531413008AC7CBFFE2941E48E5384C1053141FC3A70CEC1FE294134F697FDBE053141E0E99532C4FE2941F4D0227BBC0531419228ED0DC4FE29412808ACECBA0531415B423EC8C3FE2941C07F485FB90531419A89B061C3FE2941A045B6D3B7053141F8E461A1BFFE294168FC1873B3053141239E5EA9B8FE2941EC8E53F4AB0531418EFF90BEB1FE2941F4FDD418A50531410A9C3322A4FE2941685452079A053141FDE68C289AFE2941242B87F6910531414172F98F8DFE29413C0AD7E388053141145305E384FE29410CD04438810531413B7958E879FE2941204A7B43770531413208AC9C6EFE294118F46C966E0531413D696FF060FE2941C86F5FC762053141C781738643FE294124B7D1A04B0531413767442939FE294104E483FE43053141536B9AF731FE29410022FDD63E053141B5A679072AFE2941F8E461E135053141D8E9957226FE29418426C2862E053141FFEDEB8025FE29415093186428053141E08C28ED24FE294170A3019C210531411EF8C26422FE29412CB29DAF1705314164FE43BA21FE2941C87D1DD80F053141B47BF2B020FE29410C8A1F430B053141C00512940EFE294140AF9405F9043141E102098A03FE2941B0B43718ED043141ECD24D62E7FD29417C4F1EF6D204314124B9FC07E3FD2941CC66D5E7CD04314143014D84D8FD2941BCF3FD94C50431418AD2DE20CEFD2941445EBA29BC0431414BEC2F3BC8FD29410071ACEBB604314160D3BC63C5FD29413CB6F33DB4043141C9B359B5B8FD29415CA835EDA60431410B71AC8BAEFD29412048509C9D043141A913D004A3FD294108E9B74F9104314180F2B01091FD294190B96B697E04314190A9821182FD2941408941806F04314156EC2F3B80FD2941D044D8D06B043141DFF97EEA7AFD2941D46800AF6504314105098A1F71FD29417CF4DB975B0431419CF831666BFD2941F095B2CC55043141B213D0C465FD2941F8A9F1F24B0431417EE9267160FD2941B8F3FDB445043141CCBCE3145CFD294158158C8A400431411EC2866755FD2941580B24C839043141E62631C853FD294108E25817360431419E67B3AA52FD294114D26F5F340431412E211FD451FD294118F6979D320431410E1DC94551FD2941F0A59BD4300431414D499D0051FD29415C8B6C072F04314112D044D84CFD29419CFF901E27043141F2065F5849FD2941040DE04D1F043141A3703DCA44FD294118D9CED717043141BC0E9C3340FD2941F0E99592120431415650FC183DFD2941886ABCD40C043141C332C4713BFD294150840D2F060431416A2BF6D738FD2941A8BAB8ADFE0331414D7DAE762CFD2941245F980CF603314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C7F89C28E4AFC2941E7B1DE8BF2033141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.883' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.883' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2590956, NULL, 1, NULL, 0xBD0B0000010405000000C4A8A4EE803C31415015FBCBD5EB1C41B1B6629F763C314100780B246CEB1C415BC1A8244A3C3141E0D5E7EAD1EB1C4101098A3F493C3141809A771C2CEC1C41C4A8A4EE803C31415015FBCBD5EB1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA564163D643C3141418522E0CEEB1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.897' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.897' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 832570, NULL, 1, NULL, 0xBD0B00000104060000001751DABB64AB324170992A9899621C41CE2B65D94FAB3241F0AB1CDAE9621C41F28E53345EAB32414039B4483E631C41964C150C6FAB32413009F920FE621C418E0F7AB674AB324130DFE08BE8621C411751DABB64AB324170992A9899621C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFFF47AF961AB3241993D8904EB621C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.903' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.903' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 832570, NULL, 1, NULL, 0xBD0B00000104060000001751DABB64AB324170992A9899621C41CE2B65D94FAB3241F0AB1CDAE9621C41F28E53345EAB32414039B4483E631C41964C150C6FAB32413009F920FE621C418E0F7AB674AB324130DFE08BE8621C411751DABB64AB324170992A9899621C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFFF47AF961AB3241993D8904EB621C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.913' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.913' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 832570, NULL, 1, NULL, 0xBD0B00000104060000001751DABB64AB324170992A9899621C41CE2B65D94FAB3241F0AB1CDAE9621C41F28E53345EAB32414039B4483E631C41964C150C6FAB32413009F920FE621C418E0F7AB674AB324130DFE08BE8621C411751DABB64AB324170992A9899621C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFFF47AF961AB3241993D8904EB621C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.930' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.930' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 832570, NULL, 1, NULL, 0xBD0B00000104060000001751DABB64AB324170992A9899621C41CE2B65D94FAB3241F0AB1CDAE9621C41F28E53345EAB32414039B4483E631C41964C150C6FAB32413009F920FE621C418E0F7AB674AB324130DFE08BE8621C411751DABB64AB324170992A9899621C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CFFF47AF961AB3241993D8904EB621C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.940' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.940' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 23844361, NULL, 1, NULL, 0xBD0B0000010409000000CEAACF550A79324170855AD3CF911C41FD088ADFDB783241D0D9AC7AC8911C41BA270F6BC3783241B0A44E40FE911C41ACDFBECE02793241801A2FDD09921C41032B87A604793241E056ECAF09921C41D43D797806793241F0A59B8408921C419B4C153C08793241A09BC46006921C41E1141DE909793241003B704E03921C41CEAACF550A79324170855AD3CF911C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE5C43867EC783241DD64743DEA911C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.953' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.953' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8487464, NULL, 1, NULL, 0xBD0B0000010410000000E4AE25E4123D3641C8EC9E3C5A6B274188635DBCB73D3641F8EDEBC0116D27413F2CD49AC43D3641D0CCCC0C006D274196779C82613E364170348037286C27416307CE996E3E3641C8B35935166C27417DC0CA01B53D364160764F9EEB692741C1F5285C6F3D3641A8D78173496A27411451DA1B083D3641A8832F0CD86A2741CFB359B5F43C3641481136BCF26A274143BD5256EC3C3641B0361A40FE6A2741C20E9CB3EB3C364190E4F21FFF6A2741B7B88D46E53C3641287DAEF6076B274154B1BF4CE33C3641480DE0AD0A6B27412CFF213DF73C3641305C8F022C6B2741FD87F49B003D3641C8FA5CAD3B6B2741E4AE25E4123D3641C8EC9E3C5A6B274101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6F47B237B03D3641401B70427F6B2741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.963' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.963' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4978994, NULL, 1, NULL, 0xBD0B0000010408000000940F7A167A3630419023B9FCA27920416CAC8BFB5A363041104D840DA1792041A211A53D5436304100A16773E1792041497B83CF523630417836AB3EEF7920414260E55063363041B03C2C94177A2041769CA2C369363041A8506B1A287A2041BC1726337C36304158302AA9077A2041940F7A167A3630419023B9FCA279204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3298DE4C693630412E7B2563DD792041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.973' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.973' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10308610, 4916441, 1, NULL, 0xBD0B0000010405000000DB1B7C410AF33241683BDF8F5C99294176A52C6315F33241683789412199294110F241AFA7F23241089F3C6C1499294132E6AE05A6F232418857CA7251992941DB1B7C410AF33241683BDF8F5C99294101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6E5A484BDBF232414A21D17438992941, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.983' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.983' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15848591, 1780841, 1, NULL, 0xBD0B0000010405000000DF361AA0BA3D3141282CD4DAC6D32E413FBD52364D3F314160BA494CDBD32E41A3EFA7A6573F3141A0BFEC5EB5D02E4100098A5FC53D3141E0AE25E4A0D02E41DF361AA0BA3D3141282CD4DAC6D32E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C68656D36893E31412703B1273ED22E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:16.993' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:16.993' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12640204, NULL, 1, NULL, 0xBD0B000001040B000000EC8E537474BA2C4120E483FE635C3041817346D475BA2C4144AD697E825C304141E17A1477BA2C41A8C8765E9D5C30419C33A234C0BA2C41BCC876BE9C5C30410E4FAF54BFBA2C41B8BFEC5E8E5C30419B3C2C94BEBA2C418036AB7E815C3041CBC56D34BDBA2C41E051B87E625C30411AE25817BCBA2C4124B7D1404A5C304159D5E72ABBBA2C41942C43DC365C3041F28E53B471BA2C41081B9E9E265C3041EC8E537474BA2C4120E483FE635C304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CBF28570998BA2C41F3832DD5655C3041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.003' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.003' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14083531, 14745701, 1, NULL, 0xBD0B000001040500000014E9B7AFB06E2B413CFAED4BB46431416A1283C0C46E2B4130431C2BB4643141118C4AAAC36E2B41B442ADA98F643141161DC9A5AF6E2B410C4D84CD8F64314114E9B7AFB06E2B413CFAED4BB464314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2BCD4530BA6E2B41FF9C68FDA1643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.017' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.017' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12572063, 13416291, 1, NULL, 0xBD0B0000010405000000ECB7AF43C31F224178711B8DCFF92D41B23E575BC91F2241B0E61DA71BFA2D410266F7A4E71F2241685BB13F19FA2D415A711B8DE11F2241008A1F23CDF92D41ECB7AF43C31F224178711B8DCFF92D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2B2F5C74D51F2241EAD2C065F4F92D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.027' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.027' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977971, 23695541, 1, NULL, 0xBD0B000001040500000053EA0474DF782B4100CE19F17C6431417F7AA52CE0782B417495432B946431411CDBF93EF4782B41484013019464314160EE5A82F3782B41C866D5C77C64314153EA0474DF782B4100CE19F17C64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB38772D8E9782B414BF4B47988643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.037' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.037' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10418555, 16707561, 1, NULL, 0xBD0B000001040500000037894120528232415839B4484F4A2E41E07A146E51823241F007ACDC6D4A2E4109560E8D77823241D8F75323714A2E4155643B3F7882324100295C8F524A2E4137894120528232415839B4484F4A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA4EFA7D66482324189180436604A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.057' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.057' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14342197, NULL, 1, NULL, 0xBD0B000001043100000070348077D4B8354148B5A6F938A6234178BE9F3ACAB83541688716193CA62341905374A4C1B8354110022B073FA6234151AF94E5BFB83541D076BEDF65A62341A879C7A9C9B835418016D90E63A62341621058D9D0B83541402AA95360A6234157EC2F9BEEB835418879C76958A62341A267B36AF7B83541E8285C4F59A62341893177AD0DB9354138F31F1260A62341F4C9C3A214B93541488B6C2762A623419CCDAA0F1BB9354158C1A8A464A623413FAD69DE41B935419026C2466EA62341E72631084AB93541E8718A4E6FA62341EC1DA74869B93541C0D9ACFA75A62341EB2631E873B9354188A52C4379A62341AB0A46659AB93541E8C798BB89A623411EF46C16A3B935413855302A8DA623416B810485ACB9354150DBF93E91A62341745F072ED2B93541A8946548A0A623412DB29DAFDAB93541F08E53F4A4A62341A3F831E6E6B9354100F01608A9A62341F95C6DE5F1B93541B0802642ACA623413CF8C2E4DDBB354168DE71CA01A72341D2B359D5DFBB3541405839F4DAA62341984C15CCBFBB35417088637DCAA623419B4C159C9FBB3541E82D9040BBA6234189EB51487FBB3541402D213FADA623413E0AD7D35EBB3541F8506B7AA0A62341E6FBA9413EBB354188F38EF394A6234160A1D6941DBB3541708CB9AB8AA623418CDB68D0FCBA3541C8EEC9A381A62341011973F7DBBA35416008ACDC79A62341CB20B072C2B93541C822DBF93BA6234179832F0C57B9354108D9CE7725A62341CD44D8C050B93541D8C3422D24A62341789CA2734AB93541A84B370923A62341A813D02444B93541303A920B22A62341531E162A43B9354140EC2F3B2EA6234126F697BD3BB93541B0703D8A2DA623412A53056331B93541A8DFBE0E2DA623410AF0160827B93541584469EF2CA623418E3A01AD1CB93541E08C282D2DA6234151FC185312B93541103945C72DA6234154F5B9FA07B93541707FD9BD2EA62341904AEAA4FDB83541F004341130A62341363CBD52F3B8354180C954C131A623416E8A8E04E9B8354120166ACD33A6234171B515BBDEB83541588FC23536A6234170348077D4B8354148B5A6F938A6234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD28080D457BA35410406EBC58CA62341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:58.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.090' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.090' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14342197, NULL, 1, NULL, 0xBD0B000001043100000070348077D4B8354148B5A6F938A6234178BE9F3ACAB83541688716193CA62341905374A4C1B8354110022B073FA6234151AF94E5BFB83541D076BEDF65A62341A879C7A9C9B835418016D90E63A62341621058D9D0B83541402AA95360A6234157EC2F9BEEB835418879C76958A62341A267B36AF7B83541E8285C4F59A62341893177AD0DB9354138F31F1260A62341F4C9C3A214B93541488B6C2762A623419CCDAA0F1BB9354158C1A8A464A623413FAD69DE41B935419026C2466EA62341E72631084AB93541E8718A4E6FA62341EC1DA74869B93541C0D9ACFA75A62341EB2631E873B9354188A52C4379A62341AB0A46659AB93541E8C798BB89A623411EF46C16A3B935413855302A8DA623416B810485ACB9354150DBF93E91A62341745F072ED2B93541A8946548A0A623412DB29DAFDAB93541F08E53F4A4A62341A3F831E6E6B9354100F01608A9A62341F95C6DE5F1B93541B0802642ACA623413CF8C2E4DDBB354168DE71CA01A72341D2B359D5DFBB3541405839F4DAA62341984C15CCBFBB35417088637DCAA623419B4C159C9FBB3541E82D9040BBA6234189EB51487FBB3541402D213FADA623413E0AD7D35EBB3541F8506B7AA0A62341E6FBA9413EBB354188F38EF394A6234160A1D6941DBB3541708CB9AB8AA623418CDB68D0FCBA3541C8EEC9A381A62341011973F7DBBA35416008ACDC79A62341CB20B072C2B93541C822DBF93BA6234179832F0C57B9354108D9CE7725A62341CD44D8C050B93541D8C3422D24A62341789CA2734AB93541A84B370923A62341A813D02444B93541303A920B22A62341531E162A43B9354140EC2F3B2EA6234126F697BD3BB93541B0703D8A2DA623412A53056331B93541A8DFBE0E2DA623410AF0160827B93541584469EF2CA623418E3A01AD1CB93541E08C282D2DA6234151FC185312B93541103945C72DA6234154F5B9FA07B93541707FD9BD2EA62341904AEAA4FDB83541F004341130A62341363CBD52F3B8354180C954C131A623416E8A8E04E9B8354120166ACD33A6234171B515BBDEB83541588FC23536A6234170348077D4B8354148B5A6F938A6234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD28080D457BA35410406EBC58CA62341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.103' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.103' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10456481, 7803551, 1, NULL, 0xBD0B000001040F000000F041CF66A6F13441C4FEB2FB58A03241BBD100BE98F13441B0EA73D557A03241D0BCE3B478F134414413612355A0324140E8D90C83F03441643EE87940A03241438B6C2761F034411CB9FC47D2A13241F8E461413FF03441184FAF1464A332417A58A8F5D0F13441E088D2DE85A33241DDE995B262F33441AC8251A9A7A332413CCD3B6E72F33441D0817306EEA232417A58A87577F33441FCA7C64BB2A23241592041B184F33441EC51B8DE15A23241EA0434B1A6F334412873D71284A03241608FC2359AF23441E4A3707D6DA03241BEF528DC14F23441FC4A594662A03241F041CF66A6F13441C4FEB2FB58A0324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3EE853EDF2F134414585D50EF4A13241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.113' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.113' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226274, 35711981, 1, NULL, 0xBD0B0000010405000000C59F1A2F182E2C4178BC74B36DA1304130BB274F182E2C41D00E9C5375A13041DF68006F622E2C41DCD781D374A13041FA31E62E622E2C41382AA9136DA13041C59F1A2F182E2C4178BC74B36DA1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3970AE603D2E2C412F5FA23B71A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.127' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.127' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4969847, NULL, 1, NULL, 0xBD0B000001044F0000009C627FD92817294150F38E732491304118DBF9BEE216294138F163CC259130419028EDCDE01629419C01BC65289130416207CED9E016294114E4837E4091304112143F86E31629419CF4DB7748913041FC550EADF016294198FF903E56913041DE938745F11629411C8A1F435D913041CE7F483FED16294110D7A37074913041A8EFA7C6E7162941008F53947A913041A62C43DCE7162941187D3F957B91304108CCEE89D51629411468220C8F913041D9839E8DBE162941C8C56D949A913041445227A09C162941DC9C1165B2913041DC839ECD7B1629415C9A773CD7913041063D9B157B1629412CA91350E691304162FE437A40162941200DE0CD24923041FE1873172F1629414C158C4A43923041BE0968222A162941C020B0724F923041F87E6A3C18162941647AA5EC67923041C586A757D41529410C5D6DA5AE923041D678E9E6B815294190EB5158BF9230410AF016883A162941289A08DBBC923041119C33625D162941B0E1E915869230417DD93DF97E162941A8D85FB67F9230412B333313841629410493A922769230416A68914D8A16294174E7FBB96C92304181AEB6A291162941AC13D084639230419A4C150C9A162941DCE76A8B5A92304128651982A316294198E1E9D551923041301136FCAD16294144DA1B6C49923041B07BF270B9162941083D9B5541923041FC3311D6C5162941C842AD99399230411AC05B20D3162941800D4F3F32923041AD25E443E116294168711B4D2B923041F151B8DE55172941B0FA5CCD879130418628ED0D541729417CCE88227B91304133CD3B6E53172941583255706E913041741B0D0054172941A8D100BE619130418C6E12C355172941FC92A91255913041C5A145B658172941D493877548913041DC4603D85C172941589FABED3B913041F453E32562172941500E2D822F913041E2ACFA9C6817294100AC1C3A239130419C627FD92817294150F38E73249130414CEC2F7BA7162941B425E4C3A4923041624DF34E9A16294134014D04BB9230412D136183A91829412C014DE4B09230415ABA49CCA7182941FCFFFF5F9A923041DA1DA7E88A182941A401BCA51D913041A6CDAA0FB8172941D4E00BB321913041AB825109A8172941B009680222913041E65817B7A0172941E81B7C012E913041EF2FBBA79A172941C8C3422D3A913041F8088ADF95172941CCC3427D46913041EEDBD761921729416819E2E85291304196B20C3190172941743480675F913041B9A8A44E8F172941D04D62F06B913041A23E57BB8F172941809ECD7A789130413DB4C87691172941BCD100FE8491304152A60AC69A1729410495D449B99130410D2428DE9A17294150742487C3913041B5F3FD9499172941489B55BFCD913041A04C15EC96172941B40F7AE6D7913041BC8173E6921729414829CBF0E1913041B18BDB888D172941DCE995D2EB913041357E8CD98617294158325580F5913041BE6D34E07E172941DC88D2EEFE9130419DF831A675172941A06E121308923041668638366B172941D00968E210923041EE7E6A9C5F1729415405A35219923041842F4CE652172941503EE85921923041A3779C22451729413CA4DFEE28923041EFE4616136172941F054C10830923041FBFFFF3F0B17294164787AC540923041B469DEB1F6162941EC907E3B4B923041B447E17AE4162941D0ACFABC569230416C711B0DCB1629415CE5D0C26C923041C5F75323BA1629415CD3BCC3849230414CEC2F7BA7162941B425E4C3A4923041020000000200000000022C00000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010C109EAD228E172941C7F2B4A403923041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.137' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.137' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13978039, 23696321, 1, NULL, 0xBD0B0000010405000000BEDCB5C46B792B4130C4B1CE7B643141CF22DBB957792B417CE2C7F87B64314193900F7A58792B41D85F762F93643141CA8173866C792B419CF8310693643141BEDCB5C46B792B4130C4B1CE7B64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3B8BD51F62792B4149A86D7F87643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.147' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.147' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9679651, NULL, 1, NULL, 0xBD0B00000104040000005D764FDE93A5324180FC87744B881C41809543CB94A5324110AAF1D2F4871C41E2E995528AA5324100FED4F830881C415D764FDE93A5324180FC87744B881C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEA51B8FE90A53241DB361AC025881C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.157' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.157' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14567920, NULL, 1, NULL, 0xBD0B000001042500000023F46C56E34F3441A857CA7281AD2241B7B88D26CA4F344170AC8B9B5CAD2241DDA59B84C54F3441386210D855AD2241D4E76A2BC14F3441C08251894FAD2241A2CDAACFBC4F344108EEEB4049AD224178E09C71B84F3441F0FFFFFF42AD22412797FF10B44F3441B001BCC53CAD22410044FAADAF4F344188855A9336AD224122B07248AB4F3441288B6C6730AD224186DB68E0A64F3441D000DE422AAD2241AEE1E975A24F344128D49A2624AD22416CF90F099E4F344190F2B0101EAD2241F3EBC099994F3441F012F20118AD22413C11365C9B4F3441B8BCE3D412AD2241234A7BA3904F3441C0065F3804AD2241A8CFD5D6854F34419806F0D6F5AC224133D49AF67A4F344198B20CB1E7AC2241078A1F03704F344138CB10C7D9AC22410D2DB21D6D4F3441803480373AAD2241585227006C4F344168A1D6B458AD22413E8B6CD7884F34410040A49F64AD22417F734694A54F3441601B0D8071AD22419C33A234C24F3441C02A18557FAD2241920F7AB6DE4F34410064CC1D8EAD224123F46C56E34F3441A857CA7281AD2241AE25E403DE4F344120265305E8AD2241AC2C435CB34F344168C954C1D1AD2241F9285C6F744F34412854E325B5AD224124CB10A76A4F3441201DC925B1AD2241D98AFD85684F344198DFBE0EF1AD22417ED0B379614F344148BA498CC4AE2241AC79C729474F3441A88BDBA8D8B12241529621CE0F50344198FF90FEF3B12241C064AA402B503441004850FCB1AE2241E88C284D30503441784E40D319AE2241F831E66E2650344158D3BC6313AE2241AE25E403DE4F344120265305E8AD2241020000000200000000021900000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010CB9648CE8B94F34414AF0C234C9AF2241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.167' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.167' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10418512, 16707981, 1, NULL, 0xBD0B0000010405000000250681952B823241182DB29D6A4A2E41B125E4E32A823241D8FBA931894A2E41866CE7BB50823241100EBE708C4A2E41E07A146E51823241F007ACDC6D4A2E41250681952B823241182DB29D6A4A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAF75DC283E823241CE4028877B4A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.177' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.177' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4682726, NULL, 1, NULL, 0xBD0B00000104090000004803782B0643354178E7FB698DA123414E6B9AF71A433541A819511A8AA1234186A757CA2F433541B8CAA18587A12341490C02EB4D433541F8A9F11285A12341F39E3CAC42433541C02E6EA364A12341CCB359151D43354120C9E57F77A123414CE3A57BE3423541801D386794A12341B4A67967F142354130211F7491A123414803782B0643354178E7FB698DA1234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C82D4FBFD2743354130B982367EA12341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.183' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.183' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13843117, 29721351, 1, NULL, 0xBD0B0000010405000000B0ADD85FB2502B41047C61D2BE603141BC96904F9E502B41243A92EBBE6031415196210E9F502B41FC8C288DE36031410E1B9E1EB3502B41D8C56D74E3603141B0ADD85FB2502B41047C61D2BE60314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C47CA0FB7A8502B410118EA2FD1603141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.197' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.197' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12917354, 30292971, 1, NULL, 0xBD0B000001040A000000CAB3597586E0264158DC46A3459E3241DFD24DA2A2E026416C07CEF93B9E3241E0BE0E9CA9E0264138CF6695399E324143014D04B7E0264190635DFC349E3241CD00DEC2ACE0264150F2B0702D9E3241CCCCCC0CA9E026418C8CB98B2D9E3241A45E298BA3E02641E07A146E2F9E3241EA75E01C7EE02641D0ACFA3C3C9E3241DAD781F382E026413072F9AF419E3241CAB3597586E0264158DC46A3459E324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C942E07D099E02641EFB995F5389E3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.210' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.210' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13978004, 23696031, 1, NULL, 0xBD0B00000104050000008F6588A32F792B418895434B7C643141B97493981B792B41BCB359757C643141DD61A1561C792B4140E8D9AC93643141CA09686230792B41E4C03983936431418F6588A32F792B418895434B7C64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C0E9052FD25792B41180A40FC87643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.220' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.220' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13601652, NULL, 1, NULL, 0xBD0B0000010405000000DC2D9060CB8E3241F053E3A5AC261D41A1D6346FD58E3241D006F016AE261D41FF99089BD68E3241B0A679472B261D4141F1638CCC8E324130F46CD629261D41DC2D9060CB8E3241F053E3A5AC261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF063CCFDD08E3241717DAEF66B261D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.233' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.233' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10465120, 5676011, 1, NULL, 0xBD0B000001040500000009B5A659D4823241507B83EFD2492E412B871679F9823241B0E1E995D6492E4104F9A007FA823241F0915C7EC2492E4112143F26D3823241B02E6EA3BE492E4109B5A659D4823241507B83EFD2492E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C765690BEE68232419F5FC295CA492E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.243' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.243' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2746778, NULL, 1, NULL, 0xBD0B00000104050000000968224CBBAB32418023B97CC2641C419006F0D6A7AB324140FAED6B62641C4146BF7DFD96AB324150265305A2641C41F731E6CEA8AB3241901D386708651C410968224CBBAB32418023B97CC2641C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD8C9CBE0A8AB3241BCF15C9CB4641C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.263' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.263' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226215, 35711561, 1, NULL, 0xBD0B0000010405000000E06800AF612E2C41B40E9C3356A130416F4DF38E612E2C4168BC74934EA1304132B29D6F172E2C41C8D781334FA130412CBB278F172E2C41282AA9D356A13041E06800AF612E2C41B40E9C3356A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC3322F8F3C2E2C41F41090B352A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.273' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.273' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11981075, NULL, 1, NULL, 0xBD0B0000010408000000C639230A0E882941AC67B3AA81313041C096908FF6872941081EA7E8A531304170DE710A7E88294190AA6094DE313041F6FDD4388288294150F5B97ACE3130411AC9E53F768829410CE78CA8BA313041507424D747882941D0A59BA48E313041CCC56DB41D882941845AD37C69313041C639230A0E882941AC67B3AA8131304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C16C946B23A8829410ED5769FA6313041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.280' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.280' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6205976, NULL, 1, NULL, 0xBD0B0000010405000000D9A3701DA9423141B0A7C64BFEE61C41536B9A77BB423141D074029AE8E61C41DEC7981BB6423141302B8796C3E61C41B0BFECFEA5423141203A924BE7E61C41D9A3701DA9423141B0A7C64BFEE61C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C00E1F8DCB0423141A3A8B654E3E61C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.290' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.290' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13676709, NULL, 1, NULL, 0xBD0B000001040500000092ED7CDF87613341E003E78CFB541C419D67B32A6D61334170D2DE6097541C4166006FE1676133416027A089AD541C412597FF30756133411022FD76DF541C4192ED7CDF87613341E003E78CFB541C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C69F54F3275613341F654E925C8541C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.303' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.303' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 29171628, NULL, 1, NULL, 0xBD0B00000104050000000E363C7D5EC3324140363CBDC4C41C41E8F21F725DC3324140DFE08B3CC51C41CC6F5FC7A5C332419058A8B546C51C41278716D9A6C3324130D409E8CEC41C410E363C7D5EC3324140363CBDC4C41C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9C5AF52382C33241B546CAB805C51C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.313' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.313' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5437440, NULL, 1, NULL, 0xBD0B000001046D0000004C05A3320D473441A0E53F244E2F1E41C2E3147D11473441A0581737582F1E41FE21FD5617473441A0A223B9622F1E41F0FDD4381D473441F04525756B2F1E412ED49A2623473441B0B88D86712F1E4100E78C482E473441104D158C742F1E411C2FDDE4334734410041F163732F1E4130BB270F39473441002DB21D722F1E414A50FC183F473441A04603F8712F1E41D41B7CC144473441600AD7236E2F1E41C620B0924A47344190D634EF6D2F1E41B359F5F94F47344150AA60D46B2F1E4193B96B6955473441702041F1672F1E419C45B6935A473441809ECDAA662F1E41637FD9DD5E473441E0A370BD702F1E41D7D781335F47344130674469842F1E41952A18D55B47344150302AA9922F1E41448B6CC757473441D0BFEC9EA12F1E41DC78E9865847344100C58F31B72F1E41F01648905C47344110B5A6F9C22F1E418DC2F56861473441F021FDF6C62F1E4168DE714A67473441807CD033C32F1E417836ABFE6B473441F02FBB27B62F1E418E4AEAE46D473441806891EDA22F1E41696FF0456E473441A0E1E9958C2F1E41168C4A0A6D473441206D567D782F1E41D2915C7E6C473441F09F1AAF632F1E41AD69DEF170473441D0F5285C582F1E41C09F1AEF75473441A087855A542F1E41361AC09B7B473441709CA2A34F2F1E41AE1C5A6480473441D07A14AE4A2F1E41DAACFAFC864734413044FA6D442F1E413992CB3F8C47344190CDAACF3D2F1E41FED4782992473441C05CFE43382F1E413E355EFA96473441104B5986312F1E41D2DEE0ABA0473441A047E17A202F1E4126A91350A547344150006F01172F1E41D25D4B08AA473441D0043411092F1E41DF718A4EAE473441D0923A01FB2E1E41EA1DA768B34734410013F2C1F02E1E41846ABCD4B947344190CAA1C5E72E1E4189B0E1C9BE4734413003788BE52E1E41040000E0C347344110A08930DC2E1E41497B834FC947344130CD3B4ED82E1E4134B4C8B6CE47344120A16733D62E1E411648509CD44734413003788BD12E1E41ED63CC7DDA473441103945C7CD2E1E4165DE712AE0473441E04D6210C92E1E417F613275E547344180E7FBA9C02E1E41C9293A32EB47344120651962B82E1E410044FAADF0473441E0CEF7D3B12E1E41447B83AFF5473441D08D97EEAC2E1E4101E78C68FB473441404CA68AA52E1E41FC31E68E01483441600C022B9F2E1E415B8638D606483441E09DEFA7972E1E418C0F7A560C48344140EA0434902E1E415952270011483441A06054D2852E1E41EA26312816483441A089B0E1782E1E410C71AC2B1A483441A0423E686D2E1E41BE5B20C11F4834414091ED7C612E1E41146A4D73244834419060E550552E1E41000000C028483441D0A9F152462E1E41ED5A425E2C48344150B9FC07382E1E41F11FD2EF3048344140431C6B262E1E41DA3D79383548344150AAF152182E1E4124A0897039483441101748D00D2E1E4122166ACD3E48344160AA60D4012E1E41E258177743483441A020B072F72D1E41B0EA735548483441706FF005EE2D1E4105F016684D48344150DF4F8DE52D1E41C2F5287C5748344100A08930D82D1E419E8026425D48344130E4831ECE2D1E419DF6067F66483441E0C6BAB8B62D1E4100917E7B2448344140DA1B7C482A1E41BA96900F26483441B0460378CB291E417C6132F5B4473441106B2BF624291E41265C8FC2B9473441F0F0634CA9271E418BFD65576546344190FA5C6D45271E4111363C3D73463441E03BBD52012A1E41A213D0A47D463441E0DC4683842E1E416E8104A58046344150E3A51B8A2E1E413480B7008146344150F46CD68A2E1E41102DB23D8B46344160764F1E9E2E1E4159302A098D463441508EE472A12E1E412CA913D08E463441906891EDA42E1E41C6293A92904634413096218EA82E1E41FF6E814492463441D02CB21DAA2E1E414DD191EC93463441C0923A41AC2E1E415C5452879546344120FD87F4AE2E1E41E9FBA9119746344170E99532B22E1E41BD9F1A8F9D463441C02E6E23C12E1E41BEE3141DA746344110265305D22E1E41BFD32B65AC46344190DD9307D72E1E41DE4F8DF7B2463441E0DF2D10DF2E1E4198218ED5B7463441004ED191E52E1E413F795808B8463441B0F2B0D0E52E1E410022FDB6BD463441C0AF03E7EA2E1E41904AEA44C846344110F241CFF52E1E4170787A25D346344160FC18F3072F1E41235A64FBD7463441D0F3FDD40C2F1E41FCA067F3E3463441300B24A8132F1E41C9C3428DEE4634410066F7E41B2F1E41D7F97E0AF446344180D0B3D9212F1E410A93A942F946344180423E682A2F1E4192CB7F08FE463441B0F4DBD7322F1E4140CF66950247344100EC51383B2F1E41C6FEB23B0847344160F085C9442F1E4138D6C54D0A473441803255B0482F1E414C05A3320D473441A0E53F244E2F1E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC9D215F2484734419242FB2E7A2B1E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.323' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.323' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13998145, 23689261, 1, NULL, 0xBD0B00000104050000004C50FC98E1782B41184A7BE3BF6431411C0F0B75E2782B416407CED9D9643141CAA3707DF6782B412497FFB0D9643141EA9E3CACF5782B4184BE9FBABF6431414C50FC98E1782B41184A7BE3BF64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C50E6E20DEC782B41976A0EC9CC643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.330' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.330' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13908316, 90073177, 1, NULL, 0xBD0B0000010406000000D312F2C127512B41584ED151F160314176B5153B2C512B41DCE76ACBF4603141BC8F31B72B512B4130DD24C6E76031410632E62E1C512B41443EE8D9E7603141C36D340020512B41E07A140EEB603141D312F2C127512B41584ED151F160314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8BAEECAB26512B410A60352CEC603141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.340' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.340' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977601, 29842511, 1, NULL, 0xBD0B0000010405000000569FABAD867A2B41689CA283BC643141D00968A2727A2B4168A835ADBC643141BEB88D86737A2B417C3F359ED664314184855A93877A2B419833A274D6643141569FABAD867A2B41689CA283BC64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6EA4801A7D7A2B419D511691C9643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.350' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.350' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977873, 23694501, 1, NULL, 0xBD0B000001040500000045136143997A2B41F8FBA991906431418404C54FAD7A2B415C0B24689064314130992A98AC7A2B41C832C431796431410E83C08A987A2B41345A645B7964314145136143997A2B41F8FBA9919064314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA93F85EDA27A2B41C444A4E184643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.363' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.363' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3057011, NULL, 1, NULL, 0xBD0B0000010406000000459D80E644A5324120E4839EE9A31C416CB5153B21A5324120BC059286A41C410266F7843DA53241D01E85EBEDA41C41575227E05BA5324110FED4F867A41C4188DB682063A53241B0FE43FA47A41C41459D80E644A5324120E4839EE9A31C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C7E722DD241A53241880B4CFF69A41C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.373' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.373' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5984149, NULL, 1, NULL, 0xBD0B000001044000000094180416A49F31419047E17A8FAC1B4110A5BD91A39F314190FBA97181AC1B41B3726871A29F3141A011A5FD73AC1B41B6D100BEA09F314170DE718A67AC1B41054625859E9F3141B0C7987B5CAC1B4175029AD89B9F3141D0D4782953AC1B41C7BAB8CD989F3141F01A9EDE4BAC1B412DFF215D7E9F3141C02A1815ACAC1B4164AA60147D9F314140984CD5B9AC1B418D7EFBEA7B9F314140A5BDC1C7AC1B4186C954E17A9F3141704F1ED6D5AC1B41A5BDC1F7799F3141B028ED0DE4AC1B419D11A59D6C9F3141304AEA04CAAD1B41BD172673A89F3141B0ED7C3FCEAD1B4194180416A49F31419047E17A8FAC1B41B169DE31509F3141701283403EAC1B41F9DBD781509F314110D34D6236AC1B419AE61DC7509F3141207A36AB2EAC1B4146477219519F3141C089B0E126AC1B41D344D8B0519F3141B0218E7517AC1B413A234AFB519F3141F07F48BF0FAC1B4158D3BCE3549F3141505EBAC9BBAB1B41846ABCD4279F314160B81E05B8AB1B41806ABC94D19E3141D0FBA9F1A4AD1B41A1EFA7E6439F3141C06054D2AFAD1B418DED7CCF459F3141C0CCCCCC6AAD1B413C355EEA479F314140E483DE25AD1B410C022B374A9F3141B095D409E1AC1B4142C6DCB54C9F31416060E5509CAC1B4180D93DF94C9F3141A0F5285C94AC1B419DEFA7464D9F3141006D567D8CAC1B410B5F988C4D9F314110DE028984AC1B4117E258D74D9F314150EA04B47CAC1B41B4490C224E9F3141C0F606DF74AC1B41CECCCC6C4E9F314110713D0A6DAC1B41152FDD044F9F3141F064AA605DAC1B41D5F97E4A4F9F3141F0B9DA8A55AC1B415EFE439A4F9F3141205C20C14DAC1B41428B6CE74F9F314130B4C8F645AC1B41B169DE31509F3141701283403EAC1B41611058D9C99F3141E047E17AB4AB1B41B3BFECFEBD9F3141801C5A64F1AB1B41536B9AB7C09F3141C0506B5A0AAC1B4112E9B7EFC29F31416050FC1824AC1B412F2AA9A3C49F3141C07DAE763EAC1B41ED0DBED0C59F3141904B374959AC1B412A0F0B75C69F314180787A6574AC1B41B796908FC69F314190E4F29F8FAC1B41E3361A20C69F3141803A01CDAAAC1B41D26F5F27C59F3141F0EDEBC0C5AC1B41263A926BBE9F3141C07A14AE54AD1B415C325540BE9F314100BE301965AD1B41D91B7CC1BE9F314190D4096875AD1B41B51E85EBBF9F3141A055302A85AD1B411EF46CB6C19F3141203333F393AD1B4140C6DC15C49F3141A01A2F5DA1AD1B41B9627FF9C69F3141E0A7C60BADAD1B416A88634DCA9F3141701F63AEB6AD1B412F4CA6FACD9F3141F092A902BEAD1B41AE9DEFE7D19F3141308638D6C2AD1B4140AD69BEE39F3141F0D6A370D2AD1B41CD915CDE67A03141A0CB7FC8DBAD1B413C1CEBE26CA0314160371A40C4AB1B41611058D9C99F3141E047E17AB4AB1B41030000000200000000020F000000022800000004000000FFFFFFFF0000000006000000000000000003000000000100000003000000000200000003, 0xBD0B0000010C9241796CC49F31410DEEE1B9D6AC1B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.380' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.380' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6646964, NULL, 1, NULL, 0xBD0B000001040C000000CE915CFE3F1E3041F01B7C61210C2141B3FA5C8D271E3041C04B3749C60C21416EC5FEA2281E3041A89BC4A0C60C214110BE30B9291E304170B20CF1C60C21416A3BDFCF2A1E304180900F3AC70C2141905CFE43361E30412880B740CA0C2141D0AACFD5451E3041B8B88D86B50C2141C20E9C93481E3041B09387C5B00C21419A999919591E304130666626930C2141B1506BBA601E30410888F45B840C21419A6588036D1E3041A8946548340C2141CE915CFE3F1E3041F01B7C61210C214101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE91D7664491E3041BE17E118710C2141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.393' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.393' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10448985, 4709941, 1, NULL, 0xBD0B000001040D000000365EBA49237D3241D84D625066682E411EB072A8207D324128DBF9BE05692E41A879C7894F7D324150499D802D692E41F9A067F3507D3241C0FD65B72E692E41C3F528FC507D3241E83311362C692E41789318E4527D32414060E5D07F682E4137894180517D3241C06E12C37E682E411D5A641B427D324178C2F5E874682E413E0AD783337D3241302FDD246C682E41B39DEFA7297D3241A047E17A67682E4186FD6587277D324180A9823167682E413B82E267257D32414844FACD66682E41365EBA49237D3241D84D625066682E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9F9E36473A7D3241C4D7B942C6682E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.410' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.410' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 24235563, NULL, 1, NULL, 0xBD0B00000104090000004559863888B83241D0DCB584A4A21C41226C782A88B83241D0AD691E8DA21C41C5293A8287B832416064CCDD75A21C4106C58F4186B83241B0490C025FA21C413EFAED6B84B83241605EBAC948A21C417D2F4C0682B83241A0B20C7133A21C41306EA3C165B8324150703D0A5DA11C41FF770B0455B83241405986388EA11C414559863888B83241D0DCB584A4A21C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB679F3736FB83241383FE8F4E9A11C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.420' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.420' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090172, 35720991, 1, NULL, 0xBD0B0000010405000000840D4FAFA92D2C41D4D781B310A130410AF241CFE62D2C414CF38E7327A13041704DF3CEEF2D2C412C2AA95321A13041DC6800AFB22D2C41B80E9C930AA13041840D4FAFA92D2C41D4D781B310A1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C7C2D21BFCC2D2C410381950319A13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.433' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.433' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977644, 29847931, 1, NULL, 0xBD0B0000010405000000B5C8767E367A2B417CF08529BD6431419E57CA72227A2B41D020B052BD643141DF61A156237A2B41E0AE2544D764314167E5D062377A2B4114A3921AD7643141B5C8767E367A2B417CF08529BD64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE1AAA6EA2C7A2B41942BCA36CA643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.443' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.443' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13978047, 23696451, 1, NULL, 0xBD0B00000104050000004C840DCF7F792B4148B81EA57B643141BEDCB5C46B792B4130C4B1CE7B643141CA8173866C792B419CF8310693643141BB293A9280792B414CD191DC926431414C840DCF7F792B4148B81EA57B64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C94B11C2B76792B414F88C85587643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.453' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.453' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13769651, NULL, 1, NULL, 0xBD0B000001040600000040575B91C92B3341C0C117A653131C41D05D4B883B2C334140CD3B4E2D141C41E25817973E2C3341D0FFFFFF24131C4133C4B16EAC2B3341108F53F410131C4139674449BA2B3341E019515A36131C4140575B91C92B3341C0C117A653131C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C081FCA490B2C3341B71DE6A176131C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.463' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.463' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10545182, NULL, 1, NULL, 0xBD0B000001040500000073E7FBA9D16C3241C03FA4DFA1901D417D6ABCB4D06C3241E03923CA10911D4158EC2F3BE96C324150C2F52803911D41DAF0F40AEA6C324170559F2BA5901D4173E7FBA9D16C3241C03FA4DFA1901D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CABDB0813DD6C324133B5D1D1D6901D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.473' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.473' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977717, 23694471, 1, NULL, 0xBD0B00000104050000002BCD3BCEE4792B41CCD5560C92643141DF1B7CE1F8792B4180B740E291643141E5ACFA1CF8792B417C9ECDAA7A643141F9187317E4792B415CAA60D47A6431412BCD3BCEE4792B41CCD5560C9264314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAEE00C79EE792B41ECD5C45C86643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.497' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.497' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13978071, 23695701, 1, NULL, 0xBD0B0000010405000000434772F9BB792B410CF016287B643141964160E5A7792B41384ED1517B64314192B0E1A9A8792B41A442AD8992643141F00DBEB0BC792B41701B0D6092643141434772F9BB792B410CF016287B64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4E0E524EB2792B41D15CA2D786643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.503' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.503' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13601687, NULL, 1, NULL, 0xBD0B000001040500000099438B8CE98E324180D93DF9B0261D41F8065FB8EA8E3241D00B93292E261D41355EBAA9E08E3241305986B82C261D41D79AE67DDF8E3241F0263188AF261D4199438B8CE98E324180D93DF9B0261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE7D0221BE58E32415B19E2D86E261D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.513' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.513' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8803269, NULL, 1, NULL, 0xBD0B0000010405000000CE915CDEA48C3141708EE472424E1C4118D9CE77B98C314100F54A59364E1C41B7F3FD54BE8C314180D93DF9CB4D1C417C734634AA8C3141806DC5FECD4D1C41CE915CDEA48C3141708EE472424E1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C28288590B18C314154BEE3BF044E1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.523' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.523' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8803251, NULL, 1, NULL, 0xBD0B0000010405000000FB5C6D65C88C3141A0D85FF6CA4D1C41B7F3FD54BE8C314180D93DF9CB4D1C4118D9CE77B98C314100F54A59364E1C41287E8CF9C38C3141E0C876BE2A4E1C41FB5C6D65C88C3141A0D85FF6CA4D1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD19852F4C08C3141DFF67E06FE4D1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.533' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.533' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7482922, NULL, 1, NULL, 0xBD0B00000104050000008538D6454C7D3041A098BB16FB021D41124FAFD44B7D30418048BFFD46031D4176BE9FDA637D3041B0E8482EBF031D41E19C1185667D3041D01DA7687E031D418538D6454C7D3041A098BB16FB021D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C55DE74A1587D3041A1F0F0655F031D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.547' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.547' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090113, 35720441, 1, NULL, 0xBD0B00000104060000000FE9B7EFD62D2C4150F38E13F2A0304115FBCBEE132E2C414CBC74D308A13041A3D634EF1C2E2C4150EA04B402A13041624469EFF32D2C4164F38E73F3A03041DC6800EFDF2D2C41282AA9F3EBA030410FE9B7EFD62D2C4150F38E13F2A0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6417A3EEF92D2C413674FD65FAA03041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.557' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.557' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977911, 23708731, 1, NULL, 0xBD0B00000104050000008BA0F8F126772B41985CFEA3916431412F08AC5C26772B414847727980643141F616485012772B41D800DEA28064314152AF94E512772B41100DE0CD916431418BA0F8F126772B41985CFEA39164314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C18E414A11C772B417A0D8C2389643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.573' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.573' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 1887726, NULL, 1, NULL, 0xBD0B00000104110000001A3FC69C1D4B3141F020B072BED51C41BE0E9C93284B3141F0B7AF03A9D51C4176F2B0702A4B3141808026428BD41C41DB12F2C13B4B314130992A988FD41C41DD361A40394B31417096210E8BD41C419E1A2FFD364B3141002731C884D41C410868220C354B3141907EFBFA7CD41C418251497D334B314180D409E873D41C41122DB25D324B3141907571DB69D41C4137B4C8B6314B3141F00B93295FD41C41725F078E314B3141E09E3C2C54D41C412EA2B4D7ED4A3141D0C7983B4ED41C4176BE9F9AE94A3141401AC0DBCDD51C41684DF34EFD4A3141F0F44A59B5D51C414BEA04F4034B314150A1D634B7D51C41A513D0241B4B314160CCCCCCBDD51C411A3FC69C1D4B3141F020B072BED51C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8043964A0B4B31410BBF7A8103D51C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.600' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.600' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9680306, NULL, 1, NULL, 0xBD0B0000010405000000AB3E577B96A53241C0AACF556A871C418E06F0D696A53241002B871648871C414450FCF87DA532418099991903871C4184DB68407BA53241E054C12807881C41AB3E577B96A53241C0AACF556A871C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB5032D4E86A53241531983C974871C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.617' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.617' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13667335, NULL, 1, NULL, 0xBD0B000001040B0000001DD26F3F86A9324140257502C7471D41F7285C8F86A9324100A392BA88471D4146E17AB486A93241907F48BF6C471D4134AB3E3787A932417080B7400A471D41FB97DDB388A9324140C6DC35F2451D41711B0DC055A932410048E1FAED451D41CEDEE04B54A9324180D7817301471D4148BF7DBD53A93241B0F085496F471D41D85F760F53A932419004C58FB0471D41BA627F397BA93241C06C567DC7471D411DD26F3F86A9324140257502C7471D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C954458306EA9324151EFAE71D7461D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.630' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.630' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8928436, NULL, 1, NULL, 0xBD0B0000010406000000FA31E6CE9963334140189554705C1C412385EBF1C463334160B3EAF3A95C1C41E5D9ACDACC63334100BF0E1C335C1C413A80B700A5633341207D3FB5D25B1C417468912D9B633341D06F5F075D5C1C41FA31E6CE9963334140189554705C1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C698CA225B363334168FCCF53465C1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.637' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.637' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7013167, 164901, 1, NULL, 0xBD0B0000010405000000C88F31B7ECE4314170E7FBA9E77B19413E1CEB62A7E43141F0E2369AE07B19415C07CE99A3E4314180CE8852ED7C19419E23B9BCF5E4314190984C95E87B1941C88F31B7ECE4314170E7FBA9E77B194101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C644FD23DC0E43141F88BFED53C7C1941, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.647' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.647' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7482931, NULL, 1, NULL, 0xBD0B000001040500000076BE9FDA637D3041B0E8482EBF031D41D98173C67A7D304140D122DB31041D414F499D40807D3041C02FBB27FF031D41E19C1185667D3041D01DA7687E031D4176BE9FDA637D3041B0E8482EBF031D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC360B163717D3041C892E917DB031D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.657' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.657' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4358988, NULL, 1, NULL, 0xBD0B0000010406000000262FDDE4F74D2F41C02B655989342F4174DE718A014F2F410032E6AE8A342F417B0D4FAF134F2F4150643B5F7C342F41FBA9F1123C4F2F41A813D0845C342F4104A16733A24E2F41306519E2FE332F41262FDDE4F74D2F41C02B655989342F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDB9C93A1A44E2F41418BC0D857342F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.663' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.663' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13226304, 90073097, 1, NULL, 0xBD0B0000010409000000EE8E53F45B2E2C41183FC67C7CA13041AA7BF2B02B2E2C41CC293AD27CA13041BB86A797332E2C41549FABED7DA13041131DC9A53B2E2C41648FC2B57EA13041569FABCD432E2C4108BE30297FA1304168006F014C2E2C41F0012B477FA130417F26C2C6562E2C411C6A4D337FA130416E787A25582E2C4104917E7B7EA13041EE8E53F45B2E2C41183FC67C7CA1304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C88BBAC31472E2C41E1551DC47DA13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.673' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.673' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977814, 23695091, 1, NULL, 0xBD0B0000010405000000DAF21F12497A2B417019E238916431410861C353487A2B41FC497B037A6431416C6FF045347A2B41184D842D7A6431417D38D605357A2B41D8F7536391643141DAF21F12497A2B417019E2389164314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB88161AC3E7A2B415BE227B385643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.683' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.683' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3592723, NULL, 1, NULL, 0xBD0B0000010405000000E0C798DBCABC3341D07493184D7F1C4154302AA9FFBC3341908EE472527F1C41874160A500BD33410014D0C4037F1C418104C5EFCBBC3341A09F1AAFF67E1C41E0C798DBCABC3341D07493184D7F1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE46B105DE5BC33418EE9526D267F1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.693' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.693' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090091, NULL, 1, NULL, 0xBD0B0000010405000000E06800EF252E2C41EC60C393FCA0304133BB270F2F2E2C41C40E9C73F6A030418616D90E062E2C41E8D78133E7A03041A1D634EFFC2D2C41382AA953EDA03041E06800EF252E2C41EC60C393FCA0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C369420FF152E2C41D011A8E3F1A03041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.703' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.703' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977946, 23709061, 1, NULL, 0xBD0B00000104050000000BA5BD8162772B41805149FD7F64314141C6DC754E772B41B8EFA72680643141DB141D094F772B41D044D850916431413CE17A1463772B41BCAF0327916431410BA5BD8162772B41805149FD7F64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF5B540C558772B41F153EAA688643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.717' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.717' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10002332, NULL, 1, NULL, 0xBD0B0000010405000000674DF36EEFBA3241708104C58B4C1D41E24603B808BB32411071AC0B814C1D418EC2F5E809BB324100FDF675144C1D41EF0DBEB0F0BA324130DF4F0D104C1D41674DF36EEFBA3241708104C58B4C1D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CBF8C056AFCBA3241BD0792544C4C1D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.727' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.727' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9615601, 90000496, 1, NULL, 0xBD0B0000010405000000ED38458778A53241E0EA73350B891C4177A52C8375A5324170BDC1172B8A1C41C6E53F2490A5324120C807BD8E891C41AB9BC4E090A53241401361C34E891C41ED38458778A53241E0EA73350B891C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CECBC5F0F81A53241EEB1B69989891C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.737' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.737' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10408517, NULL, 1, NULL, 0xBD0B000001040600000066AA60940958354130B5A679C5181F41F86C56DD1658354190A8A4CE53181F410A2428FEE357354120EE5AC29A181F415FDC46A3E057354160C3D32BBA181F419A658803E657354100E6AE25F3181F4166AA60940958354130B5A679C5181F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA7F193F4F9573541F0C3AFD3A7181F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.747' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.747' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6938167, NULL, 1, NULL, 0xBD0B00000104040000000AC7BAB809002F4160621018CE442F4102CCEE8966002F4188635D5CE1442F41CE22DB7923002F4190D100DEAC442F410AC7BAB809002F4160621018CE442F4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C49E7D63E31002F41D387CF70C9442F41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.757' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.757' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14073854, NULL, 1, NULL, 0xBD0B0000010422000000CC6F5FA73B2A3441609FABAD9C091E414EAF94853B2A34417006F01688091E41396744893B2A3441501D38675B091E411E85EB313B2A3441D0D100DE45091E411E63EE1A3B2A3441C0E3A59B2E091E41E2BE0E9C3A2A3441F004349114091E41EC1FD2EF3A2A3441400E2D32FF081E41394ED1113B2A344160B6F3FDE7081E417EE2C7D83A2A3441A0E53F24BC081E411461C3F33A2A344110EBE2B6A6081E414EA60A663B2A3441F0012B077B081E414FFC18F33B2A3441307DAEB665081E418A16D92E3D2A344180559FAB4F081E41D22B65B9402A3441A0DD938726081E41F263CCDD442A3441F024060102081E41E8B7AF634C2A344110AAF152CD071E417E613255552A3441202EFFA193071E41721283E0572A3441F0A067B37F071E41AB13D0645A2A34418095438B6D071E41E39387C55E2A3441F031E62E48071E41C439236A632A344120EA043420071E419C218E95672A3441D08AFDE5F9061E419E33A254682A3441F0F97E6AE6061E4124B072A8682A34410071AC0BD1061E41D3BCE354682A344180BFEC9EBA061E41E6482E1F682A3441A020B07295061E4182AEB6425A2A3441C003568E92061E415917B7510A2A3441D0F675E081061E41F141CFE6002A3441C06722ECDF081E41C4BAB8EDFD29344180711B8D9F091E41890D4F4F3F2A344130583934380A1E417ABE9F9A3D2A3441A0855A53F8091E4154D3BCE33B2A3441900AD7A3C7091E41CC6F5FA73B2A3441609FABAD9C091E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CADD64B91292A3441EE0A4CB810081E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.770' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.770' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 1623699, NULL, 1, NULL, 0xBD0B000001042A000000BB490CC2C10B3241601283C0E03D174196B20C31BF0B324120151DC9B83D1741828CB94BAE0B32412093A902B03C1741881F63EEAB0B3241804772F9893C17411D386784A90B3241E07936AB623C1741C15B2041A70B32415088635D3D3C1741A35E290BA50B32418092CBFF173C17418CA982D19D0B324110E02D909B3B174127A913F09B0B32419067B36A7A3B1741E851B8DE990B324170E2C718563B1741E8D9AC3A960B32414054E325163B1741802F4CC6940B3241C0749398FC3A17411FA7E868920B3241504DF30ED33A174101E78CA88D0B3241002C65997F3A1741C798BB968A0B3241E031E6AE493A174125F6979D870B3241C08FC275153A1741905374A4840B3241705AD33CE1391741F0B050AB810B324170B8AF03AD39174155A835ED7E0B3241803D0AD77C39174182D93D797B0B3241803255304039174195900FDA610B3241201895D464391741CE5D4BC8750B324130D3BC63CB3A1741EF85C9D4790B32410051DA9B123B1741088A1FE3820B3241C0AF03E7B13B17418E976E32860B324100FF213DEB3B1741CD88D28E890B324130CB1087243C17410FD044F88C0B3241D0A59BC45D3C1741F1F44AF9900B3241F0718A4E9F3C1741679A770C950B3241808173C6E03C1741CC32C431990B3241F09E3C2C223D1741BE0512149C0B32415095430B4F3D1741E3B584BCA10B3241C0726811A73D17410266F764A70B3241A0BDC117FF3D1741A0EFA7E6B20B32410051DA1BB23E17419106F096B50B3241304469EFDB3E17418638D6C5B50B3241F0A9F152DD3E174194ED7CFFBA0B324140AF94652D3F1741F9065F58C10B3241300C02AB8E3F174191180416DB0B324190B5157B6A3F17416E1B0DE0C60B3241F056ECAF303E1741EE164850C40B32418035CDBB083E1741BB490CC2C10B3241601283C0E03D174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C48D636FA9C0B3241C38D9866693C1741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.780' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.780' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11097655, NULL, 1, NULL, 0xBD0B0000010405000000C54B376951663541E8FDD4781AAE2341BEF528FC5C66354158AF94E529AE23414BD8F0345E663541701D38A700AE234118E258D75266354168BC749306AE2341C54B376951663541E8FDD4781AAE234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3855D880586635413066E16A13AE2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.790' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.790' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12917389, 30293041, 1, NULL, 0xBD0B0000010409000000CCCCCC0CA9E026418C8CB98B2D9E3241B24082E2A0E02641805452C72D9E3241AE15FB0B70E0264184559F2B2F9E3241C556ECAF72E02641E43FA49F319E32419E15FB8B77E02641D8F75323369E3241A97268D17DE0264134B4C8F63B9E3241EA75E01C7EE02641D0ACFA3C3C9E3241A45E298BA3E02641E07A146E2F9E3241CCCCCC0CA9E026418C8CB98B2D9E324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C669D8ABC87E0264183131CFC329E3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.800' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.800' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11157674, NULL, 1, NULL, 0xBD0B000001040800000077E09C51A3AE3241304CA60A826F1C41B0506BFA9EAE3241B03A014D7C6F1C4182FB3A7086AE32411067D567EF6F1C4188635D1C79AE324160E09C11C06F1C41546210D863AE324120C7BAB81F701C41DE02096A76AE324170F4DB5755701C414F27A0A989AE324100651962FA6F1C4177E09C51A3AE3241304CA60A826F1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4CDCBFBB7CAE3241DBCDEC35FC6F1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.810' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.810' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14073871, NULL, 1, NULL, 0xBD0B000001042600000051FC1893C12934410076E09C600E1E417C26C206C729344100492EFF690E1E41CA20B052CC29344120D26FDF6E0E1E41C0529641D129344140F1634C6E0E1E416CF08569D6293441108273C66D0E1E413992CBFFDA2934418054C128750E1E4190976E52DF2934417054C1287F0E1E41C4051254E5293441A0DD9387810E1E41B86B09D9EA29344160218E75860E1E41FE907E9BEB29344190D044D8870E1E414F499D20F0293441007A362B1B0E1E41FEB27B3281293441A06ABCF4CF0C1E41484772397B2934412076E01C530E1E414EF38E337C2934416064CC5D510E1E4159B1BF2C8129344190081B1E4E0E1E41D1B3593587293441C07C3FB54E0E1E41F8285C8F8C29344160B81E05500E1E4120DBF99E9129344170A301BC550E1E41EAB7AF239629344160E09C91610E1E41D05D4B689A29344130C0CA216F0E1E41C3CAA1459F293441C0490C02730E1E416DAC8B3BA4293441C02F4CA6700E1E4114143F06A929344100560EAD6A0E1E41AF7268F1AD2934419023B9FC6A0E1E4189635DFCB2293441F039234A630E1E41250F0B95B729344180B5157B5B0E1E41885AD3FCBC293441205A643B590E1E4151FC1893C12934410076E09C600E1E414A477219F7293441C0DF2D903E0C1E41DF4F8D77FE29344160D6C5ED460A1E411071AC7BEC293441F0277E0C170A1E41EE41CF46DA293441A0029A88E8091E41324CA6DAC7293441709D8066BB091E41F2FDD438B5293441605530AA8F091E41AA4E40538F293441601361433C091E41224A7B238B293441D02AF6974B0A1E4180E2C778B129344120ADFA5C690B1E414A477219F7293441C0DF2D903E0C1E41020000000200000000021C00000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010C15C09CCBBD293441E8C343C8CA0B1E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.860' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.860' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14666405, NULL, 1, NULL, 0xBD0B0000010408000000806ABC94E44E3441108C4A6A8F2F1E4160C3D34BF04E3441E02CB29DB32F1E41857CD0D3244F344160734694B22F1E415F5DDC26434F344130F38E53B4301E41E8D9ACFA914F3441E0BCE39498311E41628FC2759D4F3441907A142EC2311E4169AA6014A54F344100197357BF2F1E41806ABC94E44E3441108C4A6A8F2F1E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C525D32B26C4F3441C23127DB66301E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.870' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.870' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13601113, NULL, 1, NULL, 0xBD0B00000104050000001271ACCBC68E324160643BDFED281D41DFC798DBD08E32413033A234EF281D419DCDAAEFD18E3241C08D06F06C281D41CB76BEDFC78E324110BE9F9A6B281D411271ACCBC68E324160643BDFED281D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C559FAB5DCC8E3241D0F8A067AD281D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.880' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.880' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 11325976, NULL, 1, NULL, 0xBD0B000001040500000049C807FDB3B132412004560E57811C41F3164850B8B13241B04F1E1651811C41FC4A5906D2B13241C0361A40EA801C41285C8FA2A4B1324150F08549E2801C4149C807FDB3B132412004560E57811C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C51986B3BB9B13241360CE9D40D811C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.890' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.890' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8913595, 90053152, 1, NULL, 0xBD0B000001041200000073D7129263A53441C0073D5BDEA1274153B81E8568A53441606210D8CFA127415AB1BF0C68A53441F80AB5A6CEA127410924281E52A5344170832F8CBEA12741628FC2B52DA53441E86A2BB685A127419CB437981DA53441E0BDC1975FA12741024D840D1CA53441708026823EA127416DF90F891BA53441F0C48FB136A127411271AC4B1BA53441D88C28ED33A12741E24F8D9710A5344160CA32C456A1274188855A9312A53441F82A871678A12741492EFFA118A5344110728ACEDDA127412EA2B45738A53441D054C1A800A22741AC9BC44042A5344150A8358D0BA2274122B072484FA53441C0088ADF19A2274144A4DF1E5BA5344190D32B25F7A127414C72F9CF62A53441E873B595E0A1274173D7129263A53441C0073D5BDEA1274101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6B85903335A53441152EF9C0BEA12741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.900' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.900' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10459235, 17743311, 1, NULL, 0xBD0B000001040500000081C0CA01A2823241B01C5A64544A2E4137674429A0823241803BDF8FAC4A2E41CC20B0D2AA82324130B4C876AD4A2E412D90A078AC823241B047E1BA5E4A2E4181C0CA01A2823241B01C5A64544A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C99081D44A6823241B623ED3B834A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.910' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.910' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5090156, 35720731, 1, NULL, 0xBD0B00000104050000007D16D9CEC42D2C41CC172653FEA0304132BB27CFBB2D2C4170BC747304A130410CF241CFF82D2C41286A4D331BA130415A4469EF012E2C41CC0E9C1315A130417D16D9CEC42D2C41CC172653FEA0304101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD20995DDDE2D2C4137717DC50CA13041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.920' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.920' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8446032, NULL, 1, NULL, 0xBD0B000001040500000028B9FCC7DD522B413808AC9C5C5123412331086CBF522B416058A8B55D512341277502DAC1522B41B8EEC983A05123417F58A835E0522B41709CA2639F51234128B9FCC7DD522B413808AC9C5C51234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C0D54A6D0CF522B416398708E7E512341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.940' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.940' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13602055, NULL, 1, NULL, 0xBD0B000001040500000012363CBDCC8E324140280F8B14261D4156A835CDD68E32418012834016261D415F7FD93DD88E324160E4F29F8E251D411B0DE02DCE8E3241E0F97EEA8C251D4112363CBDCC8E324140280F8B14261D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB8DA8A7DD28E32413F068195D1251D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.950' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.950' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5727022, NULL, 1, NULL, 0xBD0B000001040B0000000BAC1C7A37363241405839346CCD1741183FC63C3736324150C807BD72CD1741D712F2013736324130CB104779CD1741E00B93C936363241C06054D27FCD1741FA31E60E383632417026538582CD17419BE61DC743363241605BB13F2ACD174136EF38C5493632417051491DFDCC17416ADE71EA3D36324160984C15E4CC1741BE86A7773B3632415010583911CD1741590E2D5239363241E0BE0E9C3ECD17410BAC1C7A37363241405839346CCD174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEF3C801A3F36324181F696F925CD1741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.960' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.960' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12909581, 1050581, 1, NULL, 0xBD0B0000010409000000A6A2233946E12641D82406A1BE9E3241366EA3C147E126411C3FC6ACC09E32419531770D49E12641641CEBC2C29E324169AC8B1B4AE12641DCFBA9E1C49E3241480C02EB4AE12641EC384507C79E324101E02D507DE12641C08D06F0B59E3241FCA9F11272E126410461C393AD9E324114F9A02744E12641A0EFA726BD9E3241A6A2233946E12641D82406A1BE9E324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C83D9DE0360E12641E059CCE3B99E3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.973' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.973' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14009722, 914221, 1, NULL, 0xBD0B000001040500000089E4F21F87702B41D866D567D86431418BF6069F6B702B41E46A2B96D964314125A7E8C86B702B4170A3011CEA643141FACD1991A6702B41D85F768FE964314189E4F21F87702B41D866D567D864314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8737267582702B416C9BCB63E2643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.983' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.983' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14612381, 11706311, 1, NULL, 0xBD0B000001041D000000CEDEE0EB142D3441C0C3424DBFE43341371AC07B1C2D34418C5AD3DCC1E433416D1B0D00242D34410C7C6192C4E43341E9D9AC7A2B2D3441684BC867C7E43341EE3845E7322D3441F8088A5FCAE4334166F7E4413A2D3441DCC7987BCDE43341CA6D3480412D3441B069DED1D0E433416C44698F482D3441CC5F768FD4E4334100DE02894F2D3441CCF5287CD8E43341A679C789562D34418C348057DCE4334107C58F915D2D3441348A1F23E0E43341E2460398642D344174E09CF1E3E433414750FC986B2D3441D40B93C9E7E4334147E17A94722D34417C7AA5ACEBE43341B4FC8754762D34418C635DBCEDE433412A287E8C7B2D3441A479C7C9A8E433417F613255BF2C3441C0BAB8AD9AE43341C720B032C42C34413CA4DF7E9DE433417D51493DCB2C344104F01648A1E43341E2581757D22C3441648FC2F5A4E433418E31776DD92C34415C39B4A8A8E43341CE88D27EE02C344150840D6FACE4334142355E9AE72C344198FF901EB0E43341FA285CCFEE2C3441C8BAB88DB3E4334137D6C52DF62C3441C84D6290B6E43341B8490CC2FD2C3441DC809503B9E4334106B5A679052D3441186C781ABBE43341CA073D3B0D2D34410088F41BBDE43341CEDEE0EB142D3441C0C3424DBFE4334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C29AA0C1E392D34413C35A39EB9E43341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:17.993' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:17.993' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 1622579, NULL, 1, NULL, 0xBD0B0000010405000000E8F21F12C1B13241309D80A6BA811C41BE0E9CF3C7B1324170545227EE811C41BD529661E0B13241005917B7A8811C41D0BCE354C1B1324120A91350A3811C41E8F21F12C1B13241309D80A6BA811C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C704C8526CDB13241BA25AB7BBE811C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.003' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.003' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13978021, 23696291, 1, NULL, 0xBD0B0000010405000000CF22DBB957792B417CE2C7F87B643141891F63AE43792B41482EFF217C643141A5E8486E44792B412C7E8C599364314193900F7A58792B41D85F762F93643141CF22DBB957792B417CE2C7F87B64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC3F715144E792B4148E5FAA887643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.013' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.013' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2734079, NULL, 1, NULL, 0xBD0B00000104080000000F7A36AB7E6C314130FBCBEEC7B61C4123166A0DA76C314150FE43FA16B61C41AF8BDBA89D6C3141E0938705F3B51C410F7A36AB7E6C314130FBCBEEC7B61C41472EFF618C6C314100D49A66AAB51C41801D38A7616C3141A02D90A03AB61C413208AC3C6F6C314100C58FB17CB61C41472EFF618C6C314100D49A66AAB51C41020000000200000000020400000003000000FFFFFFFF0000000006000000000000000003000000000100000003, 0xBD0B0000010C3C93F2D8816C31414A2038532FB61C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.023' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.023' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2113716, NULL, 1, NULL, 0xBD0B00000104050000006A2BF6373FFA324190E5D0A261721C410D363CFD37FA3241A0A52C4369751C415BEC2F5B6AFA3241209A089B71751C41B369DE9171FA324100A4DF3E6A721C416A2BF6373FFA324190E5D0A261721C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C007E26C854FA32412AD047B4E9731C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.033' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.033' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977881, 23694631, 1, NULL, 0xBD0B000001040500000030992A98AC7A2B41C832C431796431418404C54FAD7A2B415C0B24689064314126068155C17A2B410424283E90643141426744A9C07A2B41540B24087964314130992A98AC7A2B41C832C4317964314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8B8E9CF9B67A2B413FB6F4B684643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.053' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.053' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10319581, 4449381, 1, NULL, 0xBD0B0000010405000000E3A59B84B17932417095430BA3642E41288716F98D79324118355EFA9F642E41DC78E9A68D793241B8096822AF642E41580E2D32B17932418820B032B2642E41E3A59B84B17932417095430BA3642E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C21A594959F793241E27EA916A9642E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.063' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.063' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10449183, 17746201, 1, NULL, 0xBD0B000001040500000012022B47CD8232412031082C524A2E41A41A2F7DCE82324198EFA746184A2E412F333353C382324158E17A54174A2E415A0E2D52C282324138BE3059474A2E4112022B47CD8232412031082C524A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC8DC7186C8823241148B765F324A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.070' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.070' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10459286, 17743151, 1, NULL, 0xBD0B0000010405000000F9285CEFB68232412885EB11694A2E41C0F5287CB5823241983F355EAE4A2E418A416025C0823241E8CAA145AF4A2E4133DD2466C182324190C2F568734A2E41F9285CEFB68232412885EB11694A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDE82D65CBB823241AC6518768E4A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.083' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.083' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9679391, 90000497, 1, NULL, 0xBD0B0000010408000000ECF44A197FA5324100948705A5861C419E3C2C1488A5324150C3D3ABBE861C41DA56EC0F8BA5324110A5BDC1AD861C415417B7D1A7A53241300F0BB50A861C41AE47E1BAA2A5324100B8AF83FC851C417758A8D58DA53241C011A53DC2851C4128E483BE81A5324140F8C2E4A0851C41ECF44A197FA5324100948705A5861C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C54F2DCF68DA5324138A68E272D861C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.113' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.113' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977695, 29851651, 1, NULL, 0xBD0B00000104050000001524283EFB792B419006F096D76431412395D4490F7A2B4144D6C56DD76431415E5452670E7A2B414048507CBD6431410FAC1C5AFA792B41D09C11A5BD6431411524283EFB792B419006F096D764314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C888A52D2047A2B415AFD5B89CA643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.123' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.123' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977784, 23694891, 1, NULL, 0xBD0B0000010405000000A0A22339207A2B41547424577A6431417D9ECD2A0C7A2B41AC9BC4807A643141ABFA5CED0C7A2B4128D9CEB791643141474772F9207A2B41E0FA5C8D91643141A0A22339207A2B41547424577A64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3DE89E92167A2B4162620E0786643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.157' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.157' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13769626, NULL, 1, NULL, 0xBD0B00000104070000004FAF94C5D42C3341308B6C6737131C41E25817973E2C3341D0FFFFFF24131C41D05D4B883B2C334140CD3B4E2D141C41F575E0BC502C3341F08AFD654A141C4114E258977F2C3341F0F1D24D3A141C41B71E85CBD32C3341A08D06F0A1131C414FAF94C5D42C3341308B6C6737131C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEDB1F4377E2C3341898CA4BFA6131C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.167' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.167' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12572047, 13416031, 1, NULL, 0xBD0B0000010405000000704F1ED6FF1F2241C06B09B9CAF92D415A711B8DE11F2241008A1F23CDF92D410266F7A4E71F2241685BB13F19FA2D41C8B12EEE05202241802BF6D716FA2D41704F1ED6FF1F2241C06B09B9CAF92D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C8108ACBDF31F22415965F3FCF1F92D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.177' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.177' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9148043, NULL, 1, NULL, 0xBD0B0000010405000000AD7268518D8B3141F0C8E5BFAC631C417A14AE87988B3141D0F1D2CD88631C4197D409E8878B3141B069DE7163631C4173AC8BBB878B3141D0B9DA8AAC631C41AD7268518D8B3141F0C8E5BFAC631C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA00B95A58D8B3141C8E934BF8B631C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.193' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.193' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12877425, NULL, 1, NULL, 0xBD0B000001040C0000002FBB27EF9A2B3341E081E2C7C3911C41CF22DB99992B334120423EE81A921C41F13845E7AB2B3341C02A181521921C41DA56EC4FB22B334150C0CAA1A4911C41CEB35915AF2B3341E0240601A2911C41AD506BDAAB2B334130D49A669F911C41E7482E9FA82B3341B06054D29C911C41EAB7AF63A52B3341303867449A911C41CC66D527A22B3341805AD3BC97911C410E71ACEB9E2B3341F0C7983B95911C419ED634AF9B2B3341801283C092911C412FBB27EF9A2B3341E081E2C7C3911C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C6ED5DAD6A42B334125CE4045DA911C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.203' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.203' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 17533538, NULL, 1, NULL, 0xBD0B0000010405000000D3CCCC0CF9583341605839B496B01B418E976E1217593341707CD0B394B01B414F401341175933416009F9A04BB01B41B169DE51FD583341201AC05B4DB01B41D3CCCC0CF9583341605839B496B01B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4C509C250959334163B15EFD71B01B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.210' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.210' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9038884, NULL, 1, NULL, 0xBD0B000001040500000062105819AFBC324160D5E7EA42C41C41BF5B2001C3BC3241B0FA5C6D5BC41C413108AC1CC4BC3241F0CC5D4BF1C31C41B8D100FEAFBC3241F0D409E8EDC31C4162105819AFBC324160D5E7EA42C41C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C17BA9CEBB9BC32415E5E58A51FC41C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.220' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.220' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8387052, NULL, 1, NULL, 0xBD0B0000010405000000C97F487F2A963041A0711B0D760A1D41ABADD8BF2E963041C0CCCC4CED0A1D41036F81442F963041F0F21F52760A1D4183D0B3392F96304180CE8852760A1D41C97F487F2A963041A0711B0D760A1D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C04DB35812D96304179C359E49D0A1D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.230' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.230' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13998013, 23688511, 1, NULL, 0xBD0B0000010405000000B415FBCB5A792B410CAE47E1D86431412D1AC0DB6E792B41586B9AB7D8643141164850FC6D792B41A813D0C4BE643141C69F1AEF59792B41F43A70EEBE643141B415FBCB5A792B410CAE47E1D864314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAB62CB6464792B415C4A4FD3CB643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.240' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.240' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6311237, NULL, 1, NULL, 0xBD0B00000104050000001C95D469BC5F3141B0C876BED4D31C4100BC0552BC5F3141E046037862D41C419C923AE1D95F314130A7E8C862D41C411ED26FFFD95F314180635DDCAED31C411C95D469BC5F3141B0C876BED4D31C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CDE5BF9BCCB5F314180FCC3D711D41C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.250' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.250' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3000991, NULL, 1, NULL, 0xBD0B0000010408000000B78D06F03BA5324190832FCC9EA31C413545477239A53241206744E979A31C41C0D32BA530A53241B0D16F5F5EA31C41058195A318A53241A0BFEC1EC5A31C41D83D79F804A5324120029A081FA41C4196BB96F012A532412041F16352A41C41F0EBC07917A532417025E4833DA41C41B78D06F03BA5324190832FCC9EA31C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C58318F9021A53241BEC5EB25D8A31C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.263' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.263' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 18550061, NULL, 1, NULL, 0xBD0B0000010411000000E4718A8EE1DA3141F060C3D35CF01841F31648D0C4DA314130ED0DBE41F01841BC7D1D58ADDA31413083C0CA2DF0184117FBCB9EADDA3141B0B437B83BF0184157423ED8ADDA3141E00B93A949F0184192537404AEDA3141B09AE69D57F0184140136123AEDA3141B0E17A9465F01841D434EFB8ADDA3141E0D781B391F018410DD044C8ACDA314100C58FB1BDF0184169F7E451ABDA314150D8F074E9F01841A3EFA756A9DA3141105374E414F11841A4BDC1D7A6DA3141D041CFE63FF118416E4694D6A3DA3141008A1F636AF11841829ECD0ADEDA314180DD2486B2F01841FAC264CAEEDA3141101B2F5D79F0184156204171E8DA3141B04E401363F01841E4718A8EE1DA3141F060C3D35CF0184101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C01B122E9C2DA31419D854DC5AAF01841, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.273' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.273' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8394962, NULL, 1, NULL, 0xBD0B000001040A000000C676BE5F3F833041902A189550FE1C41770B24A84083304120ED0D3E54FE1C418051497D6483304150EEC9C352FE1C41CC4B37A97B833041700F7A36D1FD1C419118043674833041706B9AF7BBFD1C4176A52C83A1833041E0E848AEBEFC1C41884160659283304190F1D24DBFFC1C416C8104456A833041D09C11A59FFD1C418CA0F8D16283304140D49A668AFD1C41C676BE5F3F833041902A189550FE1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD6B232FD6C833041ABD68DE6B5FD1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.283' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.283' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7319142, NULL, 1, NULL, 0xBD0B00000104060000005FFE435AF5803641504013A1DD1F214101BC0592EF803641D0D5566CDA1F2141499D80469D803641903D0AD7AC1F2141B17BF270968036413063EE1AE21F2141B203E74CEC803641D06800EF172021415FFE435AF5803641504013A1DD1F214101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF220361DC6803641E8815580E11F2141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.293' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.293' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977610, 29843971, 1, NULL, 0xBD0B0000010405000000D00968A2727A2B4168A835ADBC643141FF2A87965E7A2B413CB4C8D6BC64314143355E7A5F7A2B41604BC8C7D6643141BEB88D86737A2B417C3F359ED6643141D00968A2727A2B4168A835ADBC64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB61D770E697A2B41357487BAC9643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.303' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.303' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10497986, NULL, 1, NULL, 0xBD0B0000010430000000C6DCB58406DA3341545DDCE6205932416891EDDC96DB334168B3EAD33B593241C532C4F1ADDB33411044FAADE45732416F3D0A77B6DB3341D447E1DA65573241A289B0C1C3DB3341C44B3709A0563241E4361AA0C5DB33417CFD6537845632417D3F35DE7BDB3341101748D044573241E93FA41F7ADB3341DC53E3054A57324198559F4B78DB3341B057CA324F573241DC12F26176DB3341E485C95454573241A89BC46074DB3341B87BF270595732414E1E164A72DB3341BC25E4835E5732419F23B91C70DB334138F1638C63573241277502DA6DDB33416C832F8C68573241472EFF816BDB33413892CB7F6D573241F28E531469DB334158B1BF6C72573241C317269366DB3341E0D478497757324173C729FA63DB3341C0ADD81F7C5732415AB1BF4C61DB334104F016E88057324176711B8D5EDB334158A60AA6855732419206F0B65BDB334198BDC1578A573241AFFA5CCD58DB3341E83FA4FF8E57324194C420D055DB3341340681959357324158643BBF52DB33412492CB1F985732417ED93D994FDB3341245A649B9C5732411DC9E55F4CDB334178CC5D0BA1573241DBC56D1449DB3341904C156CA557324142BD52B645DB3341589A77BCA957324138F8C24442DB3341E43FA4FFAD573241336EA3C13EDB3341F885C934B2573241BA1E852B3BDB334180E2C758B65732413CEF388537DB3341E48C286DBA5732415ECC5DCB33DB3341F4FBA971BE5732414D40130130DB3341D00A4665C257324130D49A262CDB33414827A049C6573241009A083B28DB3341C4EC9E1CCA5732413FAD693E24DB3341903F35DECD573241FBBB053220DB334180B1BF8CD15732410D3411161CDB3341B402092AD557324132431CEB17DB33411CF46CB6D857324184E2C71815DB3341702F4C06DB573241A589B04112DB334188A44E50DD573241F653E3650FDB3341D0C56D94DF573241B6F3FD5494DA3341A09CA263695832416D12838071DA3341A4438B8C80583241F13845E73CDA3341DCF75383A35832414CC807FDDCD93341C4CEF7131E593241C6DCB58406DA3341545DDCE62059324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C92AD90E614DB3341B989504B6F583241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.313' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.313' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 16861825, NULL, 1, NULL, 0xBD0B000001040500000054F38E93FAA03841B00968A215D81D41CC4D62B009A1384160F54AD996D51D4160CC5D0BA6A03841D060545244D61D419C438B8CEA9F384190DFBE0E8BD71D4154F38E93FAA03841B00968A215D81D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB33AD8EEA4A038414CB93A7C12D71D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.323' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.323' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13862782, NULL, 1, NULL, 0xBD0B00000104090000009C2A1835F527334130C9E53F90901C4179C7299A14283341E0BFEC1EA5901C4123B0720818283341F096908F998F1C41EA95B2CC0928334130A1D6349B8F1C411F41F193FB273341F0CBEE099E8F1C41C576BE5FED27334100728A0EA28F1C415617B731DF273341A0802642A78F1C417F613215DD27334120FE43FA57901C419C2A1835F527334130C9E53F90901C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD76B67EDFB2733413D95614B15901C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.333' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.333' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 6257232, NULL, 1, NULL, 0xBD0B0000010405000000172FDD64108D3141F0830DCF5FA41B419006F0F62C8D3141C08A8E645EA41B41EEB0506BEB8C3141800B242866A31B417ED93DD9CE8C31413005A39267A31B41172FDD64108D3141F0830DCF5FA41B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C01F016E8FD8C3141C6C798FBE2A31B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.343' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.343' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13785648, NULL, 1, NULL, 0xBD0B00000104050000007F51491DD76A3341C03E57DBC9D41B41AE59F559C56A334140FBCBEE40D41B411B48507CC26A3341A03FA45FDDD41B4157643BFFBF6A33417011363C65D51B417F51491DD76A3341C03E57DBC9D41B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5DCCD07CC96A3341B12E2002D0D41B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.353' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.353' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10318810, 8024161, 1, NULL, 0xBD0B00000104EB020000A6BDC1F78FF8344174AA60344B56324147EA043497F83441348716F94E563241676FF0059EF83441D04F8D174C56324159302A49A4F8344184F08549465632415A204131A9F83441541058D93F563241428B6C67ACF834417C2F4C6638563241C8DCB524ADF83441A006F09630563241BADA8ABDACF834412CDD2486285632417E48BFDDABF83441484CA66A205632417CC0CA01ABF83441B4DFBE6E185632414EFC18F3A9F83441682BF6771056324152742497A8F8344104FBCB8E085632416F4694D6A6F83441CC6D34C000563241A5CFD596A4F83441E8FBA911F95532417C7AA50CA2F83441E485C974F1553241DE4603389FF83441889318E4E85532415D764FBE9EF83441F04F8DD7DB5532416A09F9A09EF8344124A7E8C8CE553241000000E09EF834415CF5B9BAC1553241215A647B9FF83441B89690AFB455324116B7D1C09FF83441A0F4DBB7B15532418E180426A0F83441A445B6C3AE5532410D83C0AAA0F8344150E17AD4AB5532418916D94EA1F83441440378EBA855324111583954A2F83441887AA59CA65532411E63EE6AA3F83441141DC955A45532413A3CBD92A4F83441488B6C17A25532415CCC5DCBA5F83441D4490CE29F553241B069DED1A7F8344100EBE2A69A55324150AF94A5A9F83441C8A22359955532418738D645ABF834410C83C0FA8F5532416ED712B2ACF83441649FAB8D8A5532416ABC7473ADF83441A06E1243865532417E613295ADF8344110F016E8815532412DD49A16ADF83441907CD0937D553241178C4AFAABF83441E48C285D795532412EDD2446AAF834411C6C785A7555324188F4DB97A6F83441DC0434C16E553241DDC7986BA2F83441AC33A2746855324197DD93C79DF834416096217E62553241C720B0B298F8344134D49AE65C553241B51E85AB85F834418048BF3D485532414E499D0080F83441F00FE9E7415532411E6C787A7AF834412485EB713B5532415E07CE1975F83441C0EC9EDC34553241C67F48DF6FF83441AC8BDB282E553241A43E57AB6DF834410C295C6F2B553241B696905F6BF834415807CEC928553241767AA5FC68F834417CF90F3926553241D0F7538366F83441D49AE6BD235532417E48BF4D62F83441CC6F5F771F553241334547725EF834412832E6DE1A5532414C7424F75AF834419C6CE7FB1555324161F7E4E157F83441848638D6105532419D45B65355F8344110F9A0870C5532410A2428FE52F834416410581908553241A657CAE250F83441045B428E03553241B837F8024FF83441009E5EE9FE5432418A7CD0D34DF83441A0923A01FB543241A067B30A38F83441BC172613FD553241A1A2233937F8344120B9FCC706563241A56054D23DF83441E4141DA90B563241073D9B3544F8344138C6DC7510563241828CB98B4AF834417458A85515563241F8A9F1D250F834414839B4481A5632419D45B6F356F83441AC8251691F563241495986D85CF8344148E17AD424563241A223B9BC62F8344194DB68402A563241DF0209EA68F83441385EBA492F56324106F9A0A76FF834415C05A39233563241E9AE258476F83441FCB27BB237563241C74B37C97CF8344114363C9D3C563241FA97DDB382F83441A49BC400425632418241602589F8344144E483BE46563241A6BDC1F78FF8344174AA60344B56324143C6DC5574FA34415C96218E8F5532417046945676FA3441D43B4E118C553241F7CBEEE977FA3441785F075E8855324161FE430A79FA3441DCFBA98184553241D7D781B379FA3441541E168A805532415F764F8E79FA3441802F4C867D553241615DDC4679FA344150D8F0847A5532413DDF4FDD78FA34415834808777553241AC69DE5178FA3441587B838F74553241AEB662FF77FA3441004D848D6E553241669A77BC77FA34410C83C08A685532412887168977FA3441D46F5F8762553241AA0A466577FA3441F48095835C5532410166F71477FA3441BC7BF2805555324169226CE876FA344104560E7D4E553241585BB1DF76FA3441E01DA7784755324156F5B9FA76FA3441E4C56D74405532413D60E50077FA3441C49BC4703A553241E0718ADE76FA34418C31776D34553241E9B7AF9376FA3441E4C7986B2E55324118C05B2076FA3441F89E3C6C28553241782D21FF75FA3441ECEBC069235532417858A8F575FA344120EBE2661E553241945CFE0376FA3441A405126419553241521E162A76FA34411CA5BD6114553241CED5565C76FA3441ECD9AC5A0B553241EF9E3C5C76FA3441946E125302553241F2EBC02976FA344164A3014CF95432418E4AEAC475FA34413CD49A46F054324117E258B775FA344184DB6840EC543241506B9AC775FA34418C703D3AE8543241E773B5F575FA3441BCF3FD34E4543241C252964176FA34418CA98231E05432413E355ECA76FA34416C832F3CDC543241E9B7AFC377FA344194438B5CD8543241FCC2642A79FA3441C468009FD4543241AD59F5F97AFA344130B29D0FD1543241303333A37EFA3441789ECD0ACB543241C9E53FC482FA344130AF9455C55432416766665687FA3441386744F9BF543241C7293A528CFA34418CFF90FEBA54324109F9A00791FA34418C779C32B75432410F83C0EA95FA344188B740A2B3543241EA1DA7F89AFA34419CCDAA4FB0543241A9E8482EA0FA3441885AD33CAD543241E8FBA9D1A3FA344100B37BB2AB5432417A9CA293A7FA344174C7297AAA54324146C8076DABFA34413CDD2496A954324122F46C56AFFA3441DC263108A95432414803785BB3FA3441E09AE6ADA8543241C420B062B7FA34411CA5BD71A8543241C9073D6BBBFA34412861C353A854324111583974BFFA344148EA0454A854324163325570C2FA3441A4ABAD78A854324101DE0269C5FA34410095D4C9A85432414EE3A55BC8FA3441801D3847A95432412EE6AE45CBFA344144696FF0A9543241DDA59B34CFFA3441D476BEAFAA5432414FDA1B2CD3FA3441146C783AAB543241FED47829D7FA3441EC164890AB54324184B0E129DBFA34414460E5B0AB54324116C05B20E2FA3441ECD0221BAC543241604BC807E9FA34415027A019AD543241857CD0D3EFFA344120A392AAAE543241F7065F78F6FA3441107A36CBB054324182B74042FAFA34410C6F8114B25432413E2CD40AFEFA344180E09C61B35432416ED712D201FB34416CCE88B2B454324129CB10C703FB3441D84F8D47B5543241784F1EB605FB344110F241EFB554324199FF909E07FB34415C1058A9B6543241565BB17F09FB3441043D9B75B7543241B0FA5CBD0BFB344140B6F35DB954324123EBE2C60DFB34419811A57DBB54324122EBE2960FFB344134BB27CFBD5432415639B42811FB3441B00C714CC0543241CF22DB4914FB3441F8E76A7BC55432419D923A5117FB34415827A0B9CA543241DF718A3E1AFB3441B0B88D06D05432418EA982111DFB34419489B061D5543241E19387551EFB3441683BDF1FD85432417FD0B3591FFB3441C07D1DF8DA543241B615FB1B20FB34419833A2E4DD5432413E2CD49A20FB34418CED7CDFE054324106D7A35020FB344140A4DFDEE3543241FD7E6AAC1FFB34417CC420D0E6543241BB847CB01EFB3441BC54C1A8E954324116C05B601DFB3441BCFF905EEC543241BF7D1D8819FB3441D4817366F35432417736AB3E15FB344190559F2BFA5432414A59868810FB34410822FDA600553241BB30996A0BFB34417817B7D10655324102780BE404FB34419C11A56D0E5532418C635DACFEFA34418087854A16553241BFC117C6F8FA3441B0D32B651E553241BD0E9C33F3FA3441DC1951BA26553241B07BF2B0F1FA3441BCA1456629553241BFA8A43EF0FA3441CC073D1B2C5532411D1FF4DCEEFA3441F4FDD4D82E5532412731088CEDFA3441181B9E9E31553241CAFEB2CBECFA3441C442AD79335532413AF8C224ECFA344140CD3B5E355532417614AE97EBFA34412C63EE4A37553241122FDD24EBFA34416CAD693E395532413ACD3B0EEBFA3441B059F5F93C5532417A711BBDEBFA34413C82E2E73E5532417A832F8CECFA344104BE30C94055324103A3927AEDFA34410CA8C69B425532417F1D3887EEFA34419C11A55D44553241C532C481F1FA3441407958684A553241FA31E66EF4FA3441147E8C79505532414E8D974EF7FA344100053491565532416BF90F79F8FA344150F6974D595532418F87855AF9FA344138F8C2245C55324108D7A3F0F9FA344158BB270F5F5532416207CE39FAFA34410866F70462553241199E5E59FAFA344198BB96106A5532419B4C15DCFAFA344188EB511872553241E9FBA9C1FBFA34411CE258177A553241DE0B9309FDFA344184C2F50882553241B78D06D0FDFA34418436ABEE84553241D0AACFB5FEFA344134234ACB87553241908785BAFFFA34414CBF7D9D8A5532410E2DB2DD00FB34411C41F1638D553241B1E1E9F503FB3441886CE7CB9455324189F4DB0707FB3441940F7A369C553241DBD781130AFB34414C9CA2A3A3553241726891BD0AFB3441A0ABAD88A5553241D266D5570BFB3441DCA9F172A7553241570E2DE20BFB344194A0F861A9553241FA7E6A5C0CFB34417C613255AB553241190DE07D0DFB3441C0490C02B05532419A218E050FFB344168006F91B455324198BB96F010FB34418CBE9FFAB85532417C95433B13FB344154EF3835BD553241A2923AE115FB3441A0A22339C15532416E8A8E6417FB3441BCF1D26DC35532419E3C2CF418FB34413C3EE899C5553241683BDF8F1AFB3441C8E314BDC75532418816D97E1CFB3441EC8E5304CA55324192E4F2AF1EFB34411848500CCC5532416FB5151B21FB344124F697CDCD553241021973B723FB34410CA5BD41CF55324142AD697E27FB3441DCB7AFA3D0553241D04D62402BFB3441F8A9F112D25532419E1A2FFD2EFB3441D05F768FD3553241FF65F7A432FB344170A3012CD55532418FA0F82136FB3441003B701ED75532411948506C39FB34410C7C6162D9553241C0EC9E7C3CFB3441CC20B0F2DB553241EE85C9E43EFB3441E05817B7DD553241A73E576B41FB344144A4DF4EDF5532410A560E0D44FB3441A4D409B8E0553241B6B88DC646FB34415829CBF0E1553241AFBFEC5E4CFB344140795838E4553241876CE7EB51FB344158EC2F9BE6553241AF03E76C57FB344178F90F19E9553241D81B7CE15CFB3441C032C4B1EB553241A0ABAD9877FB34410444FA0DAD543241FE1873D7E9F93441B80E9CF38B543241ECC9C3025AF834412C0DE0AD6A543241EA8C28AD54F83441F453E3E5A95432412E08AC5C54F8344194ABAD98AD543241C7FEB24B57F834412C3333A3B2543241D8E76AFB59F8344128A089D0B75432413255306A5CF83441E0839E1DBD543241724694965EF834416C1D3887C2543241E66A2BB65FF834411C1DC945C5543241462EFFA160F83441D06F5F17C85432413C70CE5861F8344128992AF8CA54324109B5A6D961F8344134014DE4CD5432413C4ED1E161F83441D09E3CECCF543241FAC264DA61F834415CCA32F4D1543241F7A067C361F834411871ACFBD3543241875AD39C61F8344184B74002D6543241B203E75C61F834411011360CDA54324132B4C88661F83441C8C64B17DE543241E202091A62F834416439B418E2543241962A181563F83441A801BC05E654324182B740F263F83441E4A59BE4E8543241F29E3C0C65F83441140456AEEB54324109CE196166F834419028ED5DEE543241FA3A70EE67F8344170567DEEF0543241938785CA6AF834412C772DC1F3543241EDF44AE96DF83441189E5E49F6543241E8C0394371F834417C09F980F854324180FB3AD074F83441285C8F62FA543241C876BE8F78F834419006F0E6FB543241DBA59B547CF834417C7FD95DFD5432410B1B9E1E80F834416C1D38C7FE543241D0AACFD582F8344194E61DE7FF543241C88F316785F8344180613255015532412A7502CA87F83441A0438B0C03553241E96A2BF689F83441D06F5F0705553241ACFA5C6D8DF83441845F07FE09553241604BC80791F834416CCC5DDB0E553241104FAFC494F83441741F639E13553241CCF753A398F8344144DD2446185532411573D7429BF8344130014D441B553241DC12F2219EF83441E073B5051E553241A05E293BA1F83441300F0B852055324104E78C88A4F8344108F697BD22553241C2529621A7F83441D0B7AF432455324186C954B1A9F83441A4A223D925553241B6A67937ACF83441EC63CC7D27553241BC0E9CB3AEF83441B872683129553241915CFE13B2F83441A433A2542B553241FFDD0249B5F834415494F6B62D5532415296214EB8F834410466F754305532411CDBF91EBBF8344170D5E72A3355324135EF38A5BDF834416C6FF045365532418CA98211C0F83441944160753955324131333363C2F8344100075FB83C5532410AB5A699C4F83441E47A140E40553241160DE04DC8F834416CB515AB45553241FBDBD711CCF8344198DA8A3D4B5532416D787AE5CFF83441182653C550553241129C33F2D1F834410C6C782A5455324186F4DB97D3F834418C1804C6575532416609F9D0D4F83441F8A7C68B5B55324164105899D5F8344144840D6F5F5532418448BF2DD6F83441E8065F88645532410993A9B2D6F8344184855AA369553241C07D1D28D7F83441F81FD2BF6E553241E27A148ED7F834412CF697DD73553241A635CD9BD7F83441188A1F237755324136D6C5BDD7F8344104F016687A553241905CFEF3D7F8344164A301AC7D5532413FAD693ED8F834411C0456EE8055324100B37B82D8F83441B8A8A47E825532419A559FFBD8F834410C9C330284553241BE86A7A7D9F8344100BC0572855532411E4A7B83DAF834413C8B6CC78655324192A0F8F1DDF83441148E7531865532417E2F4C66E2F83441486EA3E1835532411BE25847E4F83441F4F44AF982553241636DC51EE6F8344144B6F3FD81553241A935CDEBE7F83441741B0DF080553241C6BAB8ADE9F834414472F9CF7F553241302AA923EEF834418CC420107E55324127E483BEF2F83441C0E314BD7C553241B025E473F7F834417807CED97B5532413A674439FCF8344188EB51687B553241AC25E40301F934415827A0697B553241D2BCE30407F934417451494D7B55324196BB96000DF9344108A392CA7A5532415B5227F012F93441B4490CE27955324141E8D9CC18F93441806ABC947855324192B96B391EF9344110C7BA3877553241F9285C7F23F93441B80C715C755532411E73D79228F93441ACCEF7037355324194CB7F682DF9344158C1A83470553241B2EA73F531F93441846ABCF46C553241EC6A2B5636F934412C08ACCC6955324188635DBC3AF93441A82C43AC6655324120B9FC273FF9344170F38E9363553241042B874642F934416C1F631E61553241674DF30E45F9344158302A495E5532418438D67547F93441CC96901F5B5532419E923A7149F93441101B9EAE575532414750FCF84AF93441086F8104545532414794F6F64CF9344148DF4F4D4E55324168226CC84EF93441CC6F5F8748553241B003E76C50F93441B45CFEB34255324100780BE451F93441281895D43C5532414E840D9F53F9344134E2580736553241F9A067A355F93441F83A704E2F553241CA6D34F057F93441141FF4AC28553241AE1C5A845AF93441686FF02522553241BEA8A44E5CF93441F4A067631C5532410B8A1FE35DF93441F0043491165532415B2041415FF93441D03B4EB1105532417B029A6860F934412CE6AEC50A553241B0FA5CFD61F93441142DB2BD03553241EE1FD21F64F9344174AC8BDBFC5432416A9A77CC66F9344180A7572AF6543241D46800FF69F93441944AEAB4EF543241374547B26DF93441A401BC85E95432412F55305A71F9344198DFBEBEE3543241E3E9951275F93441ECD24D02DE543241225A64DB78F9344118D7A350D85432414E6B9A177AF934411C5839D4D65432413880B7807BF9344194802682D5543241C25B20117DF93441345BB15FD454324196779CC27EF9344150575B71D3543241D22B65A981F93441481CEBD2D25432413911369C84F93441CC31E67ED2543241769CA29387F9344130DD2476D2543241EA2631888AF934410CC7BAB8D25432419E779C9290F93441B4B35945D3543241DDF97E9A96F9344158AC8BEBD354324122D26F9F9CF934418C9543ABD45432416809F9A0A2F9344170537484D5543241E76A2BA6A5F93441C4DCB5A4D554324197559FABA8F934413C03788BD554324108560EADABF934418C19E238D554324113143FA6AEF93441B0FA5CADD454324108A3929AB1F93441649A770CD454324110143F96B4F9344158FC1893D3543241C88F3197B7F9344138378941D3543241A63E579BBAF9344150621018D35432411283C07ABDF93441A49F1A7FD35432415CF5B94AC0F9344168810435D45432415EE5D002C3F934417814AE37D5543241AE47E19AC5F93441FC770B84D6543241F5EDEB40CAF934414C136153D954324188855AE3CEF93441A4ABAD28DC543241A0802682D3F934419825E403DF543241FA5C6D15D7F934416C438BCCE05432412FB29DAFDAF93441943D0A87E25432416F128350DEF934418C855A33E454324186F4DBF7E1F93441D03B4ED1E554324136014D24E9F93441B88BDB58E95432419A218E35F0F934417858A815ED543241C039232AF7F93441605DDC06F1543241FEF67500FEF93441A8559F2BF55432411F85EB6102FA344124265335F854324140E8D97C06FA3441BC15FB9BFB5432419B9999490AFA344110BE3059FF543241E22406C10DFA344120FDF665035532413008ACDC10FA3441C410C7BA07553241C898BB9613FA3441E45F764F0C5532418195431B16FA34414803780B11553241A8DFBE8E18FA344190DB68D0155532419AB20CF11AFA3441A4D1009E1A553241CD5D4B481DFA3441C0F5280C1F5532414672F9AF1FFA3441288E757123553241652BF62722FA3441182DB2CD2755324192C420B024FA344170499D202C5532413F82E2272AFA34410CE561B135553241FEDD02492FFA3441E8FBA9713F553241AD69DE1134FA344148AD695E495532416609F98038FA3441C8FC8774535532411F166A1D3CFA3441408E75815B553241DEA59B1440FA3441A84E406363553241B8FC876444FA34414CC6DC156B553241FE99080B49FA3441F45C6D95725532419E01BC054EFA3441042428DE79553241F875E0FC51FA3441846132E57E55324136B4C85656FA34416C4BC89783553241B30C710C5BFA3441681F63EE87553241C6A1451660FA344184A0F8E18B55324179832F6C65FA3441F09E3C6C8F553241DA9AE63D67FA34419811A55D9055324151F38E2369FA3441985CFE2391553241DE141D196BFA3441EC839EBD915532418D87851A6DFA3441AC825129925532411183C0EA70FA3441006F81049255324143C6DC5574FA34415C96218E8F5532414B257522DFF8344138BB278FD3553241203867C4DDF8344188A0F871DB553241D668006FDDF83441C0C3426DE355324177A52CA3DDF834418C33A274EB55324120FDF6D5DDF83441B0C8767EF3553241B1FA5C8DDDF8344194D2DE80FB553241E3B584DCDCF834415C764F7E035632414C598618DCF83441707EFB7A0B56324104000080DBF83441341AC07B13563241E595B2ECDAF834418CE4F27F1B5632410F0BB586DAF83441D000DE8223563241CED556ACDAF8344184DB68802B563241A31A2FFDDBF8344144204171335632411CFDF615DCF83441EC56EC6F3B5632410A8195C3DBF83441703D0A77435632418C28ED2DDBF83441089A087B4B563241B0E1E955DAF83441580E2D7253563241D6E76A8BD8F83441904160455B5632415A17B751D6F83441840F7A166356324192559F4BD4F83441A49318446B56324166226C58D1F8344154FAED8B725632418AA7578ACBF8344168E5D0027756324193ED7C1FC3F83441B496906F7856324172C5FE32BBF83441E81114FF78563241B203E72CB3F83441D8BE0EDC785632412397FF30ABF834418CCE889278563241B3E1E935A3F83441C0EC9E3C78563241E0B5843C9BF83441E49C11C577563241139E5E4993F834411C76E01C77563241DC4603588BF834410CA3923A7656324157CA326483F83441D4073DFB74563241AA0A46C57BF83441A013D0C4725632412CE4837E74F83441AC1C5A846F5632414C7424776DF83441BC2A18956B563241F7A067D366F834414862101867563241361AC09B60F8344168894120625632414794F6A65AF83441904AEAC45C563241750B24E854F834416C82E22757563241394ED1514FF834416CA7576A515632410244FA8D4AF83441049A08FB4A5632413E8B6CA745F83441287E8CB9445632419CF831863FF83441B8A679A73F563241E5D9AC1A39F834417436ABDE3A56324179F2B03033F83441F43A708E365632417A36AB1E16F83441F8B9DAEA8E5732410088F41BA5F93441F0AE2564B05732419C11A51D34FB34411C3FC6DCD1573241EF1FD2CF55FB3441ACBFECFE3F563241AD0C71EC59FB3441444547F20E563241A023B91C54FB34415829CB500D56324113D0444851FB34417C029A580C56324152D1917C4EFB34417C0B24480B5632416ADE71BA4BFB34417404C51F0A56324182AEB60249FB34413C92CBDF0856324190A9827144FB34417CAC8BDB0656324169BC74D33FFB3441B4EA73F504563241A98251293BFB34410064CC2D035632416BB3EA7336FB34418C4AEA84015632411CB7D10030FB3441F42EDDD4FE553241838CB9CB29FB3441A4CDAA9FFB553241FB285CDF23FB3441A447E1EAF7553241666FF0451EFB34410076E0BCF355324154423ED81BFB3441AC976EF2F155324104B5A65919FB3441B4ADD83FF055324170B515CB16FB3441A001BCA5EE5532418B31772D14FB344170C1A824ED55324190C2F59811FB34414CFC18A3EB5532415C5DDC160FFB344124819503EA553241475986A80CFB3441C8AF0347E8553241860D4F4F0AFB3441ACE8486EE6553241CCE53FF408FB344180B0E1F9E4553241E7839EBD07FB344134D49A66E3553241529621AE06FB3441E04603B8E1553241E82631C805FB3441C869DEF1DF5532410AD7A3B001FB344150BD52C6D655324155F5B9FAFDFA3441C8529671CD553241C17D1DA8FAFA3441F82FBBF7C3553241EAE236BAF7FA34410876E05CBA55324142C6DCF5F6FA3441946E1273B75532411071AC4BF6FA34418C8EE482B4553241D4DEE0BBF5FA3441901A2F8DB15532419EEFA746F5FA344100AAF192AE55324110583934F4FA3441F0907EABA85532414C840D8FF2FA3441B4F831E6A2553241A25E295BF0FA344114AE47519D553241BAD1009EEDFA3441146C78FA97553241110BB556EBFA344164EE5A8293553241A233A244E9FA34419CBB96F08E55324190C2F568E7FA344130A2B4478A5532415BC1A8C4E5FA34413055308A855532418AC95421E4FA34414C72F9CF80553241FA2A8736E2FA34411CEEEB307C55324192180406E0FA344118AE47B177553241CA32C491DDFA34410846255573553241587DAE86DBFA344190A0F8E16F55324115E9B79FD9FA344120355E5A6C553241112DB2DDD7FA3441FC1FD2BF685532418AC95441D6FA3441847CD0136555324135014DA4D4FA34416007CE59615532411A3FC6ACD2FA344160BA49CC5D55324102098A5FD0FA3441500AD7735A553241286519C2CDFA3441DC3D795857553241AC9BC480CCFA344194A44ED05555324118FBCB5ECBFA344160696F3054553241190DE05DCAFA34415CCC5D7B525532417824977FC9FA34418445B6B350553241F3065FF8C8FA3441507502CA4D55324188855AC3C8FA3441F08AFDD54A55324176E926E1C8FA34413C80B7E047553241AA726851C9FA3441503333F3445532412CBB27FFC9FA3441101973E740553241B259F599CAFA34419CABADD83C55324182C0CA21CBFA3441D43845C738553241420AD793CBFA34417006F0D63655324152621038CCFA3441C8BCE3F4345532419C23B90CCDFA3441EC6A2B26335532412FB29D0FCEFA344124B29D6F31553241924AEA64D0FA3441A89999292E55324148EA04D4D2FA3441704694F62A5532411548505CD5FA344118E258D727553241A41A2FFDD7FA3441CC95B2CC24553241925CFEE3DBFA3441D0F0F43A2055324149C8078DDFFA344114022B771B553241D5AACFF5E2FA3441CCA59B841655324176A3011CE6FA344184EFA76611553241E67A14DEE8FA344104CB10B70C553241F30DBEB0EBFA3441A872681108553241F597DD93EEFA3441B4E1E97503553241409B559FF0FA3441B01C5A1400553241053D9B55F2FA3441104FAF84FC5432415305A3B2F3FA344140643BCFF8543241313333B3F4FA3441043FC6FCF454324180D93DB9F4FA34417C4694F6F15432412C333373F4FA3441E4D781F3EE543241CA32C4E1F3FA3441B0270FFBEB543241F44A5906F3FA344144189514E95432411E1FF4CCF1FA3441382AA923E5543241D85F769FF0FA3441782D212FE154324148B6F37DEFFA3441E8581737DD543241C632C4A1EEFA34413CF6974DDA543241DE581787EDFA3441BC627F79D7543241D956EC2FECFA3441B48D06C0D45432415F6DC59EEAFA3441A0F83126D25432416C4DF34EE9FA3441701804C6D0543241DD9387D5E7FA3441808EE492CF5432411EB07238E6FA3441386EA391CE5432415E764F7EE4FA3441746666C6CD543241875AD39CDEFA344120DBF90ECC543241D1B359A5D8FA34412C0378ABCA5432414FD1919CD2FA3441B03A019DC95432410E022B87CCFA3441CC1C5AE4C85432412AA089F0C6FA34413CD1912CC954324130A2B467C1FA344100295CFFC95432416DE7FBF9BBFA3441F8D9AC5ACB5432412A1895B4B6FA344134234A3BCD54324159CA32A4B1FA3441C8EC9E9CCF5432415E07CE39AEFA344198BB96C0D1543241283A920BABFA344130158C3AD45432411E85EB21A8FA3441F497DD03D75432416F8A8E84A5FA3441F47C3F15DA5432419EABAD08A4FA3441200DE0BDDC543241714694D6A2FA34419067B38ADF543241E8FBA9F1A1FA3441C4EEC973E2543241DFB5845CA1FA3441E044D870E55432419FA223E9A0FA3441D4847C70EA543241527424E7A0FA344150984C75EF543241BAB88D56A1FA344158984C75F4543241FF2A8736A2FA3441D8817366F9543241BCF5283CA3FA34411C1DC9E5FB543241528D972EA4FA34417C7AA56CFE543241E4839E0DA5FA3441346C78FA00553241D04D6220A5FA3441B8C117F602553241235A64FBA4FA34417CF2B0F004553241C29F1A9FA4FA344160CA32E406553241767AA50CA4FA3441C43099CA08553241E9AE2574A3FA3441F80DBEC00B553241039A080BA3FA3441F431E6BE0E5532419E89B0D1A2FA3441246519C211553241427958C8A2FA3441D86F5FC714553241FE4C84BDA2FA3441E40209CA1A553241FA5C6D65A2FA3441ECE236CA20553241AAA44EC0A1FA344144EA04C4265532414F8D97CEA0FA3441E40E9CB32C553241DB1B7CE19FFA3441A05E299B30553241F8A067E39EFA3441E0718A7E34553241D6C56DD49DFA3441D4A3705D385532419E33A2B49CFA3441506B9A373C5532412A6519A29AFA3441CC7D1DF843553241DD361AD098FA3441E454C1C84B553241772D213F97FA3441508B6CA753553241B69690EF95FA344100BC05925B553241666666C694FA34419C89B081635532416691EDAC93FA3441BC0E9C736B5532417CA52CA392FA3441E8F8A067735532413770CEF891FA3441E821FD667855324127E4836E91FA3441ECE2366A7D5532412138670491FA3441C4847C70825532418E8785BA90FA3441B06B097987553241CD3B4E5190FA3441F051B86E8B553241CE66D5878FFA3441E473B5558F5532414772F95F8EFA344148D8F02493553241FB7E6ADC8CFA3441D4D781D396553241D0BCE3B489FA3441AC9690BF9C5532418F976E2286FA3441D0839E6DA2553241AA79C72982FA3441E46A2BD6A755324111E02DD07DFA34413C2EFFF1AC553241D6E76A1B79FA344130355EBAB15532415917B71174FA34412CA7E828B6553241D968008F71FA34413C60E5F0B755324140E8D9DC6EFA3441C8C3426DB95532412E211F046CFA3441A4A22399BA5532414C96210E69FA34417CF2B070BB553241322AA92366FA344108000080BB553241163FC63C63FA3441F05C6D35BB553241C6E53F6460FA3441B8490C92BA55324157C1A8A45DFA34419CB43798B9553241A3A44EE059FA3441E43B4E01B8553241AA57CA2256FA3441344CA65AB65532415FBA496C52FA3441B01C5AA4B455324130FF21BD4EFA344128E483DEB25532415DE5D0124DFA3441E87A14CEB1553241187C61924BFA34417C613285B05532412D3333434AFA3441E8E2360AAF553241F0A7C62B49FA34418C537464AD55324132772D4148FA34413870CE98AB553241E293876547FA344140C6DCC5A9553241BB6B099946FA3441D4BE0EECA75532418D6CE7DB45FA34412CFAED0BA65532412806815544FA3441E82D9050A2553241FA4A59C642FA3441F0FDD4989E553241F53A702E41FA3441A813D0E49A553241A9C64B3740FA3441F0384507985532411A9E5E793FFA34416C19E21895553241161DC9F53EFA344190081B1E9255324138DF4FAD3EFA34418875711B8F553241841D38573EFA34419C3C2C248B5532410A68228C3DFA3441082DB23D87553241CD88D24E3CFA3441005D6D7583553241DAD781A33AFA3441F8AF72D87F5532414A72F98F38FA3441D41726737C5532412653050334FA34419C89B0D1755532413A4547522FFA34411C9E5E496F553241ED5A427E2AFA3441F4F0F4DA685532412CC2868725FA344110022B87625532414650FC7822FA3441583255905E55324156A8358D1FFA344138B29D7F5A553241E29C11C51CFA3441A4F8315656553241FAE461211AFA34415C984C15525532412038676414FA3441203108DC4955324166BC74430EFA3441D0F528EC415532410E9C33C207FA344168DE714A3A553241006F81E400FA3441987571FB325532415E8FC2F5FDF93441347C615230553241403EE8C9FAF9344170BC74F32D55324111D04468F7F93441809318E42B553241C17493D8F3F9344150F90F292A553241FDF67520F0F934417C44699F2855324198559F7BECF93441287502EA265532414DDA1BECE8F93441D079C70925553241F797DD73E5F93441C876BEFF225532415C5DDC46E2F93441CCDA8A7D2055324105462525DFF93441905149ED1D553241D968000FDCF9344130BB274F1B553241885AD3CCD8F934411098DD13195532411E6C784AD5F934411841F14317553241EA73B595D1F934414C9D80E615553241BEE314BDCDF93441A8D2DE0015553241C698BBC6C5F93441D815FBEB13553241098195C3BDF9344110E02D50135532417F9ECDBAB5F9344148B6F32D13553241C40E9CB3ADF934416C787A851355324132772DB1A7F934415820415114553241E651B8BEA1F9344154B6F37D15553241A86054E29BF9344104C3640A17553241B6490C2296F93441B8F3FDF418553241A89BC49092F934414CBF7D9D1A553241841D38478FF934411CB4C8C61C553241B5A679578CF934410066F7641F55324178E09CD189F93441405EBA692255324126A0898086F93441949CA28327553241657FD99D83F9344100DBF9DE2C553241E0718A2E81F93441B4408272325532411DEBE2367FF9344148E17A343855324121B9FC477EF93441BC00DE123B55324178A52C437DF9344118ECC0E93D5532415539B4287CF93441B0CB7FB840553241F4FDD4F87AF93441B0C8767E4355324146C8078D79F9344194BB9620465532417B9CA2F377F9344198D409A8485532410A1B9E2E76F93441BC32C4114B553241DE361A4074F93441C010C75A4D5532413A5EBA3970F93441E48173D651553241E91DA7286CF93441B0946548565532416891ED0C68F9344110A089B05A553241A2EFA7E663F93441ACDFBE0E5F55324124E483EE60F93441E810C71A6355324110022B275EF93441AC34EF48675532419E8026925BF934415C5DDC966B5532413E60E53059F9344180B7400270553241189E5EC955F9344104A5BDC1755532410BF016E851F934412485EB317B5532410F5839944DF9344178E2C748805532415E8FC2D548F93441E475E0FC8455324172787AB543F934419C218E4589553241865AD33C3EF93441B447E11A8D553241FA065F2839F93441201DC9459055324127E483FE33F934418C51494D93553241C86D34C02EF93441F444D83096553241FA3A706E29F93441DC56ECEF98553241624BC86721F93441606666069D5532412E4CA64A19F93441B49690EFA05532415062101811F93441B047E1AAA45532412997FFD008F934411010E937A855324118AE472104F93441D8839EEDA955324173E7FB59FFF83441D0D5565CAB553241CC7F487FFAF83441E0C9C382AC5532412C068195F5F8344120C9E55FAD553241726891CDEBF8344154EC2F5BAF553241A7CFD516E6F8344174E7FB09B4553241B7490C02E4F834414497FFF0BB55324199658883E2F83441548638D6C355324180D93DF9E0F8344180ABADB8CB5532414B257522DFF8344138BB278FD3553241030000000200000000024B00000002A801000004000000FFFFFFFF0000000006000000000000000003000000000100000003000000000200000003, 0xBD0B0000010C57551CF8CBF934414E26086935563241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.387' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.387' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3587398, 90054401, 1, NULL, 0xBD0B000001040700000058522720875034418CBB96F0361033416844696F57503441EC0FE9D7441033415E4BC88746503441D44D6290FD103341BA15FBEBD8513441E0D781131A11334157643BDFE75134415C9621EE501033412E4CA64AA15034411C88F4DB3810334158522720875034418CBB96F03610334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C687BEEC218513441A8CC82B2A7103341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.413' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.413' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13843109, NULL, 1, NULL, 0xBD0B0000010405000000549FAB2DC7502B41C4F5285CE360314115FBCBEEC6502B415C204151D7603141B0ADD85FB2502B41047C61D2BE6031410E1B9E1EB3502B41D8C56D74E3603141549FAB2DC7502B41C4F5285CE360314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CCFEEF930BB502B4125011936D6603141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.423' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.423' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14371430, NULL, 1, NULL, 0xBD0B0000010405000000E46A2B7653BA3241B039234AA9F01C4183C0CA6157BA3241D0AACF55B1F01C41D55F76EF7ABA3241B03C2C5451F01C41624BC80765BA32419033A23424F01C41E46A2B7653BA3241B039234AA9F01C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C361D46C965BA324176510BBD66F01C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.433' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.433' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15494501, NULL, 1, NULL, 0xBD0B000001044C0000008F635DDC21283941701A2F5D87D7204150B81EF521283941C00C716C8AD720410E022B372228394108BC05728DD720410BA5BDA1222839411826536590D72041342AA93323283941587FD93D93D720418CD2DEC025283941B00512D499D7204102098A2F272839412095D4C99CD7204144CF668528283941D895B2EC9FD7204194B20CC12928394168105839A3D72041A3923AE12A283941B80C71ACA6D72041B696907F2C283941A0627FB9A8D720418048BFFD2D28394190DB6820ABD720418B06F0562F283941E02B65D9ADD720410E0BB5863028394158E3A5DBB0D72041C698BB763128394178180416B8D720419EA2239931283941488FC275BAD720419AFF90CE31283941B08D06D0BCD72041A8CFD5163228394110D34D22BFD720417AE09C7132283941C0C2646AC1D720415CFE433A3328394100EEEB80C4D7204186855A1370283941E88E53746FD720413C1CEBE26A2839415072F98F60D72041BAB88DC665283941382EFF6151D7204180AEB6C260283941880B24E841D720419FABADD85B283941A8F7532332D7204122B0720857283941E085C91422D72041560E2D525228394148A4DFBE11D72041002B87B64D28394190C0CA2101D720413EC6DC3549283941A0FF903EF0D62041B68D06D044283941A0BDC117DFD620417D2F4C8640283941606891ADCDD62041506210583C28394150378901BCD620419CF8314638283941D0BCE314AAD620414160E55034283941289E5EE997D6204110D044783028394160499D8085D62041885AD3BC2C283941302CD4DA72D62041E751B81E2928394120917EFB5FD62041EE5A429E252839419889B0E14CD6204152AF94E523283941685452E742D62041E661A13622283941F087F4DB38D620415F29CB5011283941A8FD6577D1D5204186C0CA81FF273941A0A3703DF1D62041482EFFE1FD273941007F6A7C0BD72041452EFFD1FE27394190976E720ED72041B61C5AD4FF2739410872F94F11D720416B226CE800283941A817261314D720417268910D0228394148355EBA16D72041F01FD28F03283941B8EA737519D72041B0E1E9F504283941C039236A1CD72041CABAB83D0628394158B3EA931FD72041AB0A466507283941180DE0ED22D7204179832FFC07283941A8D85FD626D720418173466408283941880F7AD62AD72041055F989C08283941085D6DE52ED72041CADCB5A40828394168355EFA32D72041D8ACFA5C09283941F06A2BD636D720418F1804460A2839415082E2873AD7204142BF7D5D0B2839412854E3053ED720416E1283A00C28394130CB104741D72041048A1F830D283941B0A44E6044D720419AB437780E28394190DC466347D720419DD6347F0F28394130CD3B4E4AD72041E04F8D971028394100098A1F4DD72041B269DEB11128394100BE305953D72041FB53E3351328394130AB3E3759D72041B00C711C15283941607FD99D5ED72041669A775C17283941B84E407363D720417B9543EB19283941F82D90A067D720418CC954711B283941C8B359556AD72041AB7268D11C28394160AB3E576DD72041A8BDC1071E283941507FD99D70D720412797FF101F2839415089412074D720417C2F4C062028394188E09C5179D72041464772092128394168226C787ED72041D019511A22283941D005129483D720418F635DDC21283941701A2F5D87D7204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C09FE98BF2B2839418A32FB6AFDD62041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.443' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.443' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8969612, 31215701, 1, NULL, 0xBD0B0000010412000000039A08FBBB85334190984C1577D81B419E67B38AC7853341F0F141CFC8D81B414E158C6ACC853341F01A9E9EEDD81B41F44A59C6D0853341106A4D7313D91B4159F5B99AD485334160B29D2F3AD91B41104FAFE4D7853341D0EA73B561D91B41336EA3A1DA8533410054E3E589D91B41D45F76CFDC853341E01B7CA1B2D91B41B40C716CDE853341909465C8DBD91B411AE25877DF853341306C783A05DA1B418A0D4FEFDF85334100AB3ED72EDA1B41F21648F0DF85334180BDC1D745DA1B41EC8E53C4DF853341F03C9BD55CDA1B416DAC8B6BDF85334160CC5DCB73DA1B41DA8AFDE5DE853341B00E9CB38ADA1B41A411A51D0486334100CCEEC992DA1B41CC20B072DC85334110D3BCE3CCD81B41039A08FBBB85334190984C1577D81B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC6F59D7BE485334130B46BD2B3D91B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.467' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.467' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8969612, 31215701, 1, NULL, 0xBD0B0000010412000000039A08FBBB85334190984C1577D81B419E67B38AC7853341F0F141CFC8D81B414E158C6ACC853341F01A9E9EEDD81B41F44A59C6D0853341106A4D7313D91B4159F5B99AD485334160B29D2F3AD91B41104FAFE4D7853341D0EA73B561D91B41336EA3A1DA8533410054E3E589D91B41D45F76CFDC853341E01B7CA1B2D91B41B40C716CDE853341909465C8DBD91B411AE25877DF853341306C783A05DA1B418A0D4FEFDF85334100AB3ED72EDA1B41F21648F0DF85334180BDC1D745DA1B41EC8E53C4DF853341F03C9BD55CDA1B416DAC8B6BDF85334160CC5DCB73DA1B41DA8AFDE5DE853341B00E9CB38ADA1B41A411A51D0486334100CCEEC992DA1B41CC20B072DC85334110D3BCE3CCD81B41039A08FBBB85334190984C1577D81B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC6F59D7BE485334130B46BD2B3D91B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.477' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.477' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10358820, 90091426, 1, NULL, 0xBD0B000001040500000071F90F499066354130DF4F8DE6AD2341F797DD1390663541F82FBBA7E6AD2341A435CDDB8B663541809CA26318AE23416BBC74739866354118AE476119AE234171F90F499066354130DF4F8DE6AD234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C9323167D91663541C882A6D807AE2341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.503' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.503' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5649307, 761941, 1, NULL, 0xBD0B00000104070000000E83C04AB0D1314190FEB2FBD8F01941C8BAB84DB0D131417057CAB2BBF01941A9CFD536ACD13141B08173467EF019415E07CE79A6D13141400C022B5FF01941287502DA94D131413083C04A3FF01941E9FBA91194D1314190AC8BDBA5F019410E83C04AB0D1314190FEB2FBD8F0194101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEB061C4CA1D13141EE3BEDFB8CF01941, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.513' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.513' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14612364, 11706281, 1, NULL, 0xBD0B00000104400000000022FD96792D344168666686EFE43341FF088A9F802D344148621058F3E43341489D80A6872D3441F8B0502BF7E43341A201BCA58E2D34418095430BFBE433410A341196952D344140257502FFE4334110E9B76F9C2D344180BE9F1A03E53341CED5562CA32D3441F051B85E07E5334196A982B1A92D3441EC4EAFF40BE5334101F77500B02D3441D8B584DC10E5334196C42030B62D344138E17AF415E533419A218E55BC2D3441D03D79181BE533411C95D489C22D3441C46F5F2720E533418E7EFBBAC82D3441A0BDC13725E5334191E4F2DFCE2D3441001973572AE5334162E5D002D52D3441B847E17A2FE53341467B832FDB2D344148575B9134E53341787AA56CE12D3441E0718A8E39E53341624BC8C7E72D3441E4B7AF633EE53341C854C148EE2D3441182FDD0443E5334120166AEDF42D34412418957447E53341EA8C28ADFB2D3441448941C04BE53341FF907E7B022E34418C2A18F54FE533416A3BDF4F092E344134AD691E54E53341F02FBB27102E3441041B9E3E58E5334163325510172E34419C923A415CE533413D1361031E2E3441BC0E9C3360E533412EA2B4F7242E3441AC2E6E2364E533413F1361E32B2E3441BC490C2268E53341EC51B8BE322E3441D4B5843C6CE53341DBF0F48A392E3441C844D87070E53341BA8D0650402E344130A089B074E533419B2A1815472E3441E01FD2EF78E533419F89B0E14D2E3441E800DE227DE53341D3915CBE542E3441146C783A81E53341A6A44EC05B2E344130A2B41785E533413E355EDA622E3441F81FD2CF88E53341467B83EF692E3441008D288D8CE5334162E5D0E2702E3441B047E17A90E53341C98F3197772E344108780BC494E5334138B4C8D67D2E34410CB37BB299E5334189635DBC832E34410C93A9229FE533416E469496892E344138F8C2A4A4E53341F07C3FB58F2E34414C7958C8A9E533415EFE433A962E3441E488D25EAEE533416CC5FEF29C2E3441C48D06B0B2E53341F041CFC6A32E3441183FC6DCB6E5334148BF7D9DAA2E3441E89C1105BBE533413C80B760B12E344190703D4ABFE533411C7C6112B82E3441C878E9A6C3E53341F2D24DC2BE2E344178029A08C8E53341903A016DC52E344170E92671CCE5334131333313CC2E3441CC64AAE0D0E53341E6F21FB2D22E34414C477259D5E5334152A60A46D92E3441F09C11E5D9E5334170E7FBC9DF2E344128D49A86DEE53341460C024BE62E34417C832F2CE3E53341C00E9CD3EC2E34417814AEC7E7E533418E3A016DF32E34417C029A48ECE533418AFD6517FA2E344160E09CB1F0E5334170D71212FE2E3441D0DCB544F3E53341EC95B26C132F344114B6F35DC7E433412A287E8C7B2D3441A479C7C9A8E43341B4FC8754762D34418C635DBCEDE433410022FD96792D344168666686EFE4334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C86BE7C766A2E3441B36D4A6E23E53341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.533' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.533' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977849, 23695251, 1, NULL, 0xBD0B0000010405000000B5BFEC1E5D7A2B4104F2410F91643141819ECD2A717A2B4120EF38E59064314199D6346F707A2B41684469AF79643141E11B7C615C7A2B414C4772D979643141B5BFEC1E5D7A2B4104F2410F9164314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5B1B99C6667A2B41E119285F85643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.540' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.540' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4572602, NULL, 1, NULL, 0xBD0B00000104060000006ECE88D20A453141D00512142FE21C41198C4ACA0045314120E3361AA2E11C41547DAEF6C74431415087A7D7CEE11C41E58C28EDCF44314190C2F5A864E21C41A089B001DE443141303255B059E21C416ECE88D20A453141D00512142FE21C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5D899BAEE844314164B8B75902E21C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.553' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.553' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 2213877, NULL, 1, NULL, 0xBD0B000001040600000090180476E7E73241D0EA7335306D1B4199900F5AE8E73241C0726891DF6C1B41D9096802E9E73241104A7B03A46C1B41CA073D1B8EE732416058A8B5916C1B41D69AE69D94E73241A0F753631F6D1B4190180476E7E73241D0EA7335306D1B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C754B6AC9BCE7324179DFDE3DE06C1B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.567' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.567' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9680373, NULL, 1, NULL, 0xBD0B0000010405000000ED38458778A53241E0EA73350B891C41AB9BC4E090A53241401361C34E891C41C97F48DF91A53241B03B4E51F8881C41B696906F79A5324120948785B4881C41ED38458778A53241E0EA73350B891C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C7509CA2D85A53241C4FD54AD01891C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.577' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.577' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12728390, 90070070, 1, NULL, 0xBD0B00000104070000000D1DC925DF00274138E8D96C42BC32414DDA1B7CC50027414C50FC984FBC32413290A038DB002741AC8251495ABC32416E09F9A0F3002741C0490CC24DBC3241D3C7983BF100274134014D644CBC3241E897DD13E20027410CAE470144BC32410D1DC925DF00274138E8D96C42BC324101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C57229FCCDC002741E50E5D764EBC3241, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.587' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.587' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13998072, 23688801, 1, NULL, 0xBD0B00000104050000009E1A2F9D1E792B41A4DA8A5DD964314147E8D9AC32792B411C583934D9643141332AA9D331792B41E4361A40BF643141EB3845C71D792B41089E5E69BF6431419E1A2F9D1E792B41A4DA8A5DD964314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3960403928792B41FABF294FCC643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.603' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.603' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 9212434, NULL, 1, NULL, 0xBD0B000001040B000000E4263128D789324130EF38C570051C41F84A59267F873241D03D79D8D1081C41BF30996A878732414068226C0F091C419306F0D6FC873241204ED191D70B1C41770B24A827883241F037F8C27E0C1C41B4726851A5883241B0187357450A1C416F810445D38832419048BFFD75091C4162984C950E89324100197357B2081C411DB9FCA7D5893241D088D25EA2061C41D41B7C41EA893241D0FEB2FB43061C41E4263128D789324130EF38C570051C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD22CCA7E938832414C44B06FC1081C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.623' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.623' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13872401, NULL, 1, NULL, 0xBD0B0000010405000000C2D32BE580B73241400C022B65F41C41DAC56DF487B7324130D7A3F065F41C41BBA679E785B7324190D100DE29F41C410912141F7EB732419006F09644F41C41C2D32BE580B73241400C022B65F41C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C442D817C83B7324132FD7ACD4CF41C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.633' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.633' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4600711, 90075891, 1, NULL, 0xBD0B000001040B000000C732C471C1F13141F0D5C5EDF3D91841E37A14EEF5F1314140795828F5D918413008AC7CFCF13141107DD033F5D91841D512F22124F23141504CA60AF6D91841CD2B653924F23141D06F5F07A4D9184184C0CA4124F23141A0E461A18CD9184162C3D30BF7F131417089B0E19AD91841186A4D33C9F13141F0F0F44AA9D918411CB9FCE7AEF13141D0B4C876C4D918417A36ABDE9CF1314150795828F3D91841C732C471C1F13141F0D5C5EDF3D9184101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CEC4EA67EECF1314175943DE2CAD91841, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.647' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.647' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 5896835, NULL, 1, NULL, 0xBD0B0000010406000000AB3E57BBEB353241201895D457D7174102000020E7353241D07D1D3823D71741F3FDD478C3353241F07BF2B02DD71741F953E3A5B9353241C0B0E16973D7174173AC8BBBBD3532412087165993D71741AB3E57BBEB353241201895D457D7174101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE2BB9B64D1353241563D3FF053D71741, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.657' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.657' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3352552, NULL, 1, NULL, 0xBD0B0000010407000000B159F519E342314160DA1BFC38E61C41042B8756EF42314190AEB6E238E61C4188855AD3F54231410044FA6D1AE61C41826ABC740243314170B515FBDCE51C413FF1638C02433141D0E3141DD1E51C418E976E3200433141809B551FC6E51C41B159F519E342314160DA1BFC38E61C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C860BD361F44231413D24344908E61C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.663' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.663' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14342413, NULL, 1, NULL, 0xBD0B000001040A000000D2B359D5DFBB3541405839F4DAA623413CF8C2E4DDBB354168DE71CA01A72341C37D1D3847BC354120AC1C1A14A72341D4ACFA7C46BC3541F8B27BB213A723417AF2B0D0FFBB354120022B87ECA6234121EBE2F6EEBB354168B29D2FE3A62341A58251C9EABB354100D34DE2E0A623418C7EFB9AE6BB3541803EE899DEA623412C068155E3BB3541004FAFD4DCA62341D2B359D5DFBB3541405839F4DAA6234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5FB272A901BC3541085624E9FAA62341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.673' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.673' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7488009, NULL, 1, NULL, 0xBD0B0000010405000000E63FA45F047F304120EBE2B6B9041D4175711BCDE67E3041D04F8D17D2041D41F07C3F95E67E30413072F98FF7041D41324CA6CA037F3041D0E995B2E8041D41E63FA45F047F304120EBE2B6B9041D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C2DBCC2EDF57E30413613559FDA041D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.683' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.683' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 24047945, NULL, 1, NULL, 0xBD0B000001040A0000004382E247963B3341E0088A9FF0F51B4199999939963B3341104ED191FEF51B41754F1EF6923B334150DC460332F91B417DB740A20C3C3341F03A70CE43F91B415AA8354DD63C334130CDCC4C61F91B41F5A06713423D3341F0DF2D1071F91B41AC69DED1503D334170D5E76A38F31B414A5986B8513D3341E0051214D7F21B41F4E46121533D3341703789C13FF21B414382E247963B3341E0088A9FF0F51B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3BFA26F68A3C3341A1CE02CB97F61B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.697' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.697' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13995596, 29847801, 1, NULL, 0xBD0B00000104050000009A01BC0515772B41E47A148EDD64314126F46C1629772B41D8A59B64DD6431413689416028772B4120F77560C064314190976E5214772B4104DE0289C06431419A01BC0515772B41E47A148EDD64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CB530ABB31E772B41098163F7CE643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.717' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.717' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13998030, 23688641, 1, NULL, 0xBD0B0000010405000000FEF675E045792B4190C64B17BF64314174A301BC46792B4144158C0AD9643141B415FBCB5A792B410CAE47E1D8643141C69F1AEF59792B41F43A70EEBE643141FEF675E045792B4190C64B17BF64314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF7FADD5550792B41BA1889FCCB643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.727' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.727' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14413019, NULL, 1, NULL, 0xBD0B00000104050000000C12147F9E8A324110DBF97E43EB1B41C5293A729B8A324130302A298CEB1B4150B81E25B68A324110E7FB2990EB1B41EEB050EBB68A32415079582847EB1B410C12147F9E8A324110DBF97E43EB1B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C0232CEBCA98A324126ABF9486AEB1B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.737' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.737' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4940164, NULL, 1, NULL, 0xBD0B0000010407000000BDC11706AC253341F0D6A3F018921C41CE88D2BEB2253341605452A769921C416319E298E62533417085EBD1EB911C4123EBE206D825334180CE8892F8911C412EA2B467C925334130075F5804921C41F97E6ABCBA25334180AEB6220F921C41BDC11706AC253341F0D6A3F018921C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C238EC88EC125334111B478D525921C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.763' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.763' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 15937445, NULL, 1, NULL, 0xBD0B00000104050000000CAC1CDA128332419889B061994A2E41460C02AB1C83324120DF4F0DA34A2E41D58173E61C83324120DE0209994A2E4160984C1513833241803F355E8F4A2E410CAC1CDA128332419889B061994A2E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA2B94DE017833241F8A89E35994A2E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.773' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.773' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10465103, 5675941, 1, NULL, 0xBD0B000001040500000009B5A659D4823241507B83EFD2492E41FC3A708ED5823241A859F539E7492E41B6AF03C7F8823241687FD97DEA492E412B871679F9823241B0E1E995D6492E4109B5A659D4823241507B83EFD2492E4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C3F44F501E7823241BBE20CB8DE492E41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.787' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.787' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3771482, NULL, 1, NULL, 0xBD0B0000010407000000F4FDD45808A53141602AA913F0661B41FCCBEE491CA53141309B559FA4661B41B08BDB4826A5314110651962A5661B41EB6A2B7626A53141E020B07289661B41A860549227A5314140E561A1D5651B414F40138108A531414019E2D8D8651B41F4FDD45808A53141602AA913F0661B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C4541AECD16A53141A42EC0164B661B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.797' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.797' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8048801, NULL, 1, NULL, 0xBD0B0000010405000000C15B20C1F212304140BD5256EAFC2041711B0DC0F2123041B0051254E1FC2041F575E03CCE1230418875715BE0FC2041AB9BC440CE123041783F355EEAFC2041C15B20C1F212304140BD5256EAFC204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAE06A82DE01230414923E697E5FC2041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.807' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.807' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13873717, NULL, 1, NULL, 0xBD0B00000104040000006909F920A6F13241B0627F5978821C411951DA9B3DF23241D04672F9AD811C41C98F31F7A8F1324100FDF6758E811C416909F920A6F13241B0627F5978821C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CC4F85691D9F132412BE2A2EDE6811C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.817' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.817' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13829734, NULL, 1, NULL, 0xBD0B000001040400000079931804AAB83241E0C3422D51F01C41E761A1F6A3B83241901D38E765F01C41D6CEF7D3A9B83241400AD7A366F01C4179931804AAB83241E0C3422D51F01C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CBD9690EFA7B83241E5A3703D5FF01C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.830' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.830' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 181544, NULL, 1, NULL, 0xBD0B000001040E0000008C6CE7FBFB0A3241E021FD76316118418D0F7A36FD0A3241408863DD5660184163CC5DCBFD0A3241D0CDAA4FF05F18412385EB71040B3241B0B662FFE95F1841B4408272050B3241203A924BAD5F18416E787A05070B324120F085C9705F1841168C4A2A090B324130F2418F345F1841585227E00B0B3241308EE4B2F85E1841C1C117260F0B3241F039234ABD5E1841B047E1FA120B3241C067B36A825E18412CFF215D170B324150E7FB29485E184159EC2F5B370A324160B20C71335E18411E41F1A3320A3241E0DA8A7D106118418C6CE7FBFB0A3241E021FD763161184101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C823F76989D0A324175FCA25DA85F1841, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.843' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.843' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10694242, NULL, 1, NULL, 0xBD0B0000010405000000032B87F6F1503641386EA3C12E332041E9F21FF2D75036412090A038283320411D4A7BC3D4503641B89690CF483320411704566EEB503641C0B359F55D332041032B87F6F1503641386EA3C12E33204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CBA4EF255E35036419057C3AE3F332041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.853' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.853' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 3592791, NULL, 1, NULL, 0xBD0B0000010405000000D3C56D1485BC334130EA9532E57E1C411495D40984BC3341E03B4E513A7F1C417E26C286B8BC3341305B423E4B7F1C41BE749398B9BC3341B0938785F57E1C41D3C56D1485BC334130EA9532E57E1C4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C96A261D79EBC3341B71EBA13187F1C41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.863' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.863' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 14611945, 8013461, 1, NULL, 0xBD0B000001043600000092976E32062B3441A423B91C01E333419AE61DA70A2B3441F4770BC407E3334100098ADF0E2B344168C5FE920EE33341A713D0E4122B3441E8AE258415E333415A9FAB8D162B3441B02E6EA31CE33341EC51B8BE192B3441E82A87F623E333412B6519A21C2B3441C8B12E6E2BE333417524975F1F2B34416C2BF6F732E3334112363C1D222B3441A88026823AE33341D8096802252B3441C410C7FA41E3334170CE8812282B3441F041CF6649E333419D01BC252B2B34418C5149DD50E33341C220B0722E2B34413061C33358E333418B7CD033322B3441B810C73A5FE33341411361C3362B3441D044D8B065E33341383CBD523C2B3441DC0E9C736BE33341224A7B23422B3441ACD6340F71E33341130BB566472B3441C8AACF1577E3334120DBF9DE4B2B3441CC47E1BA7DE33341607FD9FD4F2B344140B9FCA784E33341FCC2642A542B344114B072888BE333417A0B24C8582B344154AF940592E33341BE86A7175E2B3441180DE0ED97E3334126287ECC632B3441BCC8767E9DE33341D200DEC2692B3441347424D7A2E33341C4F528DC6F2B3441503BDF0FA8E3334171A301FC752B344128530543ADE33341492575027C2B34414C1E168AB2E33341838CB90B822B3441A88251C9B7E33341B02E6E23882B34414C5986F8BCE3334132BB272F8E2B344144E17A34C2E33341083D9B15942B3441D8460398C7E3334158C1A8C4992B34416C348037CDE33341EB95B24C9F2B344150522700D3E3334176A52CC3A42B3441B86B09D9D8E333412F772D21AA2B34419CDD93C7DEE33341984C156CAF2B34414C158CCAE4E3334147BF7DBDB42B34410C5D6DC5EAE3334104BC0532BA2B3441E46C569DF0E33341708104E5BF2B34414C742437F6E33341F6EDEBE0C52B34418CB0E189FBE3334140CF6615CC2B3441A418049600E43341F1A7C68BD22B3441BCCAA14505E4334136B4C836D92B3441ECE995B209E43341C832C4D1DF2B3441240F0B350EE43341F6C2642AE62B3441980D4F0F13E4334132772D61EC2B34410834111618E433417C36ABFEED2B3441EC0DBE7019E433415327A049032C34410C5F984C00E333413FAD69DEFE2B34416C226CF8FFE2334171C5FED2F72A34418C416045ECE233417A7AA5ECFC2A34417C2F4C06F4E23341BF9F1A8F012B344190B20C91FAE2334192976E32062B3441A423B91C01E3334101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CCB9C670D9B2B344197229C065FE33341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.877' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.877' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 7488882, NULL, 1, NULL, 0xBD0B00000104070000004260E550A47D3041C08BDBE899041D41CB6D3440A47D3041A0749398C4041D416A006F81B27D304190B20CF1C2041D418A635DDCAE7D3041F0907E3BB9041D416F348047AB7D3041B0E61D27AF041D41234A7BC3A77D30415058A8B5A4041D414260E550A47D3041C08BDBE899041D4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CF91B39F2A87D304149F1930DB6041D41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.887' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.887' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4786050, NULL, 1, NULL, 0xBD0B000001040400000021DBF93EB82C324130363CBDF8BD184164BA498CC42C324100E8D9ACFABD1841F0EBC079B92C3241F0F2B0D07BBD184121DBF93EB82C324130363CBDF8BD184101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C272BACC1BC2C32410B5B42BECFBD1841, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.897' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.897' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 8969604, 31216901, 1, NULL, 0xBD0B000001040E000000E4B5845C6C8533410081044597D81B41DB68006F6385334170499D006CD91B41F09E3C6C8E853341A06E12831CDA1B41497B83AF96853341A0FB3A703EDA1B413208ACAC96853341B0900FBA33DA1B41423EE89996853341C013D00429DA1B4136AB3E7796853341E0F21F521EDA1B413E8B6C9795853341A02A18D5FBD91B41A660541294853341208F53B4D9D91B412E5530EA91853341E0AD4721B8D91B41256519228F85334140287E4C97D91B4195081BBE8B853341D0787A6577D91B41058A1FC38785334190BE9F9A58D91B41E4B5845C6C8533410081044597D81B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CAF3CC6A07B853341463BBD9970D91B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.907' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.907' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 12457698, NULL, 1, NULL, 0xBD0B000001040A000000A045B6D3F52B364188779CE284D120414C27A019032C3641D83B4E5199D12041EEB050AB102C3641100F0BF5ACD1204130E6AE851E2C3641F0D478C9BFD12041E773B5A52C2C364188A757CAD1D12041E62631083B2C3641C80E9CF3E2D120418F4AEAC4612C364140355E3AA2D120413F1361432E2C364148992A9826D12041D5CEF793292C364160DA1B7C2ED12041A045B6D3F52B364188779CE284D1204101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CD8B411FE2D2C36411FD7D18589D12041, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.917' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.917' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 13977989, 23695831, 1, NULL, 0xBD0B00000104050000001CDBF93EF4782B41484013019464314182A7574A08792B418C06F0D693643141B2F1D28D07792B419CFF909E7C64314160EE5A82F3782B41C866D5C77C6431411CDBF93EF4782B41484013019464314101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CA7BF4FE6FD782B4197B3984F88643141, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.927' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.927' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 4956478, NULL, 1, NULL, 0xBD0B000001041E000000188C4ACACDA53141C03EE8D96A661B41E8263108C3A53141A094658831661B416CF90FE9B3A5314180BC7493DD651B417B4F1EF6B0A5314100B45935CF651B41EFF44A89ADA53141C02EDDA4C2651B41D6CEF7B3A9A53141009C3322B8651B41EDEBC089A5A5314170AEB6E2AF651B41A7ADD81FA1A5314190F2B010AA651B415AB1BF8C9CA531416027A0C9A6651B4119D9CEE797A5314150764F1EA6651B41E61DA74893A53141F0BB0512A8651B415D5DDCC68EA53141209A089BAC651B4135234ABB89A531417014AE07B3651B41FD2A87E684A53141800E2DB2BB651B4167226C5880A53141407FD97DC6651B4191E4F21F7CA53141E0A67947D3651B41D5F0F44A78A53141E0F7C2E4E1651B414DA60AE674A531412054E325F2651B4187635DFC71A53141C0CE66D503661B416F3480976FA53141E0D93DB916661B41CA7F48BF6DA5314190855A932A661B415E07CE796CA53141C00968223F661B41020000A064A5314160B3EA73C4661B41F7C2646A68A53141B066D5E7D6661B41B51E856B6BA53141403333B3D6661B41D9E76A6BDCA53141A02CB29DCB661B415F3255D0DEA53141600B24A8BC661B41F05A42FED8A53141F0EDEBC0A1661B419BB20C51D3A5314190D9AC7A86661B41188C4ACACDA53141C03EE8D96A661B4101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C5A9A88019BA531413DFF623557661B41, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.940' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.940' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 1, N'HA', N'MOTIADMIN', N'Yes', N'PAIMS', CAST(N'2021-08-31' AS Date), NULL, NULL, 10265554, NULL, 1, NULL, 0xBD0B000001040F000000E83FA49F33C6354100C1392308A92341225A649B3FC635418058A8F552A9234132431C2B46C63541C8BFEC5E79A92341A657CA1251C63541E8BE0E9C72A92341CEAACFC55BC63541B898BB3668A923416766662666C63541508FC2955CA923419475712B70C63541401361C34FA923417A832FCC79C63541809ECDCA41A92341C76D340083C6354120D044B832A92341D55F76BF8BC63541C834EF9822A923413645470294C635412063EE7A11A923416A006FC19BC6354160A8356DFFA8234132DD24F6A2C635415824977FECA8234109AC1C9AA9C635411893A9C2D8A82341E83FA49F33C6354100C1392308A9234101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010C93EC833166C63541E4619B2F22A92341, NULL, NULL, NULL, 0, 0, 0, 0, NULL, NULL, 3, CAST(N'2021-08-31T16:55:57.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2021-08-31T23:55:59.000' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', CAST(N'2022-03-04T21:09:18.950' AS DateTime), N'dbo', CAST(N'2022-03-04T21:09:18.950' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 4, N'HA', N'FEESIMP', N'YES', N'PAIMS', CAST(N'2021-10-08' AS Date), NULL, NULL, 25196375, NULL, 1865, N'Strictly speaking, an extrapolation of the stra', 0xBD0B0000010411000000F953E385643633415CF7E481359234416FC5FED25F363341188C4A8A3292344162BA498C57363341280681153F92344157F5B91A5C363341080681F541923441F063CC3D7136334150B1BF4C4F923441BDD32B8576363341F8EDEBA05292344121B9FC8791363341409FAB0D5692344161C3D32BCB363341D4B5845C5D9234411E6C789AD03633418CA982515792344187D2DEE043373341DC6A2B16D7913441D1F753433E3733414C9D8026D2913441FE99089B383733418016D92ECD913441653BDF6FC5363341EC41CF664D923441BEA8A48E9D36334128287E6C489234415817B7B17B363341A489B0214492344199438BAC79363341305A64DB42923441F953E385643633415CF7E4813592344101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE41444E3D5363341675A550F2A923441, NULL, NULL, NULL, 0, 0, 0, 0, NULL, N'Firming up the g', 13, CAST(N'2021-10-08T20:26:14.683' AS DateTime), N'ETL', NULL, N'place_holder', CAST(N'2021-10-08T20:26:14.683' AS DateTime), N'ETL', NULL, N'place_holder', CAST(N'2022-03-04T21:10:01.010' AS DateTime), N'dbo', CAST(N'2022-03-04T21:10:01.010' AS DateTime), N'dbo') +GO +INSERT [dbo].[PIMS_PROPERTY] ([PROPERTY_MANAGER_ID], [PROP_MGMT_ORG_ID], [PROPERTY_TYPE_CODE], [PROPERTY_CLASSIFICATION_TYPE_CODE], [ADDRESS_ID], [REGION_CODE], [DISTRICT_CODE], [PROPERTY_AREA_UNIT_TYPE_CODE], [PROPERTY_STATUS_TYPE_CODE], [SURPLUS_DECLARATION_TYPE_CODE], [PROPERTY_DATA_SOURCE_TYPE_CODE], [PROPERTY_DATA_SOURCE_EFFECTIVE_DATE], [NAME], [DESCRIPTION], [PID], [PIN], [LAND_AREA], [LAND_LEGAL_DESCRIPTION], [BOUNDARY], [LOCATION], [ENCUMBRANCE_REASON], [SURPLUS_DECLARATION_COMMENT], [SURPLUS_DECLARATION_DATE], [IS_OWNED], [IS_PROPERTY_OF_INTEREST], [IS_VISIBLE_TO_OTHER_AGENCIES], [IS_SENSITIVE], [ZONING], [ZONING_POTENTIAL], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY], [DB_CREATE_TIMESTAMP], [DB_CREATE_USERID], [DB_LAST_UPDATE_TIMESTAMP], [DB_LAST_UPDATE_USERID]) VALUES ( NULL, NULL, N'LAND', N'COREOPER', 1, 1, 4, N'HA', N'FEESIMP', N'YES', N'PAIMS', CAST(N'2021-10-27' AS Date), NULL, NULL, 25196375, NULL, 1865, N'Strictly speaking, an extrapolation of the stra', 0xBD0B0000010411000000F953E385643633415CF7E481359234416FC5FED25F363341188C4A8A3292344162BA498C57363341280681153F92344157F5B91A5C363341080681F541923441F063CC3D7136334150B1BF4C4F923441BDD32B8576363341F8EDEBA05292344121B9FC8791363341409FAB0D5692344161C3D32BCB363341D4B5845C5D9234411E6C789AD03633418CA982515792344187D2DEE043373341DC6A2B16D7913441D1F753433E3733414C9D8026D2913441FE99089B383733418016D92ECD913441653BDF6FC5363341EC41CF664D923441BEA8A48E9D36334128287E6C489234415817B7B17B363341A489B0214492344199438BAC79363341305A64DB42923441F953E385643633415CF7E4813592344101000000020000000001000000FFFFFFFF0000000003, 0xBD0B0000010CE41444E3D5363341675A550F2A923441, NULL, NULL, NULL, 0, 0, 0, 0, NULL, N'Firming up the g', 5, CAST(N'2021-10-27T17:40:25.273' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'place_holder', CAST(N'2021-10-27T17:40:25.273' AS DateTime), N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'place_holder', CAST(N'2022-03-04T21:10:18.683' AS DateTime), N'dbo', CAST(N'2022-03-04T21:10:18.683' AS DateTime), N'dbo') +GO \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/06_DML_LEASE_PROPERTY_TENURE_TYPE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/06_DML_LEASE_PROPERTY_TENURE_TYPE.sql new file mode 100644 index 0000000000..06824ccb97 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/06_DML_LEASE_PROPERTY_TENURE_TYPE.sql @@ -0,0 +1,1296 @@ +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7723385), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11041404), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083736), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4082664), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15937437), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10459189), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13821202), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 18414885), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8750858), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13995570), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083663), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14413001), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2833913), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14116111), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11893613), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5764068), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8270333), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7487983), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2833948), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8988374), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8829381), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 25542371), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12572039), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10204610), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11756896), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 23915803), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13997998), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083698), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5868530), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10459294), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11097710), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15494772), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12648337), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5484022), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2518911), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13601709), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15937551), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15937534), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4735153), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4300017), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13908332), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13869591), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9659790), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7482876), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226291), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 16264436), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12912727), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13997971), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5608481), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13843389), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12917320), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083612), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226231), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12648302), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11929090), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11471409), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10012044), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14215225), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15885844), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14508567), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12190616), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13978063), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13769634), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9680411), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15302113), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7487991), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226151), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977920), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6205861), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 1342177), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13602039), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5649293), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226134), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083523), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083701), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14297744), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14346036), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7482965), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090083), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13998056), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083582), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 17839149), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9325611), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7894678), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090199), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8442827), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13995561), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8779074), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13602047), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9126279), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 886874), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6914781), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10318658), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12787540), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3780899), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977580), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977865), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11212527), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11472031), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083566), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13873695), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5056144), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14042231), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8803277), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3862747), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14413027), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13772341), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2344700), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6934510), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3842894), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13252984), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10319310), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12909599), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13995588), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9742522), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14116103), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13601717), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12457701), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12916421), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9987088), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10475915), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3314448), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10806121), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10465677), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977890), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14411784), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10459171), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5246881), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226177), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977776), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977954), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3175944), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14297701), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2135469), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14194589), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10418563), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14880598), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5726981), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10459227), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3940934), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090121), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977636), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8452792), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12572021), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 1179217), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8803293), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10912185), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9911413), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8451940), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14291002), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13843095), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13998005), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9680276), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10459316), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 16622537), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11016906), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9805699), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15102882), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090130), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977903), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8450919), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 23730307), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14341239), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13829726), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9680331), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977709), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 26934426), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2911230), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8992703), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15937500), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11726768), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226258), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977938), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4786068), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13843354), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13998099), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14341221), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4682807), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14612429), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13843371), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11236892), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13601679), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3842878), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7488921), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6227481), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13908341), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10783237), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14297710), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14339544), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11844990), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8534683), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13862944), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13602021), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10459251), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3094294), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14612119), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7487967), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977792), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977598), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 19171269), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 18285121), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13602012), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9956727), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10464824), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7487959), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3780929), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13995553), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977997), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977962), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14412985), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13876236), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13852558), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14767953), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 17454981), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13369792), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12909611), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12072877), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8926042), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13676687), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10496653), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977563), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10418547), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9126210), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15127125), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13852752), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4682742), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15357473), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8395080), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10449213), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7489293), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13997980), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12043087), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13786121), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11062274), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2172232), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10919473), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2848406), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2848392), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15392317), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090105), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090164), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10128239), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977652), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9939679), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10596518), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13843125), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977628), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977857), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3576825), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14612445), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 1827391), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13601695), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13508466), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226193), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12648388), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977822), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6091407), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14073676), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 24777188), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8192294), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083647), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13978055), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13998111), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13978012), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9096426), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15937461), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13253000), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226223), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 18289886), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2590956), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 832570), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 23844361), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8487464), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4978994), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10308610), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15848591), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12640204), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14083531), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12572063), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977971), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10418555), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14342197), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:58.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10456481), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226274), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4969847), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13978039), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9679651), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14567920), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10418512), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4682726), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13843117), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12917354), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13978004), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13601652), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10465120), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2746778), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226215), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11981075), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6205976), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13676709), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 29171628), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5437440), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13998145), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13908316), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977601), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977873), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3057011), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5984149), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6646964), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10448985), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 24235563), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090172), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977644), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13978047), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13769651), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10545182), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977717), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13978071), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13601687), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8803269), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8803251), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7482922), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090113), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977911), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 1887726), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9680306), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13667335), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8928436), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7013167), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7482931), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4358988), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13226304), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977814), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3592723), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090091), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977946), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10002332), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9615601), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10408517), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6938167), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14073854), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 1623699), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11097655), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12917389), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11157674), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14073871), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14666405), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13601113), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 11325976), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8913595), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10459235), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5090156), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8446032), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13602055), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5727022), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12909581), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14009722), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14612381), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 1622579), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13978021), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2734079), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2113716), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977881), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10319581), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10449183), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10459286), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9679391), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977695), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977784), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13769626), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12572047), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9148043), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12877425), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 17533538), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9038884), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8387052), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13998013), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6311237), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3000991), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 18550061), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8394962), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7319142), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977610), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10497986), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 16861825), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13862782), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 6257232), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13785648), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10318810), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3587398), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13843109), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14371430), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15494501), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8969612), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10358820), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5649307), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14612364), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977849), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4572602), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 2213877), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9680373), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12728390), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13998072), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 9212434), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13872401), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4600711), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 5896835), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3352552), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14342413), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7488009), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 24047945), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13995596), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13998030), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14413019), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4940164), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 15937445), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10465103), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3771482), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8048801), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13873717), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13829734), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 181544), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10694242), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 3592791), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 14611945), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 7488882), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4786050), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 8969604), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 12457698), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 13977989), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 4956478), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO +INSERT INTO [dbo].[PIMS_PROP_PROP_TENURE_TYPE]([PROPERTY_ID], [PROPERTY_TENURE_TYPE_CODE], [APP_CREATE_TIMESTAMP], [APP_CREATE_USERID], [APP_CREATE_USER_GUID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_TIMESTAMP], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_GUID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES( (SELECT TOP 1 PROPERTY_ID FROM PIMS_PROPERTY WHERE PID = 10265554), N'TM', '20210831 16:55:57.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A', '20210831 23:55:59.0', N'APP_PIMS_PROXY_ETL_EDIT', NULL, N'N/A') +GO diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/07_DML_PROPERTY_LEASE.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/07_DML_PROPERTY_LEASE.sql new file mode 100644 index 0000000000..9e2ca06a57 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/07_DML_PROPERTY_LEASE.sql @@ -0,0 +1,333 @@ +INSERT INTO [dbo].[PIMS_PROPERTY_LEASE] (PROPERTY_ID, LEASE_ID, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + (153, 17, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (433, 26, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (401, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (110, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (164, 43, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (224, 19, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (346, 11, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (260, 21, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (198, 39, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (409, 8, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (19, 10, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (23, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (231, 27, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (193, 11, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (435, 13, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (318, 53, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (208, 55, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (2, 29, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (295, 39, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (307, 4, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (119, 12, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (201, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (229, 51, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (425, 41, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (220, 30, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (289, 38, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (362, 29, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (91, 30, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (227, 22, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (309, 32, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (124, 12, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (350, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (71, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (405, 33, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (408, 21, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (374, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (221, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (420, 16, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (88, 14, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (408, 14, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (168, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (253, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (43, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (148, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (232, 54, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (297, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (172, 26, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (376, 13, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (389, 50, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (28, 22, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (332, 45, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (83, 31, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (352, 38, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (111, 44, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (325, 33, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (179, 4, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (46, 17, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (144, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (123, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (14, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (60, 33, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (164, 25, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (51, 32, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (227, 16, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (129, 51, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (181, 36, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (353, 2, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (20, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (209, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (392, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (177, 2, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (415, 13, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (132, 13, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (183, 22, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (65, 40, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (80, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (321, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (93, 51, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (373, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (275, 6, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (82, 4, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (133, 22, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (212, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (170, 55, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (50, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (265, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (187, 32, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (181, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (275, 4, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (173, 15, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (38, 53, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (44, 33, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (62, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (373, 32, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (400, 19, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (173, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (323, 25, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (228, 10, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (170, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (98, 22, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (104, 15, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (48, 51, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (249, 6, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (56, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (148, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (282, 17, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (342, 22, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (395, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (220, 50, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (83, 44, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (138, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (165, 20, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (148, 20, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (127, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (254, 55, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (355, 29, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (339, 12, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (63, 21, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (215, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (212, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (68, 48, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (347, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (106, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (68, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (83, 52, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (376, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (368, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (120, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (221, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (59, 47, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (315, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (166, 52, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (138, 27, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (353, 12, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (120, 26, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (362, 43, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (218, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (318, 54, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (264, 39, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (319, 14, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (423, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (72, 16, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (69, 14, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (23, 15, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (285, 11, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (228, 17, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (258, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (105, 52, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (14, 16, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (426, 49, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (291, 8, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (341, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (307, 30, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (36, 21, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (76, 19, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (348, 15, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (290, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (284, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (4, 6, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (300, 3, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (382, 45, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (222, 40, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (54, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (278, 12, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (281, 16, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (164, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (18, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (384, 8, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (140, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (3, 20, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (84, 10, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (403, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (127, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (281, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (280, 43, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (410, 25, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (96, 29, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (400, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (159, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (424, 14, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (420, 52, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (353, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (160, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (96, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (358, 31, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (218, 28, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (246, 17, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (37, 36, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (20, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (207, 47, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (46, 32, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (148, 11, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (435, 53, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (76, 52, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (369, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (381, 2, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (335, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (43, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (289, 51, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (186, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (188, 15, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (82, 8, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (355, 21, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (312, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (182, 10, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (406, 19, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (45, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (401, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (228, 29, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (95, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (224, 8, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (319, 28, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (359, 6, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (322, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (269, 41, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (42, 15, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (335, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (115, 2, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (256, 16, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (308, 50, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (396, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (12, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (438, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (132, 12, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (41, 33, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (46, 1, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (386, 41, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (421, 8, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (389, 3, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (398, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (411, 27, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (178, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (90, 13, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (185, 52, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (25, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (170, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (319, 17, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (281, 49, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (103, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (411, 44, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (136, 19, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (91, 46, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (404, 45, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (4, 3, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (4, 47, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (224, 38, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (10, 54, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (165, 21, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (406, 28, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (333, 6, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (412, 1, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (230, 40, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (361, 20, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (196, 6, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (89, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (223, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (408, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (81, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (127, 6, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (90, 30, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (51, 52, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (57, 44, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (393, 28, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (366, 51, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (151, 10, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (277, 40, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (247, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (213, 20, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (115, 24, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (206, 39, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (369, 17, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (384, 41, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (249, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (77, 53, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (173, 6, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (184, 2, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (23, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (94, 27, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (291, 21, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (8, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (134, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (192, 12, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (259, 49, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (267, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (282, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (71, 47, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (294, 52, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (211, 23, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (42, 26, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (368, 40, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (47, 31, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (6, 26, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (383, 8, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (214, 40, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (6, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (104, 18, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (91, 54, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (304, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (141, 28, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (47, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (331, 4, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (57, 31, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (190, 8, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (230, 48, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (317, 7, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (312, 38, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (36, 48, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (110, 12, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (326, 34, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (312, 9, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (78, 48, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (276, 4, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (376, 37, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (223, 16, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (398, 55, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (258, 25, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (187, 1, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (4, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (324, 42, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (409, 20, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (169, 35, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (154, 5, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (121, 54, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (320, 18, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (60, 30, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (407, 14, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (65, 32, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (149, 2, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (209, 54, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (139, 21, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'), + (222, 31, CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data', CURRENT_TIMESTAMP, N'Seed Data', N'Seed Data'); diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/08_CONTACTS_ORGANIZATION_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/08_CONTACTS_ORGANIZATION_TEST_DATA.sql new file mode 100644 index 0000000000..cc00a6952c --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/08_CONTACTS_ORGANIZATION_TEST_DATA.sql @@ -0,0 +1,27 @@ +-- Add more fields to seed data for read view of contact organization +UPDATE [PIMS_ORGANIZATION] + SET [ORGANIZATION_ALIAS] = 'MOTI', [COMMENT] = 'This is a test comment', [INCORPORATION_NUMBER] = 1234, [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 + WHERE [ORGANIZATION_ID] = 1 + +INSERT INTO [PIMS_ORGANIZATION_ADDRESS] ([ORGANIZATION_ID], [ADDRESS_ID], [ADDRESS_USAGE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES (1, 1, 'BILLING', 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data'), (1, 2, 'MAILING', 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data') + +INSERT INTO [PIMS_PERSON_ORGANIZATION] ([PERSON_ID], [ORGANIZATION_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES (2, 1, 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data'), (1, 1, 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data') + +INSERT INTO [PIMS_CONTACT_METHOD] ([CONTACT_METHOD_TYPE_CODE], [ORGANIZATION_ID], [CONTACT_METHOD_VALUE], [IS_PREFERRED_METHOD], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES ('WORKEMAIL', 1, 'tester@test.com', 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data'), ('WORKPHONE', 1, '2501234567', 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data') + +-- Add data for individual contact view +INSERT INTO [PIMS_CONTACT_METHOD] ([CONTACT_METHOD_TYPE_CODE], [PERSON_ID], [CONTACT_METHOD_VALUE], [IS_PREFERRED_METHOD], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES ('WORKEMAIL', 1, 'tester@test.com', 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data'), ('WORKPHONE', 1, '2501234567', 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data') + +INSERT INTO [PIMS_PERSON_ADDRESS] ([PERSON_ID], [ADDRESS_ID], [ADDRESS_USAGE_TYPE_CODE], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES (1, 1, 'BILLING', 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data'), (1, 2, 'MAILING', 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data') + +UPDATE [PIMS_PERSON] + SET [PREFERRED_NAME] = 'Tester McTest', [COMMENT] = 'This is a test comment.', [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 + WHERE [PERSON_ID] = 1 + +INSERT INTO [PIMS_PERSON_ORGANIZATION] ([PERSON_ID], [ORGANIZATION_ID], [IS_DISABLED], [CONCURRENCY_CONTROL_NUMBER], [APP_CREATE_USERID], [APP_CREATE_USER_DIRECTORY], [APP_LAST_UPDATE_USERID], [APP_LAST_UPDATE_USER_DIRECTORY]) + VALUES (1, 2, 0, 1, 'Test Data', 'Test Data', 'Test Data', 'Test Data') diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/09_CONTACTS_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/09_CONTACTS_TEST_DATA.sql new file mode 100644 index 0000000000..17c6e49487 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/09_CONTACTS_TEST_DATA.sql @@ -0,0 +1,8 @@ +-- Change to inactive organization +UPDATE + [dbo].[PIMS_ORGANIZATION] +SET + [IS_DISABLED] = 1, + [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + [ORGANIZATION_ID] = 5 diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/10_INSURANCE_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/10_INSURANCE_TEST_DATA.sql new file mode 100644 index 0000000000..a9a1f8a095 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/10_INSURANCE_TEST_DATA.sql @@ -0,0 +1,35 @@ +-- Insert test data for insurance related to lease id = 2 +INSERT INTO [dbo].[PIMS_INSURANCE] + ( + [LEASE_ID] + ,[INSURANCE_TYPE_CODE] + ,[COVERAGE_DESCRIPTION] + ,[COVERAGE_LIMIT] + ,[EXPIRY_DATE] + ,[CONCURRENCY_CONTROL_NUMBER] + ) +VALUES + ( + 2 + , 'GENERAL' + , 'This is a description provided for insurance in order to test. Insurance type code is general.' + , 100000 + , '2022-12-23' + , 1 +), + ( + 2 + , 'MARINE' + , 'This is a description provided for insurance in order to test. This is of type marine.' + , 100000 + , '2022-12-23' + , 1 +), + ( + 2 + , 'VEHICLE' + , 'This is a description provided for insurance in order to test. This is of type vehicle.' + , 100000 + , '2022-12-23' + , 1 +) diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/11_LEASE_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/11_LEASE_TEST_DATA.sql new file mode 100644 index 0000000000..cf2cad795f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/11_LEASE_TEST_DATA.sql @@ -0,0 +1,155 @@ +-- Add pids for lease and license header +UPDATE + [dbo].[PIMS_PROPERTY_LEASE] +SET + [LEASE_ID] = 2, + [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + [LEASE_ID] = 45 + +-- Add improvements for lease +INSERT INTO + dbo.[PIMS_PROPERTY_IMPROVEMENT] + ( + [LEASE_ID], + [PROPERTY_IMPROVEMENT_TYPE_CODE], + [IMPROVEMENT_DESCRIPTION], + [STRUCTURE_SIZE], + [CONCURRENCY_CONTROL_NUMBER] + ) +VALUES + ( + 2, + 'COMMBLDG', + 'This is a test description for the purpose of testing things and ensuring they are testable. ', + '1234 sq ft.', + 1 + ), + ( + 2, + 'OTHER', + 'This is a test description for the purpose of testing things and ensuring they are testable. ', + '111 sq ft.', + 1 + ), + ( + 2, + 'RTA', + 'This is a test description for the purpose of testing things and ensuring they are testable. ', + '222 sq ft.', + 1 + ) +-- Associate property with lease +UPDATE + [dbo].[PIMS_PROPERTY_LEASE] +SET + [LEASE_ID] = 2, + [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + [LEASE_ID] = 17 + +-- Populate random l file number for leases +UPDATE + [dbo].[PIMS_LEASE] +SET + [L_FILE_NO] = CAST( + LEFT( + CAST( + ABS(CAST(CAST(NEWID() as BINARY(10)) as int)) as varchar(max) + ) + '00000000', + 9 + ) as int + ), + [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + [L_FILE_NO] IS NULL + +-- Populate tenant name for leases +UPDATE + [dbo].[PIMS_LEASE_TENANT] +SET + [PERSON_ID] = 4, + [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + [PERSON_ID] IS NULL + +-- Populate different tenant name on even id's for varience +UPDATE + [dbo].[PIMS_LEASE_TENANT] +SET + [PERSON_ID] = 1, + [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + [LEASE_TENANT_ID] % 2 = 0 +UPDATE + [dbo].[PIMS_LEASE_TENANT] +SET + [PERSON_ID] = 2, + [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + [PERSON_ID] IS NULL + +-- Make sure every lease has property associated to it (331 seed property leases, and 110 leases) +INSERT INTO + [dbo].[PIMS_PROPERTY_LEASE] + ( + [PROPERTY_ID], + [LEASE_ID], + [CONCURRENCY_CONTROL_NUMBER] + ) +VALUES + (1, 1, 1), + (2, 2, 1), + (3, 3, 1), + (4, 4, 1), + (5, 5, 1), + (6, 6, 1), + (7, 7, 1), + (8, 8, 1), + (9, 9, 1), + (10, 10, 1), + (11, 11, 1), + (12, 12, 1), + (13, 13, 1), + (14, 14, 1), + (15, 15, 1), + (16, 16, 1), + (17, 17, 1), + (18, 18, 1), + (19, 19, 1), + (20, 20, 1), + (21, 21, 1), + (22, 22, 1), + (23, 23, 1), + (24, 24, 1), + (25, 25, 1), + (26, 26, 1), + (27, 27, 1), + (28, 28, 1), + (29, 29, 1), + (30, 30, 1), + (31, 31, 1), + (32, 32, 1), + (33, 33, 1), + (34, 34, 1), + (35, 35, 1), + (36, 36, 1), + (37, 37, 1), + (38, 38, 1), + (39, 39, 1), + (40, 40, 1), + (41, 41, 1), + (42, 42, 1), + (43, 43, 1), + (44, 44, 1), + (45, 45, 1), + (46, 46, 1), + (47, 47, 1), + (48, 48, 1), + (49, 49, 1), + (50, 50, 1), + (51, 51, 1), + (52, 52, 1), + (53, 53, 1), + (54, 54, 1), + (55, 55, 1) diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/12_SECURITY_DEPOSIT_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/12_SECURITY_DEPOSIT_TEST_DATA.sql new file mode 100644 index 0000000000..29805eaf5f --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/12_SECURITY_DEPOSIT_TEST_DATA.sql @@ -0,0 +1,28 @@ +-- Insert security deposit data of the three different SEC_DEP_HOLDER_TYPE_CODE +INSERT INTO [dbo].[PIMS_SECURITY_DEPOSIT] + ([LEASE_ID], [SECURITY_DEPOSIT_TYPE_CODE], [DESCRIPTION], [AMOUNT_PAID], [DEPOSIT_DATE], [CONCURRENCY_CONTROL_NUMBER]) +VALUES + ( + 2 + , 'PET' + , 'This is a test description' + , 1111 + , GETDATE() + , 1 + ), + ( + 3 + , 'SECURITY' + , 'This is a test description.' + , 10000 + , GETDATE() + , 1 + ), + ( + 4 + , 'PET' + , 'This is a test description.' + , 5000 + , GETDATE() + , 1 + ) diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/13_SECURITY_DEPOSIT_RETURN_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/13_SECURITY_DEPOSIT_RETURN_TEST_DATA.sql new file mode 100644 index 0000000000..19ce19a365 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/13_SECURITY_DEPOSIT_RETURN_TEST_DATA.sql @@ -0,0 +1,26 @@ +INSERT INTO [dbo].[PIMS_SECURITY_DEPOSIT_RETURN] + ( + [SECURITY_DEPOSIT_ID] + ,[TERMINATION_DATE] + ,[CLAIMS_AGAINST] + ,[RETURN_AMOUNT] + ,[RETURN_DATE] + ,[CONCURRENCY_CONTROL_NUMBER] + ) +VALUES + ( + 1 + , GETDATE() + , 500 + , 250 + , GETDATE() + , 1 + ), + ( + 2 + , GETDATE() + , 500 + , 270 + , GETDATE() + , 1 + ) diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/14_SECURITY_DEPOSIT_RETURN_HOLDER_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/14_SECURITY_DEPOSIT_RETURN_HOLDER_TEST_DATA.sql new file mode 100644 index 0000000000..43c0c0a899 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/14_SECURITY_DEPOSIT_RETURN_HOLDER_TEST_DATA.sql @@ -0,0 +1,17 @@ +INSERT INTO [dbo].[PIMS_SECURITY_DEPOSIT_RETURN_HOLDER] + ( + [SECURITY_DEPOSIT_RETURN_ID] + ,[PERSON_ID] + ,[CONCURRENCY_CONTROL_NUMBER] + ) +VALUES + ( + (SELECT TOP 1 SECURITY_DEPOSIT_RETURN_ID FROM PIMS_SECURITY_DEPOSIT_RETURN WHERE SECURITY_DEPOSIT_ID = 1) + , (SELECT TOP 1 PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Wilson') + , 1 + ), + ( + (SELECT TOP 1 SECURITY_DEPOSIT_RETURN_ID FROM PIMS_SECURITY_DEPOSIT_RETURN WHERE SECURITY_DEPOSIT_ID = 2) + , (SELECT TOP 1 PERSON_ID FROM PIMS_PERSON WHERE SURNAME = 'Mouse') + , 1 + ) diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/15_SURPLUS_DECLERATION_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/15_SURPLUS_DECLERATION_TEST_DATA.sql new file mode 100644 index 0000000000..bd18739adf --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/15_SURPLUS_DECLERATION_TEST_DATA.sql @@ -0,0 +1,18 @@ +-- Creating test data for surplus declerations +INSERT INTO PIMS_PROPERTY_LEASE + (PROPERTY_ID, LEASE_ID, CONCURRENCY_CONTROL_NUMBER) +VALUES + (2, 45, 1) +INSERT INTO PIMS_PROPERTY_LEASE + (PROPERTY_ID, LEASE_ID, CONCURRENCY_CONTROL_NUMBER) +VALUES + (3, 45, 1) + +UPDATE PIMS_PROPERTY SET SURPLUS_DECLARATION_TYPE_CODE = 'YES', SURPLUS_DECLARATION_DATE = CURRENT_TIMESTAMP, CONCURRENCY_CONTROL_NUMBER = CONCURRENCY_CONTROL_NUMBER + 1 + WHERE PROPERTY_ID = 39 + +UPDATE PIMS_PROPERTY SET SURPLUS_DECLARATION_TYPE_CODE = 'UNKNOWN', SURPLUS_DECLARATION_DATE = CURRENT_TIMESTAMP, SURPLUS_DECLARATION_COMMENT = 'Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia curae; Vestibulum tempus iaculis ex eget semper. Etiam eget sollicitudin mauris. Mauris nec ligula eu massa faucibus ullamcorper in a dui. Donec ut arcu lacinia libero vehicula convallis vel tempus orci. Integer erat turpis, rhoncus et auctor rhoncus, blandit at elit. In elit lectus, finibus non interdum ut, sodales nec leo. In orci odio, finibus in mi et, rhoncus blandit ligula.',CONCURRENCY_CONTROL_NUMBER = CONCURRENCY_CONTROL_NUMBER + 1 + WHERE PROPERTY_ID = 2 + +UPDATE PIMS_PROPERTY SET SURPLUS_DECLARATION_TYPE_CODE = 'NO', SURPLUS_DECLARATION_DATE = CURRENT_TIMESTAMP, SURPLUS_DECLARATION_COMMENT = 'Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia curae; Vestibulum tempus iaculis ex eget semper. Etiam eget sollicitudin mauris. Mauris nec ligula eu massa faucibus ullamcorper in a dui. Donec ut arcu lacinia libero vehicula convallis vel tempus orci. Integer erat turpis, rhoncus et auctor rhoncus, blandit at elit. In elit lectus, finibus non interdum ut, sodales nec leo. In orci odio, finibus in mi et, rhoncus blandit ligula.',CONCURRENCY_CONTROL_NUMBER = CONCURRENCY_CONTROL_NUMBER + 1 + WHERE PROPERTY_ID = 3 diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/16_TENANT_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/16_TENANT_TEST_DATA.sql new file mode 100644 index 0000000000..cf95201c53 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/16_TENANT_TEST_DATA.sql @@ -0,0 +1,122 @@ +-- Populate lease tenant data +INSERT INTO + [dbo].[PIMS_LEASE_TENANT] + ( + LEASE_ID, + ORGANIZATION_ID, + LESSOR_TYPE_CODE, + CONCURRENCY_CONTROL_NUMBER + ) +VALUES + (45, 2, 'ORG', 1) + +-- Insert contact methods +INSERT INTO + PIMS_CONTACT_METHOD + ( + CONCURRENCY_CONTROL_NUMBER, + CONTACT_METHOD_TYPE_CODE, + PERSON_ID, + CONTACT_METHOD_VALUE, + APP_CREATE_USERID, + APP_CREATE_USER_DIRECTORY, + APP_LAST_UPDATE_USERID, + APP_LAST_UPDATE_USER_DIRECTORY + ) +VALUES + ( + 1, + 'WORKMOBIL', + 1, + '1111111111', + 'Test Data', + 'Test Data', + 'Test Data', + 'Test Data' + ) +INSERT INTO + PIMS_CONTACT_METHOD + ( + CONCURRENCY_CONTROL_NUMBER, + CONTACT_METHOD_TYPE_CODE, + PERSON_ID, + CONTACT_METHOD_VALUE, + APP_CREATE_USERID, + APP_CREATE_USER_DIRECTORY, + APP_LAST_UPDATE_USERID, + APP_LAST_UPDATE_USER_DIRECTORY + ) +VALUES + ( + 1, + 'WORKPHONE', + 2, + '2222222222', + 'Test Data', + 'Test Data', + 'Test Data', + 'Test Data' + ) +INSERT INTO + PIMS_CONTACT_METHOD + ( + CONCURRENCY_CONTROL_NUMBER, + CONTACT_METHOD_TYPE_CODE, + PERSON_ID, + CONTACT_METHOD_VALUE, + APP_CREATE_USERID, + APP_CREATE_USER_DIRECTORY, + APP_LAST_UPDATE_USERID, + APP_LAST_UPDATE_USER_DIRECTORY + ) +VALUES + ( + 1, + 'PERSMOBIL', + 2, + '3333333333', + 'Test Data', + 'Test Data', + 'Test Data', + 'Test Data' + ) + +INSERT INTO + PIMS_PERSON_ORGANIZATION + ( + PERSON_ID, + ORGANIZATION_ID, + CONCURRENCY_CONTROL_NUMBER, + APP_CREATE_USERID, + APP_CREATE_USER_DIRECTORY, + APP_LAST_UPDATE_USERID, + APP_LAST_UPDATE_USER_DIRECTORY + ) +VALUES + ( + 2, + 2, + 1, + 'Test Data', + 'Test Data', + 'Test Data', + 'Test Data' + ) + +-- Update postal code +UPDATE + PIMS_ADDRESS +SET + POSTAL_CODE = 'V6Z 5G7', + CONCURRENCY_CONTROL_NUMBER = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + ADDRESS_ID = 1 + +-- Add notes for lease tenant +UPDATE + [dbo].[PIMS_LEASE_TENANT] +SET + [NOTE] = 'These are notes for the organization record', + [CONCURRENCY_CONTROL_NUMBER] = [CONCURRENCY_CONTROL_NUMBER] + 1 +WHERE + [LEASE_TENANT_ID] = 1 diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/17_PIMS_USER_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/17_PIMS_USER_TEST_DATA.sql new file mode 100644 index 0000000000..54e78d07a8 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/17_PIMS_USER_TEST_DATA.sql @@ -0,0 +1,6 @@ +INSERT INTO PIMS_USER (PERSON_ID, BUSINESS_IDENTIFIER_VALUE, ISSUE_DATE, CONCURRENCY_CONTROL_NUMBER, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + (1, 'BSMITH', GETUTCDATE(), 1, GETUTCDATE(), 'seed_data', 'seed_data', GETUTCDATE(), 'seed_data', 'seed_data'), + (2, 'VBALL', GETUTCDATE(), 1, GETUTCDATE(), 'seed_data', 'seed_data', GETUTCDATE(), 'seed_data', 'seed_data'), + (3, 'STINKY', GETUTCDATE(), 1, GETUTCDATE(), 'seed_data', 'seed_data', GETUTCDATE(), 'seed_data', 'seed_data'), + (4, 'NACHO', GETUTCDATE(), 1, GETUTCDATE(), 'seed_data', 'seed_data', GETUTCDATE(), 'seed_data', 'seed_data'); \ No newline at end of file diff --git a/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/18_PIMS_ACCESS_REQUEST_TEST_DATA.sql b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/18_PIMS_ACCESS_REQUEST_TEST_DATA.sql new file mode 100644 index 0000000000..ed37076673 --- /dev/null +++ b/database/mssql/scripts/dbscripts/PSP_PIMS_S32_00/Test Data/18_PIMS_ACCESS_REQUEST_TEST_DATA.sql @@ -0,0 +1,6 @@ +INSERT INTO PIMS_ACCESS_REQUEST (USER_ID, ROLE_ID, ACCESS_REQUEST_STATUS_TYPE_CODE, REGION_CODE, CONCURRENCY_CONTROL_NUMBER, APP_CREATE_TIMESTAMP, APP_CREATE_USERID, APP_CREATE_USER_DIRECTORY, APP_LAST_UPDATE_TIMESTAMP, APP_LAST_UPDATE_USERID, APP_LAST_UPDATE_USER_DIRECTORY) +VALUES + (1, 1, 'RECEIVED', 1, 1, GETUTCDATE(), 'seed_data', 'seed_data', GETUTCDATE(), 'seed_data', 'seed_data'), + (2, 2, 'INITIATED', 1, 1, GETUTCDATE(), 'seed_data', 'seed_data', GETUTCDATE(), 'seed_data', 'seed_data'), + (3, 3, 'APPROVED', 1, 1, GETUTCDATE(), 'seed_data', 'seed_data', GETUTCDATE(), 'seed_data', 'seed_data'), + (4, 4, 'DENIED', 1, 1, GETUTCDATE(), 'seed_data', 'seed_data', GETUTCDATE(), 'seed_data', 'seed_data'); \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml index 6150a11c62..234896575f 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -90,6 +90,22 @@ services: networks: - psp + ####################### Clam AV ####################### + # example av test file here: https://serverfault.com/questions/484082/how-should-i-test-clam-anti-virus + clamav: + image: mkodockx/docker-clamav:alpine-idb-amd64 + ports: + - 3310:3310 + restart: on-failure + container_name: psp-clamav + healthcheck: + test: [ "CMD", "./check.sh" ] + interval: 60s + retries: 3 + start_period: 120s + networks: + - psp + ####################### Networks Definition ####################### networks: psp: diff --git a/etl/LISOS_PIMS/LISOS_22March/LISOS_22March.dtproj b/etl/LISOS_PIMS/LISOS_22March/LISOS_22March.dtproj index e026859bcd..273c439d5f 100644 --- a/etl/LISOS_PIMS/LISOS_22March/LISOS_22March.dtproj +++ b/etl/LISOS_PIMS/LISOS_22March/LISOS_22March.dtproj @@ -1,12 +1,12 @@  Project - 15.0.2000.167 + 15.0.2000.180 9.0.1.0 $base64$PFNvdXJjZUNvbnRyb2xJbmZvIHhtbG5zOnhzZD0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEiIHhtbG5zOnhzaT0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEtaW5zdGFuY2UiIHhtbG5zOmRkbDI9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDAzL2VuZ2luZS8yIiB4bWxuczpkZGwyXzI9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDAzL2VuZ2luZS8yLzIiIHhtbG5zOmRkbDEwMF8xMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDA4L2VuZ2luZS8xMDAvMTAwIiB4bWxuczpkZGwyMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEwL2VuZ2luZS8yMDAiIHhtbG5zOmRkbDIwMF8yMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEwL2VuZ2luZS8yMDAvMjAwIiB4bWxuczpkZGwzMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDExL2VuZ2luZS8zMDAiIHhtbG5zOmRkbDMwMF8zMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDExL2VuZ2luZS8zMDAvMzAwIiB4bWxuczpkZGw0MDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEyL2VuZ2luZS80MDAiIHhtbG5zOmRkbDQwMF80MDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEyL2VuZ2luZS80MDAvNDAwIiB4bWxuczpkZGw1MDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEzL2VuZ2luZS81MDAiIHhtbG5zOmRkbDUwMF81MDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEzL2VuZ2luZS81MDAvNTAwIiB4bWxuczpkd2Q9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vRGF0YVdhcmVob3VzZS9EZXNpZ25lci8xLjAiPg0KICA8RW5hYmxlZD5mYWxzZTwvRW5hYmxlZD4NCiAgPFByb2plY3ROYW1lPjwvUHJvamVjdE5hbWU+DQogIDxBdXhQYXRoPjwvQXV4UGF0aD4NCiAgPExvY2FsUGF0aD48L0xvY2FsUGF0aD4NCiAgPFByb3ZpZGVyPjwvUHJvdmlkZXI+DQo8L1NvdXJjZUNvbnRyb2xJbmZvPg== - LISOS_22March 4.database - LISOS_22March 4.database + LISOS_22March 2.database + LISOS_22March 2.database diff --git a/etl/PAIMS_PIMS/PAIMS_PIMS/MOTI_LEGACY_PAIMS_PIMS_DATA_MIGRATION.dtproj b/etl/PAIMS_PIMS/PAIMS_PIMS/MOTI_LEGACY_PAIMS_PIMS_DATA_MIGRATION.dtproj index cb553fc814..112fccdbf1 100644 --- a/etl/PAIMS_PIMS/PAIMS_PIMS/MOTI_LEGACY_PAIMS_PIMS_DATA_MIGRATION.dtproj +++ b/etl/PAIMS_PIMS/PAIMS_PIMS/MOTI_LEGACY_PAIMS_PIMS_DATA_MIGRATION.dtproj @@ -1,7 +1,7 @@  Project - 15.0.2000.167 + 15.0.2000.180 9.0.1.0 $base64$PFNvdXJjZUNvbnRyb2xJbmZvIHhtbG5zOnhzZD0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEiIHhtbG5zOnhzaT0iaHR0cDovL3d3dy53My5vcmcvMjAwMS9YTUxTY2hlbWEtaW5zdGFuY2UiIHhtbG5zOmRkbDI9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDAzL2VuZ2luZS8yIiB4bWxuczpkZGwyXzI9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDAzL2VuZ2luZS8yLzIiIHhtbG5zOmRkbDEwMF8xMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDA4L2VuZ2luZS8xMDAvMTAwIiB4bWxuczpkZGwyMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEwL2VuZ2luZS8yMDAiIHhtbG5zOmRkbDIwMF8yMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEwL2VuZ2luZS8yMDAvMjAwIiB4bWxuczpkZGwzMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDExL2VuZ2luZS8zMDAiIHhtbG5zOmRkbDMwMF8zMDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDExL2VuZ2luZS8zMDAvMzAwIiB4bWxuczpkZGw0MDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEyL2VuZ2luZS80MDAiIHhtbG5zOmRkbDQwMF80MDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEyL2VuZ2luZS80MDAvNDAwIiB4bWxuczpkZGw1MDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEzL2VuZ2luZS81MDAiIHhtbG5zOmRkbDUwMF81MDA9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vYW5hbHlzaXNzZXJ2aWNlcy8yMDEzL2VuZ2luZS81MDAvNTAwIiB4bWxuczpkd2Q9Imh0dHA6Ly9zY2hlbWFzLm1pY3Jvc29mdC5jb20vRGF0YVdhcmVob3VzZS9EZXNpZ25lci8xLjAiPg0KICA8RW5hYmxlZD5mYWxzZTwvRW5hYmxlZD4NCiAgPFByb2plY3ROYW1lPjwvUHJvamVjdE5hbWU+DQogIDxBdXhQYXRoPjwvQXV4UGF0aD4NCiAgPExvY2FsUGF0aD48L0xvY2FsUGF0aD4NCiAgPFByb3ZpZGVyPjwvUHJvdmlkZXI+DQo8L1NvdXJjZUNvbnRyb2xJbmZvPg== @@ -41,10 +41,10 @@ Package2 1 0 - 478 + 492 - {AC3BC405-1120-461A-AF8E-BEC21B66C8D6} + {FA32F93D-61EA-4A87-A537-3EBA0271A6F6} 8 @@ -77,7 +77,7 @@ 0 0 0 - Data Source=lizzard.th.gov.bc.ca:20208/TST11;User ID=DESMITH;Provider=OraOLEDB.Oracle.1;Persist Security Info=True; + Data Source=lizzard.th.gov.bc.ca:20208/DEV03;User ID=prisharm;Provider=OraOLEDB.Oracle.1;Persist Security Info=True; 18 @@ -180,7 +180,7 @@ 0 0 0 - lizzard.th.gov.bc.ca:20208/TST11 + lizzard.th.gov.bc.ca:20208/DEV03 18 @@ -195,7 +195,7 @@ 0 0 0 - DESMITH + prisharm 18 @@ -225,7 +225,7 @@ 0 0 0 - Data Source=sqldevtst.th.gov.bc.ca;User ID=PIMS_TST;Initial Catalog=PIMS_TST;Provider=SQLNCLI11.1;Auto Translate=False; + Data Source=127.0.0.1,5433;User ID=admin;Initial Catalog=pims;Provider=SQLNCLI11.1;Auto Translate=False; 18 @@ -285,7 +285,7 @@ 0 0 0 - PIMS_TST + pims 18 @@ -329,7 +329,7 @@ 0 0 0 - sqldevtst.th.gov.bc.ca + 127.0.0.1,5433 18 @@ -344,7 +344,7 @@ 0 0 0 - PIMS_TST + admin 18 diff --git a/etl/PAIMS_PIMS/PAIMS_PIMS/PAM_LOAD_PAIMS_TO_PIMS_DATASET_2.dtsx b/etl/PAIMS_PIMS/PAIMS_PIMS/PAM_LOAD_PAIMS_TO_PIMS_DATASET_2.dtsx index 39fe456f4d..62c285a57a 100644 --- a/etl/PAIMS_PIMS/PAIMS_PIMS/PAM_LOAD_PAIMS_TO_PIMS_DATASET_2.dtsx +++ b/etl/PAIMS_PIMS/PAIMS_PIMS/PAM_LOAD_PAIMS_TO_PIMS_DATASET_2.dtsx @@ -8,13 +8,13 @@ DTS:DelayValidation="True" DTS:DTSID="{7712D7BF-1FA7-4742-8725-CCFCBB85D4F5}" DTS:ExecutableType="Microsoft.Package" - DTS:LastModifiedProductVersion="15.0.2000.167" + DTS:LastModifiedProductVersion="15.0.2000.180" DTS:LocaleID="4105" DTS:ObjectName="Package2" DTS:PackageType="5" DTS:ProtectionLevel="0" - DTS:VersionBuild="479" - DTS:VersionGUID="{38238DF6-F54E-412B-A286-958970A32C42}"> + DTS:VersionBuild="492" + DTS:VersionGUID="{FA32F93D-61EA-4A87-A537-3EBA0271A6F6}"> 8 @@ -27,7 +27,11 @@ + DTS:ConnectionString="Data Source=lizzard.th.gov.bc.ca:20208/DEV03;User ID=prisharm;Provider=OraOLEDB.Oracle.1;Persist Security Info=True;"> + + + DTS:ConnectionString="Data Source=127.0.0.1,5433;User ID=admin;Initial Catalog=pims;Provider=SQLNCLI11.1;Auto Translate=False;"> + + + + + + + + @@ -6270,44 +6294,44 @@ where [refTable].[APP_CREATE_USER_DIRECTORY] = ? startId="Package\Load Contact Method\Data Conversion 5.Outputs[Data Conversion Output]" /> + startId="Package\Load Contact Method\AUDIT TRAIL.Outputs[Derived Column Output]" /> + startId="Package\Load Contact Method\CONTACT_METHOD_TYPE_CODE - WORKEMAIL.Outputs[Derived Column Output]" /> + startId="Package\Load Contact Method\CONTACT_METHOD_TYPE_CODE - MOBLPHONE.Outputs[Derived Column Output]" /> + startId="Package\Load Contact Method\CONTACT_METHOD_TYPE_CODE - FAX.Outputs[Derived Column Output]" /> + startId="Package\Load Contact Method\CONTACT_METHOD_TYPE_CODE - WORKPHONE.Outputs[Derived Column Output]" /> + startId="Package\Load Contact Method\CONTACT_METHOD_TYPE_CODE - PERSPHONE.Outputs[Derived Column Output]" /> + startId="Package\Load Contact Method\Derived Column.Outputs[Derived Column Output]" /> + startId="Package\Load Contact Method\Derived Column 1.Outputs[Derived Column Output]" /> startId="Package\Load Contact Method\Multicast.Outputs[Multicast Output 2]" /> + startId="Package\Load Contact Method\PIMS_CONTACT_METHOD FOR ORGANIZATION.Outputs[OLE DB Destination Error Output]" /> + startId="Package\Load Contact Method\PIMS_CONTACT_METHOD FOR PERSON.Outputs[OLE DB Destination Error Output]" /> DTS:refId="Package\Load Interest Holder Persons and Organizations" DTS:CreationName="Microsoft.Pipeline" DTS:Description="Data Flow Task" - DTS:DTSID="{AAF62B0B-EAD6-4ED8-83D0-E3A0D944600C}" + DTS:DTSID="{43d78511-8cc8-4d9d-af7a-6910beaf0e73}" DTS:ExecutableType="Microsoft.Pipeline" DTS:LocaleID="-1" DTS:ObjectName="Load Interest Holder Persons and Organizations" @@ -9448,6 +9472,52 @@ where [refTable].[DESCRIPTION] = ? name="FriendlyExpression">"place_holder" + + + "APP_PIMS_PROXY_ETL_EDIT" + "APP_PIMS_PROXY_ETL_EDIT" + + + + + "APP_PIMS_PROXY_ETL_EDIT" + "APP_PIMS_PROXY_ETL_EDIT" + + @@ -9622,6 +9692,112 @@ where [refTable].[DESCRIPTION] = ? + + + + + + + + + + + + + + + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]} + false + + + + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]} + false + + + + + + + + + + + + + + + refId="Package\Load Interest Holder Persons and Organizations\Filter pre-existing organisation" + componentClassID="Microsoft.Lookup" + contactInfo="Lookup;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;6" + description="Joins additional columns to the data flow by looking up values in a table. For example, join to the 'employee id' column the employees table to get 'hire date' and 'employee name'. We recommend this transformation when the lookup table can fit into memory." + name="Filter pre-existing organisation" + usesDispositions="true" + version="6"> + + select * from [dbo].[PIMS_ORGANIZATION] + select * from (select * from [dbo].[PIMS_ORGANIZATION]) [refTable] +where [refTable].[ORGANIZATION_NAME] = ? + 0 + 0 + 1 + 0 + 25 + 25 + <referenceMetadata><referenceColumns><referenceColumn name="ORGANIZATION_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="PRNT_ORGANIZATION_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="REGION_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DISTRICT_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="ORGANIZATION_TYPE_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/><referenceColumn name="ORG_IDENTIFIER_TYPE_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/><referenceColumn name="ORGANIZATION_IDENTIFIER" dataType="DT_WSTR" length="100" precision="0" scale="0" codePage="0"/><referenceColumn name="ORGANIZATION_NAME" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="ORGANIZATION_ALIAS" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="INCORPORATION_NUMBER" dataType="DT_WSTR" length="50" precision="0" scale="0" codePage="0"/><referenceColumn name="WEBSITE" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="IS_DISABLED" dataType="DT_BOOL" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="CONCURRENCY_CONTROL_NUMBER" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]}; + 1252 + false + + + + + refId="Package\Load Interest Holder Persons and Organizations\Filter pre-existing organisation.Inputs[Lookup Input]" + name="Lookup Input"> + cachedName="UNICODE_ORGANIZATION_NAME" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]"> + + ORGANIZATION_NAME + + + - - ![ISNULL](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]}) - !ISNULL(ORGANIZATION_NAME) - 0 - + name="Lookup Match Output" + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Filter pre-existing organisation.Inputs[Lookup Input]"> - - true - + name="Lookup No Match Output" + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Filter pre-existing organisation.Inputs[Lookup Input]"> + name="Lookup Error Output" + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Filter pre-existing organisation.Inputs[Lookup Input]"> @@ -10090,96 +10317,157 @@ where [refTable].[DESCRIPTION] = ? + refId="Package\Load Interest Holder Persons and Organizations\Fiter pre-existing person" + componentClassID="Microsoft.Lookup" + contactInfo="Lookup;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;6" + description="Joins additional columns to the data flow by looking up values in a table. For example, join to the 'employee id' column the employees table to get 'hire date' and 'employee name'. We recommend this transformation when the lookup table can fit into memory." + name="Fiter pre-existing person" + usesDispositions="true" + version="6"> + + select * from [dbo].[PIMS_PERSON] + select * from (select * from [dbo].[PIMS_PERSON]) [refTable] +where [refTable].[FIRST_NAME] = ? and [refTable].[SURNAME] = ? + 0 + 0 + 1 + 0 + 25 + 25 + <referenceMetadata><referenceColumns><referenceColumn name="PERSON_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="SURNAME" dataType="DT_WSTR" length="50" precision="0" scale="0" codePage="0"/><referenceColumn name="FIRST_NAME" dataType="DT_WSTR" length="50" precision="0" scale="0" codePage="0"/><referenceColumn name="MIDDLE_NAMES" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="NAME_SUFFIX" dataType="DT_WSTR" length="50" precision="0" scale="0" codePage="0"/><referenceColumn name="PREFERRED_NAME" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="BIRTH_DATE" dataType="DT_DBDATE" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="ADDRESS_COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="IS_DISABLED" dataType="DT_BOOL" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="CONCURRENCY_CONTROL_NUMBER" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="USE_ORGANIZATION_ADDRESS" dataType="DT_BOOL" length="0" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]};#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]}; + 1252 + false + + + + + refId="Package\Load Interest Holder Persons and Organizations\Fiter pre-existing person.Inputs[Lookup Input]" + name="Lookup Input"> + cachedName="UNICODE_SURNAME" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]"> + + SURNAME + + + + cachedName="UNICODE_ FIRST_NAME" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]"> + + FIRST_NAME + + + - - ![ISNULL](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]}) || ![ISNULL](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]}) - !ISNULL(SURNAME) || !ISNULL(FIRST_NAME) - 0 - + name="Lookup Match Output" + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Fiter pre-existing person.Inputs[Lookup Input]"> - - true - + name="Lookup No Match Output" + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Fiter pre-existing person.Inputs[Lookup Input]"> + name="Lookup Error Output" + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Fiter pre-existing person.Inputs[Lookup Input]"> @@ -10188,110 +10476,178 @@ where [refTable].[DESCRIPTION] = ? + refId="Package\Load Interest Holder Persons and Organizations\Format Organization_Name" + componentClassID="Microsoft.DerivedColumn" + contactInfo="Derived Column;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;0" + description="Creates new column values by applying expressions to transformation input columns. Create new columns or overwrite existing ones. For example, concatenate the values from the 'first name' and 'last name' column to make a 'full name' column." + name="Format Organization_Name" + usesDispositions="true"> - - - - - - - - - - - + refId="Package\Load Interest Holder Persons and Organizations\Format Organization_Name.Inputs[Derived Column Input]" + description="Input to the Derived Column Transformation" + name="Derived Column Input"> + + + + [LTRIM](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]}) + LTRIM(UNICODE_ORGANIZATION_NAME) + + + + + + + + + + + + + + + - - - - - - - + + lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[FIRST_NAME]" + truncationRowDisposition="FailComponent" + usageType="readWrite"> "OTHINCORPNO" + name="Expression">(DT_WSTR,50)[TRIM](#{Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[FIRST_NAME]}) "OTHINCORPNO" + name="FriendlyExpression">(DT_WSTR,50)TRIM(FIRST_NAME) - - + + + + (DT_WSTR,50)[TRIM](#{Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[SURNAME]}) + (DT_WSTR,50)TRIM(SURNAME) + + + + + + + + + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Format Output Columns.Inputs[Derived Column Input]"> @@ -10300,15 +10656,15 @@ where [refTable].[DESCRIPTION] = ? @@ -10316,19 +10672,19 @@ where [refTable].[DESCRIPTION] = ? + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Format PIMS_Organisation output column.Inputs[Derived Column Input]"> @@ -10345,27 +10701,50 @@ where [refTable].[DESCRIPTION] = ? name="FriendlyExpression">"OTHER" + + + "OTHINCORPNO" + "OTHINCORPNO" + + + synchronousInputId="Package\Load Interest Holder Persons and Organizations\Format PIMS_Organisation output column.Inputs[Derived Column Input]"> @@ -10374,217 +10753,444 @@ where [refTable].[DESCRIPTION] = ? - - 0 - "APP_PAM"."PAM_INTEREST_HOLDER" - - - - 1252 - false - 0 - - - - - + refId="Package\Load Interest Holder Persons and Organizations\IS_ORGANIZATION" + componentClassID="Microsoft.ConditionalSplit" + contactInfo="Conditional Split;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;0" + description="Routes data rows to different outputs depending on the content of the data. Use conditions (SSIS expressions) to specify which rows are routed. For example, separate records that need to be cleaned from those that are ready to be loaded or route only a subset of records." + name="IS_ORGANIZATION" + usesDispositions="true"> + + + + + + + + - - - - - - - - + refId="Package\Load Interest Holder Persons and Organizations\IS_ORGANIZATION.Outputs[Organization]" + description="Output 1 of the Conditional Split Transformation" + errorOrTruncationOperation="Computation" + errorRowDisposition="FailComponent" + exclusionGroup="1" + name="Organization" + synchronousInputId="Package\Load Interest Holder Persons and Organizations\IS_ORGANIZATION.Inputs[Conditional Split Input]" + truncationRowDisposition="FailComponent"> + + ![ISNULL](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]}) && [LEN]([TRIM](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]})) > 0 + !ISNULL(ORGANIZATION_NAME) && LEN(TRIM(ORGANIZATION_NAME)) > 0 + 0 + + + + + + true + + + + + + refId="Package\Load Interest Holder Persons and Organizations\IS_ORGANIZATION.Outputs[Conditional Split Error Output].Columns[ErrorCode]" + dataType="i4" + lineageId="Package\Load Interest Holder Persons and Organizations\IS_ORGANIZATION.Outputs[Conditional Split Error Output].Columns[ErrorCode]" + name="ErrorCode" + specialFlags="1" /> + refId="Package\Load Interest Holder Persons and Organizations\IS_ORGANIZATION.Outputs[Conditional Split Error Output].Columns[ErrorColumn]" + dataType="i4" + lineageId="Package\Load Interest Holder Persons and Organizations\IS_ORGANIZATION.Outputs[Conditional Split Error Output].Columns[ErrorColumn]" + name="ErrorColumn" + specialFlags="2" /> + + + + + + + + + + + + + + + + + + + (![ISNULL](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]}) || ![ISNULL](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]})) && ([LEN]([TRIM](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]})) > 0 || [LEN]([TRIM](#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]})) > 0) + (!ISNULL(SURNAME) || !ISNULL(FIRST_NAME)) && (LEN(TRIM(FIRST_NAME)) > 0 || LEN(TRIM(SURNAME)) > 0) + 0 + + + + + + true + + + + + + refId="Package\Load Interest Holder Persons and Organizations\IS_PERSON.Outputs[Conditional Split Error Output].Columns[ErrorCode]" + dataType="i4" + lineageId="Package\Load Interest Holder Persons and Organizations\IS_PERSON.Outputs[Conditional Split Error Output].Columns[ErrorCode]" + name="ErrorCode" + specialFlags="1" /> + refId="Package\Load Interest Holder Persons and Organizations\IS_PERSON.Outputs[Conditional Split Error Output].Columns[ErrorColumn]" + dataType="i4" + lineageId="Package\Load Interest Holder Persons and Organizations\IS_PERSON.Outputs[Conditional Split Error Output].Columns[ErrorColumn]" + name="ErrorColumn" + specialFlags="2" /> - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + 0 + "APP_PAM"."PAM_INTEREST_HOLDER" + + + + 1252 + false + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + cachedLength="23" cachedName="APP_CREATE_USERID" externalMetadataColumnId="Package\Load Interest Holder Persons and Organizations\PIMS_ORGANIZATIION.Inputs[OLE DB Destination Input].ExternalColumns[APP_CREATE_USERID]" - lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[APP_CREATE_USERID]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[APP_CREATE_USERID]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[APP_CREATE_USER_DIRECTORY]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USERID]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Format PIMS_Organisation output column.Outputs[Derived Column Output].Columns[ORGANIZATION_TYPE_CODE]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Format PIMS_Organisation output column.Outputs[Derived Column Output].Columns[ORGANIZATION_IDENTIFIER_TYPE_CODE]" /> + + + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_ORGANIZATION_NAME]" /> @@ -11135,49 +11757,63 @@ where [refTable].[DESCRIPTION] = ? cachedLength="23" cachedName="APP_CREATE_USERID" externalMetadataColumnId="Package\Load Interest Holder Persons and Organizations\PIMS_PERSON.Inputs[OLE DB Destination Input].ExternalColumns[APP_CREATE_USERID]" - lineageId="Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_CREATE_USERID]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[APP_CREATE_USERID]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[APP_CREATE_USER_DIRECTORY]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USERID]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[UNICODE_SURNAME]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[UNICODE_ FIRST_NAME]" /> + lineageId="Package\Load Interest Holder Persons and Organizations\Sort.Outputs[Sort Output].Columns[UNICODE_MIDDLE_NAME]" /> + + @@ -11286,6 +11922,10 @@ where [refTable].[DESCRIPTION] = ? dataType="wstr" length="2000" name="ADDRESS_COMMENT" /> + @@ -11506,11 +12146,11 @@ where [refTable].[DESCRIPTION] = ? 0 + name="NewComparisonFlags">3 0 + name="NewSortKeyPosition">2 0 + name="NewComparisonFlags">3 0 + name="NewSortKeyPosition">1 5 + name="NewComparisonFlags">0 1 + name="NewSortKeyPosition">0 name="NewSortKeyPosition">0 + + + 0 + 0 + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 0 + 0 + + @@ -11907,10 +12615,12 @@ where [refTable].[DESCRIPTION] = ? + name="SURNAME" + sortKeyPosition="2"> + name="FIRST_NAME" + sortKeyPosition="1"> + name="ORGANIZATION_NAME"> name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]} + + + #{Package\Load Interest Holder Persons and Organizations\Converting First_Name and Surname datatype.Outputs[Data Conversion Output].Columns[Copy of SURNAME]} + + + + + #{Package\Load Interest Holder Persons and Organizations\Converting First_Name and Surname datatype.Outputs[Data Conversion Output].Columns[Copy of FIRST_NAME]} + + + + + #{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[DB_CREATE_USERID]} + + + + + #{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[DB_LAST_UPDATE_USERID]} + + + + true + -1 + + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Inputs[Sort Input]" + name="Sort Input"> + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[SURNAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[FIRST_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MIDDLE_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[PROVINCE]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">7 + 1 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY_ID]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY_ID]} - - - - - - - - - + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[SURNAME]} + description="Specifies the sort order of the column." + name="NewSortKeyPosition">0 + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Inputs[Sort Input].Columns[PROVINCE_STATE_ID]" + cachedDataType="i2" + cachedName="PROVINCE_STATE_ID" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE_STATE_ID]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[FIRST_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Inputs[Sort Input].Columns[APP_CREATE_USERID]" + cachedDataType="wstr" + cachedLength="23" + cachedName="APP_CREATE_USERID" + lineageId="Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_CREATE_USERID]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Inputs[Sort Input].Columns[APP_CREATE_USER_DIRECTORY]" + cachedDataType="wstr" + cachedLength="12" + cachedName="APP_CREATE_USER_DIRECTORY" + lineageId="Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_CREATE_USER_DIRECTORY]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Inputs[Sort Input].Columns[APP_LAST_UPDATE_USERID]" + cachedDataType="wstr" + cachedLength="23" + cachedName="APP_LAST_UPDATE_USERID" + lineageId="Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USERID]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Inputs[Sort Input].Columns[APP_LAST_UPDATE_USER_DIRECTORY]" + cachedDataType="wstr" + cachedLength="12" + cachedName="APP_LAST_UPDATE_USER_DIRECTORY" + lineageId="Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Inputs[Sort Input].Columns[DB_CREATE_USERID]" + cachedDataType="wstr" + cachedLength="23" + cachedName="DB_CREATE_USERID" + lineageId="Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[DB_CREATE_USERID]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Inputs[Sort Input].Columns[DB_LAST_UPDATE_USERID]" + cachedDataType="wstr" + cachedLength="23" + cachedName="DB_LAST_UPDATE_USERID" + lineageId="Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[DB_LAST_UPDATE_USERID]"> #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[PROVINCE]} + description="Specifies the comparison options for character data." + name="NewComparisonFlags">0 + 0 - + + + + + + + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY]} - - + + #{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY_ID]} + description="Specifies the lineage identifier of the input column that is associated with this output column." + name="SortColumnId">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} - - - - - - - - - - - + + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[INTEREST_HOLDER_ID]" + dataType="numeric" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[INTEREST_HOLDER_ID]" + name="INTEREST_HOLDER_ID" + precision="10"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + + + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_COUNTRY]" + dataType="wstr" + length="20" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_COUNTRY]" + name="UNICODE_COUNTRY"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} + + + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_PROVINCE]" + dataType="wstr" + length="2" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_PROVINCE]" + name="UNICODE_PROVINCE"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + + - - + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_ORGANIZATION_NAME]" + comparisonFlags="7" + dataType="wstr" + length="200" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_ORGANIZATION_NAME]" + name="UNICODE_ORGANIZATION_NAME" + sortKeyPosition="1"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} + + + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_ FIRST_NAME]" + name="UNICODE_ FIRST_NAME"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + + + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_MIDDLE_NAME]" + name="UNICODE_MIDDLE_NAME"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} + + + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[UNICODE_SURNAME]" + name="UNICODE_SURNAME"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} + + + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[COUNTRY_ID]" + dataType="i2" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[COUNTRY_ID]" + name="COUNTRY_ID"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY_ID]} + + + refId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[PROVINCE_STATE_ID]" + dataType="i2" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[PROVINCE_STATE_ID]" + name="PROVINCE_STATE_ID"> + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE_STATE_ID]} + + + length="23" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[APP_CREATE_USERID]" + name="APP_CREATE_USERID"> + + #{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_CREATE_USERID]} + + + length="12" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[APP_CREATE_USER_DIRECTORY]" + name="APP_CREATE_USER_DIRECTORY"> + + #{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_CREATE_USER_DIRECTORY]} + + + length="23" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USERID]" + name="APP_LAST_UPDATE_USERID"> + + #{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USERID]} + + + length="12" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]" + name="APP_LAST_UPDATE_USER_DIRECTORY"> + + #{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]} + + + length="23" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[DB_CREATE_USERID]" + name="DB_CREATE_USERID"> + + #{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[DB_CREATE_USERID]} + + - + length="23" + lineageId="Package\Load Interest Holder Persons and Organizations\Sort 1.Outputs[Sort Output].Columns[DB_LAST_UPDATE_USERID]" + name="DB_LAST_UPDATE_USERID"> + + #{Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id).Outputs[Derived Column Output].Columns[DB_LAST_UPDATE_USERID]} + + + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[SURNAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[SURNAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[FIRST_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[FIRST_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[MIDDLE_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[STREET_ADDRESS_1]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[STREET_ADDRESS_2]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[STREET_ADDRESS_3]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[PROVINCE]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[PROVINCE]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[COUNTRY]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[ORGANIZATION_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[INTEREST_HOLDER_ID]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_COUNTRY]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_PROVINCE]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_ORGANIZATION_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_ FIRST_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_MIDDLE_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_SURNAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} - - #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY_ID]} - - - + lineageId="Package\Load Interest Holder Persons and Organizations\COUNTRY_ID.Outputs[Lookup Match Output].Columns[COUNTRY_ID]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE_STATE_ID]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY_ID]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[SURNAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[SURNAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[FIRST_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[FIRST_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[MIDDLE_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[STREET_ADDRESS_1]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[STREET_ADDRESS_2]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[STREET_ADDRESS_3]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[PROVINCE]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[PROVINCE]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[COUNTRY]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[ORGANIZATION_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER.Outputs[OLE DB Source Output].Columns[INTEREST_HOLDER_ID]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_COUNTRY]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_PROVINCE]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_ORGANIZATION_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_ FIRST_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_MIDDLE_NAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} + lineageId="Package\Load Interest Holder Persons and Organizations\Data Conversion.Outputs[Data Conversion Output].Columns[UNICODE_SURNAME]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} - - #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY_ID]} - - - + lineageId="Package\Load Interest Holder Persons and Organizations\Canada.Outputs[Derived Column Output].Columns[COUNTRY_ID]"> #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE_STATE_ID]} + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY_ID]} @@ -13502,1391 +14393,1301 @@ where [refTable].[DESCRIPTION] = ? - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - select * from [dbo].[PIMS_ADDRESS] - select * from (select * from [dbo].[PIMS_ADDRESS]) [refTable] -where [refTable].[APP_CREATE_USER_DIRECTORY] = ? - 0 - 0 - 1 - 0 - 25 - 25 - <referenceMetadata><referenceColumns><referenceColumn name="ADDRESS_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="REGION_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DISTRICT_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="PROVINCE_STATE_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="COUNTRY_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_1" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_2" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_3" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="MUNICIPALITY_NAME" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="POSTAL_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/><referenceColumn name="OTHER_COUNTRY" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="LATITUDE" dataType="DT_NUMERIC" length="0" precision="8" scale="6" codePage="0"/><referenceColumn name="LONGITUDE" dataType="DT_NUMERIC" length="0" precision="9" scale="6" codePage="0"/><referenceColumn name="COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="CONCURRENCY_CONTROL_NUMBER" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> - #{Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Output].Columns[PIMS_PERSON_APP_CREATE_USER_DIRECTORY]}; - 1252 - false - - - - + refId="Package\Load Interest Holder Persons and Organizations\Union All 1" + componentClassID="Microsoft.UnionAll" + contactInfo="Union All;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;1" + description="Combines rows from multiple data flows without sorting. For example, add rows back to a data flow after correction of errors. If sorting is important, we recommend using the Merge transformation." + name="Union All 1" + version="1"> + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Inputs[Union All Input 1]" + name="Union All Input 1"> + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Inputs[Union All Input 1].Columns[SURNAME]" + cachedCodepage="1252" + cachedDataType="str" + cachedLength="50" + cachedName="SURNAME" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[SURNAME]"> APP_CREATE_USER_DIRECTORY - + containsID="true" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]} - - - - - - - - + ADDRESS_ID + containsID="true" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]} - - + + APP_CREATE_USER_DIRECTORY + containsID="true" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} - - - - - - - - - - - - - - - - - - - select * from [dbo].[PIMS_ADDRESS] - select * from (select * from [dbo].[PIMS_ADDRESS]) [refTable] -where [refTable].[APP_CREATE_USER_DIRECTORY] = ? - 0 - 0 - 1 - 0 - 25 - 25 - <referenceMetadata><referenceColumns><referenceColumn name="ADDRESS_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="REGION_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DISTRICT_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="PROVINCE_STATE_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="COUNTRY_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_1" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_2" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_3" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="MUNICIPALITY_NAME" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="POSTAL_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/><referenceColumn name="OTHER_COUNTRY" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="LATITUDE" dataType="DT_NUMERIC" length="0" precision="8" scale="6" codePage="0"/><referenceColumn name="LONGITUDE" dataType="DT_NUMERIC" length="0" precision="9" scale="6" codePage="0"/><referenceColumn name="COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="CONCURRENCY_CONTROL_NUMBER" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> - #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]}; - 1252 - false - - - - - - - + + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Inputs[Union All Input 1].Columns[STREET_ADDRESS_1]" + cachedCodepage="1252" + cachedDataType="str" + cachedLength="50" + cachedName="STREET_ADDRESS_1" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]"> APP_CREATE_USER_DIRECTORY + containsID="true" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + + + + + containsID="true" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} - - - - - - - - + ADDRESS_ID + containsID="true" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} - - - - - - - - - - - - - - - - - - - - - - - - - - + + "APP_PIMS_PROXY_ETL_EDIT" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + + + + "APP_PIMS_PROXY_ETL_EDIT" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE]} - - + + "place_holder" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY]} + + + + "place_holder" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} - - + + "APP_PIMS_PROXY_ETL_EDIT" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + + + + "APP_PIMS_PROXY_ETL_EDIT" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} - - + + "place_holder" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + + + + "place_holder" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} - - + + "MAILING" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + + + + "MAILING" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} - - - - - - - - - - - - - - - - + + + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} + + + + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY_ID]} + + + + + #{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE_STATE_ID]} + + + - - - - - + + + "APP_PIMS_PROXY_ETL_EDIT" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]} + + + + "APP_PIMS_PROXY_ETL_EDIT" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]} - - + + "place_holder" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MIDDLE_NAME]} + + + + "place_holder" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} - - + + "APP_PIMS_PROXY_ETL_EDIT" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_2]} + + + + "APP_PIMS_PROXY_ETL_EDIT" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[STREET_ADDRESS_3]} - - + + "place_holder" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + + + + "place_holder" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE]} - - + + "MAILING" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY]} + + + + "MAILING" + dataType="System.Int32" + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[ORGANIZATION_NAME]} - - - - - - - - - - - - - - - - true - -1 - - - - + + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Inputs[Union All Input 2].Columns[INTEREST_HOLDER_ID]" + cachedDataType="numeric" + cachedName="INTEREST_HOLDER_ID" + cachedPrecision="10" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]"> 0 - 1 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[INTEREST_HOLDER_ID]} + cachedLength="20" + cachedName="UNICODE_COUNTRY" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]"> 0 - 0 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]} + cachedLength="2" + cachedName="UNICODE_PROVINCE" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]"> 0 - 0 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]} + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Inputs[Union All Input 2].Columns[UNICODE_ORGANIZATION_NAME]" + cachedDataType="wstr" + cachedLength="200" + cachedName="UNICODE_ORGANIZATION_NAME" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]"> 0 - 2 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]} + cachedLength="50" + cachedName="UNICODE_ FIRST_NAME" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]"> 0 - 0 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]} + cachedLength="50" + cachedName="UNICODE_MIDDLE_NAME" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]"> 0 - 0 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]} + cachedLength="50" + cachedName="UNICODE_SURNAME" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]"> 0 - 0 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_SURNAME]} + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Inputs[Union All Input 2].Columns[COUNTRY_ID]" + cachedDataType="i2" + cachedName="COUNTRY_ID" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All.Outputs[Union All Output 1].Columns[COUNTRY_ID]"> 0 - 0 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[COUNTRY_ID]} + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Inputs[Union All Input 2].Columns[PROVINCE_STATE_ID]" + cachedDataType="i2" + cachedName="PROVINCE_STATE_ID" + lineageId="Package\Load Interest Holder Persons and Organizations\BC.Outputs[Derived Column Output].Columns[PROVINCE_STATE_ID]"> 0 - 3 + description="Output column lineage ID" + name="OutputColumnLineageID">#{Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[PROVINCE_STATE_ID]} + + + + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1]" + name="Union All Output 1"> - - #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_ID]} - - - - - #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]} - - + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]" + codePage="1252" + dataType="str" + length="50" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[SURNAME]" + name="SURNAME" /> - - #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[INCORPORATION_NUMBER]} - - + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[FIRST_NAME]" + name="FIRST_NAME" /> - - #{Package\Load Person Address and Organization Address\Address ID in PIMS Address.Outputs[Lookup Match Output].Columns[ADDRESS_ID]} - - + refId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MIDDLE_NAME]" + codePage="1252" + dataType="str" + length="50" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[MIDDLE_NAME]" + name="MIDDLE_NAME" /> + + + + + + + + - - #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_CREATE_USERID]} - - + length="20" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_COUNTRY]" + name="UNICODE_COUNTRY" /> - - #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_CREATE_USER_DIRECTORY]} - - + length="2" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_PROVINCE]" + name="UNICODE_PROVINCE" /> - - #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USERID]} - - + length="200" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ORGANIZATION_NAME]" + name="UNICODE_ORGANIZATION_NAME" /> - - #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]} - - + length="50" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_ FIRST_NAME]" + name="UNICODE_ FIRST_NAME" /> - - #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[ADDRESS_USAGE_TYPE_CODE]} - - + length="50" + lineageId="Package\Load Interest Holder Persons and Organizations\Union All 1.Outputs[Union All Output 1].Columns[UNICODE_MIDDLE_NAME]" + name="UNICODE_MIDDLE_NAME" /> + + + - - - - - - - - - - - - - - - [GETDATE]() - GETDATE() - - - - - "LOAD PERSON ADDFRESS AND ORGANIZATION ADDRESS" - "LOAD PERSON ADDFRESS AND ORGANIZATION ADDRESS" - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + select * from [dbo].[PIMS_ADDRESS] + select * from (select * from [dbo].[PIMS_ADDRESS]) [refTable] +where [refTable].[APP_CREATE_USER_DIRECTORY] = ? + 0 + 0 + 1 + 0 + 25 + 25 + <referenceMetadata><referenceColumns><referenceColumn name="ADDRESS_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="REGION_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DISTRICT_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="PROVINCE_STATE_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="COUNTRY_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_1" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_2" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_3" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="MUNICIPALITY_NAME" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="POSTAL_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/><referenceColumn name="OTHER_COUNTRY" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="LATITUDE" dataType="DT_NUMERIC" length="0" precision="8" scale="6" codePage="0"/><referenceColumn name="LONGITUDE" dataType="DT_NUMERIC" length="0" precision="9" scale="6" codePage="0"/><referenceColumn name="COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="CONCURRENCY_CONTROL_NUMBER" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> + #{Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Output].Columns[PIMS_PERSON_APP_CREATE_USER_DIRECTORY]}; + 1252 + false + + + + + + + + "ADDRESS ID in PIMS ADDRESS" + description="Specifies the column in the reference table that a column joins." + name="JoinToReferenceColumn">APP_CREATE_USER_DIRECTORY "ADDRESS ID in PIMS ADDRESS" + dataType="System.Null" + description="Specifies the column in the reference table from which a column is copied." + name="CopyFromReferenceColumn" /> - + + + + + + + + "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" - "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" + description="Specifies the column in the reference table from which a column is copied." + name="CopyFromReferenceColumn">ADDRESS_ID "Address not found for Interest Holder: " + #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]} + description="Specifies the column in the reference table from which a column is copied." + name="CopyFromReferenceColumn">APP_CREATE_USER_DIRECTORY + + + + + + + + + + + + + + + + + + + + select * from [dbo].[PIMS_ADDRESS] + select * from (select * from [dbo].[PIMS_ADDRESS]) [refTable] +where [refTable].[APP_CREATE_USER_DIRECTORY] = ? + 0 + 0 + 1 + 0 + 25 + 25 + <referenceMetadata><referenceColumns><referenceColumn name="ADDRESS_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="REGION_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DISTRICT_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="PROVINCE_STATE_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="COUNTRY_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_1" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_2" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_3" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="MUNICIPALITY_NAME" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="POSTAL_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/><referenceColumn name="OTHER_COUNTRY" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="LATITUDE" dataType="DT_NUMERIC" length="0" precision="8" scale="6" codePage="0"/><referenceColumn name="LONGITUDE" dataType="DT_NUMERIC" length="0" precision="9" scale="6" codePage="0"/><referenceColumn name="COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="CONCURRENCY_CONTROL_NUMBER" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> + #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]}; + 1252 + false + + + + + + + + + "Address not found for Interest Holder: " + APP_CREATE_USER_DIRECTORY + description="Specifies the column in the reference table that a column joins." + name="JoinToReferenceColumn">APP_CREATE_USER_DIRECTORY + + + + + + + + + + + + + ADDRESS_ID + + + + name="Lookup Error Output" + synchronousInputId="Package\Load Person Address and Organization Address\Address ID in PIMS Address.Inputs[Lookup Input]"> @@ -14895,171 +15696,164 @@ where [refTable].[APP_CREATE_USER_DIRECTORY] = ? - - - + synchronousInputId="Package\Load Person Address and Organization Address\Audit Trail.Inputs[Derived Column Input]"> [GETDATE]() + name="Expression">"APP_PIMS_PROXY_ETL_EDIT" GETDATE() + name="FriendlyExpression">"APP_PIMS_PROXY_ETL_EDIT" "Load Person Address and Organizartion Address" + name="Expression">"place_holder" "Load Person Address and Organizartion Address" + name="FriendlyExpression">"place_holder" "Address ID in PIMS Address" + name="Expression">"APP_PIMS_PROXY_ETL_EDIT" "Address ID in PIMS Address" + name="FriendlyExpression">"APP_PIMS_PROXY_ETL_EDIT" "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" + name="Expression">"place_holder" "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" + name="FriendlyExpression">"place_holder" "Failed to find Address Id for: " + #{Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Output].Columns[PIMS_PERSON_APP_CREATE_USER_DIRECTORY]} + name="Expression">"MAILING" "Failed to find Address Id for: " + PIMS_PERSON_APP_CREATE_USER_DIRECTORY + name="FriendlyExpression">"MAILING" + synchronousInputId="Package\Load Person Address and Organization Address\Audit Trail.Inputs[Derived Column Input]"> @@ -15068,334 +15862,164 @@ where [refTable].[APP_CREATE_USER_DIRECTORY] = ? - - 0 - [etl].[ETL_ERROR_LOG] - - - 1252 - false - 3 - false - false - TABLOCK,CHECK_CONSTRAINTS - 2147483647 - - - - + refId="Package\Load Person Address and Organization Address\Audit Trail 1" + componentClassID="Microsoft.DerivedColumn" + contactInfo="Derived Column;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;0" + description="Creates new column values by applying expressions to transformation input columns. Create new columns or overwrite existing ones. For example, concatenate the values from the 'first name' and 'last name' column to make a 'full name' column." + name="Audit Trail 1" + usesDispositions="true"> - - - - - - - - - - - - - - - - + refId="Package\Load Person Address and Organization Address\Audit Trail 1.Inputs[Derived Column Input]" + description="Input to the Derived Column Transformation" + name="Derived Column Input"> + + name="Derived Column Output" + synchronousInputId="Package\Load Person Address and Organization Address\Audit Trail 1.Inputs[Derived Column Input]"> + refId="Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_CREATE_USERID]" + dataType="wstr" + errorOrTruncationOperation="Computation" + errorRowDisposition="FailComponent" + length="23" + lineageId="Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_CREATE_USERID]" + name="APP_CREATE_USERID" + truncationRowDisposition="FailComponent"> + + "APP_PIMS_PROXY_ETL_EDIT" + "APP_PIMS_PROXY_ETL_EDIT" + + - - - - - - - - 0 - [etl].[ETL_ERROR_LOG] - - - 1252 - false - 0 - false - false - TABLOCK,CHECK_CONSTRAINTS - 2147483647 - - - - - - - - - - - - - - - - - + + "place_holder" + "place_holder" + + + - + + "APP_PIMS_PROXY_ETL_EDIT" + "APP_PIMS_PROXY_ETL_EDIT" + + + - - - - - - - + errorOrTruncationOperation="Computation" + errorRowDisposition="FailComponent" + length="12" + lineageId="Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]" + name="APP_LAST_UPDATE_USER_DIRECTORY" + truncationRowDisposition="FailComponent"> + + "place_holder" + "place_holder" + + + + + "MAILING" + "MAILING" + + + + + + name="Derived Column Error Output" + synchronousInputId="Package\Load Person Address and Organization Address\Audit Trail 1.Inputs[Derived Column Input]"> @@ -15404,736 +16028,673 @@ where [refTable].[APP_CREATE_USER_DIRECTORY] = ? + refId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses" + componentClassID="Microsoft.Sort" + contactInfo="Sort;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;1" + description="Sorts input data in ascending or descending order when it cannot be sorted at its source. For example, sort sales data by 'customer id' before it is written to a flat file and delivered to another department. Note: We do not recommend this transformation for large data flows." + name="Deduplicate Organization Addresses" + version="1"> 0 - [dbo].[PIMS_ORGANIZATION] - - - - 1252 - false + dataType="System.Boolean" + description="Indicates whether the Sort transformation removes rows with duplicate sort values." + name="EliminateDuplicates">true 0 - + description="Specifies the maximum number of threads to use for sorting." + expressionType="Notify" + name="MaximumThreads">-1 - - - + + + + + + 0 + 1 + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 0 + 2 + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 0 + 0 + + + + + 0 + 3 + + + + + + + refId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output]" + isSorted="true" + name="Sort Output"> + sortKeyPosition="1"> + + #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_ID]} + + + lineageId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]" + name="ORGANIZATION_APP_CREATE_USER_DIRECTORY"> + + #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]} + + - - - - + + #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[INCORPORATION_NUMBER]} + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - + lineageId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[ADDRESS_ID]" + name="ADDRESS_ID" + sortKeyPosition="2"> + + #{Package\Load Person Address and Organization Address\Address ID in PIMS Address.Outputs[Lookup Match Output].Columns[ADDRESS_ID]} + + + refId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[APP_CREATE_USERID]" + dataType="wstr" + length="23" + lineageId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[APP_CREATE_USERID]" + name="APP_CREATE_USERID"> + + #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_CREATE_USERID]} + + + refId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[APP_CREATE_USER_DIRECTORY]" + dataType="wstr" + length="12" + lineageId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[APP_CREATE_USER_DIRECTORY]" + name="APP_CREATE_USER_DIRECTORY"> + + #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_CREATE_USER_DIRECTORY]} + + + refId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USERID]" + dataType="wstr" + length="23" + lineageId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USERID]" + name="APP_LAST_UPDATE_USERID"> + + #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USERID]} + + + length="12" + lineageId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]" + name="APP_LAST_UPDATE_USER_DIRECTORY"> + + #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]} + + + length="7" + lineageId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[ADDRESS_USAGE_TYPE_CODE]" + name="ADDRESS_USAGE_TYPE_CODE" + sortKeyPosition="3"> + + #{Package\Load Person Address and Organization Address\Audit Trail 1.Outputs[Derived Column Output].Columns[ADDRESS_USAGE_TYPE_CODE]} + + - - 0 - [dbo].[PIMS_ORGANIZATION_ADDRESS] - - - 1252 - false - 3 - false - false - TABLOCK,CHECK_CONSTRAINTS - 2147483647 - - - - + refId="Package\Load Person Address and Organization Address\Derived Column" + componentClassID="Microsoft.DerivedColumn" + contactInfo="Derived Column;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;0" + description="Creates new column values by applying expressions to transformation input columns. Create new columns or overwrite existing ones. For example, concatenate the values from the 'first name' and 'last name' column to make a 'full name' column." + name="Derived Column" + usesDispositions="true"> + refId="Package\Load Person Address and Organization Address\Derived Column.Inputs[Derived Column Input]" + description="Input to the Derived Column Transformation" + name="Derived Column Input"> - - - - - - + cachedLength="30" + cachedName="ORGANIZATION_APP_CREATE_USER_DIRECTORY" + lineageId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]" /> - - - - - - - - - - - - - - - - - - - - + + name="Derived Column Output" + synchronousInputId="Package\Load Person Address and Organization Address\Derived Column.Inputs[Derived Column Input]"> + refId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_TIME]" + dataType="dbTimeStamp" + errorOrTruncationOperation="Computation" + errorRowDisposition="FailComponent" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_TIME]" + name="ERROR_TIME" + truncationRowDisposition="FailComponent"> + + [GETDATE]() + GETDATE() + + - - - - - - - - 0 - [dbo].[PIMS_PERSON] - - SELECT * -FROM PIMS_PERSON -WHERE APP_CREATE_USERID='APP_PIMS_PROXY_ETL_EDIT'; - - 1252 - false - 0 - - - - - - - - + refId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_OPERATION_NAME]" + dataType="wstr" + errorOrTruncationOperation="Computation" + errorRowDisposition="FailComponent" + length="45" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_OPERATION_NAME]" + name="ERROR_OPERATION_NAME" + truncationRowDisposition="FailComponent"> + + "LOAD PERSON ADDFRESS AND ORGANIZATION ADDRESS" + "LOAD PERSON ADDFRESS AND ORGANIZATION ADDRESS" + + + length="26" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_TASK_NAME]" + name="ERROR_TASK_NAME" + truncationRowDisposition="FailComponent"> + + "ADDRESS ID in PIMS ADDRESS" + "ADDRESS ID in PIMS ADDRESS" + + + length="32" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_ETL_NAME]" + name="ERROR_ETL_NAME" + truncationRowDisposition="FailComponent"> + + "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" + "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" + + + length="69" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_ROW]" + name="ERROR_ROW" + truncationRowDisposition="FailComponent"> + + "Address not found for Interest Holder: " + #{Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]} + "Address not found for Interest Holder: " + APP_CREATE_USER_DIRECTORY + + - - - - - - - - - - - - - - - - - - - - - - - - - + + name="Derived Column Error Output" + synchronousInputId="Package\Load Person Address and Organization Address\Derived Column.Inputs[Derived Column Input]"> - - + + + + + + + + + + + + + + + + + + + [GETDATE]() + GETDATE() + + + + errorOrTruncationOperation="Computation" + errorRowDisposition="FailComponent" + length="45" + lineageId="Package\Load Person Address and Organization Address\Derived Column 1.Outputs[Derived Column Output].Columns[ERROR_OPERATION_NAME]" + name="ERROR_OPERATION_NAME" + truncationRowDisposition="FailComponent"> + + "Load Person Address and Organizartion Address" + "Load Person Address and Organizartion Address" + + + errorOrTruncationOperation="Computation" + errorRowDisposition="FailComponent" + length="26" + lineageId="Package\Load Person Address and Organization Address\Derived Column 1.Outputs[Derived Column Output].Columns[ERROR_TASK_NAME]" + name="ERROR_TASK_NAME" + truncationRowDisposition="FailComponent"> + + "Address ID in PIMS Address" + "Address ID in PIMS Address" + + + + + "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" + "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" + + + + + "Failed to find Address Id for: " + #{Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Output].Columns[PIMS_PERSON_APP_CREATE_USER_DIRECTORY]} + "Failed to find Address Id for: " + PIMS_PERSON_APP_CREATE_USER_DIRECTORY + + + + + + + + + @@ -16144,7 +16705,7 @@ WHERE APP_CREATE_USERID='APP_PIMS_PROXY_ETL_EDIT'; [dbo].[PIMS_PERSON_ADDRESS] + name="OpenRowset">[etl].[ETL_ERROR_LOG] - - + refId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].Columns[ERROR_TIME]" + cachedDataType="dbTimeStamp" + cachedName="ERROR_TIME" + externalMetadataColumnId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_TIME]" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_TIME]" /> + cachedLength="45" + cachedName="ERROR_OPERATION_NAME" + externalMetadataColumnId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_OPERATION_NAME]" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_OPERATION_NAME]" /> + cachedLength="26" + cachedName="ERROR_TASK_NAME" + externalMetadataColumnId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_TASK_NAME]" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_TASK_NAME]" /> + cachedLength="32" + cachedName="ERROR_ETL_NAME" + externalMetadataColumnId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_ETL_NAME]" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_ETL_NAME]" /> + cachedLength="69" + cachedName="ERROR_ROW" + externalMetadataColumnId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_ROW]" + lineageId="Package\Load Person Address and Organization Address\Derived Column.Outputs[Derived Column Output].Columns[ERROR_ROW]" /> - - - - - - - - + name="ERROR_TIME" /> - + length="100" + name="ERROR_OPERATION_NAME" /> - + length="100" + name="ERROR_TASK_NAME" /> - + length="100" + name="ERROR_ETL_NAME" /> + refId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_ROW]" + dataType="nText" + name="ERROR_ROW" /> + refId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_CODE]" + dataType="i4" + name="ERROR_CODE" /> + refId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_COLUMN]" + dataType="i4" + name="ERROR_COLUMN" /> + synchronousInputId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG.Inputs[OLE DB Destination Input]"> @@ -16357,308 +16857,167 @@ WHERE APP_CREATE_USERID='APP_PIMS_PROXY_ETL_EDIT'; - - - - - - - - - - - - - - - - - - - - - - + version="4"> select * from [dbo].[PIMS_ADDRESS] + dataType="System.Int32" + description="The number of seconds before a command times out. A value of 0 indicates an infinite time-out." + name="CommandTimeout">0 select * from (select * from [dbo].[PIMS_ADDRESS]) [refTable] -where [refTable].[STREET_ADDRESS_1] = ? and [refTable].[MUNICIPALITY_NAME] = ? + description="Specifies the name of the database object used to open a rowset." + name="OpenRowset">[etl].[ETL_ERROR_LOG] 0 + dataType="System.String" + description="Specifies the variable that contains the name of the database object used to open a rowset." + name="OpenRowsetVariable"> 2 + dataType="System.String" + description="The SQL command to be executed." + name="SqlCommand" + UITypeEditor="Microsoft.DataTransformationServices.Controls.ModalMultilineStringEditor, Microsoft.DataTransformationServices.Controls, Version=15.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"> 0 + description="Specifies the column code page to use when code page information is unavailable from the data source." + name="DefaultCodePage">1252 0 + dataType="System.Boolean" + description="Forces the use of the DefaultCodePage property value when describing character data." + name="AlwaysUseDefaultCodePage">false 25 + description="Specifies the mode used to access the database." + name="AccessMode" + typeConverter="AccessMode">0 25 + dataType="System.Boolean" + description="Indicates whether the values supplied for identity columns will be copied to the destination. If false, values for identity columns will be auto-generated at the destination. Applies only if fast load is turned on." + name="FastLoadKeepIdentity">false <referenceMetadata><referenceColumns><referenceColumn name="ADDRESS_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="REGION_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DISTRICT_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="PROVINCE_STATE_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="COUNTRY_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_1" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_2" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_3" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="MUNICIPALITY_NAME" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="POSTAL_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/><referenceColumn name="OTHER_COUNTRY" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="LATITUDE" dataType="DT_NUMERIC" length="0" precision="8" scale="6" codePage="0"/><referenceColumn name="LONGITUDE" dataType="DT_NUMERIC" length="0" precision="9" scale="6" codePage="0"/><referenceColumn name="COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="CONCURRENCY_CONTROL_NUMBER" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> + dataType="System.Boolean" + description="Indicates whether the columns containing null will have null inserted in the destination. If false, columns containing null will have their default values inserted at the destination. Applies only if fast load is turned on." + name="FastLoadKeepNulls">false #{Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[CIVIC_ADDRESS]};#{Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]}; + description="Specifies options to be used with fast load. Applies only if fast load is turned on." + name="FastLoadOptions">TABLOCK,CHECK_CONSTRAINTS 1252 - false + description="Specifies when commits are issued during data insertion. A value of 0 specifies that one commit will be issued at the end of data insertion. Applies only if fast load is turned on." + name="FastLoadMaxInsertCommitSize">2147483647 + refId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG 1.Inputs[OLE DB Destination Input]" + errorOrTruncationOperation="Insert" + errorRowDisposition="FailComponent" + hasSideEffects="true" + name="OLE DB Destination Input"> + - - STREET_ADDRESS_1 - - - + cachedLength="45" + cachedName="ERROR_OPERATION_NAME" + externalMetadataColumnId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG 1.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_OPERATION_NAME]" + lineageId="Package\Load Person Address and Organization Address\Derived Column 1.Outputs[Derived Column Output].Columns[ERROR_OPERATION_NAME]" /> - - MUNICIPALITY_NAME - - - + cachedLength="26" + cachedName="ERROR_TASK_NAME" + externalMetadataColumnId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG 1.Inputs[OLE DB Destination Input].ExternalColumns[ERROR_TASK_NAME]" + lineageId="Package\Load Person Address and Organization Address\Derived Column 1.Outputs[Derived Column Output].Columns[ERROR_TASK_NAME]" /> + + - + + + + + + + + + - - - - ADDRESS_ID - - - - - REGION_CODE - - - - - DISTRICT_CODE - - - - - STREET_ADDRESS_1 - - - - - MUNICIPALITY_NAME - - - - - - - - - + name="OLE DB Destination Error Output" + synchronousInputId="Package\Load Person Address and Organization Address\ETL_ERROR_LOG 1.Inputs[OLE DB Destination Input]"> @@ -16667,495 +17026,482 @@ where [refTable].[STREET_ADDRESS_1] = ? and [refTable].[MUNICIPALITY_NAME] = ? + version="7"> + 0 [dbo].[PIMS_ORGANIZATION] + + select * from "APP_PAM"."PAM_TAKE_PROPERTY" + UITypeEditor="Microsoft.DataTransformationServices.Controls.ModalMultilineStringEditor, Microsoft.DataTransformationServices.Controls, Version=15.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91"> select * from (select * from "APP_PAM"."PAM_TAKE_PROPERTY") "refTable" -where "refTable"."PROPERTY_ID" = ? + description="The variable that contains the SQL command to be executed." + name="SqlCommandVariable"> 0 + description="Specifies the column code page to use when code page information is unavailable from the data source." + name="DefaultCodePage">1252 0 + dataType="System.Boolean" + description="Forces the use of the DefaultCodePage property value when describing character data." + name="AlwaysUseDefaultCodePage">false 1 - 0 - 25 - 25 - <referenceMetadata><referenceColumns><referenceColumn name="TAKE_ID" dataType="DT_NUMERIC" length="0" precision="10" scale="0" codePage="0"/><referenceColumn name="PROPERTY_ID" dataType="DT_NUMERIC" length="0" precision="10" scale="0" codePage="0"/><referenceColumn name="AREA" dataType="DT_NUMERIC" length="0" precision="8" scale="4" codePage="0"/><referenceColumn name="AREA_UNIT_CODE" dataType="DT_STR" length="2" precision="0" scale="0" codePage="1252"/><referenceColumn name="LAST_UPDATE_DATETIME" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="LAST_UPDATE_USERID" dataType="DT_STR" length="30" precision="0" scale="0" codePage="1252"/></referenceColumns></referenceMetadata> + description="Specifies the mode used to access the database." + name="AccessMode" + typeConverter="AccessMode">0 #{Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[PROPERTY_ID]}; - 1252 - false + description="The mappings between the parameters in the SQL command and variables." + name="ParameterMapping"> - - - - - - PROPERTY_ID - - - - - - - - - - - - - AREA - - - - - AREA_UNIT_CODE - - - - - - - - - - - - - - - - - - - - - - - + refId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output]" + name="OLE DB Source Output"> - - "APP_PIMS_PROXY_ETL_EDIT" - "APP_PIMS_PROXY_ETL_EDIT" - - - - - "place_holder" - "place_holder" - - + externalMetadataColumnId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].ExternalColumns[ORGANIZATION_ID]" + lineageId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_ID]" + name="ORGANIZATION_ID" + truncationRowDisposition="FailComponent" /> - - "APP_PIMS_PROXY_ETL_EDIT" - "APP_PIMS_PROXY_ETL_EDIT" - - + externalMetadataColumnId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].ExternalColumns[APP_CREATE_USER_DIRECTORY]" + length="30" + lineageId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[ORGANIZATION_APP_CREATE_USER_DIRECTORY]" + name="ORGANIZATION_APP_CREATE_USER_DIRECTORY" + truncationRowDisposition="FailComponent" /> - - "place_holder" - "place_holder" - - + externalMetadataColumnId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].ExternalColumns[INCORPORATION_NUMBER]" + length="50" + lineageId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Output].Columns[INCORPORATION_NUMBER]" + name="INCORPORATION_NUMBER" + truncationRowDisposition="FailComponent" /> - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + name="OLE DB Source Error Output"> - - - - - - - - - - - - - - - - "COREOPER" - "COREOPER" - - - - - - - + refId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Error Output].Columns[ORGANIZATION_ID]" + dataType="i8" + lineageId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Error Output].Columns[ORGANIZATION_ID]" + name="ORGANIZATION_ID" /> + refId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Error Output].Columns[APP_CREATE_USER_DIRECTORY]" + dataType="wstr" + length="30" + lineageId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Error Output].Columns[APP_CREATE_USER_DIRECTORY]" + name="APP_CREATE_USER_DIRECTORY" /> + refId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Error Output].Columns[INCORPORATION_NUMBER]" + dataType="wstr" + length="50" + lineageId="Package\Load Person Address and Organization Address\PIMS Organization.Outputs[OLE DB Source Error Output].Columns[INCORPORATION_NUMBER]" + name="INCORPORATION_NUMBER" /> - - - - - - - [REPLACENULL](#{Package\Load Properties\Address Id, Region and District Code.Outputs[Lookup Match Output].Columns[REGION_CODE]},1) - REPLACENULL(REGION_CODE,1) - - + refId="Package\Load Person Address and Organization Address\PIMS ORGANIZATION_ADDRESS" + componentClassID="Microsoft.OLEDBDestination" + contactInfo="OLE DB Destination;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;4" + description="OLE DB Destination" + name="PIMS ORGANIZATION_ADDRESS" + usesDispositions="true" + version="4"> + + 0 + [dbo].[PIMS_ORGANIZATION_ADDRESS] + + + 1252 + false + 3 + false + false + TABLOCK,CHECK_CONSTRAINTS + 2147483647 + + + + + + + - - [REPLACENULL](#{Package\Load Properties\Address Id, Region and District Code.Outputs[Lookup Match Output].Columns[DISTRICT_CODE]},#{Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]} == "VICTORIA" ? 2 : 1) - REPLACENULL(DISTRICT_CODE,[PAM Property].MUNICIPALITY_NAME == "VICTORIA" ? 2 : 1) - - + refId="Package\Load Person Address and Organization Address\PIMS ORGANIZATION_ADDRESS.Inputs[OLE DB Destination Input].Columns[ORGANIZATION_ID]" + cachedDataType="i8" + cachedName="ORGANIZATION_ID" + cachedSortKeyPosition="1" + externalMetadataColumnId="Package\Load Person Address and Organization Address\PIMS ORGANIZATION_ADDRESS.Inputs[OLE DB Destination Input].ExternalColumns[ORGANIZATION_ID]" + lineageId="Package\Load Person Address and Organization Address\Deduplicate Organization Addresses.Outputs[Sort Output].Columns[ORGANIZATION_ID]" /> + + + + + + - + + + + + + + + + + + + + + + + + + + + - - - + name="OLE DB Destination Error Output" + synchronousInputId="Package\Load Person Address and Organization Address\PIMS ORGANIZATION_ADDRESS.Inputs[OLE DB Destination Input]"> @@ -17164,347 +17510,468 @@ where "refTable"."PROPERTY_ID" = ? - - - - - - - - + refId="Package\Load Person Address and Organization Address\PIMS PERSON" + componentClassID="Microsoft.OLEDBSource" + contactInfo="OLE DB Source;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;7" + description="OLE DB Source" + name="PIMS PERSON" + usesDispositions="true" + version="7"> + + 0 + [dbo].[PIMS_PERSON] + + SELECT * +FROM PIMS_PERSON +WHERE APP_CREATE_USERID='APP_PIMS_PROXY_ETL_EDIT'; + + 1252 + false + 0 + + + + + + refId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Output]" + name="OLE DB Source Output"> + - - #{Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Match Output].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]} - false - - + externalMetadataColumnId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Output].ExternalColumns[APP_CREATE_USER_DIRECTORY]" + length="30" + lineageId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Output].Columns[PIMS_PERSON_APP_CREATE_USER_DIRECTORY]" + name="PIMS_PERSON_APP_CREATE_USER_DIRECTORY" + truncationRowDisposition="FailComponent" /> + - + + + + + + + + + + + + + + + + + + + + + + + + + + name="OLE DB Source Error Output"> - - - - - - - - - - - - - - - - - "HA" - "HA" - - - - 0000.0000 - 0000.0000 - - - - - - - + refId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Error Output].Columns[PERSON_ID]" + dataType="i8" + lineageId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Error Output].Columns[PERSON_ID]" + name="PERSON_ID" /> + refId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Error Output].Columns[APP_CREATE_USER_DIRECTORY]" + dataType="wstr" + length="30" + lineageId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Error Output].Columns[APP_CREATE_USER_DIRECTORY]" + name="APP_CREATE_USER_DIRECTORY" /> + refId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Error Output].Columns[ADDRESS_COMMENT]" + dataType="wstr" + length="2000" + lineageId="Package\Load Person Address and Organization Address\PIMS PERSON.Outputs[OLE DB Source Error Output].Columns[ADDRESS_COMMENT]" + name="ADDRESS_COMMENT" /> + refId="Package\Load Person Address and Organization Address\PIMS PERSON_ADDRESS" + componentClassID="Microsoft.OLEDBDestination" + contactInfo="OLE DB Destination;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;4" + description="OLE DB Destination" + name="PIMS PERSON_ADDRESS" + usesDispositions="true" + version="4"> + + 0 + [dbo].[PIMS_PERSON_ADDRESS] + + + 1252 + false + 3 + false + false + TABLOCK,CHECK_CONSTRAINTS + 2147483647 + + + + + refId="Package\Load Person Address and Organization Address\PIMS PERSON_ADDRESS.Inputs[OLE DB Destination Input]" + errorOrTruncationOperation="Insert" + errorRowDisposition="FailComponent" + hasSideEffects="true" + name="OLE DB Destination Input"> + + + cachedLength="23" + cachedName="AUDIT_TRAIL_APP_CREATE_USERID" + externalMetadataColumnId="Package\Load Person Address and Organization Address\PIMS PERSON_ADDRESS.Inputs[OLE DB Destination Input].ExternalColumns[APP_CREATE_USERID]" + lineageId="Package\Load Person Address and Organization Address\Audit Trail.Outputs[Derived Column Output].Columns[AUDIT_TRAIL_APP_CREATE_USERID]" /> + + + + - - - - - - - - - "Load Properties" - "Load Properties" - - - + + + + - - "Store property in PIMS_PROPERTY" - "Store property in PIMS_PROPERTY" - - - + + + + - - "MUNICIPALITY_NAME: " + [REPLACENULL](#{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]},"NULL") - "MUNICIPALITY_NAME: " + REPLACENULL(MUNICIPALITY_NAME,"NULL") - - - + + + - - [GETDATE]() - GETDATE() - - - + - - "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" - "PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" - - - - - + length="30" + name="APP_LAST_UPDATE_USERID" /> + + + + + + + + + + + name="OLE DB Destination Error Output" + synchronousInputId="Package\Load Person Address and Organization Address\PIMS PERSON_ADDRESS.Inputs[OLE DB Destination Input]"> @@ -17512,241 +17979,308 @@ where "refTable"."PROPERTY_ID" = ? - - - 0 - [etl].[ETL_ERROR_LOG] - - - 1252 - false - 3 - false - false - TABLOCK,CHECK_CONSTRAINTS + + + + + + + + + + + + + + + + + + + + + + + + + select * from [dbo].[PIMS_ADDRESS] + select * from (select * from [dbo].[PIMS_ADDRESS]) [refTable] +where [refTable].[STREET_ADDRESS_1] = ? and [refTable].[MUNICIPALITY_NAME] = ? 2147483647 + description="Specifies the type of connection used to access the reference dataset." + name="ConnectionType" + typeConverter="LookupConnectionType">0 + 2 + 0 + 0 + 25 + 25 + <referenceMetadata><referenceColumns><referenceColumn name="ADDRESS_ID" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="REGION_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DISTRICT_CODE" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="PROVINCE_STATE_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="COUNTRY_ID" dataType="DT_I2" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_1" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_2" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="STREET_ADDRESS_3" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="MUNICIPALITY_NAME" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="POSTAL_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/><referenceColumn name="OTHER_COUNTRY" dataType="DT_WSTR" length="200" precision="0" scale="0" codePage="0"/><referenceColumn name="LATITUDE" dataType="DT_NUMERIC" length="0" precision="8" scale="6" codePage="0"/><referenceColumn name="LONGITUDE" dataType="DT_NUMERIC" length="0" precision="9" scale="6" codePage="0"/><referenceColumn name="COMMENT" dataType="DT_WSTR" length="2000" precision="0" scale="0" codePage="0"/><referenceColumn name="CONCURRENCY_CONTROL_NUMBER" dataType="DT_I8" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_CREATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_GUID" dataType="DT_GUID" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="APP_LAST_UPDATE_USER_DIRECTORY" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_CREATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_TIMESTAMP" dataType="DT_DBTIMESTAMP" length="0" precision="0" scale="0" codePage="0"/><referenceColumn name="DB_LAST_UPDATE_USERID" dataType="DT_WSTR" length="30" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> + #{Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[CIVIC_ADDRESS]};#{Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]}; + 1252 + false + refId="Package\Load Properties\Address Id, Region and District Code.Inputs[Lookup Input]" + name="Lookup Input"> - - - + cachedLength="100" + cachedName="CIVIC_ADDRESS" + lineageId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[CIVIC_ADDRESS]"> + + STREET_ADDRESS_1 + + + + cachedLength="40" + cachedName="MUNICIPALITY_NAME" + lineageId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]"> + + MUNICIPALITY_NAME + + + - - - - - - - - - + + name="Lookup Match Output" + synchronousInputId="Package\Load Properties\Address Id, Region and District Code.Inputs[Lookup Input]"> + refId="Package\Load Properties\Address Id, Region and District Code.Outputs[Lookup Match Output].Columns[ADDRESS_ID]" + dataType="i8" + errorOrTruncationOperation="Copy Column" + lineageId="Package\Load Properties\Address Id, Region and District Code.Outputs[Lookup Match Output].Columns[ADDRESS_ID]" + name="ADDRESS_ID" + truncationRowDisposition="FailComponent"> + + ADDRESS_ID + + - - - - - - - - - - - - - - + refId="Package\Load Properties\Address Id, Region and District Code.Outputs[Lookup Match Output].Columns[REGION_CODE]" + dataType="i2" + errorOrTruncationOperation="Copy Column" + lineageId="Package\Load Properties\Address Id, Region and District Code.Outputs[Lookup Match Output].Columns[REGION_CODE]" + name="REGION_CODE" + truncationRowDisposition="FailComponent"> + + REGION_CODE + + + + DISTRICT_CODE + + + "LAND" + description="Specifies the column in the reference table from which a column is copied." + name="CopyFromReferenceColumn">STREET_ADDRESS_1 + + + + "LAND" + description="Specifies the column in the reference table from which a column is copied." + name="CopyFromReferenceColumn">MUNICIPALITY_NAME + + + + name="Lookup Error Output" + synchronousInputId="Package\Load Properties\Address Id, Region and District Code.Inputs[Lookup Input]"> @@ -17755,1060 +18289,842 @@ where "refTable"."PROPERTY_ID" = ? + version="6"> - 0 "APP_PAM"."PAM_PROPERTY" + description="Specifies the SQL statement that generates the lookup table." + expressionType="Notify" + name="SqlCommand" + UITypeEditor="Microsoft.DataTransformationServices.Controls.ModalMultilineStringEditor, Microsoft.DataTransformationServices.Controls, Version=15.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91">select property_id,area,cast(area_unit_code as nvarchar2(20)) as area_unit_code from app_pam.pam_take_property + description="Specifies a SQL statement that uses parameters to generate the lookup table." + expressionType="Notify" + name="SqlCommandParam" + UITypeEditor="Microsoft.DataTransformationServices.Controls.ModalMultilineStringEditor, Microsoft.DataTransformationServices.Controls, Version=15.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91">select * from (select property_id,area,cast(area_unit_code as nvarchar2(20)) as area_unit_code from app_pam.pam_take_property) "refTable" +where "refTable"."PROPERTY_ID" = ? + 0 + 0 + 1 + 0 + 25 + 25 SELECT * -FROM APP_PAM.PAM_PROPERTY -WHERE PID_NO IS NOT NULL + description="Indicates whether to reference metadata in an XML format." + name="ReferenceMetadataXml"><referenceMetadata><referenceColumns><referenceColumn name="PROPERTY_ID" dataType="DT_NUMERIC" length="0" precision="10" scale="0" codePage="0"/><referenceColumn name="AREA" dataType="DT_NUMERIC" length="0" precision="8" scale="4" codePage="0"/><referenceColumn name="AREA_UNIT_CODE" dataType="DT_WSTR" length="20" precision="0" scale="0" codePage="0"/></referenceColumns></referenceMetadata> + description="Specifies the list of lineage identifiers that map to the parameters that the SQL statement in the SQLCommand property uses. Entries in the list are separated by semicolons." + name="ParameterMap">#{Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[PROPERTY_ID]}; 1252 false - 2 - + description="Determines whether duplicate keys in the reference data should be treated as errors when full cache mode is used." + name="TreatDuplicateKeysAsError">false + + + + + + PROPERTY_ID + + + + + + + + refId="Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Match Output]" + errorOrTruncationOperation="Lookup" + exclusionGroup="1" + name="Lookup Match Output" + synchronousInputId="Package\Load Properties\Area and Area Unit Code.Inputs[Lookup Input]"> + refId="Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Match Output].Columns[LAND_AREA]" + dataType="numeric" + errorOrTruncationOperation="Copy Column" + lineageId="Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Match Output].Columns[LAND_AREA]" + name="LAND_AREA" + precision="8" + scale="4" + truncationRowDisposition="FailComponent"> + + AREA + + + errorOrTruncationOperation="Copy Column" + length="20" + lineageId="Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Match Output].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]" + name="PROPERTY_AREA_UNIT_TYPE_CODE" + truncationRowDisposition="FailComponent"> + + AREA_UNIT_CODE + + + + + + + + + + + refId="Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Error Output].Columns[ErrorCode]" + dataType="i4" + lineageId="Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Error Output].Columns[ErrorCode]" + name="ErrorCode" + specialFlags="1" /> + refId="Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Error Output].Columns[ErrorColumn]" + dataType="i4" + lineageId="Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Error Output].Columns[ErrorColumn]" + name="ErrorColumn" + specialFlags="2" /> + + + + + + + + + + + + + + + length="23" + lineageId="Package\Load Properties\Audit Trail.Outputs[Derived Column Output].Columns[APP_CREATE_USERID]" + name="APP_CREATE_USERID" + truncationRowDisposition="FailComponent"> + + "APP_PIMS_PROXY_ETL_EDIT" + "APP_PIMS_PROXY_ETL_EDIT" + + + length="12" + lineageId="Package\Load Properties\Audit Trail.Outputs[Derived Column Output].Columns[APP_CREATE_USER_DIRECTORY]" + name="APP_CREATE_USER_DIRECTORY" + truncationRowDisposition="FailComponent"> + + "place_holder" + "place_holder" + + + length="23" + lineageId="Package\Load Properties\Audit Trail.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USERID]" + name="APP_LAST_UPDATE_USERID" + truncationRowDisposition="FailComponent"> + + "APP_PIMS_PROXY_ETL_EDIT" + "APP_PIMS_PROXY_ETL_EDIT" + + + length="12" + lineageId="Package\Load Properties\Audit Trail.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]" + name="APP_LAST_UPDATE_USER_DIRECTORY" + truncationRowDisposition="FailComponent"> + + "place_holder" + "place_holder" + + + + + + + + refId="Package\Load Properties\Audit Trail.Outputs[Derived Column Error Output].Columns[ErrorCode]" + dataType="i4" + lineageId="Package\Load Properties\Audit Trail.Outputs[Derived Column Error Output].Columns[ErrorCode]" + name="ErrorCode" + specialFlags="1" /> + - - - - - - - - - - + + + + + + + + + + + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + "COREOPER" + "COREOPER" + + + + + + + + + + + + + + + + + + + + + + [REPLACENULL](#{Package\Load Properties\Address Id, Region and District Code.Outputs[Lookup Match Output].Columns[REGION_CODE]},1) + REPLACENULL(REGION_CODE,1) + + + + + [REPLACENULL](#{Package\Load Properties\Address Id, Region and District Code.Outputs[Lookup Match Output].Columns[DISTRICT_CODE]},#{Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]} == "VICTORIA" ? 2 : 1) + REPLACENULL(DISTRICT_CODE,[PAM Property].MUNICIPALITY_NAME == "VICTORIA" ? 2 : 1) + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - + lineageId="Package\Load Properties\Data Conversion.Outputs[Data Conversion Output].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]" + name="PROPERTY_AREA_UNIT_TYPE_CODE" + truncationRowDisposition="FailComponent"> + + #{Package\Load Properties\Area and Area Unit Code.Outputs[Lookup Match Output].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]} + false + + + + + name="Data Conversion Error Output" + synchronousInputId="Package\Load Properties\Data Conversion.Inputs[Data Conversion Input]"> + + + + + + + + + + + + + + - - - - - - - + lineageId="Package\Load Properties\Derived Column.Outputs[Derived Column Output].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]" + name="PROPERTY_AREA_UNIT_TYPE_CODE" + truncationRowDisposition="FailComponent"> + + "HA" + "HA" + + + errorOrTruncationOperation="Computation" + errorRowDisposition="FailComponent" + lineageId="Package\Load Properties\Derived Column.Outputs[Derived Column Output].Columns[LAND_AREA]" + name="LAND_AREA" + precision="8" + scale="4" + truncationRowDisposition="FailComponent"> + + 0000.0000 + 0000.0000 + + + + + + + + + - - 0 - [dbo].[PIMS_PROPERTY] - - - 1252 - false - 3 - false - false - TABLOCK,CHECK_CONSTRAINTS - 2147483647 - - - - + refId="Package\Load Properties\Derived Column 1" + componentClassID="Microsoft.DerivedColumn" + contactInfo="Derived Column;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;0" + description="Creates new column values by applying expressions to transformation input columns. Create new columns or overwrite existing ones. For example, concatenate the values from the 'first name' and 'last name' column to make a 'full name' column." + name="Derived Column 1" + usesDispositions="true"> + refId="Package\Load Properties\Derived Column 1.Inputs[Derived Column Input]" + description="Input to the Derived Column Transformation" + name="Derived Column Input"> - - - - - - - - - - - - - - - - - - - - + cachedLength="200" + cachedName="MUNICIPALITY_NAME" + lineageId="Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]" /> - - - - - - - - - + + + + + + - + + "Load Properties" + "Load Properties" + + + - - + + "Store property in PIMS_PROPERTY" + "Store property in PIMS_PROPERTY" + + + - + + "MUNICIPALITY_NAME: " + [REPLACENULL](#{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]},"NULL") + "MUNICIPALITY_NAME: " + REPLACENULL(MUNICIPALITY_NAME,"NULL") + + + + + [GETDATE]() + GETDATE() + + + - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - [GETDATE]() + name="Expression">"PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" GETDATE() + name="FriendlyExpression">"PAM_LOAD_PAIMS_TO_PIMS_DATASET_2" + synchronousInputId="Package\Load Properties\Derived Column 1.Inputs[Derived Column Input]"> @@ -18817,94 +19133,166 @@ WHERE PID_NO IS NOT NULL + refId="Package\Load Properties\Error Log" + componentClassID="Microsoft.OLEDBDestination" + contactInfo="OLE DB Destination;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;4" + description="OLE DB Destination" + name="Error Log" + usesDispositions="true" + version="4"> + + 0 + [etl].[ETL_ERROR_LOG] + + + 1252 + false + 3 + false + false + TABLOCK,CHECK_CONSTRAINTS + 2147483647 + + + + - + refId="Package\Load Properties\Error Log.Inputs[OLE DB Destination Input]" + errorOrTruncationOperation="Insert" + errorRowDisposition="FailComponent" + hasSideEffects="true" + name="OLE DB Destination Input"> + + + + + + + + + + + + + + + + - - - - "PAIMS" - "PAIMS" - - - - - [GETDATE]() - GETDATE() - - - - - - + name="OLE DB Destination Error Output" + synchronousInputId="Package\Load Properties\Error Log.Inputs[OLE DB Destination Input]"> @@ -18913,15 +19301,15 @@ WHERE PID_NO IS NOT NULL @@ -18929,56 +19317,56 @@ WHERE PID_NO IS NOT NULL + synchronousInputId="Package\Load Properties\LAND as PROPERTY_TYPE_CODE.Inputs[Derived Column Input]"> "FEESIMP" + name="Expression">"LAND" "FEESIMP" + name="FriendlyExpression">"LAND" + synchronousInputId="Package\Load Properties\LAND as PROPERTY_TYPE_CODE.Inputs[Derived Column Input]"> @@ -18987,4194 +19375,4108 @@ WHERE PID_NO IS NOT NULL - - - - - + refId="Package\Load Properties\PAM Property" + componentClassID="Microsoft.OLEDBSource" + contactInfo="OLE DB Source;Microsoft Corporation; Microsoft SQL Server; (C) Microsoft Corporation; All Rights Reserved; http://www.microsoft.com/sql/support;7" + description="OLE DB Source" + name="PAM Property" + usesDispositions="true" + validateExternalMetadata="False" + version="7"> + + 0 + "APP_PAM"."PAM_PROPERTY" + + SELECT * +FROM APP_PAM.PAM_PROPERTY +WHERE PID_NO IS NOT NULL + + 1252 + false + 2 + + + + + + refId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output]" + name="OLE DB Source Output"> - - "UNKNOWN" - "UNKNOWN" - - - - - - - + externalMetadataColumnId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].ExternalColumns[CIVIC_ADDRESS]" + length="100" + lineageId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[CIVIC_ADDRESS]" + name="CIVIC_ADDRESS" + truncationRowDisposition="FailComponent" /> + refId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]" + dataType="wstr" + errorOrTruncationOperation="Conversion" + errorRowDisposition="FailComponent" + externalMetadataColumnId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].ExternalColumns[CITY]" + length="40" + lineageId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[MUNICIPALITY_NAME]" + name="MUNICIPALITY_NAME" + truncationRowDisposition="FailComponent" /> - - - - - - - - - - - - - - + refId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[DESCRIPTION]" + dataType="wstr" + errorOrTruncationOperation="Conversion" + errorRowDisposition="FailComponent" + externalMetadataColumnId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].ExternalColumns[DESCRIPTION]" + length="2000" + lineageId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[DESCRIPTION]" + name="DESCRIPTION" + truncationRowDisposition="FailComponent" /> + + + - - "TM" - "TM" - - - - - - - + lineageId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[ZONING]" + name="ZONING" + truncationRowDisposition="FailComponent" /> + refId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[ZONING_POTENTIAL]" + dataType="wstr" + errorOrTruncationOperation="Conversion" + errorRowDisposition="FailComponent" + externalMetadataColumnId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].ExternalColumns[LAND_USE_DESCRIPTION]" + length="30" + lineageId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[ZONING_POTENTIAL]" + name="ZONING_POTENTIAL" + truncationRowDisposition="FailComponent" /> + refId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[PROPERTY_ID]" + dataType="numeric" + errorOrTruncationOperation="Conversion" + errorRowDisposition="FailComponent" + externalMetadataColumnId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].ExternalColumns[PROPERTY_ID]" + lineageId="Package\Load Properties\PAM Property.Outputs[OLE DB Source Output].Columns[PROPERTY_ID]" + name="PROPERTY_ID" + precision="10" + truncationRowDisposition="FailComponent" /> - - - - - - - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[CIVIC_ADDRESS]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[DESCRIPTION]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PID]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PIN]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[LAND_LEGAL_DESCRIPTION]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ZONING]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ZONING_POTENTIAL]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_ID]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_TYPE_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_CLASSIFICATION_TYPE_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ADDRESS_ID]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[REGION_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[DISTRICT_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_TENURE_TYPE_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[LAND_AREA]} - - - - - - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[CIVIC_ADDRESS]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[DESCRIPTION]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PID]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PIN]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[LAND_LEGAL_DESCRIPTION]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ZONING]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ZONING_POTENTIAL]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_ID]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_TYPE_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_CLASSIFICATION_TYPE_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ADDRESS_ID]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[REGION_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[DISTRICT_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_TENURE_TYPE_CODE]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[LAND_AREA]} - - - - - #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]} - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - "RESIDNT" - "RESIDNT" - - - - - (DT_UI2)1 - (DT_UI2)1 - - - - - "APP_PIMS_PROXY_ETL_EDIT" - "APP_PIMS_PROXY_ETL_EDIT" - - - - - "place_holder" - "place_holder" - - - - - "APP_PIMS_PROXY_ETL_EDIT" - "APP_PIMS_PROXY_ETL_EDIT" - - - - - "place_holder" - "place_holder" - - - - - (DT_UI2)1 - (DT_UI2)1 - - - - - - - - - - - - - - - - - true - -1 - - - - - - - 0 - 1 - - - - - 0 - 2 - - - - - 0 - 3 - - - - - 0 - 4 - - - - - 0 - 5 - - - - - 0 - 6 - - - - - 0 - 7 - - - - - 0 - 8 - - - - - 0 - 9 - - - - - 0 - 10 - - - - - 0 - 11 - - - - - 0 - 12 - - - - - 0 - 13 - - - - - 0 - 14 - - - - - 0 - 15 - - - - - 0 - 16 - - - - - 0 - 17 - - - - - 0 - 18 - - - - - 0 - 19 - - - - - 0 - 20 - - - - - 0 - 21 - - - - - 0 - 22 - - - - - - - - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[PROPERTY_ID]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[REGION_NO]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[DISTRICT_NO]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[DESCRIPTION]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[FULL_LEGAL_DESCRIPTION]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[FILE_NUMBER]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[FILE_NUMBER_SUFFIX]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[PID_NO]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[PIN]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[CIVIC_ADDRESS]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[CITY]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[PROPERTY_TENURE_TYPE_CODE]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[COMMENTS]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[LAND_USE_DESCRIPTION]} - - - - - #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[ACTUAL_LAND_USE_CODE]} - - - - - #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[ADDRESS_USAGE_TYPE_CODE]} - - - - - #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[COUNTRY_ID]} - - - - - #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[APP_CREATE_USERID]} - - - - - #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[APP_CREATE_USER_DIRECTORY]} - - - - - #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USERID]} - - - - - #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]} - - - - - #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[PROVINCE_STATE_ID]} - - - - - - - - - - 0 - "APP_PAM"."PAM_PROPERTY" - - - - 1252 - false - 0 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - 0 - [dbo].[PIMS_ADDRESS] - - - 1252 - false - 3 - false - false - TABLOCK,CHECK_CONSTRAINTS,ROWS_PER_BATCH = 1 - 2147483647 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + [dbo].[PIMS_PROPERTY] + + + 1252 + false + 3 + false + false + TABLOCK,CHECK_CONSTRAINTS + 2147483647 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + [GETDATE]() + GETDATE() + + + + + + + + + + + + + + + + + + + + + + + + + + "PAIMS" + "PAIMS" + + + + + [GETDATE]() + GETDATE() + + + + + + + + + + + + + + + + + + + + + + + + + + "FEESIMP" + "FEESIMP" + + + + + + + + + + + + + + + + + + + + + + + + + + "UNKNOWN" + "UNKNOWN" + + + + + + + + + + + + + + + + + + + + + + + + + + "TM" + "TM" + + + + + + + + + + + + + + + + + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[CIVIC_ADDRESS]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[DESCRIPTION]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PID]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PIN]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[LAND_LEGAL_DESCRIPTION]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ZONING]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ZONING_POTENTIAL]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_ID]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_TYPE_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_CLASSIFICATION_TYPE_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ADDRESS_ID]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[REGION_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[DISTRICT_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_TENURE_TYPE_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[LAND_AREA]} + + + + + + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[CIVIC_ADDRESS]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[MUNICIPALITY_NAME]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[DESCRIPTION]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PID]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PIN]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[LAND_LEGAL_DESCRIPTION]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ZONING]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ZONING_POTENTIAL]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_ID]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_TYPE_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_CLASSIFICATION_TYPE_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[ADDRESS_ID]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[REGION_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[DISTRICT_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[STREET_ADDRESS_1]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_TENURE_TYPE_CODE]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[LAND_AREA]} + + + + + #{Package\Load Properties\Union All.Outputs[Union All Output 1].Columns[PROPERTY_AREA_UNIT_TYPE_CODE]} + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + "RESIDNT" + "RESIDNT" + + + + + (DT_UI2)1 + (DT_UI2)1 + + + + + "APP_PIMS_PROXY_ETL_EDIT" + "APP_PIMS_PROXY_ETL_EDIT" + + + + + "place_holder" + "place_holder" + + + + + "APP_PIMS_PROXY_ETL_EDIT" + "APP_PIMS_PROXY_ETL_EDIT" + + + + + "place_holder" + "place_holder" + + + + + (DT_UI2)1 + (DT_UI2)1 + + + + + + + + + + + + + + + + + true + -1 + + + + + + + 0 + 1 + + + + + 0 + 2 + + + + + 0 + 3 + + + + + 0 + 4 + + + + + 0 + 5 + + + + + 0 + 6 + + + + + 0 + 7 + + + + + 0 + 8 + + + + + 0 + 9 + + + + + 0 + 10 + + + + + 0 + 11 + + + + + 0 + 12 + + + + + 0 + 13 + + + + + 0 + 14 + + + + + 0 + 15 + + + + + 0 + 16 + + + + + 0 + 17 + + + + + 0 + 18 + + + + + 0 + 19 + + + + + 0 + 20 + + + + + 0 + 21 + + + + + 0 + 22 + + + + + + + + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[PROPERTY_ID]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[REGION_NO]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[DISTRICT_NO]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[DESCRIPTION]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[FULL_LEGAL_DESCRIPTION]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[FILE_NUMBER]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[FILE_NUMBER_SUFFIX]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[PID_NO]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[PIN]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[CIVIC_ADDRESS]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[CITY]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[PROPERTY_TENURE_TYPE_CODE]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[COMMENTS]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[LAND_USE_DESCRIPTION]} + + + + + #{Package\Load Property Addresses\PAM_PROPERTY.Outputs[OLE DB Source Output].Columns[ACTUAL_LAND_USE_CODE]} + + + + + #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[ADDRESS_USAGE_TYPE_CODE]} + + + + + #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[COUNTRY_ID]} + + + + + #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[APP_CREATE_USERID]} + + + + + #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[APP_CREATE_USER_DIRECTORY]} + + + + + #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USERID]} + + + + + #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[APP_LAST_UPDATE_USER_DIRECTORY]} + + + + + #{Package\Load Property Addresses\Audit Trail.Outputs[Derived Column Output].Columns[PROVINCE_STATE_ID]} + + + + + + + + + + 0 + "APP_PAM"."PAM_PROPERTY" + + + + 1252 + false + 0 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 0 + [dbo].[PIMS_ADDRESS] + + + 1252 + false + 3 + false + false + TABLOCK,CHECK_CONSTRAINTS,ROWS_PER_BATCH = 1 + 2147483647 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Id="Package.PrecedenceConstraints[Constraint]" + TopLeft="420.333324127727,1021.40000080586"> + End="0,49.5666677480281"> + End="0,49.5666677480281" /> @@ -23184,31 +23486,19 @@ WHERE PID_NO IS NOT NULL + Id="Package.PrecedenceConstraints[Constraint 1]" + TopLeft="419.378778989267,1120.46666855388"> + End="0,41.209092257817"> - - - - + End="0,41.209092257817" /> @@ -23218,19 +23508,19 @@ WHERE PID_NO IS NOT NULL + Id="Package.PrecedenceConstraints[Constraint 11]" + TopLeft="416.886359236759,1378"> + End="0,24.384854722553"> + End="0,24.384854722553" /> @@ -23261,54 +23551,24 @@ WHERE PID_NO IS NOT NULL + - - - - - - - - - - - - - - + Id="Package.PrecedenceConstraints[Constraint 3]" + TopLeft="423.582052640889,919.296774161296"> + End="0,52.6032266445587"> - - - - + End="0,52.6032266445587" /> @@ -23317,20 +23577,24 @@ WHERE PID_NO IS NOT NULL + + Id="Package.PrecedenceConstraints[Constraint 2]" + TopLeft="420.581352781603,1211.1757608117"> + End="0,33.0855253245384"> + End="0,33.0855253245384" /> @@ -23340,31 +23604,19 @@ WHERE PID_NO IS NOT NULL + Id="Package.PrecedenceConstraints[Constraint 4]" + TopLeft="420.502568990851,1293.36128613624"> + End="0,35.1387138637617"> - - - - + End="0,35.1387138637617" /> @@ -23386,7 +23638,7 @@ WHERE PID_NO IS NOT NULL Id="Package\Load Contact Method\Data Conversion 2" TopLeft="1194.95239658204,232" /> Id="Package\Load Contact Method\Data Conversion 1" TopLeft="800,232" /> Id="Package\Load Contact Method\PIMS_CONTACT_METHOD FOR PERSON" TopLeft="2033.85714285714,680.142857142857" /> Id="Package\Load Contact Method\PAM_INTEREST_HOLDER - HOME_PHONE_NO" TopLeft="280.952396582042,162.733333450423" /> Id="Package\Load Contact Method\Derived Column" TopLeft="1780,586" /> Id="Package\Load Contact Method\CONTACT_METHOD_TYPE_CODE - WORKEMAIL" TopLeft="1905.1666241818,301.399999338786" /> Id="Package\Load Contact Method\PAM_INTEREST_HOLDER - WORK_PHONE_NO" TopLeft="685.238110867757,167.190476307566" /> Id="Package\Load Contact Method\Data Conversion 5" TopLeft="1061,627" /> Id="Package\Load Contact Method\ETL ERROR LOG" TopLeft="1771,487" /> Id="Package\Load Contact Method\Data Conversion 4" TopLeft="2012.42857142857,230" /> Id="Package\Load Contact Method\Data Conversion 3" TopLeft="1603.95239658204,232" /> Id="Package\Load Contact Method\AUDIT TRAIL" TopLeft="1079,544" /> - - - + + + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + @@ -24428,7 +24636,7 @@ WHERE PID_NO IS NOT NULL OverwriteParamsSQLProp false + type="q2:boolean">false UsedTableName @@ -24930,611 +25138,331 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Person Address and Organization Address"> - - - - - - - - - - - - - - + Capacity="32" xmlns="clr-namespace:Microsoft.SqlServer.IntegrationServices.Designer.Model.Serialization;assembly=Microsoft.SqlServer.IntegrationServices.Graph" xmlns:mssgle="clr-namespace:Microsoft.SqlServer.Graph.LayoutEngine;assembly=Microsoft.SqlServer.Graph" xmlns:assembly="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:mssgm="clr-namespace:Microsoft.SqlServer.Graph.Model;assembly=Microsoft.SqlServer.Graph"> + Size="252,42" + Id="Package\Load Person Address and Organization Address\PIMS ORGANIZATION_ADDRESS" + TopLeft="939,483" /> + Size="158,42" + Id="Package\Load Person Address and Organization Address\Derived Column" + TopLeft="1314,197" /> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + Size="183,42" + Id="Package\Load Person Address and Organization Address\ETL_ERROR_LOG 1" + TopLeft="649,195" /> + + + + + + + + + + + Id="Package\Load Person Address and Organization Address.Paths[Derived Column Output1]" + TopLeft="165,343"> + End="0,112.5"> + End="0,112.5" /> + Id="Package\Load Person Address and Organization Address.Paths[Derived Column Output]" + TopLeft="1472,218.5"> + End="67.5,0"> + End="67.5,0" /> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + Id="Package\Load Person Address and Organization Address.Paths[Sort Output]" + TopLeft="1063,437"> + End="0,38.5"> + End="0,38.5" /> + Id="Package\Load Person Address and Organization Address.Paths[OLE DB Source Output1]" + TopLeft="1061.25,105"> + End="0,83.5"> - - - - + End="0,83.5" /> + Id="Package\Load Person Address and Organization Address.Paths[OLE DB Source Output]" + TopLeft="166.25,91"> + End="0,89.5"> - - - - + End="0,89.5" /> + Id="Package\Load Person Address and Organization Address.Paths[Lookup No Match Output1]" + TopLeft="273,212"> + End="123.5,0"> - - - - + End="123.5,0" /> - - - - - - - - - - - - - - - - - - + Id="Package\Load Person Address and Organization Address.Paths[Lookup No Match Output]" + TopLeft="1169,217.5"> + End="137.5,0"> - - - - - + + End="137.5,0" /> - + + Id="Package\Load Person Address and Organization Address.Paths[Lookup Match Output1]" + TopLeft="166.25,230"> + End="0,63.5"> - - - - + End="0,63.5" /> - + + Id="Package\Load Person Address and Organization Address.Paths[Lookup Match Output]" + TopLeft="1062,238"> + End="0,62.5"> + End="0,62.5" /> - + + Id="Package\Load Person Address and Organization Address.Paths[Derived Column Output3]" + TopLeft="1062.5,350"> + End="0,37.5"> + End="0,37.5" /> - + + Id="Package\Load Person Address and Organization Address.Paths[Derived Column Output2]" + TopLeft="571,215.5"> + End="70.5,0"> - - - - + End="70.5,0" /> - + + design-time-name="Package\Load Person Address and Organization Address\PIMS ORGANIZATION_ADDRESS"> DataSourceViewID @@ -25547,7 +25475,7 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Person Address and Organization Address\ETL_ERROR_LOG 1"> DataSourceViewID @@ -25560,7 +25488,7 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Person Address and Organization Address\Address ID in PIMS Address"> OverwriteParamsSQLProp @@ -25570,7 +25498,7 @@ WHERE PID_NO IS NOT NULL UsedTableName [dbo].[PIMS_COUNTRY] + type="q3:string">[dbo].[PIMS_ADDRESS] TableInfoObjectType @@ -25583,7 +25511,46 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Person Address and Organization Address\PIMS Organization"> + + + DataSourceViewID + + + TableInfoObjectType + Table + + + + + + + DataSourceViewID + + + TableInfoObjectType + Table + + + + + + + DataSourceViewID + + + TableInfoObjectType + Table + + + + DataSourceViewID @@ -25596,7 +25563,7 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Person Address and Organization Address\Adderss ID in PIMS Address"> OverwriteParamsSQLProp @@ -25606,7 +25573,7 @@ WHERE PID_NO IS NOT NULL UsedTableName [dbo].[PIMS_PROVINCE_STATE] + type="q3:string">[dbo].[PIMS_ADDRESS] TableInfoObjectType @@ -25619,357 +25586,533 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Properties"> + Capacity="64" xmlns="clr-namespace:Microsoft.SqlServer.IntegrationServices.Designer.Model.Serialization;assembly=Microsoft.SqlServer.IntegrationServices.Graph" xmlns:mssgle="clr-namespace:Microsoft.SqlServer.Graph.LayoutEngine;assembly=Microsoft.SqlServer.Graph" xmlns:assembly="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:mssgm="clr-namespace:Microsoft.SqlServer.Graph.Model;assembly=Microsoft.SqlServer.Graph"> + Size="307.2,42" + Id="Package\Load Properties\TM as PROPERTY_TENURE_TYPE_CODE" + TopLeft="1299.8333334989,267.266667107476" /> + Size="330,42" + Id="Package\Load Properties\PROPERTY_DATA_SOURCE_EFFECTIVE_DATE" + TopLeft="11,504" /> + Size="160.8,42" + Id="Package\Load Properties\Data Conversion" + TopLeft="874,217" /> + Size="259.2,42" + Id="Package\Load Properties\LAND as PROPERTY_TYPE_CODE" + TopLeft="241.999987085661,151.666668181949" /> + Size="128.8,42" + Id="Package\Load Properties\Audit Trail" + TopLeft="111.499977648259,592.266664586597" /> + Size="288,42" + Id="Package\Load Properties\SURPLUS_DECLARATION_TYPE_CODE" + TopLeft="39,427" /> + Size="259.2,42" + Id="Package\Load Properties\Address Id, Region and District Code" + TopLeft="904.833319988516,152.266669958963" /> + Size="320,42" + Id="Package\Load Properties\Crude Null Correction for Region and District" + TopLeft="1287.49998738368,154.466670723491" /> + Size="224.8,42" + Id="Package\Load Properties\PROPERTY_STATUS_TYPE" + TopLeft="360.666638188894,267.600005021096" /> + Size="167.2,42" + Id="Package\Load Properties\Derived Column 1" + TopLeft="744,587" /> + Size="188.8,42" + Id="Package\Load Properties\PIMS_PROPERTY" + TopLeft="384.166629943585,589.133340413836" /> + Size="316.8,47.2" + Id="Package\Load Properties\COREOPER as PROPERTY_CLASSIFICATION" + TopLeft="527.999988079071,149.26666902913" /> + Size="123.2,42" + Id="Package\Load Properties\Union All" + TopLeft="703,267" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Id="Package\Load Properties.Paths[Derived Column Output5]" + TopLeft="175.99998882413,546"> + End="0,38.766664586597"> + End="0,38.766664586597" /> - + + Id="Package\Load Properties.Paths[Derived Column Output4]" + TopLeft="844.999988079071,173.016669494046"> + End="52.333331909445,0"> + End="52.333331909445,0" /> - + + Id="Package\Load Properties.Paths[Derived Column Output3]" + TopLeft="500.999987085661,172.716668605539"> + End="19.50000099341,0"> + End="19.50000099341,0" /> - + + Id="Package\Load Properties.Paths[Derived Column Output2]" + TopLeft="1450.41666044129,196.466670723491"> + End="0,63.299996383985"> + End="0,63.299996383985" /> - + + Id="Package\Load Properties.Paths[Derived Column Output1]" + TopLeft="179.5,469"> + End="0,27.5"> + End="0,27.5" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + Id="Package\Load Properties.Paths[Lookup No Match Output]" + TopLeft="1151.83334015475,312.066667128139"> + End="-192.500000198678,65.033332272635"> + End="0,39.164007548746" /> + + + + + Id="Package\Load Properties.Paths[Lookup Match Output1]" + TopLeft="1163.83331998852,174.366670341227"> + End="116.166667395164,0"> + End="116.166667395164,0" /> + Id="Package\Load Properties.Paths[Lookup Match Output]" + TopLeft="1051.33334015475,291.066667128139"> + End="-96.83334015475,-24.566667128139"> + End="-92.83334015475,0" /> + + + Id="Package\Load Properties.Paths[Derived Column Output10]" + TopLeft="1299.8333334989,289.666667117807"> + End="-39.99999334415,0"> + End="-39.99999334415,0" /> - + + Id="Package\Load Properties.Paths[Derived Column Output9]" + TopLeft="911,604.5"> + End="190.5,0"> + End="190.5,0" /> - + + Id="Package\Load Properties.Paths[Derived Column Output8]" + TopLeft="240.499977648259,611.700002500216"> + End="136.166652295326,0"> + End="136.166652295326,0" /> - + - - - DataSourceViewID - - - TableInfoObjectType - Table - - - - - - - DataSourceViewID - - - TableInfoObjectType - Table - - - - + design-time-name="Package\Load Properties\Address Id, Region and District Code"> OverwriteParamsSQLProp @@ -25992,7 +26135,7 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Properties\PIMS_PROPERTY"> DataSourceViewID @@ -26005,7 +26148,7 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Properties\Error Log"> DataSourceViewID @@ -26018,7 +26161,7 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Properties\PAM Property"> DataSourceViewID @@ -26031,290 +26174,479 @@ WHERE PID_NO IS NOT NULL + design-time-name="Package\Load Properties\Area and Area Unit Code"> - DataSourceViewID + OverwriteParamsSQLProp + false + + + UsedTableName + TableInfoObjectType Table + type="q4:int">0 + + + DataSourceViewID + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + design-time-name="Package\Load Property Addresses\PAM_PROPERTY"> - OverwriteParamsSQLProp - false - - - UsedTableName - [dbo].[PIMS_ADDRESS] + DataSourceViewID TableInfoObjectType 0 + type="q2:string">Table + + + + DataSourceViewID + + TableInfoObjectType + Table + + design-time-name="Package\Load Interest Holder Persons and Organizations"> + Size="130,42" + Id="Package\Load Interest Holder Persons and Organizations\Canada" + TopLeft="766,171" /> + Size="107.2,42" + Id="Package\Load Interest Holder Persons and Organizations\Sort 1" + TopLeft="621.307692942535,1188.63096785159" /> + Size="132,42" + Id="Package\Load Interest Holder Persons and Organizations\Union All 1" + TopLeft="451,543" /> + Size="114,42" + Id="Package\Load Interest Holder Persons and Organizations\BC" + TopLeft="778,436.6" /> + Size="195.2,42" + Id="Package\Load Interest Holder Persons and Organizations\Fiter pre-existing person" + TopLeft="279.6,1118.16" /> + Size="123.2,42" + Id="Package\Load Interest Holder Persons and Organizations\Union All" + TopLeft="463,272" /> + Size="194,42" + Id="Package\Load Interest Holder Persons and Organizations\Format Output Columns" + TopLeft="284.8,1279.12" /> + Size="142,42" + Id="Package\Load Interest Holder Persons and Organizations\IS_PERSON" + TopLeft="307,952.36" /> + Size="172,42" + Id="Package\Load Interest Holder Persons and Organizations\COUNTRY_ID" + TopLeft="435,174" /> + Size="200.8,42" + Id="Package\Load Interest Holder Persons and Organizations\PROVINCE_STATE_ID" + TopLeft="433,356" /> + Size="280,42" + Id="Package\Load Interest Holder Persons and Organizations\Format PIMS_Organisation output column" + TopLeft="532.450000550197,1265.97483885804" /> + Size="156.8,42" + Id="Package\Load Interest Holder Persons and Organizations\PIMS_PERSON" + TopLeft="300.264285714286,1366.92428571429" /> + Size="212,42" + Id="Package\Load Interest Holder Persons and Organizations\Format Organization_Name" + TopLeft="575.861559495983,1044.25161081973" /> + Size="176.8,42" + Id="Package\Load Interest Holder Persons and Organizations\IS_ORGANIZATION" + TopLeft="596.461558578989,953.245158742395" /> + + + + + Size="226,44" + Id="Package\Load Interest Holder Persons and Organizations\PAM_INTEREST_HOLDER" + TopLeft="420,7.99999999999986" /> + Size="223.2,42" + Id="Package\Load Interest Holder Persons and Organizations\Filter pre-existing organisation" + TopLeft="567.076923556582,1116.46580650967" /> + Size="280.8,42" + Id="Package\Load Interest Holder Persons and Organizations\Audit Trail (and capture interest holder id)" + TopLeft="366.75,742.25" /> + Size="136,42" + Id="Package\Load Interest Holder Persons and Organizations\Multicast" + TopLeft="440.75,853.25" /> + Id="Package\Load Interest Holder Persons and Organizations.Paths[Lookup Match Output1]" + TopLeft="501.333333333333,398"> + End="15.6666666666667,137.5"> + End="0,54.6870681145113" /> + + + + - + + Id="Package\Load Interest Holder Persons and Organizations.Paths[Lookup Match Output]" + TopLeft="521,216"> + End="-15.6666666666667,48.5"> + End="0,29.1685393258427" /> + + + + - + + Id="Package\Load Interest Holder Persons and Organizations.Paths[Derived Column Output5]" + TopLeft="831,213"> + End="-287.333333333333,51.5"> + End="0,30.9454253611557" /> + + + + - + + Id="Package\Load Interest Holder Persons and Organizations.Paths[Derived Column Output4]" + TopLeft="380.132142857143,1320.72"> + End="0,38.7042857142858"> - + End="0,38.7042857142858" /> + + + + + + + + + + + + + - + End="0,49.4171026374345" /> + + + + + + + + + + + + + + End="0,23.1141956899367" /> - + + Id="Package\Load Interest Holder Persons and Organizations.Paths[Derived Column Output1]" + TopLeft="508,784.25"> + End="0,61.5"> + End="0,61.5" /> - + + Id="Package\Load Interest Holder Persons and Organizations.Paths[Derived Column Output]" + TopLeft="835,478.6"> + End="-297.333333333333,56.9"> + End="0,34.177245508982" /> + Point1="0,34.177245508982" + Point2="0,38.177245508982" + Point3="-4,38.177245508982" /> + End="-293.333333333333,38.177245508982" /> + + - + + Id="Package\Load Interest Holder Persons and Organizations.Paths[Data Conversion Output1]" + TopLeft="378.2,1083.52"> + End="0,27.1399999999999"> + End="0,27.1399999999999" /> @@ -26324,19 +26656,31 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Data Conversion Output]" + TopLeft="532.5,125"> + End="-11.5,41.5"> + End="0,20.5" /> + + + + @@ -26346,19 +26690,31 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Union All Output 11]" + TopLeft="517,585"> + End="-9.75,149.75"> + End="0,74.625" /> + + + + @@ -26368,19 +26724,31 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Union All Output 1]" + TopLeft="524.5,314"> + End="9,34.5"> + End="0,17" /> + + + + @@ -26390,31 +26758,19 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Sort Output1]" + TopLeft="379.6,1239.12"> + End="0,32.5000000000007"> - - - - + End="0,32.5000000000007" /> @@ -26424,19 +26780,19 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Sort Output]" + TopLeft="673.678846746366,1230.23096785159"> + End="0,28.2438710064444"> + End="0,28.2438710064444" /> @@ -26446,63 +26802,67 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Person]" + TopLeft="378.6,994.36"> + End="0,40.0599999999999"> + End="0,40.0599999999999" /> - + + Id="Package\Load Interest Holder Persons and Organizations.Paths[Organization]" + TopLeft="683.361559037486,994.845158742395"> + End="0,41.9064520773354"> + End="0,41.9064520773354" /> - + + Id="Package\Load Interest Holder Persons and Organizations.Paths[OLE DB Source Output]" + TopLeft="532.75,51.9999999999999"> + End="0,23.5000000000001"> + End="0,23.5000000000001" /> @@ -26512,19 +26872,31 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Multicast Output 3]" + TopLeft="487.416666666667,895.25"> + End="-109.416666666667,49.6100000000001"> + End="0,19.2424418604652" /> + + + + @@ -26534,19 +26906,31 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Multicast Output 1]" + TopLeft="530.083333333333,895.25"> + End="154.778225245655,50.4951587423947"> + End="0,19.6026808835327" /> + + + + @@ -26556,248 +26940,115 @@ WHERE PID_NO IS NOT NULL + Id="Package\Load Interest Holder Persons and Organizations.Paths[Lookup No Match Output3]" + TopLeft="565.666666666667,398"> + End="269.333333333333,31.1"> + End="0,11.6229022704837" /> + Point1="0,11.6229022704837" + Point2="0,15.6229022704837" + Point3="4,15.6229022704837" /> + End="265.333333333333,15.6229022704837" /> + Point1="265.333333333333,15.6229022704837" + Point2="269.333333333333,15.6229022704837" + Point3="269.333333333333,19.6229022704837" /> + End="269.333333333333,31.1" /> - + - - - - - - - OverwriteParamsSQLProp - false - - - UsedTableName - [dbo].[PIMS_ADDRESS] - - - TableInfoObjectType - 0 - - - DataSourceViewID - - - - - - - DataSourceViewID - - - TableInfoObjectType - Table - - - - - - - DataSourceViewID - - - TableInfoObjectType - Table - - - - - - - DataSourceViewID - - - TableInfoObjectType - Table - - - - - - - OverwriteParamsSQLProp - false - - - UsedTableName - "APP_PAM"."PAM_TAKE_PROPERTY" - - - TableInfoObjectType - 0 - - - DataSourceViewID - - - - - - - - - - + Id="Package\Load Interest Holder Persons and Organizations.Paths[Lookup No Match Output2]" + TopLeft="377.4,1159.76"> + End="0,30.2600000000002"> + End="0,30.2600000000002" /> + Id="Package\Load Interest Holder Persons and Organizations.Paths[Lookup No Match Output1]" + TopLeft="607,193.5"> + End="151.5,0"> + End="151.5,0" /> + Id="Package\Load Interest Holder Persons and Organizations.Paths[Lookup No Match Output]" + TopLeft="676.792308249558,1158.06580650967"> + End="0,23.0651613419266"> + End="0,23.0651613419266" /> - - - - DataSourceViewID - - - TableInfoObjectType - Table - - - - - - - DataSourceViewID - - - TableInfoObjectType - Table - - - ]]> \ No newline at end of file diff --git a/frontend/Makefile b/frontend/Makefile index baba9c8451..1081fec585 100644 --- a/frontend/Makefile +++ b/frontend/Makefile @@ -86,9 +86,9 @@ pr: | needs-rebase test local-build ## Runs various checks before a pull request # Docker Development ############################################################################## -docker: | build run rebuild-all-local-friendly-message ## Builds and runs the docker containers +docker: | build up rebuild-all-local-friendly-message ## Builds and runs the docker containers -restart: | stop build run rebuild-all-local-friendly-message ## Rebuilds the docker containers +restart: | stop build up rebuild-all-local-friendly-message ## Rebuilds the docker containers build-all: ## Rebuilds all docker containers for this project @echo -e "\n$(P) Building images..." @@ -98,14 +98,22 @@ build: ## Builds the frontend container @echo -e "\n$(P) Building images..." @docker-compose build --force-rm --no-cache frontend -run: ## Runs the frontend docker container +up: ## Runs the frontend docker container @echo -e "\n$(P) Running client and server..." @docker-compose up -d -stop: ## Tears down the docker development containers +down: ## Tears down the docker development containers @echo -e "\n$(P) Stopping client and server..." @docker-compose down +start: ## Starts the local containers (n=service name) + @echo "$(P) Starting client and server containers..." + @docker-compose start $(n) + +stop: ## Stops the local containers (n=service name) + @echo "$(P) Stopping client and server..." + @docker-compose stop $(n) + clean: ## Removes local docker containers, images, volumes, etc @echo -e "\n$(P) Removing containers, images, volumes etc..." @echo "$(P) Note: does not clear image cache." @@ -118,4 +126,4 @@ rebuild-all-local-friendly-message: @echo "$(P) pims_database will be available at http://localhost:5433" @echo "$(P) pims_keycloak will be available at http://keycloak:8080" -.PHONY: docker restart build run stop clean +.PHONY: docker restart build up down start stop clean diff --git a/frontend/package-lock.json b/frontend/package-lock.json index 3fc02290be..299f252821 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -1,12 +1,12 @@ { "name": "frontend", - "version": "1.1.0-30.29", + "version": "1.1.0-32.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "frontend", - "version": "1.1.0-30.29", + "version": "1.1.0-32.3", "hasInstallScript": true, "dependencies": { "@bcgov/bc-sans": "1.0.1", @@ -1205,12 +1205,6 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/jest/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/abab": { "version": "2.0.5", "integrity": "sha512-9IK9EadsbHo6jLWIpxpR6pL0sazTXV6+SQv25ZB+F7Bj9mJNaOc4nCRabwd5M/JwmUa8idz6Eci6eKfJryPs6Q==", @@ -1350,15 +1344,6 @@ "node": ">=7.0.0" } }, - "node_modules/renderkid/node_modules/strip-ansi/node_modules/ansi-regex": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/read-pkg-up/node_modules/p-locate": { "version": "2.0.0", "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=", @@ -2018,21 +2003,6 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/jest-changed-files/node_modules/get-stream": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", - "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", - "dev": true, - "dependencies": { - "pump": "^3.0.0" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/webpack-dev-server/node_modules/string_decoder": { "version": "1.1.1", "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", @@ -2868,8 +2838,7 @@ }, "node_modules/fs.realpath": { "version": "1.0.0", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "dev": true + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" }, "node_modules/from2/node_modules/isarray": { "version": "1.0.0", @@ -2941,12 +2910,6 @@ "node": ">= 4.0" } }, - "node_modules/jest-util/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/read-pkg-up/node_modules/p-try": { "version": "1.0.0", "integrity": "sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M=", @@ -3641,20 +3604,6 @@ "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" } }, - "node_modules/cheerio/node_modules/domutils": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", - "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", - "dev": true, - "dependencies": { - "dom-serializer": "^1.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0" - }, - "funding": { - "url": "https://github.com/fb55/domutils?sponsor=1" - } - }, "node_modules/eslint-module-utils": { "version": "2.6.0", "integrity": "sha512-6j9xxegbqe8/kZY8cYpcp0xhbK0EgJlg3g9mib3/miLaExuuwc3n5UEfSnU6hWMbT0FAYVvDbL9RrRgpUeQIvA==", @@ -4274,7 +4223,6 @@ "node_modules/glob": { "version": "7.1.6", "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", - "dev": true, "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -5145,7 +5093,6 @@ "node_modules/path-is-absolute": { "version": "1.0.1", "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", - "dev": true, "engines": { "node": ">=0.10.0" } @@ -5357,21 +5304,6 @@ "@types/react": "*" } }, - "node_modules/@jest/core/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/npm/node_modules/@npmcli/map-workspaces/node_modules/brace-expansion": { "version": "2.0.1", "inBundle": true, @@ -5380,6 +5312,18 @@ "balanced-match": "^1.0.0" } }, + "node_modules/string-width/node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, "node_modules/colorette": { "version": "1.2.2", "integrity": "sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w==", @@ -5639,8 +5583,7 @@ }, "node_modules/balanced-match": { "version": "1.0.2", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" }, "node_modules/character-reference-invalid": { "version": "1.1.4", @@ -6519,8 +6462,7 @@ }, "node_modules/inherits": { "version": "2.0.4", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, "node_modules/is-callable": { "version": "1.2.4", @@ -7144,14 +7086,6 @@ "node": ">=8" } }, - "node_modules/npm/node_modules/cli-columns/node_modules/is-fullwidth-code-point": { - "version": "3.0.0", - "inBundle": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/require-main-filename": { "version": "2.0.0", "integrity": "sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==", @@ -7634,18 +7568,6 @@ "integrity": "sha1-mEcocL8igTL8vdhoEputEsPAKeM=", "dev": true }, - "node_modules/base/node_modules/is-data-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", - "dev": true, - "dependencies": { - "kind-of": "^6.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/@babel/plugin-proposal-private-property-in-object": { "version": "7.14.0", "integrity": "sha512-59ANdmEwwRUkLjB7CRtwJxxwtjESw+X2IePItA+RGQh+oy5RmpCh/EvVVvh5XQc3yxsm5gtv0+i9oBZhaDNVTg==", @@ -7812,21 +7734,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@jest/console/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/debug": { "version": "4.3.4", "resolved": "https://registry.npmjs.org/debug/-/debug-4.3.4.tgz", @@ -8654,7 +8561,6 @@ "node_modules/once": { "version": "1.4.0", "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "dev": true, "dependencies": { "wrappy": "1" } @@ -8896,18 +8802,6 @@ "safe-buffer": "^5.1.1" } }, - "node_modules/base/node_modules/is-accessor-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", - "dev": true, - "dependencies": { - "kind-of": "^6.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/snapdragon/node_modules/ms": { "version": "2.0.0", "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g=", @@ -9118,12 +9012,6 @@ "integrity": "sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==", "dev": true }, - "node_modules/@jest/console/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/jest-runtime/node_modules/color-convert": { "version": "2.0.1", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", @@ -9605,12 +9493,6 @@ "node": ">=10" } }, - "node_modules/@jest/types/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/workbox-routing": { "version": "5.1.4", "integrity": "sha512-8ljknRfqE1vEQtnMtzfksL+UXO822jJlHTIR7+BtJuxQ17+WPZfsHqvk1ynR/v0EHik4x2+826Hkwpgh4GKDCw==", @@ -9899,12 +9781,6 @@ "node": ">=8" } }, - "node_modules/memory-fs/node_modules/isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==", - "dev": true - }, "node_modules/trough": { "version": "1.0.5", "integrity": "sha512-rvuRbTarPXmMb79SmzEp8aqXNKcK+y0XaB298IXueQ8I2PsrATcPBCSPyK/dDNa2iWOhKlfNnOjdAOTBU/nkFA==", @@ -9919,18 +9795,6 @@ "inBundle": true, "license": "ISC" }, - "node_modules/define-property/node_modules/is-data-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", - "dev": true, - "dependencies": { - "kind-of": "^6.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/@babel/plugin-transform-react-jsx-self": { "version": "7.12.13", "integrity": "sha512-FXYw98TTJ125GVCCkFLZXlZ1qGcsYqNQhVBQcZjyrwf8FEUtVfKIoidnO8S0q+KBQpDYNTmiGo1gn67Vti04lQ==", @@ -9942,18 +9806,6 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/jest-resolve/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, "node_modules/jest-jasmine2/node_modules/color-name": { "version": "1.1.4", "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", @@ -10026,14 +9878,6 @@ "node": ">= 0.6" } }, - "node_modules/npm/node_modules/@colors/colors": { - "version": "1.5.0", - "license": "MIT", - "optional": true, - "engines": { - "node": ">=0.1.90" - } - }, "node_modules/assert": { "version": "1.5.0", "integrity": "sha512-EDsgawzwoun2CZkCgtxJbv392v4nbk9XDD06zI+kQYoBM/3RBWLlEyJARDOmhAAosBjWACEkKL6S+lIZtcAubA==", @@ -10085,18 +9929,6 @@ "inBundle": true, "license": "MIT" }, - "node_modules/del/node_modules/array-union": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-1.0.2.tgz", - "integrity": "sha512-Dxr6QJj/RdU/hCaBjOfxW+q6lyuVE6JFWIrAUpuOOhoJJoQ99cUn3igRaHVB5P9WrgFVN0FfArM3x0cueOU8ng==", - "dev": true, - "dependencies": { - "array-uniq": "^1.0.1" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/detect-port-alt/node_modules/debug": { "version": "2.6.9", "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==", @@ -10160,18 +9992,6 @@ "minimalistic-crypto-utils": "^1.0.1" } }, - "node_modules/@jest/console/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, "node_modules/react-datepicker": { "version": "3.8.0", "integrity": "sha512-iFVNEp8DJoX5yEvEiciM7sJKmLGrvE70U38KhpG13XrulNSijeHw1RZkhd/0UmuXR71dcZB/kdfjiidifstZjw==", @@ -10760,18 +10580,6 @@ "node": ">=8" } }, - "node_modules/mini-css-extract-plugin/node_modules/json5": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz", - "integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==", - "dev": true, - "dependencies": { - "minimist": "^1.2.0" - }, - "bin": { - "json5": "lib/cli.js" - } - }, "node_modules/range-parser": { "version": "1.2.1", "integrity": "sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==", @@ -11316,15 +11124,6 @@ "version": "1.1.1", "integrity": "sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==" }, - "node_modules/enhanced-resolve/node_modules/string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "dependencies": { - "safe-buffer": "~5.1.0" - } - }, "node_modules/@surma/rollup-plugin-off-main-thread": { "version": "1.4.2", "integrity": "sha512-yBMPqmd1yEJo/280PAMkychuaALyQ9Lkb5q1ck3mjJrFuEobIfhnQ4J3mbvBoISmR3SWMWV+cGB/I0lCQee79A==", @@ -11761,19 +11560,6 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/cssnano/node_modules/parse-json": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha512-aOIos8bujGN93/8Ox/jPLh7RwVnPEysynVFE+fQZyg6jKELEHwzgKdLRFHUgXJL6kylijVSBC4BvN9OmsB48Rw==", - "dev": true, - "dependencies": { - "error-ex": "^1.3.1", - "json-parse-better-errors": "^1.0.1" - }, - "engines": { - "node": ">=4" - } - }, "node_modules/postcss-safe-parser/node_modules/source-map": { "version": "0.6.1", "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", @@ -13014,13 +12800,14 @@ } }, "node_modules/string-width": { - "version": "4.2.2", - "integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==", + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", "dev": true, "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.0" + "strip-ansi": "^6.0.1" }, "engines": { "node": ">=8" @@ -13083,15 +12870,6 @@ "integrity": "sha1-WjUNoLERO4N+z//VgSy+WNbq4ZM=", "dev": true }, - "node_modules/mini-html-webpack-plugin/node_modules/source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/babel-runtime/node_modules/regenerator-runtime": { "version": "0.11.1", "integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==", @@ -13841,15 +13619,6 @@ "once": "^1.4.0" } }, - "node_modules/array-uniq": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/array-uniq/-/array-uniq-1.0.3.tgz", - "integrity": "sha512-MNha4BWQ6JbwhFhj03YK552f7cb3AzoE8SzeljgChvL1dl3IcvggXVz1DilzySZkCja+CXuZbdW7yATchWn8/Q==", - "dev": true, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/escalade": { "version": "3.1.1", "integrity": "sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==", @@ -13977,19 +13746,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/escodegen/node_modules/levn": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", - "integrity": "sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==", - "dev": true, - "dependencies": { - "prelude-ls": "~1.1.2", - "type-check": "~0.3.2" - }, - "engines": { - "node": ">= 0.8.0" - } - }, "node_modules/popper.js": { "version": "1.16.1", "integrity": "sha512-Wb4p1J4zyFTbM+u6WuO4XstYx4Ky9Cewe4DWrel7B0w6VVICvPwdOpotjzcf6eD8TsckVnIMNONQyPIUFOUbCQ==", @@ -14023,7 +13779,6 @@ "node_modules/minimatch": { "version": "3.0.4", "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, "dependencies": { "brace-expansion": "^1.1.7" }, @@ -14119,27 +13874,6 @@ "node": ">=6.0.0" } }, - "node_modules/jest-resolve/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/express/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "dev": true - }, "node_modules/dom-serializer/node_modules/domelementtype": { "version": "2.2.0", "integrity": "sha512-DtBMo82pv1dFtUmHyr48beiuq792Sxohr+8Hm9zoxklYPfa6n0Z3Byjj2IV7bmr2IyqClnqEQhfgHJJ5QF0R5A==", @@ -14597,21 +14331,6 @@ "node": ">=4.0.0" } }, - "node_modules/@jest/reporters/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/@babel/plugin-transform-react-constant-elements": { "version": "7.13.13", "integrity": "sha512-SNJU53VM/SjQL0bZhyU+f4kJQz7bQQajnrZRSaU21hruG/NWY41AEM9AWXeXX90pYr/C2yAmTgI6yW3LlLrAUQ==", @@ -16257,12 +15976,6 @@ "node": ">= 10.14.2" } }, - "node_modules/@jest/reporters/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/babel-preset-react-app/node_modules/@babel/preset-env": { "version": "7.12.1", "integrity": "sha512-H8kxXmtPaAGT7TyBvSSkoSTUK6RHh61So05SyEbpmr0MCZrsNYn7mGMzzeYoOUCdHzww61k8XBft2TaES+xPLg==", @@ -16628,18 +16341,6 @@ "node": ">=4" } }, - "node_modules/@jest/core/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, "node_modules/npm/node_modules/smart-buffer": { "version": "4.2.0", "inBundle": true, @@ -16871,6 +16572,7 @@ "node_modules/lru-cache": { "version": "6.0.0", "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, "dependencies": { "yallist": "^4.0.0" }, @@ -16966,6 +16668,15 @@ "asap": "~2.0.6" } }, + "node_modules/renderkid/node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "engines": { + "node": ">=0.10.0" + } + }, "node_modules/fb-watchman": { "version": "2.0.1", "integrity": "sha512-DkPJKQeY6kKwmuMretBhr7G6Vodr7bFwDYTXIkfG1gjvNpaxBTQV3PbXg6bR1c1UP4jPOX0jHUbbHANL9vRjVg==", @@ -18038,18 +17749,6 @@ "@babel/core": "^7.0.0-0" } }, - "node_modules/jest/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, "node_modules/@babel/plugin-transform-modules-systemjs": { "version": "7.13.8", "integrity": "sha512-hwqctPYjhM6cWvVIlOIe27jCIBgHCsdH2xCJVAYQm7V5yTMoilbVMi9f6wKg0rpQAOn6ZG4AOyvCqFF/hUh6+A==", @@ -18852,27 +18551,6 @@ "is-in-browser": "^1.0.2" } }, - "node_modules/jest/node_modules/has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true, - "engines": { - "node": ">=8" - } - }, - "node_modules/jest/node_modules/supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "dependencies": { - "has-flag": "^4.0.0" - }, - "engines": { - "node": ">=8" - } - }, "node_modules/postcss-page-break": { "version": "2.0.0", "integrity": "sha512-tkpTSrLpfLfD9HvgOlJuigLuk39wVTbbd8RKcy8/ugV2bNBUW3xU+AIqyxhDrQr1VUj1RmyJrBn1YWrqUm9zAQ==", @@ -19651,20 +19329,6 @@ "inBundle": true, "license": "MIT" }, - "node_modules/base/node_modules/is-descriptor": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", - "dev": true, - "dependencies": { - "is-accessor-descriptor": "^1.0.0", - "is-data-descriptor": "^1.0.0", - "kind-of": "^6.0.2" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/npm/node_modules/validate-npm-package-license": { "version": "3.0.4", "inBundle": true, @@ -19783,17 +19447,6 @@ "node": ">= 10.14.2" } }, - "node_modules/npm/node_modules/node-gyp/node_modules/is-fullwidth-code-point": { - "version": "1.0.0", - "inBundle": true, - "license": "MIT", - "dependencies": { - "number-is-nan": "^1.0.0" - }, - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/@webassemblyjs/wast-printer": { "version": "1.9.0", "integrity": "sha512-2J0nE95rHXHyQ24cWjMKJ1tqB/ds8z/cyeOZxJhcb+rW+SQASVjuznUSmdz5GpVJTzU8JkhYut0D3siFDD6wsA==", @@ -20619,12 +20272,6 @@ "node": ">=0.4.0" } }, - "node_modules/compression/node_modules/ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "dev": true - }, "node_modules/growly": { "version": "1.3.0", "integrity": "sha1-8QdIy+dq+WS3yWyTxrzCivEgwIE=", @@ -20734,18 +20381,6 @@ "node": ">=4" } }, - "node_modules/@jest/types/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, "node_modules/jest-changed-files/node_modules/cross-spawn": { "version": "7.0.3", "integrity": "sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==", @@ -20878,7 +20513,6 @@ "node_modules/inflight": { "version": "1.0.6", "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "dev": true, "dependencies": { "once": "^1.3.0", "wrappy": "1" @@ -21058,12 +20692,6 @@ "node": ">=0.10.0" } }, - "node_modules/@jest/core/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/read-pkg-up": { "version": "2.0.0", "integrity": "sha1-a3KoBImE4MQeeVEP1en6mbO1Sb4=", @@ -22545,22 +22173,6 @@ "node": ">=8" } }, - "node_modules/jest/node_modules/chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "dependencies": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/chalk?sponsor=1" - } - }, "node_modules/@babel/plugin-transform-sticky-regex": { "version": "7.12.13", "integrity": "sha512-Jc3JSaaWT8+fr7GRvQP02fKDsYk4K/lYwWq38r/UGfaxo89ajud321NH28KRQ7xy1Ybc0VUE5Pz8psjNNDUglg==", @@ -22829,7 +22441,6 @@ "node_modules/brace-expansion": { "version": "1.1.11", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, "dependencies": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -23030,18 +22641,6 @@ "version": "0.3.8", "integrity": "sha1-wB3mPvsO7JeYgB1Ax+Da4ltYLIQ=" }, - "node_modules/@jest/reporters/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, "node_modules/d": { "version": "1.0.1", "integrity": "sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==", @@ -23594,8 +23193,7 @@ }, "node_modules/concat-map": { "version": "0.0.1", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "dev": true + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" }, "node_modules/escodegen/node_modules/prelude-ls": { "version": "1.1.2", @@ -24274,7 +23872,8 @@ }, "node_modules/yallist": { "version": "4.0.0", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true }, "node_modules/fast-levenshtein": { "version": "2.0.6", @@ -25524,8 +25123,9 @@ } }, "node_modules/is-core-module": { - "version": "2.8.0", - "integrity": "sha512-vd15qHsaqrRL7dtH6QNuy0ndJmRDrS9HAM1CAiSifNUFv4x1a0CCVsj18hJ1mShxIG6T2i1sO78MkP56r0nYRw==", + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.9.0.tgz", + "integrity": "sha512-+5FPy5PnwmO3lvfMb0AsoPaBG+5KHUI0wYFXOtYPnVVVspTFUuMZNfNaNVRt3FZadstu2c8x23vykRW/NBoU6A==", "dev": true, "dependencies": { "has": "^1.0.3" @@ -26339,21 +25939,6 @@ "node": ">=0.10.0" } }, - "node_modules/jest/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, "node_modules/isarray": { "version": "0.0.1", "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=" @@ -26900,8 +26485,7 @@ }, "node_modules/wrappy": { "version": "1.0.2", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "dev": true + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" }, "node_modules/jest": { "version": "26.6.0", @@ -27794,12 +27378,6 @@ "inBundle": true, "license": "ISC" }, - "node_modules/jest-resolve/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "node_modules/webpack-dev-server/node_modules/is-number/node_modules/kind-of": { "version": "3.2.2", "integrity": "sha1-MeohpzS6ubuw8yRm2JOupR5KPGQ=", @@ -29204,15 +28782,6 @@ "slash": "^3.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "chalk": { "version": "4.1.1", "integrity": "sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg==", @@ -29222,21 +28791,6 @@ "supports-color": "^7.1.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "has-flag": { "version": "4.0.0", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", @@ -29287,15 +28841,6 @@ "strip-ansi": "^6.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", @@ -29306,21 +28851,6 @@ "supports-color": "^7.1.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", @@ -29450,15 +28980,6 @@ "v8-to-istanbul": "^7.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", @@ -29469,21 +28990,6 @@ "supports-color": "^7.1.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", @@ -29693,21 +29199,6 @@ "supports-color": "^7.1.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "has-flag": { "version": "4.0.0", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", @@ -31335,12 +30826,6 @@ "integrity": "sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==", "dev": true }, - "array-uniq": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/array-uniq/-/array-uniq-1.0.3.tgz", - "integrity": "sha512-MNha4BWQ6JbwhFhj03YK552f7cb3AzoE8SzeljgChvL1dl3IcvggXVz1DilzySZkCja+CXuZbdW7yATchWn8/Q==", - "dev": true - }, "array-unique": { "version": "0.3.2", "integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg=", @@ -32043,8 +31528,7 @@ }, "balanced-match": { "version": "1.0.2", - "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==", - "dev": true + "integrity": "sha512-3oSeUO0TMV67hN1AmbXsK4yaqU7tjiHlbxRDZOpH0KW9+CeX4bRAaX0Anxt0tx2MrpRpWwQaPwIlISEJhYU5Pw==" }, "base": { "version": "0.11.2", @@ -32067,35 +31551,6 @@ "requires": { "is-descriptor": "^1.0.0" } - }, - "is-accessor-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-accessor-descriptor/-/is-accessor-descriptor-1.0.0.tgz", - "integrity": "sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==", - "dev": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-data-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", - "dev": true, - "requires": { - "kind-of": "^6.0.0" - } - }, - "is-descriptor": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/is-descriptor/-/is-descriptor-1.0.2.tgz", - "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", - "dev": true, - "requires": { - "is-accessor-descriptor": "^1.0.0", - "is-data-descriptor": "^1.0.0", - "kind-of": "^6.0.2" - } } } }, @@ -32224,7 +31679,6 @@ "brace-expansion": { "version": "1.1.11", "integrity": "sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==", - "dev": true, "requires": { "balanced-match": "^1.0.0", "concat-map": "0.0.1" @@ -32639,17 +32093,6 @@ "domelementtype": "^2.2.0" } }, - "domutils": { - "version": "2.8.0", - "resolved": "https://registry.npmjs.org/domutils/-/domutils-2.8.0.tgz", - "integrity": "sha512-w96Cjofp72M5IIhpjgobBimYEfoPjx1Vx0BSX9P30WBdZW2WIKU0T1Bd0kz2eNZ9ikjKgHbEyKx8BB6H1L3h3A==", - "dev": true, - "requires": { - "dom-serializer": "^1.0.1", - "domelementtype": "^2.2.0", - "domhandler": "^4.2.0" - } - }, "htmlparser2": { "version": "6.1.0", "integrity": "sha512-gyyPk6rgonLFEDGoeRgQNaEUvdJ4ktTmmUh/h2t7s+M8oPpIPxgNACWa+6ESR57kXstwqPiCut0V8NRpcwgU7A==", @@ -33043,12 +32486,6 @@ "requires": { "ms": "2.0.0" } - }, - "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "dev": true } } }, @@ -33113,8 +32550,7 @@ }, "concat-map": { "version": "0.0.1", - "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=", - "dev": true + "integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s=" }, "concat-stream": { "version": "1.6.2", @@ -33765,16 +33201,6 @@ "resolve-from": "^3.0.0" } }, - "parse-json": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-4.0.0.tgz", - "integrity": "sha512-aOIos8bujGN93/8Ox/jPLh7RwVnPEysynVFE+fQZyg6jKELEHwzgKdLRFHUgXJL6kylijVSBC4BvN9OmsB48Rw==", - "dev": true, - "requires": { - "error-ex": "^1.3.1", - "json-parse-better-errors": "^1.0.1" - } - }, "resolve-from": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/resolve-from/-/resolve-from-3.0.0.tgz", @@ -34039,15 +33465,6 @@ "kind-of": "^6.0.0" } }, - "is-data-descriptor": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/is-data-descriptor/-/is-data-descriptor-1.0.0.tgz", - "integrity": "sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==", - "dev": true, - "requires": { - "kind-of": "^6.0.0" - } - }, "is-descriptor": { "version": "1.0.2", "integrity": "sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==", @@ -34074,15 +33491,6 @@ "rimraf": "^2.6.3" }, "dependencies": { - "array-union": { - "version": "1.0.2", - "resolved": "https://registry.npmjs.org/array-union/-/array-union-1.0.2.tgz", - "integrity": "sha512-Dxr6QJj/RdU/hCaBjOfxW+q6lyuVE6JFWIrAUpuOOhoJJoQ99cUn3igRaHVB5P9WrgFVN0FfArM3x0cueOU8ng==", - "dev": true, - "requires": { - "array-uniq": "^1.0.1" - } - }, "globby": { "version": "6.1.0", "integrity": "sha1-9abXDoOV4hyFj7BInWTfAkJNUGw=", @@ -34544,15 +33952,6 @@ "string_decoder": "~1.1.1", "util-deprecate": "~1.0.1" } - }, - "string_decoder": { - "version": "1.1.1", - "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", - "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", - "dev": true, - "requires": { - "safe-buffer": "~5.1.0" - } } } }, @@ -34748,16 +34147,6 @@ "integrity": "sha512-BxbNGGNm0RyRYvUdHpIwv9IWzeM9XClbOxwoATuFdOE7ZE6wHL+HQ5T8hoPM+zHvmKzzsEqhgy0GrQ5X13afiQ==", "dev": true }, - "levn": { - "version": "0.3.0", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.3.0.tgz", - "integrity": "sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==", - "dev": true, - "requires": { - "prelude-ls": "~1.1.2", - "type-check": "~0.3.2" - } - }, "optionator": { "version": "0.8.3", "integrity": "sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==", @@ -35575,12 +34964,6 @@ "ms": "2.0.0" } }, - "ms": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz", - "integrity": "sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==", - "dev": true - }, "path-to-regexp": { "version": "0.1.7", "integrity": "sha1-32BBeABfUi8V60SQ5yR6G/qmf4w=", @@ -36241,8 +35624,7 @@ }, "fs.realpath": { "version": "1.0.0", - "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=", - "dev": true + "integrity": "sha1-FQStJSMVjKpA20onh8sBQRmU6k8=" }, "fsevents": { "version": "1.2.13", @@ -36362,7 +35744,6 @@ "glob": { "version": "7.1.6", "integrity": "sha512-LwaxwyZ72Lk7vZINtNNrywX0ZuLyStrdDtabefZKAY5ZGJhVtgdznluResxNmPitE0SAO+O26sWTHeKSI2wMBA==", - "dev": true, "requires": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", @@ -36986,7 +36367,6 @@ "inflight": { "version": "1.0.6", "integrity": "sha1-Sb1jMdfQLQwJvJEKEHW6gWW1bfk=", - "dev": true, "requires": { "once": "^1.3.0", "wrappy": "1" @@ -36994,8 +36374,7 @@ }, "inherits": { "version": "2.0.4", - "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", - "dev": true + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==" }, "ini": { "version": "1.3.8", @@ -37145,8 +36524,9 @@ } }, "is-core-module": { - "version": "2.8.0", - "integrity": "sha512-vd15qHsaqrRL7dtH6QNuy0ndJmRDrS9HAM1CAiSifNUFv4x1a0CCVsj18hJ1mShxIG6T2i1sO78MkP56r0nYRw==", + "version": "2.9.0", + "resolved": "https://registry.npmjs.org/is-core-module/-/is-core-module-2.9.0.tgz", + "integrity": "sha512-+5FPy5PnwmO3lvfMb0AsoPaBG+5KHUI0wYFXOtYPnVVVspTFUuMZNfNaNVRt3FZadstu2c8x23vykRW/NBoU6A==", "dev": true, "requires": { "has": "^1.0.3" @@ -37520,46 +36900,6 @@ "jest-cli": "^26.6.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, - "chalk": { - "version": "4.1.2", - "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", - "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "dev": true, - "requires": { - "ansi-styles": "^4.1.0", - "supports-color": "^7.1.0" - } - }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, - "has-flag": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", - "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "dev": true - }, "jest-cli": { "version": "26.6.3", "integrity": "sha512-GF9noBSa9t08pSyl3CY4frMrqp+aQXFGFkf5hEPbh/pIUFYWMK6ZLTfbmadxJVcJrdRoChlWQsA2VkJcDFK8hg==", @@ -37579,15 +36919,6 @@ "prompts": "^2.0.1", "yargs": "^15.4.1" } - }, - "supports-color": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", - "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "dev": true, - "requires": { - "has-flag": "^4.0.0" - } } } }, @@ -37627,15 +36958,6 @@ "strip-final-newline": "^2.0.0" } }, - "get-stream": { - "version": "5.2.0", - "resolved": "https://registry.npmjs.org/get-stream/-/get-stream-5.2.0.tgz", - "integrity": "sha512-nBF+F1rAZVCu/p7rjzgA+Yb4lfYXrpl7a6VmJrU8wF9I1CKvP/QwPNZHnOlwbTkY6dvtFIzFMSyQXbLoTQPRpA==", - "dev": true, - "requires": { - "pump": "^3.0.0" - } - }, "is-stream": { "version": "2.0.0", "integrity": "sha512-XCoy+WlUr7d1+Z8GgSuXmpuUFC9fOhRXglJMx+dwLKTkL44Cjd4W1Z5P+BQZpr+cR93aGP4S/s7Ftw6Nd/kiEw==", @@ -38290,15 +37612,6 @@ "slash": "^3.0.0" }, "dependencies": { - "ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "dev": true, - "requires": { - "color-convert": "^2.0.1" - } - }, "chalk": { "version": "4.1.1", "integrity": "sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg==", @@ -38308,21 +37621,6 @@ "supports-color": "^7.1.0" } }, - "color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "dev": true, - "requires": { - "color-name": "~1.1.4" - } - }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "has-flag": { "version": "4.0.0", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", @@ -38792,12 +38090,6 @@ "color-name": "~1.1.4" } }, - "color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true - }, "has-flag": { "version": "4.0.0", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", @@ -39554,6 +38846,7 @@ "lru-cache": { "version": "6.0.0", "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, "requires": { "yallist": "^4.0.0" } @@ -39683,12 +38976,6 @@ "readable-stream": "^2.0.1" }, "dependencies": { - "isarray": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", - "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==", - "dev": true - }, "readable-stream": { "version": "2.3.7", "integrity": "sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==", @@ -39819,22 +39106,6 @@ "webpack-sources": "^1.1.0" }, "dependencies": { - "json5": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz", - "integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==", - "dev": true, - "requires": { - "minimist": "1.2.6" - }, - "dependencies": { - "minimist": { - "version": "1.2.6", - "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz", - "integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==" - } - } - }, "loader-utils": { "version": "1.4.0", "integrity": "sha512-qH0WSMBtn/oHuwjy/NucEgbx5dbxxnxup9s4PVXJUDHZBQY+s0NWA9rJf53RBnQZxfch7euUui7hpoAPvALZdA==", @@ -39865,12 +39136,6 @@ "webpack-sources": "^2.0.1" }, "dependencies": { - "source-map": { - "version": "0.6.1", - "resolved": "https://registry.npmjs.org/source-map/-/source-map-0.6.1.tgz", - "integrity": "sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==", - "dev": true - }, "webpack-sources": { "version": "2.2.0", "integrity": "sha512-bQsA24JLwcnWGArOKUxYKhX3Mz/nK1Xf6hxullKERyktjNMC4x8koOeaDNTA2fEJ09BdWLbM/iTW0ithREUP0w==", @@ -39895,7 +39160,6 @@ "minimatch": { "version": "3.0.4", "integrity": "sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==", - "dev": true, "requires": { "brace-expansion": "^1.1.7" } @@ -40468,10 +39732,6 @@ "write-file-atomic": "^4.0.1" }, "dependencies": { - "@colors/colors": { - "version": "1.5.0", - "optional": true - }, "@gar/promisify": { "version": "1.1.3", "bundled": true @@ -42060,7 +41320,6 @@ "once": { "version": "1.4.0", "integrity": "sha1-WDsap3WWHUsROsF9nFC6753Xa9E=", - "dev": true, "requires": { "wrappy": "1" } @@ -42407,8 +41666,7 @@ }, "path-is-absolute": { "version": "1.0.1", - "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=", - "dev": true + "integrity": "sha1-F0uSaHNVNP+8es5r9TpanhtcX18=" }, "path-is-inside": { "version": "1.0.2", @@ -45204,6 +44462,12 @@ "strip-ansi": "^3.0.0" }, "dependencies": { + "ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true + }, "strip-ansi": { "version": "3.0.1", "integrity": "sha1-ajhfuIU9lS1f8F0Oiq+UJ43GPc8=", @@ -45215,8 +44479,7 @@ "ansi-regex": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", - "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", - "dev": true + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==" } } } @@ -46618,13 +45881,32 @@ "dev": true }, "string-width": { - "version": "4.2.2", - "integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==", + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", "dev": true, "requires": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", - "strip-ansi": "^6.0.0" + "strip-ansi": "^6.0.1" + }, + "dependencies": { + "strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "requires": { + "ansi-regex": "5.0.1" + }, + "dependencies": { + "ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==" + } + } + } } }, "string.prototype.matchall": { @@ -49323,8 +48605,7 @@ }, "wrappy": { "version": "1.0.2", - "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=", - "dev": true + "integrity": "sha1-tSQ9jz7BqjXxNkYFvA0QNuMKtp8=" }, "write-file-atomic": { "version": "3.0.3", @@ -49370,7 +48651,8 @@ }, "yallist": { "version": "4.0.0", - "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==" + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true }, "yaml": { "version": "1.10.2", diff --git a/frontend/package.json b/frontend/package.json index 8c0156c932..6dc18d81e7 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,6 +1,6 @@ { "name": "frontend", - "version": "1.1.0-31.23", + "version": "2.1.0-32.25", "private": true, "dependencies": { "@bcgov/bc-sans": "1.0.1", diff --git a/frontend/src/components/Table/Table.tsx b/frontend/src/components/Table/Table.tsx index ce42e3cdd6..24c4582abf 100644 --- a/frontend/src/components/Table/Table.tsx +++ b/frontend/src/components/Table/Table.tsx @@ -778,7 +778,7 @@ export const Table = ( )} - {props.pageSize !== -1 && instance={instance} />} + {props.pageSize !== props.data.length && instance={instance} />} )} diff --git a/frontend/src/components/common/CancelConfirmationModal.tsx b/frontend/src/components/common/CancelConfirmationModal.tsx new file mode 100644 index 0000000000..8553f4d194 --- /dev/null +++ b/frontend/src/components/common/CancelConfirmationModal.tsx @@ -0,0 +1,22 @@ +import GenericModal, { ModalProps } from 'components/common/GenericModal'; +import React from 'react'; + +export const CancelConfirmationModal: React.FC = props => { + const { + title = 'Unsaved Changes', + message = 'You have made changes on this form. Do you wish to leave without saving?', + okButtonText = 'Confirm', + cancelButtonText = 'No', + ...rest + } = props; + + return ( + + ); +}; diff --git a/frontend/src/components/common/GenericModal.tsx b/frontend/src/components/common/GenericModal.tsx index 4389665850..5a4b9cb62c 100644 --- a/frontend/src/components/common/GenericModal.tsx +++ b/frontend/src/components/common/GenericModal.tsx @@ -136,6 +136,7 @@ export const GenericModal = (props: BsModalProps & ModalProps) => { {cancelButtonText && ( )} - diff --git a/frontend/src/components/common/form/TableSelect.tsx b/frontend/src/components/common/form/TableSelect.tsx index 341e8b73da..ed58e74f47 100644 --- a/frontend/src/components/common/form/TableSelect.tsx +++ b/frontend/src/components/common/form/TableSelect.tsx @@ -57,7 +57,7 @@ export const TableSelect = ({ addLabel, }: TableSelectProps) => { const { values, setFieldValue } = useFormikContext(); - const existingItems: T[] = getIn(values, field); + const existingItems: T[] = getIn(values, field) ?? []; const columnsWithRemove = useMemo( () => getColumnsWithRemove((rows: T[]) => setFieldValue(field, rows), [...columns]), [columns, field, setFieldValue], @@ -82,13 +82,13 @@ export const TableSelect = ({ )} - + name="selected-items" columns={columnsWithRemove} - data={existingItems ?? []} + data={existingItems} lockPageSize - pageSize={-1} + pageSize={existingItems.length} footer /> diff --git a/frontend/src/components/common/styles.ts b/frontend/src/components/common/styles.ts index 67b098bb06..fd6eb912db 100644 --- a/frontend/src/components/common/styles.ts +++ b/frontend/src/components/common/styles.ts @@ -3,6 +3,7 @@ import { Breadcrumb as BsBreadcrumb, Row } from 'react-bootstrap'; import { Tabs as BsTabs } from 'react-bootstrap'; import styled, { css } from 'styled-components'; +import { Button } from './buttons'; import { Form } from './form'; import GenericModal from './GenericModal'; @@ -142,3 +143,10 @@ export const FilterBoxForm = styled(Form)` background-color: ${({ theme }) => theme.css.filterBoxColor}; border-radius: 0.5rem; `; + +export const StyledAddButton = styled(Button)` + &.btn.btn-primary, + &.btn.btn-primary:active { + background-color: ${props => props.theme.css.completedColor}; + } +`; diff --git a/frontend/src/components/contact/ContactManagerView/ContactResultComponent/__snapshots__/ContactResultComponent.test.tsx.snap b/frontend/src/components/contact/ContactManagerView/ContactResultComponent/__snapshots__/ContactResultComponent.test.tsx.snap index ae4e1b9271..0ec7841bc3 100644 --- a/frontend/src/components/contact/ContactManagerView/ContactResultComponent/__snapshots__/ContactResultComponent.test.tsx.snap +++ b/frontend/src/components/contact/ContactManagerView/ContactResultComponent/__snapshots__/ContactResultComponent.test.tsx.snap @@ -141,6 +141,29 @@ exports[`Contact Search Results Table matches snapshot 1`] = ` margin-right: 0; } +.c6.c6.btn { + background-color: unset; + border: none; +} + +.c6.c6.btn:hover, +.c6.c6.btn:focus, +.c6.c6.btn:active { + background-color: unset; + outline: none; + box-shadow: none; +} + +.c6.c6.btn svg { + -webkit-transition: all 0.3s ease-out; + transition: all 0.3s ease-out; +} + +.c6.c6.btn svg:hover { + -webkit-transition: all 0.3s ease-in; + transition: all 0.3s ease-in; +} + .c3 { display: -webkit-box; display: -webkit-flex; @@ -180,29 +203,6 @@ exports[`Contact Search Results Table matches snapshot 1`] = ` height: 1.6rem; } -.c6.c6.btn { - background-color: unset; - border: none; -} - -.c6.c6.btn:hover, -.c6.c6.btn:focus, -.c6.c6.btn:active { - background-color: unset; - outline: none; - box-shadow: none; -} - -.c6.c6.btn svg { - -webkit-transition: all 0.3s ease-out; - transition: all 0.3s ease-out; -} - -.c6.c6.btn svg:hover { - -webkit-transition: all 0.3s ease-in; - transition: all 0.3s ease-in; -} - .c4 { -webkit-box-pack: space-around; -webkit-justify-content: space-around; diff --git a/frontend/src/components/maps/leaflet/LayerPopup/hooks/useLayerQuery.tsx b/frontend/src/components/maps/leaflet/LayerPopup/hooks/useLayerQuery.tsx index cf0bb2bc44..8a05137212 100644 --- a/frontend/src/components/maps/leaflet/LayerPopup/hooks/useLayerQuery.tsx +++ b/frontend/src/components/maps/leaflet/LayerPopup/hooks/useLayerQuery.tsx @@ -84,6 +84,7 @@ const wfsAxios = (timeout?: number) => { }; /** + * // TODO: This should be deprecated * Custom hook to fetch layer feature collection from wfs url * @param url wfs request url * @param geometry the name of the geometry in the feature collection diff --git a/frontend/src/components/maps/leaflet/PointClusterer.tsx b/frontend/src/components/maps/leaflet/PointClusterer.tsx index 7639a7c2f6..7378bca450 100644 --- a/frontend/src/components/maps/leaflet/PointClusterer.tsx +++ b/frontend/src/components/maps/leaflet/PointClusterer.tsx @@ -338,7 +338,7 @@ export const PointClusterer: React.FC = ({ position={[latitude, longitude]} icon={getMarkerIcon(cluster)} eventHandlers={{ - click: () => { + click: e => { const convertedProperty = convertToProperty( cluster.properties, latitude, diff --git a/frontend/src/components/maps/leaflet/mapUtils.tsx b/frontend/src/components/maps/leaflet/mapUtils.tsx index 4780a1659c..2aaa9c2756 100644 --- a/frontend/src/components/maps/leaflet/mapUtils.tsx +++ b/frontend/src/components/maps/leaflet/mapUtils.tsx @@ -159,7 +159,7 @@ export const asProperty = (point: PointFeature): IProperty => { * The resulting filter is URL-encoded * @param object an object to convert to a cql filter string. */ -export const toCqlFilter = (object: any, pidOverride?: boolean) => { +export const toCqlFilter = (object: Record, pidOverride?: boolean) => { const cqlValue: string = toCqlFilterValue(object, pidOverride); return cqlValue.length ? `cql_filter=${encodeURIComponent(cqlValue)}` : ''; }; @@ -169,11 +169,11 @@ export const toCqlFilter = (object: any, pidOverride?: boolean) => { * NOTE: The resulting string value is left as-is. It will not be URL-encoded * @param object an object to convert to a cql filter string. */ -export const toCqlFilterValue = (object: any, pidOverride?: boolean) => { +export const toCqlFilterValue = (object: Record, forceSimplePid?: boolean) => { const cql: string[] = []; Object.keys(object).forEach((key: string) => { if (object[key]) { - if (key === 'PID' || (key === 'PID_PADDED' && object[key] && !pidOverride)) { + if ((key === 'PID' || key === 'PID_PADDED') && object[key] && !forceSimplePid) { cql.push( `PIN ilike '%${object[key]}%' OR PID ilike '%${object[key]}%' OR PID_PADDED ilike '%${object[key]}%'`, ); diff --git a/frontend/src/constants/API.ts b/frontend/src/constants/API.ts index 05c06bd464..a1839ec0cd 100644 --- a/frontend/src/constants/API.ts +++ b/frontend/src/constants/API.ts @@ -83,6 +83,7 @@ export const RESEARCH_PURPOSE_TYPES = 'PimsResearchPurposeType'; export const PROPERTY_RESEARCH_PURPOSE_TYPES = 'PimsPropResearchPurposeType'; export const PROPERTY_LAND_PARCEL_TYPES = 'PimsPropertyType'; export const PPH_STATUS_TYPES = 'PimsPphStatusType'; +export const DOCUMENT_STATUS_TYPES = 'PimsDocumentStatusType'; // TODO: This should all be removed from this and moved to the useApi* hooks. // Auth Service diff --git a/frontend/src/constants/documentTypes.ts b/frontend/src/constants/documentTypes.ts new file mode 100644 index 0000000000..44584592db --- /dev/null +++ b/frontend/src/constants/documentTypes.ts @@ -0,0 +1,4 @@ +export enum DocumentTypes { + FILE = 'file', + ACTIVITY = 'activity', +} diff --git a/frontend/src/features/admin/edit-user/__snapshots__/EditUserPage.test.tsx.snap b/frontend/src/features/admin/edit-user/__snapshots__/EditUserPage.test.tsx.snap index d128eae483..5b99f1714b 100644 --- a/frontend/src/features/admin/edit-user/__snapshots__/EditUserPage.test.tsx.snap +++ b/frontend/src/features/admin/edit-user/__snapshots__/EditUserPage.test.tsx.snap @@ -8,12 +8,7 @@ exports[`Edit user page EditUserPage renders 1`] = `
- .c4 { - margin-left: 0.5rem; - cursor: pointer; -} - -.c6.btn { + .c6.btn { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -146,6 +141,11 @@ exports[`Edit user page EditUserPage renders 1`] = ` margin-right: 0; } +.c4 { + margin-left: 0.5rem; + cursor: pointer; +} + .c1 { font-family: 'BCSans-Bold'; font-size: 3.2rem; diff --git a/frontend/src/features/contacts/contact/create/Organization/__snapshots__/CreateOrganizationForm.test.tsx.snap b/frontend/src/features/contacts/contact/create/Organization/__snapshots__/CreateOrganizationForm.test.tsx.snap index 6de0230687..5fdaee6c83 100644 --- a/frontend/src/features/contacts/contact/create/Organization/__snapshots__/CreateOrganizationForm.test.tsx.snap +++ b/frontend/src/features/contacts/contact/create/Organization/__snapshots__/CreateOrganizationForm.test.tsx.snap @@ -144,6 +144,40 @@ exports[`CreateOrganizationForm renders as expected 1`] = ` margin-right: 0; } +.c10.c10.btn { + color: #aaaaaa; + -webkit-text-decoration: none; + text-decoration: none; + line-height: unset; +} + +.c10.c10.btn .text { + display: none; +} + +.c10.c10.btn:hover, +.c10.c10.btn:active, +.c10.c10.btn:focus { + color: #d8292f; + -webkit-text-decoration: none; + text-decoration: none; + opacity: unset; + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: row; + -ms-flex-direction: row; + flex-direction: row; +} + +.c10.c10.btn:hover .text, +.c10.c10.btn:active .text, +.c10.c10.btn:focus .text { + display: inline; + line-height: 2rem; +} + .c0 { display: -webkit-box; display: -webkit-flex; @@ -193,40 +227,6 @@ exports[`CreateOrganizationForm renders as expected 1`] = ` padding: 2.5rem; } -.c10.c10.btn { - color: #aaaaaa; - -webkit-text-decoration: none; - text-decoration: none; - line-height: unset; -} - -.c10.c10.btn .text { - display: none; -} - -.c10.c10.btn:hover, -.c10.c10.btn:active, -.c10.c10.btn:focus { - color: #d8292f; - -webkit-text-decoration: none; - text-decoration: none; - opacity: unset; - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; -} - -.c10.c10.btn:hover .text, -.c10.c10.btn:active .text, -.c10.c10.btn:focus .text { - display: inline; - line-height: 2rem; -} - .c8 { display: -webkit-box; display: -webkit-flex; diff --git a/frontend/src/features/contacts/contact/create/Person/__snapshots__/CreatePersonForm.test.tsx.snap b/frontend/src/features/contacts/contact/create/Person/__snapshots__/CreatePersonForm.test.tsx.snap index 810f3de207..ef7606107e 100644 --- a/frontend/src/features/contacts/contact/create/Person/__snapshots__/CreatePersonForm.test.tsx.snap +++ b/frontend/src/features/contacts/contact/create/Person/__snapshots__/CreatePersonForm.test.tsx.snap @@ -144,6 +144,40 @@ exports[`CreatePersonForm renders as expected 1`] = ` margin-right: 0; } +.c11.c11.btn { + color: #aaaaaa; + -webkit-text-decoration: none; + text-decoration: none; + line-height: unset; +} + +.c11.c11.btn .text { + display: none; +} + +.c11.c11.btn:hover, +.c11.c11.btn:active, +.c11.c11.btn:focus { + color: #d8292f; + -webkit-text-decoration: none; + text-decoration: none; + opacity: unset; + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: row; + -ms-flex-direction: row; + flex-direction: row; +} + +.c11.c11.btn:hover .text, +.c11.c11.btn:active .text, +.c11.c11.btn:focus .text { + display: inline; + line-height: 2rem; +} + .c6 button.close { font-size: 2.4rem; } @@ -197,40 +231,6 @@ exports[`CreatePersonForm renders as expected 1`] = ` gap: 1.6rem; } -.c11.c11.btn { - color: #aaaaaa; - -webkit-text-decoration: none; - text-decoration: none; - line-height: unset; -} - -.c11.c11.btn .text { - display: none; -} - -.c11.c11.btn:hover, -.c11.c11.btn:active, -.c11.c11.btn:focus { - color: #d8292f; - -webkit-text-decoration: none; - text-decoration: none; - opacity: unset; - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; -} - -.c11.c11.btn:hover .text, -.c11.c11.btn:active .text, -.c11.c11.btn:focus .text { - display: inline; - line-height: 2rem; -} - .c9 { display: -webkit-box; display: -webkit-flex; diff --git a/frontend/src/features/contacts/contact/create/__snapshots__/CreateContactContainer.test.tsx.snap b/frontend/src/features/contacts/contact/create/__snapshots__/CreateContactContainer.test.tsx.snap index 993bd2ec5b..42db090581 100644 --- a/frontend/src/features/contacts/contact/create/__snapshots__/CreateContactContainer.test.tsx.snap +++ b/frontend/src/features/contacts/contact/create/__snapshots__/CreateContactContainer.test.tsx.snap @@ -8,11 +8,7 @@ exports[`CreateContactContainer component should render as expected 1`] = `
- .c11 button.close { - font-size: 2.4rem; -} - -.c15.btn { + .c15.btn { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -145,6 +141,44 @@ exports[`CreateContactContainer component should render as expected 1`] = ` margin-right: 0; } +.c16.c16.btn { + color: #aaaaaa; + -webkit-text-decoration: none; + text-decoration: none; + line-height: unset; +} + +.c16.c16.btn .text { + display: none; +} + +.c16.c16.btn:hover, +.c16.c16.btn:active, +.c16.c16.btn:focus { + color: #d8292f; + -webkit-text-decoration: none; + text-decoration: none; + opacity: unset; + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: row; + -ms-flex-direction: row; + flex-direction: row; +} + +.c16.c16.btn:hover .text, +.c16.c16.btn:active .text, +.c16.c16.btn:focus .text { + display: inline; + line-height: 2rem; +} + +.c11 button.close { + font-size: 2.4rem; +} + .c9 { border-radius: 1rem; width: 100%; @@ -232,40 +266,6 @@ exports[`CreateContactContainer component should render as expected 1`] = ` flex-direction: row; } -.c16.c16.btn { - color: #aaaaaa; - -webkit-text-decoration: none; - text-decoration: none; - line-height: unset; -} - -.c16.c16.btn .text { - display: none; -} - -.c16.c16.btn:hover, -.c16.c16.btn:active, -.c16.c16.btn:focus { - color: #d8292f; - -webkit-text-decoration: none; - text-decoration: none; - opacity: unset; - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; -} - -.c16.c16.btn:hover .text, -.c16.c16.btn:active .text, -.c16.c16.btn:focus .text { - display: inline; - line-height: 2rem; -} - .c2 { text-align: left; } diff --git a/frontend/src/features/contacts/contact/edit/Organization/__snapshots__/UpdateOrganizationForm.test.tsx.snap b/frontend/src/features/contacts/contact/edit/Organization/__snapshots__/UpdateOrganizationForm.test.tsx.snap index 9847d95324..bbbeb79506 100644 --- a/frontend/src/features/contacts/contact/edit/Organization/__snapshots__/UpdateOrganizationForm.test.tsx.snap +++ b/frontend/src/features/contacts/contact/edit/Organization/__snapshots__/UpdateOrganizationForm.test.tsx.snap @@ -150,39 +150,6 @@ exports[`UpdateOrganizationForm renders as expected 1`] = ` padding: 2.5rem; } -.c2 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: column; - -ms-flex-direction: column; - flex-direction: column; - gap: 1.6rem; -} - -.c6 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; - gap: 0.5rem; -} - -.c13 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; - gap: 1.6rem; -} - .c10.c10.btn { color: #aaaaaa; -webkit-text-decoration: none; @@ -217,6 +184,39 @@ exports[`UpdateOrganizationForm renders as expected 1`] = ` line-height: 2rem; } +.c2 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + gap: 1.6rem; +} + +.c6 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: row; + -ms-flex-direction: row; + flex-direction: row; + gap: 0.5rem; +} + +.c13 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: row; + -ms-flex-direction: row; + flex-direction: row; + gap: 1.6rem; +} + .c8 { display: -webkit-box; display: -webkit-flex; diff --git a/frontend/src/features/contacts/contact/edit/Person/__snapshots__/UpdatePersonForm.test.tsx.snap b/frontend/src/features/contacts/contact/edit/Person/__snapshots__/UpdatePersonForm.test.tsx.snap index 965ebac58a..500dbf6e6c 100644 --- a/frontend/src/features/contacts/contact/edit/Person/__snapshots__/UpdatePersonForm.test.tsx.snap +++ b/frontend/src/features/contacts/contact/edit/Person/__snapshots__/UpdatePersonForm.test.tsx.snap @@ -154,39 +154,6 @@ exports[`UpdatePersonForm renders as expected 1`] = ` padding: 2.5rem; } -.c2 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: column; - -ms-flex-direction: column; - flex-direction: column; - gap: 1.6rem; -} - -.c7 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; - gap: 0.5rem; -} - -.c13 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; - gap: 1.6rem; -} - .c11.c11.btn { color: #aaaaaa; -webkit-text-decoration: none; @@ -221,6 +188,39 @@ exports[`UpdatePersonForm renders as expected 1`] = ` line-height: 2rem; } +.c2 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + gap: 1.6rem; +} + +.c7 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: row; + -ms-flex-direction: row; + flex-direction: row; + gap: 0.5rem; +} + +.c13 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: row; + -ms-flex-direction: row; + flex-direction: row; + gap: 1.6rem; +} + .c9 { display: -webkit-box; display: -webkit-flex; diff --git a/frontend/src/features/contacts/contact/edit/__snapshots__/UpdateContactContainer.test.tsx.snap b/frontend/src/features/contacts/contact/edit/__snapshots__/UpdateContactContainer.test.tsx.snap index a57a27b0c3..1116b02db5 100644 --- a/frontend/src/features/contacts/contact/edit/__snapshots__/UpdateContactContainer.test.tsx.snap +++ b/frontend/src/features/contacts/contact/edit/__snapshots__/UpdateContactContainer.test.tsx.snap @@ -8,11 +8,7 @@ exports[`UpdateContactContainer renders as expected 1`] = `
- .c9 button.close { - font-size: 2.4rem; -} - -.c13.btn { + .c13.btn { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -145,6 +141,44 @@ exports[`UpdateContactContainer renders as expected 1`] = ` margin-right: 0; } +.c14.c14.btn { + color: #aaaaaa; + -webkit-text-decoration: none; + text-decoration: none; + line-height: unset; +} + +.c14.c14.btn .text { + display: none; +} + +.c14.c14.btn:hover, +.c14.c14.btn:active, +.c14.c14.btn:focus { + color: #d8292f; + -webkit-text-decoration: none; + text-decoration: none; + opacity: unset; + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: row; + -ms-flex-direction: row; + flex-direction: row; +} + +.c14.c14.btn:hover .text, +.c14.c14.btn:active .text, +.c14.c14.btn:focus .text { + display: inline; + line-height: 2rem; +} + +.c9 button.close { + font-size: 2.4rem; +} + .c6 { border-radius: 1rem; width: 100%; @@ -212,40 +246,6 @@ exports[`UpdateContactContainer renders as expected 1`] = ` flex-direction: row; } -.c14.c14.btn { - color: #aaaaaa; - -webkit-text-decoration: none; - text-decoration: none; - line-height: unset; -} - -.c14.c14.btn .text { - display: none; -} - -.c14.c14.btn:hover, -.c14.c14.btn:active, -.c14.c14.btn:focus { - color: #d8292f; - -webkit-text-decoration: none; - text-decoration: none; - opacity: unset; - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; -} - -.c14.c14.btn:hover .text, -.c14.c14.btn:active .text, -.c14.c14.btn:focus .text { - display: inline; - line-height: 2rem; -} - .c2 { text-align: left; } diff --git a/frontend/src/features/documents/list/DocumentFilter/DocumentFilterForm.test.tsx b/frontend/src/features/documents/list/DocumentFilter/DocumentFilterForm.test.tsx new file mode 100644 index 0000000000..54744adb89 --- /dev/null +++ b/frontend/src/features/documents/list/DocumentFilter/DocumentFilterForm.test.tsx @@ -0,0 +1,87 @@ +import axios from 'axios'; +import MockAdapter from 'axios-mock-adapter'; +import { Formik } from 'formik'; +import { createMemoryHistory } from 'history'; +import { defaultDocumentFilter } from 'interfaces/IDocumentResults'; +import { noop } from 'lodash'; +import { mockLookups } from 'mocks'; +import { mockDocumentTypesResponse } from 'mocks/mockDocuments'; +import { lookupCodesSlice } from 'store/slices/lookupCodes'; +import { fillInput, renderAsync, RenderOptions } from 'utils/test-utils'; + +import { DocumentFilterForm, IDocumentFilterFormProps } from './DocumentFilterForm'; + +const history = createMemoryHistory(); +const mockAxios = new MockAdapter(axios); +const onSetFilter = jest.fn(); +const storeState = { + [lookupCodesSlice.name]: { lookupCodes: mockLookups }, +}; + +describe('DocumentFilterForm component', () => { + const setup = async ( + renderOptions: RenderOptions & + Partial & { + initialValues?: any; + } = {}, + ) => { + // render component under test + const component = await renderAsync( + + + , + { + ...renderOptions, + store: storeState, + history, + }, + ); + + return { + component, + }; + }; + + beforeEach(() => { + mockAxios.reset(); + mockAxios.onGet(`documents/document-types`).reply(200, mockDocumentTypesResponse()); + }); + + it('renders as expected', async () => { + const { component } = await setup({}); + + expect(component.asFragment()).toMatchSnapshot(); + }); + + it('renders with data as expected', async () => { + const { component } = await setup({ + initialValues: { ...defaultDocumentFilter }, + }); + + expect(component.asFragment()).toMatchSnapshot(); + }); + + it('renders documentType with data as expected', async () => { + const { + component: { getByTestId, container }, + } = await setup({ + initialValues: { ...defaultDocumentFilter }, + }); + + await fillInput(container, 'documentType', 'Registered', 'select'); + + expect(getByTestId('document-type')).not.toBeNull(); + }); + + it('renders documentStatus with data as expected', async () => { + const { + component: { getByTestId, container }, + } = await setup({ + initialValues: { ...defaultDocumentFilter }, + }); + + await fillInput(container, 'documentStatus', 'Draft', 'select'); + + expect(getByTestId('document-status')).not.toBeNull(); + }); +}); diff --git a/frontend/src/features/documents/list/DocumentFilter/DocumentFilterForm.tsx b/frontend/src/features/documents/list/DocumentFilter/DocumentFilterForm.tsx new file mode 100644 index 0000000000..9468b99986 --- /dev/null +++ b/frontend/src/features/documents/list/DocumentFilter/DocumentFilterForm.tsx @@ -0,0 +1,96 @@ +import { ResetButton, SearchButton } from 'components/common/buttons'; +import { Form, Select, SelectOption } from 'components/common/form'; +import * as API from 'constants/API'; +import { Formik } from 'formik'; +import { useApiDocuments } from 'hooks/pims-api/useApiDocuments'; +import useIsMounted from 'hooks/useIsMounted'; +import useLookupCodeHelpers from 'hooks/useLookupCodeHelpers'; +import { defaultDocumentFilter, IDocumentFilter } from 'interfaces/IDocumentResults'; +import React from 'react'; +import { Col, Row } from 'react-bootstrap'; +import styled from 'styled-components'; + +export interface IDocumentFilterFormProps { + documentFilter?: IDocumentFilter; + onSetFilter: (filterValues: IDocumentFilter) => void; +} + +export const DocumentFilterForm = (props: IDocumentFilterFormProps) => { + const { getOptionsByType } = useLookupCodeHelpers(); + const documentStatusTypeOptions = getOptionsByType(API.DOCUMENT_STATUS_TYPES); + const isMounted = useIsMounted(); + const { getDocumentTypes } = useApiDocuments(); + const [documentTypes, setDocumentTypes] = React.useState([]); + + React.useEffect(() => { + getDocumentTypes().then(({ data }) => { + if (data && isMounted()) { + setDocumentTypes( + data.map(dt => { + return { + label: dt.documentType, + value: dt.id ? dt.id.toString() : '', + }; + }), + ); + } + }); + }, [isMounted, getDocumentTypes]); + + return ( + + enableReinitialize + initialValues={props.documentFilter ?? defaultDocumentFilter} + onSubmit={(values: IDocumentFilter, { setSubmitting }: any) => { + props.onSetFilter(values); + setSubmitting(false); + }} + > + {formikProps => ( + + + + + + + + + + + + { + formikProps.resetForm(); + props.onSetFilter(defaultDocumentFilter); + }} + /> + + + + )} + + ); +}; + +const FilterBoxForm = styled(Form)` + background-color: ${({ theme }) => theme.css.filterBoxColor}; + border-radius: 0.5rem; +`; + +const ColButtons = styled(Col)` + border-left: 0.2rem solid white; +`; diff --git a/frontend/src/features/documents/list/DocumentFilter/__snapshots__/DocumentFilterForm.test.tsx.snap b/frontend/src/features/documents/list/DocumentFilter/__snapshots__/DocumentFilterForm.test.tsx.snap new file mode 100644 index 0000000000..f09e695acf --- /dev/null +++ b/frontend/src/features/documents/list/DocumentFilter/__snapshots__/DocumentFilterForm.test.tsx.snap @@ -0,0 +1,549 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`DocumentFilterForm component renders as expected 1`] = ` + +
+
+ .c2.btn { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-align-items: center; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + -webkit-box-pack: center; + -webkit-justify-content: center; + -ms-flex-pack: center; + justify-content: center; + padding: 0.4rem 1.2rem; + min-height: 3rem; + border: 0.2rem solid transparent; + border-radius: 0.4rem; + text-align: center; + -webkit-text-decoration: none; + text-decoration: none; + font-size: 1.8rem; + font-family: 'BCSans','Noto Sans',Verdana,Arial,sans-serif; + font-weight: 700; + -webkit-letter-spacing: 0.1rem; + -moz-letter-spacing: 0.1rem; + -ms-letter-spacing: 0.1rem; + letter-spacing: 0.1rem; + cursor: pointer; +} + +.c2.btn:hover { + -webkit-text-decoration: underline; + text-decoration: underline; + opacity: 0.8; +} + +.c2.btn:focus { + outline-width: 0.4rem; + outline-style: solid; + outline-offset: 1px; + box-shadow: none; +} + +.c2.btn.btn-primary { + border: none; +} + +.c2.btn.btn-secondary { + background: none; +} + +.c2.btn.btn-info { + border: none; + background: none; + padding-left: 0.6rem; + padding-right: 0.6rem; +} + +.c2.btn.btn-info:hover, +.c2.btn.btn-info:active, +.c2.btn.btn-info:focus { + background: none; +} + +.c2.btn.btn-light { + border: none; +} + +.c2.btn.btn-dark { + border: none; +} + +.c2.btn.btn-link { + font-size: 1.6rem; + font-weight: 400; + background: none; + border: none; + -webkit-text-decoration: none; + text-decoration: none; + min-height: 2.5rem; + line-height: 3rem; + -webkit-box-pack: left; + -webkit-justify-content: left; + -ms-flex-pack: left; + justify-content: left; + -webkit-letter-spacing: unset; + -moz-letter-spacing: unset; + -ms-letter-spacing: unset; + letter-spacing: unset; + padding: 0; +} + +.c2.btn.btn-link:hover, +.c2.btn.btn-link:active, +.c2.btn.btn-link:focus { + -webkit-text-decoration: underline; + text-decoration: underline; + border: none; + background: none; + box-shadow: none; + outline: none; +} + +.c2.btn.btn-link:disabled, +.c2.btn.btn-link.disabled { + background: none; + pointer-events: none; +} + +.c2.btn:disabled, +.c2.btn:disabled:hover { + box-shadow: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + pointer-events: none; + cursor: not-allowed; + opacity: 0.65; +} + +.c2.Button .Button__icon { + margin-right: 1.6rem; +} + +.c2.Button--icon-only:focus { + outline: none; +} + +.c2.Button--icon-only .Button__icon { + margin-right: 0; +} + +.c0 { + border-radius: 0.5rem; +} + +.c1 { + border-left: 0.2rem solid white; +} + +
+
+
+ +
+
+
+ +
+
+
+
+ +
+
+
+ + +
+
+
+ +`; + +exports[`DocumentFilterForm component renders with data as expected 1`] = ` + +
+
+ .c2.btn { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-align-items: center; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + -webkit-box-pack: center; + -webkit-justify-content: center; + -ms-flex-pack: center; + justify-content: center; + padding: 0.4rem 1.2rem; + min-height: 3rem; + border: 0.2rem solid transparent; + border-radius: 0.4rem; + text-align: center; + -webkit-text-decoration: none; + text-decoration: none; + font-size: 1.8rem; + font-family: 'BCSans','Noto Sans',Verdana,Arial,sans-serif; + font-weight: 700; + -webkit-letter-spacing: 0.1rem; + -moz-letter-spacing: 0.1rem; + -ms-letter-spacing: 0.1rem; + letter-spacing: 0.1rem; + cursor: pointer; +} + +.c2.btn:hover { + -webkit-text-decoration: underline; + text-decoration: underline; + opacity: 0.8; +} + +.c2.btn:focus { + outline-width: 0.4rem; + outline-style: solid; + outline-offset: 1px; + box-shadow: none; +} + +.c2.btn.btn-primary { + border: none; +} + +.c2.btn.btn-secondary { + background: none; +} + +.c2.btn.btn-info { + border: none; + background: none; + padding-left: 0.6rem; + padding-right: 0.6rem; +} + +.c2.btn.btn-info:hover, +.c2.btn.btn-info:active, +.c2.btn.btn-info:focus { + background: none; +} + +.c2.btn.btn-light { + border: none; +} + +.c2.btn.btn-dark { + border: none; +} + +.c2.btn.btn-link { + font-size: 1.6rem; + font-weight: 400; + background: none; + border: none; + -webkit-text-decoration: none; + text-decoration: none; + min-height: 2.5rem; + line-height: 3rem; + -webkit-box-pack: left; + -webkit-justify-content: left; + -ms-flex-pack: left; + justify-content: left; + -webkit-letter-spacing: unset; + -moz-letter-spacing: unset; + -ms-letter-spacing: unset; + letter-spacing: unset; + padding: 0; +} + +.c2.btn.btn-link:hover, +.c2.btn.btn-link:active, +.c2.btn.btn-link:focus { + -webkit-text-decoration: underline; + text-decoration: underline; + border: none; + background: none; + box-shadow: none; + outline: none; +} + +.c2.btn.btn-link:disabled, +.c2.btn.btn-link.disabled { + background: none; + pointer-events: none; +} + +.c2.btn:disabled, +.c2.btn:disabled:hover { + box-shadow: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + pointer-events: none; + cursor: not-allowed; + opacity: 0.65; +} + +.c2.Button .Button__icon { + margin-right: 1.6rem; +} + +.c2.Button--icon-only:focus { + outline: none; +} + +.c2.Button--icon-only .Button__icon { + margin-right: 0; +} + +.c0 { + border-radius: 0.5rem; +} + +.c1 { + border-left: 0.2rem solid white; +} + +
+
+
+ +
+
+
+ +
+
+
+
+ +
+
+
+ + +
+
+
+ +`; diff --git a/frontend/src/features/documents/list/DocumentListView.test.tsx b/frontend/src/features/documents/list/DocumentListView.test.tsx new file mode 100644 index 0000000000..4dd1f93b94 --- /dev/null +++ b/frontend/src/features/documents/list/DocumentListView.test.tsx @@ -0,0 +1,69 @@ +import axios from 'axios'; +import MockAdapter from 'axios-mock-adapter'; +import { DocumentTypes } from 'constants/documentTypes'; +import { mockLookups } from 'mocks'; +import { mockDocumentsResponse, mockDocumentTypesResponse } from 'mocks/mockDocuments'; +import { lookupCodesSlice } from 'store/slices/lookupCodes'; +import { render, RenderOptions, waitFor } from 'utils/test-utils'; + +import { DocumentListView, IDocumentListViewProps } from './DocumentListView'; + +const mockAxios = new MockAdapter(axios); +const storeState = { + [lookupCodesSlice.name]: { lookupCodes: mockLookups }, +}; + +describe('Document List View', () => { + const setup = (renderOptions?: RenderOptions & IDocumentListViewProps) => { + // render component under test + const component = render( + , + { + ...renderOptions, + store: storeState, + }, + ); + + return { + ...component, + }; + }; + + beforeEach(() => { + mockAxios.reset(); + mockAxios.onGet(`documents/document-types`).reply(200, mockDocumentTypesResponse()); + }); + + it('renders as expected', async () => { + const { asFragment } = setup(); + const fragment = await waitFor(() => asFragment()); + expect(fragment).toMatchSnapshot(); + }); + + it('should have the Documents type in the component', () => { + const { getByTestId } = setup({ + hideFilters: false, + isLoading: false, + documentType: DocumentTypes.FILE, + entityId: 0, + documentResults: mockDocumentsResponse(), + }); + expect(getByTestId('document-type')).toBeInTheDocument(); + }); + + it('should not have the Documents status in the component', () => { + const { getByTestId } = setup({ + hideFilters: false, + isLoading: false, + documentType: DocumentTypes.FILE, + entityId: 0, + documentResults: mockDocumentsResponse(), + }); + expect(getByTestId('document-type')).toBeInTheDocument(); + }); +}); diff --git a/frontend/src/features/documents/list/DocumentListView.tsx b/frontend/src/features/documents/list/DocumentListView.tsx new file mode 100644 index 0000000000..1d467f4026 --- /dev/null +++ b/frontend/src/features/documents/list/DocumentListView.tsx @@ -0,0 +1,78 @@ +import { TableSort } from 'components/Table/TableSort'; +import { DocumentTypes } from 'constants/documentTypes'; +import { defaultDocumentFilter, IDocumentFilter } from 'interfaces/IDocumentResults'; +import { orderBy } from 'lodash'; +import { Api_Document } from 'models/api/Document'; +import React from 'react'; + +import { DocumentFilterForm } from './DocumentFilter/DocumentFilterForm'; +import { DocumentResults } from './DocumentResults/DocumentResults'; +import * as Styled from './styles'; + +export interface IDocumentListViewProps { + entityId: number; + documentType: DocumentTypes; + isLoading: boolean; + documentResults: Api_Document[]; + hideFilters?: boolean; + defaultFilters?: IDocumentFilter; +} +/** + * Page that displays documents information. + */ +export const DocumentListView: React.FunctionComponent = ( + props: IDocumentListViewProps, +) => { + const { documentResults, isLoading, defaultFilters, hideFilters } = props; + const [sort, setSort] = React.useState>({}); + + const [filters, setFilters] = React.useState( + defaultFilters ?? defaultDocumentFilter, + ); + + const sortedFilteredDocuments = React.useMemo(() => { + if (documentResults?.length > 0) { + let documentItems = [...documentResults]; + + if (filters) { + documentItems = documentItems.filter(document => { + return ( + (!filters.documentTypeId || + document.documentTypeId === Number(filters.documentTypeId)) && + (!filters.status || document.statusTypeCode?.id === filters.status) + ); + }); + } + if (sort) { + const sortFields = Object.keys(sort); + if (sortFields?.length > 0) { + const keyName = (sort as any)[sortFields[0]]; + return orderBy( + documentItems, + sortFields[0] === 'statusTypeCode' ? 'statusTypeCode.description' : sortFields[0], + keyName, + ); + } + } + return documentItems; + } + return []; + }, [documentResults, sort, filters]); + + return ( + + + Documents + {!hideFilters && } + + + + ); +}; + +export default DocumentListView; diff --git a/frontend/src/features/documents/list/DocumentResults/DocumentResults.test.tsx b/frontend/src/features/documents/list/DocumentResults/DocumentResults.test.tsx new file mode 100644 index 0000000000..b6ad6a2419 --- /dev/null +++ b/frontend/src/features/documents/list/DocumentResults/DocumentResults.test.tsx @@ -0,0 +1,46 @@ +import { mockDocumentsResponse } from 'mocks/mockDocuments'; +import { render, RenderOptions } from 'utils/test-utils'; + +import { DocumentResults, IDocumentResultProps } from './DocumentResults'; + +const setSort = jest.fn(); + +// mock auth library +jest.mock('@react-keycloak/web'); + +// render component under test +const setup = (renderOptions: RenderOptions & Partial = { results: [] }) => { + const { results, ...rest } = renderOptions; + const utils = render(, { + ...rest, + }); + const tableRows = utils.container.querySelectorAll('.table .tbody .tr-wrapper'); + // long css selector to: get the FIRST header or table, then get the SVG up/down sort buttons + const sortButtons = utils.container.querySelector( + '.table .thead .tr .sortable-column div', + ) as HTMLElement; + return { + ...utils, + tableRows, + sortButtons, + }; +}; + +describe('Document Results Table', () => { + beforeEach(() => { + setSort.mockClear(); + }); + + it('matches snapshot', async () => { + const { asFragment } = setup({ results: mockDocumentsResponse() }); + expect(asFragment()).toMatchSnapshot(); + }); + + it('displays a message when no matching records found', async () => { + const { tableRows, findAllByText } = setup({ results: [] }); + + expect(tableRows.length).toBe(0); + const toasts = await findAllByText('No matching Documents found'); + expect(toasts[0]).toBeVisible(); + }); +}); diff --git a/frontend/src/features/documents/list/DocumentResults/DocumentResults.tsx b/frontend/src/features/documents/list/DocumentResults/DocumentResults.tsx new file mode 100644 index 0000000000..786faae124 --- /dev/null +++ b/frontend/src/features/documents/list/DocumentResults/DocumentResults.tsx @@ -0,0 +1,70 @@ +import { ColumnWithProps, DateCell, renderTypeCode, Table } from 'components/Table'; +import { TableSort } from 'components/Table/TableSort'; +import { Api_Document } from 'models/api/Document'; + +export interface IDocumentResultProps { + results: Api_Document[]; + loading?: boolean; + + sort: TableSort; + setSort: (value: TableSort) => void; +} + +const columns: ColumnWithProps[] = [ + { + Header: 'Document type', + accessor: 'documentType', + align: 'left', + sortable: true, + minWidth: 30, + maxWidth: 40, + }, + { + Header: 'File name', + accessor: 'fileName', + sortable: true, + width: 50, + maxWidth: 100, + }, + { + Header: 'Upload date', + accessor: 'appCreateTimestamp', + sortable: true, + width: 10, + maxWidth: 20, + Cell: DateCell, + }, + { + Header: 'Uploaded by', + accessor: 'appCreateUserid', + sortable: true, + width: 10, + maxWidth: 20, + }, + { + Header: 'Status', + accessor: 'statusTypeCode', + sortable: true, + width: 10, + maxWidth: 20, + Cell: renderTypeCode, + }, +]; +export function DocumentResults(props: IDocumentResultProps) { + const { results, setSort, sort, ...rest } = props; + + return ( + + name="documentsTable" + manualSortBy={false} + lockPageSize={true} + manualPagination={false} + totalItems={results.length} + columns={columns} + externalSort={{ sort, setSort }} + data={results ?? []} + noRowsMessage="No matching Documents found" + {...rest} + > + ); +} diff --git a/frontend/src/features/documents/list/DocumentResults/__snapshots__/DocumentResults.test.tsx.snap b/frontend/src/features/documents/list/DocumentResults/__snapshots__/DocumentResults.test.tsx.snap new file mode 100644 index 0000000000..fedcb13aa9 --- /dev/null +++ b/frontend/src/features/documents/list/DocumentResults/__snapshots__/DocumentResults.test.tsx.snap @@ -0,0 +1,550 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Document Results Table matches snapshot 1`] = ` + +
+
+ .c0 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + -webkit-align-items: center; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + -webkit-box-pack: center; + -webkit-justify-content: center; + -ms-flex-pack: center; + justify-content: center; + margin-left: 0.5rem; +} + +.c2 { + width: 1.6rem; + height: 1.6rem; +} + +.c1 { + width: 1.6rem; + height: 1.6rem; +} + +
+
+
+
+
+ Document type +
+ + + + + + +
+
+
+
+
+ File name +
+ + + + + + +
+
+
+
+
+ Upload date +
+ + + + + + +
+
+
+
+
+ Uploaded by +
+ + + + + + +
+
+
+
+
+ Status +
+ + + + + + +
+
+
+
+
+
+
+
+
+ Survey +
+
+ Survey.pdf +
+
+ Jan 10, 2022 +
+
+ James Bond +
+
+ Draft +
+
+
+
+
+
+ Photo +
+
+ Photo_Rest.pdf +
+
+ Jan 11, 2022 +
+
+ Amelia Bond +
+
+ Amended +
+
+
+
+
+
+ Correspondence +
+
+ Test Correspondence.pdf +
+
+ Jan 13, 2022 +
+
+ Jerry J +
+
+ Registered +
+
+
+
+
+
+ Correspondence +
+
+ New Correspondence.pdf +
+
+ Jan 14, 2022 +
+
+ Tom Hank +
+
+ Sent +
+
+
+
+
+
+
+ + 1 - 4 of 4 + +
+
+
+ +
+
+ +`; diff --git a/frontend/src/features/documents/list/__snapshots__/DocumentListView.test.tsx.snap b/frontend/src/features/documents/list/__snapshots__/DocumentListView.test.tsx.snap new file mode 100644 index 0000000000..c00f11f553 --- /dev/null +++ b/frontend/src/features/documents/list/__snapshots__/DocumentListView.test.tsx.snap @@ -0,0 +1,861 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`Document List View renders as expected 1`] = ` + +
+
+ .c6.btn { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-align-items: center; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + -webkit-box-pack: center; + -webkit-justify-content: center; + -ms-flex-pack: center; + justify-content: center; + padding: 0.4rem 1.2rem; + min-height: 3rem; + border: 0.2rem solid transparent; + border-radius: 0.4rem; + text-align: center; + -webkit-text-decoration: none; + text-decoration: none; + font-size: 1.8rem; + font-family: 'BCSans','Noto Sans',Verdana,Arial,sans-serif; + font-weight: 700; + -webkit-letter-spacing: 0.1rem; + -moz-letter-spacing: 0.1rem; + -ms-letter-spacing: 0.1rem; + letter-spacing: 0.1rem; + cursor: pointer; +} + +.c6.btn:hover { + -webkit-text-decoration: underline; + text-decoration: underline; + opacity: 0.8; +} + +.c6.btn:focus { + outline-width: 0.4rem; + outline-style: solid; + outline-offset: 1px; + box-shadow: none; +} + +.c6.btn.btn-primary { + border: none; +} + +.c6.btn.btn-secondary { + background: none; +} + +.c6.btn.btn-info { + border: none; + background: none; + padding-left: 0.6rem; + padding-right: 0.6rem; +} + +.c6.btn.btn-info:hover, +.c6.btn.btn-info:active, +.c6.btn.btn-info:focus { + background: none; +} + +.c6.btn.btn-light { + border: none; +} + +.c6.btn.btn-dark { + border: none; +} + +.c6.btn.btn-link { + font-size: 1.6rem; + font-weight: 400; + background: none; + border: none; + -webkit-text-decoration: none; + text-decoration: none; + min-height: 2.5rem; + line-height: 3rem; + -webkit-box-pack: left; + -webkit-justify-content: left; + -ms-flex-pack: left; + justify-content: left; + -webkit-letter-spacing: unset; + -moz-letter-spacing: unset; + -ms-letter-spacing: unset; + letter-spacing: unset; + padding: 0; +} + +.c6.btn.btn-link:hover, +.c6.btn.btn-link:active, +.c6.btn.btn-link:focus { + -webkit-text-decoration: underline; + text-decoration: underline; + border: none; + background: none; + box-shadow: none; + outline: none; +} + +.c6.btn.btn-link:disabled, +.c6.btn.btn-link.disabled { + background: none; + pointer-events: none; +} + +.c6.btn:disabled, +.c6.btn:disabled:hover { + box-shadow: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + pointer-events: none; + cursor: not-allowed; + opacity: 0.65; +} + +.c6.Button .Button__icon { + margin-right: 1.6rem; +} + +.c6.Button--icon-only:focus { + outline: none; +} + +.c6.Button--icon-only .Button__icon { + margin-right: 0; +} + +.c7 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + -webkit-align-items: center; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + -webkit-box-pack: center; + -webkit-justify-content: center; + -ms-flex-pack: center; + justify-content: center; + margin-left: 0.5rem; +} + +.c9 { + width: 1.6rem; + height: 1.6rem; +} + +.c8 { + width: 1.6rem; + height: 1.6rem; +} + +.c4 { + border-radius: 0.5rem; +} + +.c5 { + border-left: 0.2rem solid white; +} + +.c1 { + width: 100%; + -webkit-box-flex: 1; + -webkit-flex-grow: 1; + -ms-flex-positive: 1; + flex-grow: 1; + overflow-y: auto; +} + +.c0 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-flex-direction: column; + -ms-flex-direction: column; + flex-direction: column; + -webkit-box-flex: 1; + -webkit-flex-grow: 1; + -ms-flex-positive: 1; + flex-grow: 1; + width: 100%; + gap: 2.5rem; + padding: 0; +} + +.c2 { + padding: 1.6rem 3.2rem; + width: 100%; +} + +.c3 { + text-align: left; +} + +
+
+

+ Documents +

+
+
+
+ +
+
+
+ +
+
+
+
+ +
+
+
+ + +
+
+
+
+
+
+
+
+ Document type +
+ + + + + + +
+
+
+
+
+ File name +
+ + + + + + +
+
+
+
+
+ Upload date +
+ + + + + + +
+
+
+
+
+ Uploaded by +
+ + + + + + +
+
+
+
+
+ Status +
+ + + + + + +
+
+
+
+
+
+
+
+
+ Survey +
+
+ Survey.pdf +
+
+ Jan 10, 2022 +
+
+ James Bond +
+
+ Draft +
+
+
+
+
+
+ Photo +
+
+ Photo_Rest.pdf +
+
+ Jan 11, 2022 +
+
+ Amelia Bond +
+
+ Amended +
+
+
+
+
+
+ Correspondence +
+
+ Test Correspondence.pdf +
+
+ Jan 13, 2022 +
+
+ Jerry J +
+
+ Registered +
+
+
+
+
+
+ Correspondence +
+
+ New Correspondence.pdf +
+
+ Jan 14, 2022 +
+
+ Tom Hank +
+
+ Sent +
+
+
+
+
+
+
+ + 1 - 4 of 4 + +
+
+
+ +
+
+
+
+ +`; diff --git a/frontend/src/features/documents/list/styles.ts b/frontend/src/features/documents/list/styles.ts new file mode 100644 index 0000000000..93ae5e6ba3 --- /dev/null +++ b/frontend/src/features/documents/list/styles.ts @@ -0,0 +1,20 @@ +import { Scrollable as ScrollableBase } from 'components/common/Scrollable/Scrollable'; +import styled from 'styled-components'; + +export const ListPage = styled.div` + display: flex; + flex-direction: column; + flex-grow: 1; + width: 100%; + gap: 2.5rem; + padding: 0; +`; + +export const Scrollable = styled(ScrollableBase)` + padding: 1.6rem 3.2rem; + width: 100%; +`; + +export const PageHeader = styled.h3` + text-align: left; +`; diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantContainer.test.tsx b/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantContainer.test.tsx index bbafd48471..ffc901be2c 100644 --- a/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantContainer.test.tsx +++ b/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantContainer.test.tsx @@ -1,3 +1,4 @@ +import { screen } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import axios from 'axios'; import MockAdapter from 'axios-mock-adapter'; @@ -5,7 +6,9 @@ import { Claims } from 'constants/claims'; import { LeaseContextProvider } from 'features/leases/context/LeaseContext'; import { createMemoryHistory } from 'history'; import { defaultLease, ILease } from 'interfaces'; +import { getMockLease } from 'mocks/mockLease'; import { + fillInput, getAllByRole as getAllByRoleBase, mockKeycloak, renderAsync, @@ -22,7 +25,7 @@ jest.mock('@react-keycloak/web'); const history = createMemoryHistory(); const mockAxios = new MockAdapter(axios); -xdescribe('AddLeaseTenantForm component', () => { +describe('AddLeaseTenantContainer component', () => { const setup = async (renderOptions: RenderOptions & { lease?: ILease } = {}) => { // render component under test const component = await renderAsync( @@ -84,8 +87,7 @@ xdescribe('AddLeaseTenantForm component', () => { const dataRow = findFirstRowTableTwo() as HTMLElement; expect(dataRow).not.toBeNull(); expect(findCell(dataRow, 3)?.textContent).toBe('Bob Billy Smith'); - expect(findCell(dataRow, 4)?.textContent).toBe('Smith'); - expect(findCell(dataRow, 5)?.textContent).toBe('Bob'); + expect(findCell(dataRow, 4)?.textContent).toBe('Not applicable'); const saveButton = getByText('Save'); expect(saveButton).not.toBeDisabled(); @@ -94,11 +96,103 @@ xdescribe('AddLeaseTenantForm component', () => { expect(mockAxios.history.put[0].data).toEqual(expectedTenantRequestData); }); }); + + it('Pre-existing items from the contact list view can be added to', async () => { + mockAxios.onPut().reply(200); + mockAxios.onGet().reply(200, { + items: sampleContactResponse, + }); + const { + component: { getByText, findByTestId, findByText, findAllByText }, + } = await setup({ lease: getMockLease() }); + + const checkbox = await findByTestId('selectrow-P2'); + userEvent.click(checkbox); + + const addButton = getByText('Add selected tenants'); + userEvent.click(addButton); + + await waitFor(async () => { + expect(await findAllByText('Bob Billy Smith')).toHaveLength(3); + }); + + expect(await findByText('French Mouse Property Management')).toBeVisible(); + expect(await findByText('Dairy Queen Forever! Property Management')).toBeVisible(); + expect(await findByText('Pussycat Property Management')).toBeVisible(); + }); + + describe('displays modal warning when a tenant organization with persons has no primary contact', () => { + it('shows the modal with expected text', async () => { + mockAxios.onPut().reply(200); + mockAxios.onGet().reply(200, { + items: [], + }); + + const { + component: { container, getByText }, + } = await setup({ lease: getMockLease() }); + // Remove the primary contact + await fillInput(container, 'tenants.0.primaryContactId', '', 'select'); + + const saveButton = getByText('Save'); + userEvent.click(saveButton); + + const modalText = await screen.findByText('Confirm save'); + expect(modalText).toBeVisible(); + }); + + it('does not save when modal is cancelled', async () => { + mockAxios.onPut().reply(200); + mockAxios.onGet().reply(200, { + items: [], + }); + + const { + component: { container, getByText }, + } = await setup({ lease: getMockLease() }); + // Remove the primary contact + await fillInput(container, 'tenants.0.primaryContactId', '', 'select'); + + const saveButton = getByText('Save'); + userEvent.click(saveButton); + + const cancelButton = await screen.findByTitle('cancel-modal'); + userEvent.click(cancelButton); + + await waitFor(() => { + expect(mockAxios.history.put).toHaveLength(0); + }); + }); + + it('saves the form when modal confirmed', async () => { + mockAxios.onPut().reply(200); + mockAxios.onGet().reply(200, { + items: [], + }); + + const { + component: { container, getByText }, + } = await setup({ lease: getMockLease() }); + // Remove the primary contact + await fillInput(container, 'tenants.0.primaryContactId', '', 'select'); + + const saveButton = getByText('Save'); + userEvent.click(saveButton); + + const modalSaveButton = await screen.findByTitle('ok-modal'); + userEvent.click(modalSaveButton); + + await waitFor(() => { + expect(mockAxios.history.put[0].data).toEqual(expectedTenantWithPrimaryContactRequestData); + }); + }); + }); }); const expectedTenantRequestData = - '{"organizations":[],"persons":[],"properties":[],"improvements":[],"securityDeposits":[],"securityDepositReturns":[],"startDate":"2020-01-01","lFileNo":"","tfaFileNo":0,"psFileNo":"","programName":"","motiName":"Moti, Name, Name","amount":0,"renewalCount":0,"tenantNotes":[],"insurances":[],"isResidential":false,"isCommercialBuilding":false,"isOtherImprovement":false,"returnNotes":"","terms":[],"tenants":[{"id":"P2","personId":2,"rowVersion":0,"summary":"Bob Billy Smith","surname":"Smith","firstName":"Bob","isDisabled":false,"leaseId":1}],"statusType":{"id":"ACTIVE","description":"Active","isDisabled":false},"region":{"regionCode":1,"regionName":"South Coast Region"},"programType":{"id":"OTHER","description":"Other","isDisabled":false},"paymentReceivableType":{"id":"RCVBL","description":"Receivable","isDisabled":false},"categoryType":{"id":"COMM","description":"Commercial","isDisabled":false},"purposeType":{"id":"BCFERRIES","description":"BC Ferries","isDisabled":false},"responsibilityType":{"id":"HQ","description":"Headquarters","isDisabled":false},"initiatorType":{"id":"PROJECT","description":"Project","isDisabled":false},"type":{"id":"LSREG","description":"Lease - Registered","isDisabled":false},"id":1}'; - + '{"organizations":[],"persons":[],"properties":[],"improvements":[],"securityDeposits":[],"securityDepositReturns":[],"startDate":"2020-01-01","lFileNo":"","tfaFileNo":0,"psFileNo":"","programName":"","motiName":"Moti, Name, Name","amount":0,"renewalCount":0,"tenantNotes":[],"insurances":[],"isResidential":false,"isCommercialBuilding":false,"isOtherImprovement":false,"returnNotes":"","terms":[],"tenants":[{"leaseId":1,"personId":2}],"hasDigitalLicense":null,"hasPhysicalLicense":null,"statusType":{"id":"ACTIVE","description":"Active","isDisabled":false},"region":{"regionCode":1,"regionName":"South Coast Region"},"programType":{"id":"OTHER","description":"Other","isDisabled":false},"paymentReceivableType":{"id":"RCVBL","description":"Receivable","isDisabled":false},"categoryType":{"id":"COMM","description":"Commercial","isDisabled":false},"purposeType":{"id":"BCFERRIES","description":"BC Ferries","isDisabled":false},"responsibilityType":{"id":"HQ","description":"Headquarters","isDisabled":false},"initiatorType":{"id":"PROJECT","description":"Project","isDisabled":false},"type":{"id":"LSREG","description":"Lease - Registered","isDisabled":false},"id":1}'; +const expectedTenantWithPrimaryContactRequestData = + '{"organizations":[],"persons":[],"properties":[],"improvements":[],"securityDeposits":[],"securityDepositReturns":[],"startDate":"","lFileNo":"","tfaFileNo":0,"psFileNo":"","programName":"","motiName":"","amount":0,"renewalCount":0,"tenantNotes":["a note","",""],"insurances":[],"isResidential":false,"isCommercialBuilding":false,"isOtherImprovement":false,"returnNotes":"","terms":[],"tenants":[{"leaseId":1,"organizationId":2,"note":"a note"},{"leaseId":1,"organizationId":3,"note":""},{"leaseId":1,"organizationId":4,"note":""}],"hasDigitalLicense":null,"hasPhysicalLicense":null,"id":1,"rowVersion":2}'; const sampleContactResponse = [ { id: 'P2', diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantContainer.tsx b/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantContainer.tsx index c1b5c37404..f3d8b4ddd9 100644 --- a/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantContainer.tsx +++ b/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantContainer.tsx @@ -62,7 +62,6 @@ export const AddLeaseTenantContainer: React.FunctionComponent setHandleSubmit(undefined)} lease={formikRef?.current?.values} /> diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantForm.test.tsx b/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantForm.test.tsx index aa908d0b66..b848b13978 100644 --- a/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantForm.test.tsx +++ b/frontend/src/features/leases/detail/LeasePages/tenant/AddLeaseTenantForm.test.tsx @@ -2,11 +2,12 @@ import userEvent from '@testing-library/user-event'; import axios from 'axios'; import MockAdapter from 'axios-mock-adapter'; import { Claims } from 'constants/claims'; +import { apiLeaseToFormLease } from 'features/leases/leaseUtils'; import { Formik } from 'formik'; import { createMemoryHistory } from 'history'; -import { IContactSearchResult } from 'interfaces'; +import { IFormLease } from 'interfaces'; import { noop } from 'lodash'; -import React from 'react'; +import { getMockLease } from 'mocks/mockLease'; import { getAllByRole as getAllByRoleBase, mockKeycloak, @@ -16,6 +17,7 @@ import { } from 'utils/test-utils'; import AddLeaseTenantForm, { IAddLeaseTenantFormProps } from './AddLeaseTenantForm'; +import { FormTenant } from './Tenant'; // mock auth library jest.mock('@react-keycloak/web'); @@ -23,14 +25,14 @@ jest.mock('@react-keycloak/web'); const history = createMemoryHistory(); const mockAxios = new MockAdapter(axios); -xdescribe('AddLeaseTenantForm component', () => { +describe('AddLeaseTenantForm component', () => { const setup = async ( renderOptions: RenderOptions & Partial & { - initialValues?: any; - selectedTenants?: IContactSearchResult[]; + initialValues?: IFormLease; + selectedTenants?: FormTenant[]; onCancel?: () => void; - setSelectedTenants?: (tenants: IContactSearchResult[]) => void; + setSelectedTenants?: (tenants: FormTenant[]) => void; } = {}, ) => { // render component under test @@ -41,7 +43,8 @@ xdescribe('AddLeaseTenantForm component', () => { setSelectedTenants={renderOptions.setSelectedTenants ?? noop} onCancel={renderOptions.onCancel ?? noop} onSubmit={noop as any} - formikRef={{} as any} + formikRef={null} + initialValues={renderOptions.initialValues} /> , { @@ -74,6 +77,8 @@ xdescribe('AddLeaseTenantForm component', () => { it('renders as expected', async () => { mockAxios.onGet().reply(200, []); const { component } = await setup({}); + const { findByTitle } = component; + await findByTitle('table-loading'); expect(component.asFragment()).toMatchSnapshot(); }); @@ -82,8 +87,9 @@ xdescribe('AddLeaseTenantForm component', () => { const cancel = jest.fn(); mockAxios.onGet().reply(200, { items: [] }); const { - component: { getByText }, + component: { getByText, findByTitle }, } = await setup({ onCancel: cancel }); + await findByTitle('table-loading'); const cancelButton = getByText('Cancel'); userEvent.click(cancelButton); @@ -96,12 +102,13 @@ xdescribe('AddLeaseTenantForm component', () => { items: sampleContactResponse, }); const { - component: { findByTestId }, + component: { findByTestId, findByTitle }, } = await setup({ setSelectedTenants: setSelectedTenants }); + await findByTitle('table-loading'); const checkBox = await findByTestId('selectrow-O5'); userEvent.click(checkBox); - expect(setSelectedTenants).toHaveBeenCalledWith([sampleContactResponse[1]]); + expect(setSelectedTenants).toHaveBeenCalledWith([sampleFormTenant[0]]); }); it('items from the contact list view can be added', async () => { @@ -124,8 +131,7 @@ xdescribe('AddLeaseTenantForm component', () => { const dataRow = findFirstRowTableTwo() as HTMLElement; expect(dataRow).not.toBeNull(); expect(findCell(dataRow, 3)?.textContent).toBe('Bob Billy Smith'); - expect(findCell(dataRow, 4)?.textContent).toBe('Smith'); - expect(findCell(dataRow, 5)?.textContent).toBe('Bob'); + expect(findCell(dataRow, 4)?.textContent).toBe('Not applicable'); const saveButton = getByText('Save'); expect(saveButton).not.toBeDisabled(); }); @@ -138,7 +144,7 @@ xdescribe('AddLeaseTenantForm component', () => { component: { getByText, getByTestId, findAllByTitle }, } = await setup({ initialValues: { tenants: sampleContactResponse } as any, - selectedTenants: [sampleContactResponse[0] as any], + selectedTenants: [new FormTenant(undefined, sampleContactResponse[0])], }); const addButton = getByText('Add selected tenants'); userEvent.click(addButton); @@ -146,7 +152,7 @@ xdescribe('AddLeaseTenantForm component', () => { await findAllByTitle('Click to remove'); const dataRows = within(getByTestId('selected-items')).getAllByRole('row'); expect(dataRows).not.toBeNull(); - expect(dataRows).toHaveLength(3); + expect(dataRows).toHaveLength(4); }); it('items can be removed', async () => { @@ -173,7 +179,144 @@ xdescribe('AddLeaseTenantForm component', () => { dataRow = findFirstRowTableTwo() as HTMLElement; expect(findCell(dataRow, 3)?.textContent).toBe('Bob Billy Smith'); - expect(findCell(dataRow, 5)?.textContent).toBe('Bob'); + expect(findCell(dataRow, 4)?.textContent).toBe('Not applicable'); + }); + describe('primary contact behaviour', () => { + it('previously selected organization with one primary contact displays correctly', async () => { + mockAxios.onAny().reply(200, { + items: sampleContactResponse, + }); + const { + component: { findByText }, + } = await setup({ + initialValues: apiLeaseToFormLease(getMockLease()), + selectedTenants: [], + }); + + const primaryContact = await findByText('Stinky Cheese'); + expect(primaryContact).toBeVisible(); + }); + + it('previously selected organization with multiple primary contacts displays correctly', async () => { + mockAxios.onAny().reply(200, { + items: sampleContactResponse, + }); + const { + component: { findByDisplayValue }, + } = await setup({ + initialValues: apiLeaseToFormLease(getMockLease()), + selectedTenants: [], + }); + + const primaryContact = await findByDisplayValue('Bob Billy Smith'); + expect(primaryContact).toBeVisible(); + expect(primaryContact).toContainHTML( + '', + ); + }); + + it('previously selected organization with no primary contacts displays correctly', async () => { + mockAxios.onAny().reply(200, { + items: sampleContactResponse, + }); + const { + component: { findByText }, + } = await setup({ + initialValues: apiLeaseToFormLease(getMockLease()), + selectedTenants: [], + }); + + const primaryContact = await findByText('No contacts available'); + expect(primaryContact).toBeVisible(); + }); + + it('previously selected organization with multiple primary contacts does not allow duplicate selection', async () => { + mockAxios.onAny().reply(200, { + items: sampleContactResponse, + }); + const { + component: { findByDisplayValue, getByText }, + } = await setup({ + initialValues: apiLeaseToFormLease(getMockLease()), + selectedTenants: [sampleContactResponse[0] as any], + }); + + const addButton = getByText('Add selected tenants'); + userEvent.click(addButton); + + const primaryContact = await findByDisplayValue('Bob Billy Smith'); + expect(primaryContact).toBeVisible(); + }); + + it('selecting organization with one primary contact displays correctly', async () => { + mockAxios.onAny().reply(200, { + items: [orgWithOnePerson], + }); + const { + component: { getByText, findByText }, + } = await setup({ + initialValues: { tenants: [] } as any, + selectedTenants: [new FormTenant(undefined, orgWithOnePerson)], + }); + + const addButton = getByText('Add selected tenants'); + userEvent.click(addButton); + + const organization = await findByText('Dairy Queen Forever! Property Management'); + + expect(organization).toBeVisible(); + + const primaryContact = await findByText('Stinky Cheese'); + expect(primaryContact).toBeVisible(); + }); + + it('selecting organization with multiple primary contacts displays correctly', async () => { + mockAxios.onAny().reply(200, { + items: [orgWithMultiplePeople], + }); + const { + component: { findByText, getByText, findByDisplayValue }, + } = await setup({ + initialValues: { tenants: [] } as any, + selectedTenants: [new FormTenant(undefined, orgWithMultiplePeople)], + }); + + const addButton = getByText('Add selected tenants'); + userEvent.click(addButton); + + const organization = await findByText('French Mouse Property Management'); + + expect(organization).toBeVisible(); + + const primaryContact = await findByDisplayValue('Select a contact'); + expect(primaryContact).toBeVisible(); + expect(primaryContact).toContainHTML( + '', + ); + }); + + it('selecting organization with no primary contacts displays correctly', async () => { + mockAxios.onAny().reply(200, { + items: [orgWithNoPeople], + }); + const { + component: { findByText, getByText }, + } = await setup({ + initialValues: { tenants: [] } as any, + selectedTenants: [new FormTenant(undefined, orgWithNoPeople)], + }); + + const addButton = getByText('Add selected tenants'); + userEvent.click(addButton); + + const organization = await findByText('Pussycat Property Management'); + + expect(organization).toBeVisible(); + + const primaryContact = await findByText('No contacts available'); + expect(primaryContact).toBeVisible(); + expect(primaryContact).toContainHTML('

No contacts available

'); + }); }); }); @@ -197,3 +340,169 @@ const sampleContactResponse = [ isDisabled: false, }, ]; + +const sampleFormTenant = [ + { + email: undefined, + id: 'O5', + initialPrimaryContact: undefined, + isDisabled: undefined, + landline: undefined, + leaseId: undefined, + leaseTenantId: undefined, + lessorTypeCode: { + id: 'ORG', + }, + mailingAddress: { + streetAddress1: undefined, + }, + mobile: undefined, + municipalityName: undefined, + note: undefined, + organizationId: 5, + organizationPersons: undefined, + original: { + id: 'O5', + isDisabled: false, + organizationId: 5, + organizationName: "Bob's Property Management", + rowVersion: 0, + summary: "Bob's Property Management", + }, + personId: undefined, + primaryContactId: undefined, + rowVersion: undefined, + summary: "Bob's Property Management", + }, +]; + +const orgWithOnePerson = { + id: 'O3', + organizationId: 3, + organization: { + id: 3, + isDisabled: false, + name: 'Dairy Queen Forever! Property Management', + organizationPersons: [ + { + person: { + id: 3, + isDisabled: false, + surname: 'Cheese', + firstName: 'Stinky', + middleNames: '', + personOrganizations: [ + { + personId: 3, + isDisabled: false, + rowVersion: 1, + }, + ], + personAddresses: [], + contactMethods: [], + rowVersion: 1, + }, + personId: 3, + organizationId: 3, + isDisabled: false, + rowVersion: 1, + }, + ], + organizationAddresses: [], + contactMethods: [], + rowVersion: 1, + }, + rowVersion: 0, + summary: 'Dairy Queen Forever! Property Management', + organizationName: 'Dairy Queen Forever! Property Management', + isDisabled: false, +}; +const orgWithMultiplePeople = { + id: 'O2', + organizationId: 2, + organization: { + id: 2, + isDisabled: false, + name: 'French Mouse Property Management', + alias: '', + incorporationNumber: '', + organizationPersons: [ + { + person: { + id: 1, + isDisabled: false, + surname: 'Smith', + firstName: 'Bob', + middleNames: 'Billy', + preferredName: 'Tester McTest', + personOrganizations: [ + { + personId: 1, + isDisabled: false, + rowVersion: 3, + }, + ], + personAddresses: [], + contactMethods: [], + comment: 'This is a test comment.', + rowVersion: 4, + }, + personId: 1, + organizationId: 2, + isDisabled: false, + rowVersion: 3, + }, + { + person: { + id: 4, + isDisabled: false, + surname: 'Mouse', + firstName: 'Minnie', + middleNames: 'Nacho Cheese', + personOrganizations: [ + { + personId: 4, + isDisabled: false, + rowVersion: 1, + }, + ], + personAddresses: [], + contactMethods: [], + rowVersion: 1, + }, + personId: 4, + organizationId: 2, + isDisabled: false, + rowVersion: 1, + }, + ], + organizationAddresses: [], + contactMethods: [], + comment: '', + rowVersion: 2, + }, + rowVersion: 0, + summary: 'French Mouse Property Management', + organizationName: 'French Mouse Property Management', + mailingAddress: '1450 Glentana rd.', + municipalityName: 'Victoria', + provinceState: 'BC', + isDisabled: false, +}; +const orgWithNoPeople = { + id: 'O4', + organizationId: 4, + organization: { + id: 4, + isDisabled: false, + name: 'Pussycat Property Management', + organizationPersons: [], + organizationAddresses: [], + contactMethods: [], + rowVersion: 1, + }, + rowVersion: 0, + summary: 'Pussycat Property Management', + organizationName: 'Pussycat Property Management', + isDisabled: false, +}; diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/PrimaryContactWarningModal.test.tsx b/frontend/src/features/leases/detail/LeasePages/tenant/PrimaryContactWarningModal.test.tsx new file mode 100644 index 0000000000..833b05b955 --- /dev/null +++ b/frontend/src/features/leases/detail/LeasePages/tenant/PrimaryContactWarningModal.test.tsx @@ -0,0 +1,65 @@ +import { screen } from '@testing-library/react'; +import { apiLeaseToFormLease } from 'features/leases/leaseUtils'; +import { createMemoryHistory } from 'history'; +import { defaultFormLease, IFormLease } from 'interfaces'; +import { noop } from 'lodash'; +import { mockApiPerson, mockOrganization } from 'mocks/filterDataMock'; +import { getMockLeaseWithNoTenants } from 'mocks/mockLease'; +import React from 'react'; +import { render, RenderOptions, userEvent } from 'utils/test-utils'; + +import PrimaryContactWarningModal from './PrimaryContactWarningModal'; + +const history = createMemoryHistory(); + +describe('PrimaryContactWarningModal component', () => { + const setup = ( + renderOptions: RenderOptions & { lease?: IFormLease; saveCallback?: Function } = {}, + ) => { + // render component under test + const component = render( + , + { + ...renderOptions, + history, + }, + ); + + return { + component, + }; + }; + it('renders as expected', () => { + const { component } = setup({ + lease: { ...defaultFormLease, persons: [mockApiPerson], organizations: [mockOrganization] }, + }); + expect(component.asFragment()).toMatchSnapshot(); + }); + it('calls saveCallback on save', () => { + const saveCallback = jest.fn(); + const { component } = setup({ + saveCallback: saveCallback, + lease: { ...defaultFormLease, persons: [mockApiPerson, mockApiPerson] }, + }); + const { getByText } = component; + const save = getByText('Save'); + userEvent.click(save); + + expect(saveCallback).toHaveBeenCalled(); + }); + + it('displays all organization tenants that have multiple persons and no primary contact', () => { + setup({ + lease: apiLeaseToFormLease(getMockLeaseWithNoTenants()), + saveCallback: noop, + }); + const tenantText = screen.getByText(content => + content.includes('French Mouse Property Management'), + ); + + expect(tenantText).toBeVisible(); + }); +}); diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/PrimaryContactWarningModal.tsx b/frontend/src/features/leases/detail/LeasePages/tenant/PrimaryContactWarningModal.tsx index 8c64a7e008..76f5e1246e 100644 --- a/frontend/src/features/leases/detail/LeasePages/tenant/PrimaryContactWarningModal.tsx +++ b/frontend/src/features/leases/detail/LeasePages/tenant/PrimaryContactWarningModal.tsx @@ -7,14 +7,12 @@ import { FormTenant } from './Tenant'; interface IPrimaryContactWarningModalProps { saveCallback?: Function; - setSaveCallback: (display: Function | undefined) => void; lease: IFormLease | undefined; onCancel?: Function; } const PrimaryContactWarningModal: React.FunctionComponent = ({ saveCallback, - setSaveCallback, lease, onCancel, }) => { @@ -23,7 +21,6 @@ const PrimaryContactWarningModal: React.FunctionComponent setSaveCallback(undefined)} title="Confirm save" message={ <> diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/Tenant.test.tsx b/frontend/src/features/leases/detail/LeasePages/tenant/Tenant.test.tsx index cda7aec56f..f82ebe8f30 100644 --- a/frontend/src/features/leases/detail/LeasePages/tenant/Tenant.test.tsx +++ b/frontend/src/features/leases/detail/LeasePages/tenant/Tenant.test.tsx @@ -1,15 +1,18 @@ +import { apiLeaseToFormLease } from 'features/leases/leaseUtils'; import { Formik } from 'formik'; import { createMemoryHistory } from 'history'; import { defaultFormLease, IFormLease } from 'interfaces'; import { noop } from 'lodash'; import { mockApiPerson, mockOrganization } from 'mocks/filterDataMock'; +import { getMockLease } from 'mocks/mockLease'; +import { getMockOrganization } from 'mocks/mockOrganization'; import { render, RenderOptions } from 'utils/test-utils'; -import Tenant, { ITenantProps } from './Tenant'; +import Tenant, { FormTenant, ITenantProps } from './Tenant'; const history = createMemoryHistory(); -xdescribe('Tenant component', () => { +describe('Tenant component', () => { const setup = (renderOptions: RenderOptions & ITenantProps & { lease?: IFormLease } = {}) => { // render component under test const component = render( @@ -34,7 +37,21 @@ xdescribe('Tenant component', () => { }); it('renders one Person Tenant section per person', () => { const { component } = setup({ - lease: { ...defaultFormLease, persons: [mockApiPerson, mockApiPerson] }, + lease: { + ...defaultFormLease, + tenants: [ + new FormTenant({ + lessorType: { id: 'PER' }, + person: { ...mockApiPerson }, + leaseId: 1, + }), + new FormTenant({ + lessorType: { id: 'PER' }, + person: { ...mockApiPerson }, + leaseId: 1, + }), + ], + }, }); const { getAllByText } = component; const personTenant = getAllByText('Tenant Name:'); @@ -54,9 +71,9 @@ xdescribe('Tenant component', () => { }, }); const { getAllByText } = component; - const personTenant = getAllByText('Notes'); + const notes = getAllByText('Notes'); - expect(personTenant).toHaveLength(1); + expect(notes).toHaveLength(2); }); it('renders no person information section if there are no persons', () => { @@ -71,7 +88,19 @@ xdescribe('Tenant component', () => { it('renders one organization tenant section per organization', () => { const { component } = setup({ - lease: { ...defaultFormLease, organizations: [mockOrganization, mockOrganization] }, + lease: { + ...defaultFormLease, + tenants: [ + new FormTenant({ + organization: { ...getMockOrganization() }, + leaseId: 1, + }), + new FormTenant({ + organization: { ...getMockOrganization() }, + leaseId: 1, + }), + ], + }, }); const { getAllByText } = component; const organizationTenant = getAllByText('Tenant organization:'); @@ -91,7 +120,15 @@ xdescribe('Tenant component', () => { it('renders organization phone numbers as expected', () => { const { component } = setup({ - lease: { ...defaultFormLease, organizations: [mockOrganization] }, + lease: { + ...defaultFormLease, + tenants: [ + new FormTenant({ + organization: { ...getMockOrganization() }, + leaseId: 1, + }), + ], + }, }); const { getByLabelText } = component; const landline = getByLabelText('Landline:'); @@ -103,7 +140,10 @@ xdescribe('Tenant component', () => { it('renders person phone numbers as expected', () => { const { component } = setup({ - lease: { ...defaultFormLease, persons: [mockApiPerson] }, + lease: { + ...defaultFormLease, + tenants: [new FormTenant({ person: mockApiPerson, leaseId: 1 })], + }, }); const { getByLabelText } = component; const landline = getByLabelText('Landline:'); @@ -112,4 +152,39 @@ xdescribe('Tenant component', () => { expect(landline).toHaveDisplayValue('222-333-4444'); expect(mobile).toHaveDisplayValue('555-666-7777'); }); + + it('renders primary contact successfully', () => { + const mockLeaseWithTenants = getMockLease(); + const { component } = setup({ + lease: apiLeaseToFormLease(mockLeaseWithTenants), + }); + const { getByText } = component; + const primaryContact = getByText('Bob Billy Smith'); + expect(primaryContact).toBeVisible(); + }); + + it('renders primary contact even if not part of organization persons', () => { + const mockLeaseWithTenants = getMockLease(); + if (mockLeaseWithTenants.tenants[0].primaryContact?.id) { + mockLeaseWithTenants.tenants[0].primaryContact.id = 5; + } + mockLeaseWithTenants.tenants[0].primaryContactId = 5; + const { component } = setup({ + lease: apiLeaseToFormLease(mockLeaseWithTenants), + }); + const { getByText } = component; + const primaryContact = getByText('Bob Billy Smith'); + expect(primaryContact).toBeVisible(); + }); + + it('renders updated primary contact if primaryContact id does not match', () => { + const mockLeaseWithTenants = getMockLease(); + mockLeaseWithTenants.tenants[0].primaryContactId = 4; // this is the id of the other person associated to this organization tenant. + const { component } = setup({ + lease: apiLeaseToFormLease(mockLeaseWithTenants), + }); + const { getByText } = component; + const primaryContact = getByText('Minnie Nacho Cheese Mouse'); + expect(primaryContact).toBeVisible(); + }); }); diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/Tenant.tsx b/frontend/src/features/leases/detail/LeasePages/tenant/Tenant.tsx index 9e0d026367..97627d25c0 100644 --- a/frontend/src/features/leases/detail/LeasePages/tenant/Tenant.tsx +++ b/frontend/src/features/leases/detail/LeasePages/tenant/Tenant.tsx @@ -67,9 +67,7 @@ export class FormTenant { const tenant = apiModel.person ?? apiModel.organization; const address = !!tenant ? getApiPersonOrOrgMailingAddress(tenant) : undefined; this.id = - apiModel.lessorTypeCode?.id === 'PER' - ? `P${apiModel.personId}` - : `O${apiModel.organizationId}`; + apiModel.lessorType?.id === 'PER' ? `P${apiModel.personId}` : `O${apiModel.organizationId}`; this.personId = apiModel.personId; this.summary = apiModel.person ? formatApiPersonNames(tenant) : apiModel.organization?.name; this.leaseId = apiModel.leaseId; @@ -90,9 +88,9 @@ export class FormTenant { ); this.mobile = getPreferredContactMethodValue( tenant?.contactMethods, - ContactMethodTypes.PersonalPhone, + ContactMethodTypes.WorkMobile, ); - this.lessorTypeCode = apiModel.lessorTypeCode; + this.lessorTypeCode = apiModel.lessorType; this.primaryContactId = apiModel.primaryContactId; this.initialPrimaryContact = apiModel.primaryContact; } else if (!!selectedContactModel) { @@ -127,7 +125,8 @@ export interface ITenantProps { */ export const Tenant: React.FunctionComponent = ({ nameSpace }) => { const { values: lease } = useFormikContext(); - const tenants: Api_LeaseTenant[] = getIn(lease, withNameSpace(nameSpace, 'tenants')) ?? []; + const tenants: FormTenant[] = getIn(lease, withNameSpace(nameSpace, 'tenants')) ?? []; + console.log(tenants); return ( {}} enableReinitialize> @@ -135,12 +134,12 @@ export const Tenant: React.FunctionComponent = ({ nameSpace }) => name={withNameSpace(nameSpace, 'properties')} render={renderProps => ( <> - {tenants.map((tenant: Api_LeaseTenant, index) => ( + {tenants.map((tenant: FormTenant, index) => ( - {!!tenant.personId ? ( + {tenant.lessorTypeCode?.id === 'PER' ? ( Tenant Information Tenant organization: - Primary Contact: - - {primaryContactName} - + Primary contact: + {primaryContact?.id ? ( + + {primaryContactName} + + ) : null}
- Show Active contacts only + Show active users only
@@ -1010,6 +1012,7 @@ exports[`AddLeaseTenantForm component renders as expected 1`] = `
diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/__snapshots__/AddLeaseTenantForm.test.tsx.snap b/frontend/src/features/leases/detail/LeasePages/tenant/__snapshots__/AddLeaseTenantForm.test.tsx.snap index 38cefad9a7..9a0b4b6905 100644 --- a/frontend/src/features/leases/detail/LeasePages/tenant/__snapshots__/AddLeaseTenantForm.test.tsx.snap +++ b/frontend/src/features/leases/detail/LeasePages/tenant/__snapshots__/AddLeaseTenantForm.test.tsx.snap @@ -161,38 +161,6 @@ exports[`AddLeaseTenantForm component renders as expected 1`] = ` margin-right: 0; } -.c15 { - margin-top: 3rem; - font-size: 1.4rem; -} - -.c15 .table .tr .td:first-of-type, -.c15 .table .tr .td:nth-of-type(2), -.c15 .table .tr .th:first-of-type, -.c15 .table .tr .th:nth-of-type(2) { - border-left: 0; - border-right: 0; - padding: 0; -} - -.c6 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-align-items: baseline; - -webkit-box-align: baseline; - -ms-flex-align: baseline; - align-items: baseline; - gap: 0.8rem; -} - -.c6 .form-label { - -webkit-flex-shrink: 0; - -ms-flex-negative: 0; - flex-shrink: 0; -} - .c5 { display: -webkit-box; display: -webkit-flex; @@ -236,6 +204,38 @@ exports[`AddLeaseTenantForm component renders as expected 1`] = ` height: 1.6rem; } +.c15 { + margin-top: 3rem; + font-size: 1.4rem; +} + +.c15 .table .tr .td:first-of-type, +.c15 .table .tr .td:nth-of-type(2), +.c15 .table .tr .th:first-of-type, +.c15 .table .tr .th:nth-of-type(2) { + border-left: 0; + border-right: 0; + padding: 0; +} + +.c6 { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-align-items: baseline; + -webkit-box-align: baseline; + -ms-flex-align: baseline; + align-items: baseline; + gap: 0.8rem; +} + +.c6 .form-label { + -webkit-flex-shrink: 0; + -ms-flex-negative: 0; + flex-shrink: 0; +} + .c16 { z-index: 100; width: 100%; @@ -590,6 +590,7 @@ exports[`AddLeaseTenantForm component renders as expected 1`] = ` class="c10 Button Button--icon-only primary btn btn-primary" data-testid="search" id="search-button" + title="search" type="button" >
- Show Active contacts only + Show active users only
@@ -1005,12 +1007,9 @@ exports[`AddLeaseTenantForm component renders as expected 1`] = `
-
+ No Contacts match the search criteria
+
+
+
+ +`; diff --git a/frontend/src/features/leases/detail/LeasePages/tenant/columns.tsx b/frontend/src/features/leases/detail/LeasePages/tenant/columns.tsx index 417847079a..64933aa9c7 100644 --- a/frontend/src/features/leases/detail/LeasePages/tenant/columns.tsx +++ b/frontend/src/features/leases/detail/LeasePages/tenant/columns.tsx @@ -55,11 +55,12 @@ const columns = [ minWidth: 200, width: 300, Cell: (props: CellProps) => { - const persons = props.row.original?.organizationPersons?.map(op => op.person); - let primaryContact = props.row.original.initialPrimaryContact; - if (props.row.original.primaryContactId !== props.row.original.initialPrimaryContact?.id) { - primaryContact = props.row.original.primaryContactId - ? getPrimaryContact(props.row.original.primaryContactId, props.row.original) + const original = props.row.original; + const persons = original?.organizationPersons?.map(op => op.person); + let primaryContact = original.initialPrimaryContact; + if (original.primaryContactId !== original.initialPrimaryContact?.id) { + primaryContact = original.primaryContactId + ? getPrimaryContact(original.primaryContactId, original) : undefined; } const primaryContactOptions: SelectOption[] = @@ -79,7 +80,7 @@ const columns = [ > ); } else if (persons?.length === 1) { - return

{formatApiPersonNames(primaryContact)}

; + return

{formatApiPersonNames(primaryContact ?? persons[0])}

; } else { return

No contacts available

; } diff --git a/frontend/src/features/mapSideBar/MotiInventoryContainer.test.tsx b/frontend/src/features/mapSideBar/MotiInventoryContainer.test.tsx index a724f33f24..3aa9a695fc 100644 --- a/frontend/src/features/mapSideBar/MotiInventoryContainer.test.tsx +++ b/frontend/src/features/mapSideBar/MotiInventoryContainer.test.tsx @@ -35,10 +35,10 @@ describe('MotiInventoryContainer component', () => { // render component under test const utils = render( , { ...renderOptions, @@ -63,7 +63,6 @@ describe('MotiInventoryContainer component', () => { mockAxios.onGet().reply(200, {}); setup({ - readOnly: true, pid: '9212434', onClose, onZoom, @@ -77,29 +76,28 @@ describe('MotiInventoryContainer component', () => { it('shows the property information tab for inventory properties', async () => { mockAxios.onPost().reply(200, {}); - mockAxios.onGet(new RegExp('properties/*')).reply(200, {}); - mockAxios.onGet(new RegExp('ogs-internal/*')).reply(200, {}); + mockAxios.onGet(new RegExp('/properties/*')).reply(200, { id: 9212434 }); + mockAxios.onGet(new RegExp('/ogs-internal/*')).reply(200, {}); const { findByText, queryByTestId } = setup({ - readOnly: true, - pid: '9212434', + id: 9212434, onClose, onZoom, }); await waitFor(() => { expect(mockAxios.history.get.length).toBeGreaterThanOrEqual(1); - expect(mockAxios.history.get[0].url).toBe(`/properties/009-212-434`); + expect(mockAxios.history.get[0].url).toBe(`/properties/9212434`); }); - expect(await findByText(/property attributes/i)).toBeInTheDocument(); await waitFor(() => { expect(queryByTestId('filter-backdrop-loading')).toBeNull(); }); + expect(await findByText(/property attributes/i)).toBeInTheDocument(); }); it('hides the property information tab for non-inventory properties', async () => { mockAxios.onPost().reply(200, {}); - // non-inventory properties return a "not-found" error from API + // non-inventory properties will not attempt to contact the backend. const error = { isAxiosError: true, response: { status: 404 }, @@ -107,42 +105,16 @@ describe('MotiInventoryContainer component', () => { mockAxios.onGet(new RegExp('/properties/*')).reply(404, error); mockAxios.onGet(new RegExp('ogs-internal/*')).reply(200, {}); - const { queryByText, getByText, queryByTestId } = setup({ - readOnly: true, + const { queryByText, getByText, queryAllByTestId } = setup({ pid: '9212434', onClose, onZoom, }); - await waitFor(() => { - expect(mockAxios.history.get.length).toBeGreaterThanOrEqual(1); - expect(mockAxios.history.get[0].url).toBe(`/properties/009-212-434`); - }); expect(queryByText(/property attributes/i)).toBeNull(); expect(getByText('Title')).toHaveClass('active'); - expect(queryByTestId('filter-backdrop-loading')).toBeNull(); - }); - - it('shows the EDIT property form when read-only prop set to FALSE', async () => { - mockAxios.onPost().reply(200, {}); - mockAxios.onGet(new RegExp('properties/*')).reply(200, {}); - mockAxios.onGet(new RegExp('ogs-internal/*')).reply(200, {}); - - const { findByText, queryByTestId } = setup({ - readOnly: false, - pid: '9212434', - onClose, - onZoom, - }); - await waitFor(() => { - expect(mockAxios.history.get.length).toBeGreaterThanOrEqual(1); - expect(mockAxios.history.get[0].url).toBe(`/properties/concept/9212434`); - }); - - expect(await findByText(/property attributes/i)).toBeInTheDocument(); - await waitFor(() => { - expect(queryByTestId('filter-backdrop-loading')).toBeNull(); + expect(queryAllByTestId('filter-backdrop-loading')).toHaveLength(0); }); }); }); diff --git a/frontend/src/features/mapSideBar/MotiInventoryContainer.tsx b/frontend/src/features/mapSideBar/MotiInventoryContainer.tsx index 663516f255..7e0d4ff844 100644 --- a/frontend/src/features/mapSideBar/MotiInventoryContainer.tsx +++ b/frontend/src/features/mapSideBar/MotiInventoryContainer.tsx @@ -1,30 +1,27 @@ import { ReactComponent as LotSvg } from 'assets/images/icon-lot.svg'; import axios, { AxiosError } from 'axios'; +import GenericModal from 'components/common/GenericModal'; +import ComposedProperty from 'features/properties/map/propertyInformation/ComposedProperty'; +import PropertyViewSelector from 'features/properties/map/propertyInformation/PropertyViewSelector'; +import SidebarFooter from 'features/properties/map/shared/SidebarFooter'; +import { FormikProps } from 'formik'; import useIsMounted from 'hooks/useIsMounted'; import { useLtsa } from 'hooks/useLtsa'; import { useProperties } from 'hooks/useProperties'; import { usePropertyAssociations } from 'hooks/usePropertyAssociations'; import { IApiError } from 'interfaces/IApiError'; import { IPropertyApiModel } from 'interfaces/IPropertyApiModel'; -import { LtsaOrders } from 'interfaces/ltsaModels'; -import { Api_PropertyAssociations } from 'models/api/Property'; -import React, { useCallback, useEffect, useState } from 'react'; -import { useHistory } from 'react-router-dom'; +import React, { useEffect, useState } from 'react'; +import { toast } from 'react-toastify'; import styled from 'styled-components'; import { pidFormatter } from 'utils'; -import { usePropertyDetails } from './hooks/usePropertyDetails'; import MapSideBarLayout from './layout/MapSideBarLayout'; import { MotiInventoryHeader } from './MotiInventoryHeader'; -import { InventoryTabNames, InventoryTabs, TabInventoryView } from './tabs/InventoryTabs'; -import LtsaTabView from './tabs/ltsa/LtsaTabView'; -import PropertyAssociationTabView from './tabs/propertyAssociations/PropertyAssociationTabView'; -import { PropertyDetailsTabView } from './tabs/propertyDetails/detail/PropertyDetailsTabView'; -import { UpdatePropertyDetailsContainer } from './tabs/propertyDetails/update/UpdatePropertyDetailsContainer'; export interface IMotiInventoryContainerProps { + id?: number; pid?: string; - readOnly?: boolean; onClose: () => void; onZoom: (apiProperty?: IPropertyApiModel | undefined) => void; } @@ -34,163 +31,182 @@ export interface IMotiInventoryContainerProps { */ export const MotiInventoryContainer: React.FunctionComponent = props => { const isMounted = useIsMounted(); - const history = useHistory(); - const [ltsaData, setLtsaData] = useState(undefined); - const [apiProperty, setApiProperty] = useState(undefined); - const [propertyAssociations, setPropertyAssociations] = useState< - Api_PropertyAssociations | undefined - >(undefined); - const [ltsaDataRequestedOn, setLtsaDataRequestedOn] = useState(undefined); - const [showPropertyInfoTab, setShowPropertyInfoTab] = useState(true); - const [activeTab, setActiveTab] = useState(InventoryTabNames.property); - // First, fetch property information from PSP API - const { getPropertyWithPid, getPropertyWithPidLoading: propertyLoading } = useProperties(); - useEffect(() => { - const func = async () => { - try { - if (!!props.pid && !!props.readOnly) { - const propInfo = await getPropertyWithPid(props.pid); - if (isMounted() && propInfo.pid === pidFormatter(props.pid)) { - setApiProperty(propInfo); - setShowPropertyInfoTab(true); - } - } - } catch (e) { - // PSP-2919 Hide the property info tab for non-inventory properties - // We get an error because PID is not on our database - if (axios.isAxiosError(e)) { - const axiosError = e as AxiosError; - if (axiosError?.response?.status === 404) { - setShowPropertyInfoTab(false); - setActiveTab(InventoryTabNames.title); - } - } - } - }; + const [showCancelConfirmModal, setShowCancelConfirmModal] = useState(false); - func(); - }, [getPropertyWithPid, isMounted, props.pid, props.readOnly]); + const [isEditing, setIsEditing] = useState(false); + + const [formikRef, setFormikRef] = useState> | undefined>( + undefined, + ); + + // First, fetch property information from PSP API + const { getPropertyLoading: propertyLoading, getProperty } = useProperties(); const { getPropertyAssociations, isLoading: propertyAssociationsLoading, } = usePropertyAssociations(); + const { getLtsaData, ltsaLoading } = useLtsa(); + + const [composedProperty, setComposedProperty] = useState({ + apiPropertyLoading: ltsaLoading, + ltsaLoading: propertyLoading, + propertyAssociationsLoading: propertyAssociationsLoading, + }); + + useEffect(() => { + setComposedProperty(property => ({ + ...property, + pid: props.pid, + })); + setIsEditing(false); + }, [props.pid]); + useEffect(() => { - async function fetchResearchFile() { - if (props.pid !== undefined) { - const response = await getPropertyAssociations(props.pid); - setPropertyAssociations(response); + setComposedProperty(property => ({ + ...property, + ltsaLoading: ltsaLoading, + apiPropertyLoading: propertyLoading, + propertyAssociationsLoading: propertyAssociationsLoading, + })); + }, [propertyLoading, ltsaLoading, propertyAssociationsLoading]); + + const fetchPimsProperty = React.useCallback(async () => { + try { + if (!!props.id) { + const propInfo = await getProperty(props.id); + if (isMounted() && propInfo?.id === props.id) { + setComposedProperty(property => ({ ...property, apiProperty: propInfo })); + } + } + } catch (e) { + // PSP-2919 Hide the property info tab for non-inventory properties + // We get an error because PID is not on our database + if (axios.isAxiosError(e)) { + const axiosError = e as AxiosError; + if (axiosError?.response?.status === 404) { + setComposedProperty(property => ({ ...property, apiProperty: undefined })); + } else { + toast.error('Failed to load property. Please refresh this page to try again'); + } } } - fetchResearchFile(); - }, [getPropertyAssociations, props.pid]); + }, [getProperty, isMounted, props.id]); - // After API property object has been received, we query relevant map layers to find - // additional information which we store in a different model (IPropertyDetailsForm) - const propertyViewForm = usePropertyDetails(apiProperty); + useEffect(() => { + fetchPimsProperty(); + }, [fetchPimsProperty]); + + useEffect(() => { + const getAssociations = async () => { + if (props?.id !== undefined) { + const response = await getPropertyAssociations(props.id); + if (response !== undefined) { + setComposedProperty(property => ({ ...property, propertyAssociations: response })); + } + } + }; + getAssociations(); + }, [getPropertyAssociations, props?.id]); - const { getLtsaData, ltsaLoading } = useLtsa(); useEffect(() => { const func = async () => { - setLtsaDataRequestedOn(new Date()); - setLtsaData(undefined); - if (!!props.pid) { + setComposedProperty(property => ({ + ...property, + ltsaDataRequestedOn: new Date(), + ltsaData: undefined, + })); + + if (!!props?.pid) { const ltsaData = await getLtsaData(pidFormatter(props.pid)); if ( isMounted() && ltsaData?.parcelInfo?.orderedProduct?.fieldedData.parcelIdentifier === - pidFormatter(props.pid) + pidFormatter(props?.pid) ) { - setLtsaData(ltsaData); + setComposedProperty(property => ({ ...property, ltsaData: ltsaData })); } } }; func(); - }, [getLtsaData, props.pid, isMounted]); - - const tabViews: TabInventoryView[] = []; - - tabViews.push({ - content: ( - - ), - key: InventoryTabNames.title, - name: 'Title', - }); - - tabViews.push({ - content: <>, - key: InventoryTabNames.value, - name: 'Value', - }); + }, [getLtsaData, props?.pid, isMounted]); - var defaultTab = InventoryTabNames.title; + const onSuccess = () => { + fetchPimsProperty(); + setIsEditing(false); + }; - if (showPropertyInfoTab) { - if (props.readOnly) { - tabViews.push({ - content: , - key: InventoryTabNames.property, - name: 'Property Details', - }); + const handleSaveClick = async () => { + if (formikRef !== undefined) { + formikRef.current?.setSubmitting(true); + formikRef.current?.submitForm(); + } + }; + + const handleCancelClick = () => { + if (formikRef !== undefined) { + if (formikRef.current?.dirty) { + setShowCancelConfirmModal(true); + } else { + handleCancelConfirm(); + } } else { - tabViews.push({ - content: , - key: InventoryTabNames.property, - name: 'Property Details', - }); + handleCancelConfirm(); } - defaultTab = InventoryTabNames.property; - } - - if (propertyAssociations?.id !== undefined) { - tabViews.push({ - content: ( - - ), - key: InventoryTabNames.pims, - name: 'PIMS Files', - }); - } - - const onEditPropertyInformation = useCallback( - () => history.push(`/mapview/property/${props.pid}/edit`), - [history, props.pid], - ); + }; + + const handleCancelConfirm = () => { + if (formikRef !== undefined) { + formikRef.current?.resetForm(); + } + setIsEditing(false); + setShowCancelConfirmModal(false); + }; return ( + header={} + footer={ + isEditing && ( + + ) } icon={} showCloseButton onClose={props.onClose} > - + <> + + +
If you cancel now, this property information will not be saved.
+
+ Are you sure you want to Cancel? + + } + handleOk={handleCancelConfirm} + handleCancel={() => setShowCancelConfirmModal(false)} + okButtonText="Ok" + cancelButtonText="Resume editing" + show + /> +
); }; diff --git a/frontend/src/features/mapSideBar/MotiInventoryHeader.test.tsx b/frontend/src/features/mapSideBar/MotiInventoryHeader.test.tsx index 151273cfc3..0ca22b3f25 100644 --- a/frontend/src/features/mapSideBar/MotiInventoryHeader.test.tsx +++ b/frontend/src/features/mapSideBar/MotiInventoryHeader.test.tsx @@ -1,29 +1,24 @@ import { IPropertyApiModel } from 'interfaces/IPropertyApiModel'; -import { LtsaOrders } from 'interfaces/ltsaModels'; -import { mockLtsaResponse } from 'mocks/filterDataMock'; import { render, RenderOptions, RenderResult, userEvent } from 'utils/test-utils'; -import { MotiInventoryHeader } from './MotiInventoryHeader'; +import { IMotiInventoryHeaderProps, MotiInventoryHeader } from './MotiInventoryHeader'; + +const defaultComposedProperty = { + ltsaLoading: false, + apiPropertyLoading: false, + propertyAssociationsLoading: false, +}; const onZoom = jest.fn(); describe('MotiInventoryHeader component', () => { const setup = ( - renderOptions: RenderOptions & { - ltsaData?: LtsaOrders; - property?: IPropertyApiModel; - ltsaLoading?: boolean; - propertyLoading?: boolean; - } = {}, + renderOptions: RenderOptions & IMotiInventoryHeaderProps = { + composedProperty: defaultComposedProperty, + }, ): RenderResult => { // render component under test const result = render( - , + , ); return result; }; @@ -38,23 +33,24 @@ describe('MotiInventoryHeader component', () => { }); it('renders a spinner when the data is loading', () => { - const { getByTestId } = setup({ ltsaLoading: true }); + const { getByTestId } = setup({ + composedProperty: { ...defaultComposedProperty, ltsaLoading: true }, + }); const spinner = getByTestId('filter-backdrop-loading'); expect(spinner).toBeVisible(); }); it('displays PID', async () => { + const testPid = '009-212-434'; const result = setup({ - ltsaData: mockLtsaResponse, - ltsaLoading: false, - propertyLoading: false, - property: undefined, + composedProperty: { + ...defaultComposedProperty, + pid: testPid, + }, }); // PID is shown - expect( - result.getByText(mockLtsaResponse.parcelInfo.orderedProduct.fieldedData.parcelIdentifier), - ).toBeVisible(); + expect(result.getByText(testPid)).toBeVisible(); }); it('displays land parcel type', async () => { @@ -62,10 +58,7 @@ describe('MotiInventoryHeader component', () => { propertyType: { description: 'A land type description' }, }; const result = setup({ - ltsaData: undefined, - ltsaLoading: false, - propertyLoading: false, - property: testProperty, + composedProperty: { ...defaultComposedProperty, apiProperty: testProperty }, }); // PID is shown expect(result.getByText(testProperty?.propertyType?.description as string)).toBeVisible(); @@ -73,11 +66,9 @@ describe('MotiInventoryHeader component', () => { it('allows the active property to be zoomed in', async () => { const testProperty: IPropertyApiModel = {} as any; + const { getByTitle } = setup({ - ltsaData: undefined, - ltsaLoading: false, - propertyLoading: false, - property: testProperty, + composedProperty: { ...defaultComposedProperty, apiProperty: testProperty }, }); const zoomButton = getByTitle('Zoom Map'); userEvent.click(zoomButton); @@ -86,10 +77,7 @@ describe('MotiInventoryHeader component', () => { it('does not allow property zooming if no property is visible', async () => { const { getByTitle } = setup({ - ltsaData: undefined, - property: undefined, - ltsaLoading: false, - propertyLoading: false, + composedProperty: { ...defaultComposedProperty, apiProperty: undefined }, }); const zoomButton = getByTitle('Zoom Map'); diff --git a/frontend/src/features/mapSideBar/MotiInventoryHeader.tsx b/frontend/src/features/mapSideBar/MotiInventoryHeader.tsx index e3901d98bd..72981e32b2 100644 --- a/frontend/src/features/mapSideBar/MotiInventoryHeader.tsx +++ b/frontend/src/features/mapSideBar/MotiInventoryHeader.tsx @@ -1,106 +1,85 @@ import { IconButton } from 'components/common/buttons'; -import ProtectedComponent from 'components/common/ProtectedComponent'; import TooltipWrapper from 'components/common/TooltipWrapper'; import LoadingBackdrop from 'components/maps/leaflet/LoadingBackdrop/LoadingBackdrop'; -import { Claims } from 'constants/index'; +import ComposedProperty from 'features/properties/map/propertyInformation/ComposedProperty'; import { IPropertyApiModel } from 'interfaces/IPropertyApiModel'; -import { AssociatedPlan, LtsaOrders } from 'interfaces/ltsaModels'; +import { AssociatedPlan } from 'interfaces/ltsaModels'; import React from 'react'; import { Col, Row } from 'react-bootstrap'; -import { FaEdit, FaSearchPlus } from 'react-icons/fa'; +import { FaSearchPlus } from 'react-icons/fa'; import styled from 'styled-components'; +import { pidFormatter } from 'utils'; import { HeaderField } from './tabs/HeaderField'; -interface IMotiInventoryHeaderProps { - ltsaData?: LtsaOrders; - ltsaLoading: boolean; - propertyLoading: boolean; - property?: IPropertyApiModel; - showEditButton?: boolean; +export interface IMotiInventoryHeaderProps { + composedProperty: ComposedProperty; onZoom?: (apiProperty?: IPropertyApiModel | undefined) => void; - onEdit?: () => void; } export const MotiInventoryHeader: React.FunctionComponent = props => { - const pid = props.ltsaData?.parcelInfo.orderedProduct.fieldedData.parcelIdentifier; + const pid = pidFormatter(props.composedProperty.pid); + const ltsaData = props.composedProperty.ltsaData; const planNumbers = - props.ltsaData === undefined + ltsaData === undefined ? [] - : (props.ltsaData?.parcelInfo.orderedProduct.fieldedData - .associatedPlans as AssociatedPlan[]).map(x => x.planNumber); + : (ltsaData?.parcelInfo.orderedProduct.fieldedData.associatedPlans as AssociatedPlan[]).map( + x => x.planNumber, + ); - const isLoading = props.ltsaLoading || props.propertyLoading; + const isLoading = props.composedProperty.ltsaLoading || props.composedProperty.apiPropertyLoading; return ( <> - - - - - - - - - - - {pid} - - - - - - - {planNumbers.map((planNumber: string, index: number) => ( - - {planNumber} - - ))} - - - - - {props.property?.propertyType?.description} - - - - - - {props.showEditButton && ( - - - - - - - - )} - - props?.onZoom && props?.onZoom(props.property)} + + + + + + - + + + + + {pid} + + + + + + + {planNumbers.join(', ')} + + + + - - - - - - + {props.composedProperty.apiProperty?.propertyType?.description} + + + + + + + props?.onZoom && props?.onZoom(props.composedProperty.apiProperty)} + > + + + + + ); }; -const HeaderWrapper = styled.div` - margin-left: 3rem; - margin-right: 3rem; - margin-top: 1rem; - position: relative; -`; const StyledDivider = styled.div` margin-top: 0.5rem; border-bottom-style: solid; diff --git a/frontend/src/features/mapSideBar/__snapshots__/MotiInventoryHeader.test.tsx.snap b/frontend/src/features/mapSideBar/__snapshots__/MotiInventoryHeader.test.tsx.snap index 5af4496d9d..c334a953ec 100644 --- a/frontend/src/features/mapSideBar/__snapshots__/MotiInventoryHeader.test.tsx.snap +++ b/frontend/src/features/mapSideBar/__snapshots__/MotiInventoryHeader.test.tsx.snap @@ -8,7 +8,7 @@ exports[`MotiInventoryHeader component renders as expected 1`] = `
- .c1.btn { + .c0.btn { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -38,49 +38,49 @@ exports[`MotiInventoryHeader component renders as expected 1`] = ` cursor: pointer; } -.c1.btn:hover { +.c0.btn:hover { -webkit-text-decoration: underline; text-decoration: underline; opacity: 0.8; } -.c1.btn:focus { +.c0.btn:focus { outline-width: 0.4rem; outline-style: solid; outline-offset: 1px; box-shadow: none; } -.c1.btn.btn-primary { +.c0.btn.btn-primary { border: none; } -.c1.btn.btn-secondary { +.c0.btn.btn-secondary { background: none; } -.c1.btn.btn-info { +.c0.btn.btn-info { border: none; background: none; padding-left: 0.6rem; padding-right: 0.6rem; } -.c1.btn.btn-info:hover, -.c1.btn.btn-info:active, -.c1.btn.btn-info:focus { +.c0.btn.btn-info:hover, +.c0.btn.btn-info:active, +.c0.btn.btn-info:focus { background: none; } -.c1.btn.btn-light { +.c0.btn.btn-light { border: none; } -.c1.btn.btn-dark { +.c0.btn.btn-dark { border: none; } -.c1.btn.btn-link { +.c0.btn.btn-link { font-size: 1.6rem; font-weight: 400; background: none; @@ -100,9 +100,9 @@ exports[`MotiInventoryHeader component renders as expected 1`] = ` padding: 0; } -.c1.btn.btn-link:hover, -.c1.btn.btn-link:active, -.c1.btn.btn-link:focus { +.c0.btn.btn-link:hover, +.c0.btn.btn-link:active, +.c0.btn.btn-link:focus { -webkit-text-decoration: underline; text-decoration: underline; border: none; @@ -111,14 +111,14 @@ exports[`MotiInventoryHeader component renders as expected 1`] = ` outline: none; } -.c1.btn.btn-link:disabled, -.c1.btn.btn-link.disabled { +.c0.btn.btn-link:disabled, +.c0.btn.btn-link.disabled { background: none; pointer-events: none; } -.c1.btn:disabled, -.c1.btn:disabled:hover { +.c0.btn:disabled, +.c0.btn:disabled:hover { box-shadow: none; -webkit-user-select: none; -moz-user-select: none; @@ -129,175 +129,164 @@ exports[`MotiInventoryHeader component renders as expected 1`] = ` opacity: 0.65; } -.c1.Button .Button__icon { +.c0.Button .Button__icon { margin-right: 1.6rem; } -.c1.Button--icon-only:focus { +.c0.Button--icon-only:focus { outline: none; } -.c1.Button--icon-only .Button__icon { +.c0.Button--icon-only .Button__icon { margin-right: 0; } -.c2.c2.btn { +.c1.c1.btn { background-color: unset; border: none; } -.c2.c2.btn:hover, -.c2.c2.btn:focus, -.c2.c2.btn:active { +.c1.c1.btn:hover, +.c1.c1.btn:focus, +.c1.c1.btn:active { background-color: unset; outline: none; box-shadow: none; } -.c2.c2.btn svg { +.c1.c1.btn svg { -webkit-transition: all 0.3s ease-out; transition: all 0.3s ease-out; } -.c2.c2.btn svg:hover { +.c1.c1.btn svg:hover { -webkit-transition: all 0.3s ease-in; transition: all 0.3s ease-in; } -.c0 { - margin-left: 3rem; - margin-right: 3rem; - margin-top: 1rem; - position: relative; -} -
-
- -
-
- - - - -
+ +
+
+ + - +
+
+
-
- -
-
- -
+ +
+
+
+
+
+ +
+
-
- -
-
- -
+
+
+
-
- -
-
- -
+ +
+
+
-
+
+ -
+ + +
+
.c0 { diff --git a/frontend/src/features/mapSideBar/hooks/useMapSideBarQueryParams.tsx b/frontend/src/features/mapSideBar/hooks/useMapSideBarQueryParams.tsx index 1cb77a1635..b556937b67 100644 --- a/frontend/src/features/mapSideBar/hooks/useMapSideBarQueryParams.tsx +++ b/frontend/src/features/mapSideBar/hooks/useMapSideBarQueryParams.tsx @@ -4,6 +4,7 @@ import AddResearchContainer from 'features/properties/map/research/add/AddResear import ResearchContainer from 'features/properties/map/research/ResearchContainer'; import { IPropertyApiModel } from 'interfaces/IPropertyApiModel'; import { isNumber } from 'lodash'; +import queryString from 'query-string'; import React, { useCallback, useState } from 'react'; import { useHistory, useLocation } from 'react-router-dom'; @@ -25,7 +26,6 @@ export enum MapViewState { RESEARCH_ADD = 'research_add', RESEARCH_VIEW = 'research_view', PROPERTY_INFORMATION = 'property_information', - PROPERTY_INFORMATION_EDIT = 'property_information_edit', ACQUISITION_ADD = 'acquisition_add', } @@ -54,8 +54,9 @@ export const useMapSideBarQueryParams = (map?: L.Map): IMapSideBar => { var parts = location.pathname.split('/'); var currentState: MapViewState = MapViewState.MAP_ONLY; - var researchId = 0; - var propertyId = ''; + var researchId: number = 0; + var propertyId: number | undefined = 0; + var pid = ''; if (parts.length === 2) { currentState = MapViewState.MAP_ONLY; } else if (parts.length > 2) { @@ -69,12 +70,12 @@ export const useMapSideBarQueryParams = (map?: L.Map): IMapSideBar => { currentState = MapViewState.MAP_ONLY; } } else if (parts.length > 3 && parts[2] === 'property') { - propertyId = parts[3]; - if (parts.length === 5 && parts[4] === 'edit') { - currentState = MapViewState.PROPERTY_INFORMATION_EDIT; - } else { - currentState = MapViewState.PROPERTY_INFORMATION; - } + pid = queryString.parse(location.search).pid?.toString() ?? ''; + propertyId = !!parts[3] ? +parts[3] : undefined; + currentState = MapViewState.PROPERTY_INFORMATION; + } else if (parts.length > 3 && parts[2] === 'non-inventory-property') { + pid = parts[3]; + currentState = MapViewState.PROPERTY_INFORMATION; } else if (parts[2] === 'acquisition') { if (parts.length === 4 && parts[3] === 'new') { currentState = MapViewState.ACQUISITION_ADD; @@ -104,20 +105,14 @@ export const useMapSideBarQueryParams = (map?: L.Map): IMapSideBar => { case MapViewState.PROPERTY_INFORMATION: setSidebarComponent( , ); setShowSideBar(true); break; - case MapViewState.PROPERTY_INFORMATION_EDIT: - setSidebarComponent( - , - ); - setShowSideBar(true); - break; case MapViewState.ACQUISITION_ADD: setSidebarComponent(); setShowSideBar(true); diff --git a/frontend/src/features/mapSideBar/tabs/propertyDetails/detail/PropertyDetailsTabView.tsx b/frontend/src/features/mapSideBar/tabs/propertyDetails/detail/PropertyDetailsTabView.tsx index 78a910c6ab..8179b72340 100644 --- a/frontend/src/features/mapSideBar/tabs/propertyDetails/detail/PropertyDetailsTabView.tsx +++ b/frontend/src/features/mapSideBar/tabs/propertyDetails/detail/PropertyDetailsTabView.tsx @@ -1,226 +1,227 @@ -import { Text } from 'components/common/form'; -import { RadioGroup } from 'components/common/form/RadioGroup'; import LoadingBackdrop from 'components/maps/leaflet/LoadingBackdrop/LoadingBackdrop'; import * as API from 'constants/API'; import { PropertyAdjacentLandTypes, PropertyTenureTypes } from 'constants/index'; -import { Formik, FormikProps, getIn } from 'formik'; import useLookupCodeHelpers from 'hooks/useLookupCodeHelpers'; -import noop from 'lodash/noop'; import Api_TypeCode from 'models/api/TypeCode'; import Multiselect from 'multiselect-react-dropdown'; import React from 'react'; -import { Col, Row } from 'react-bootstrap'; +import { Button, Col, Form, Row } from 'react-bootstrap'; +import { FaEdit } from 'react-icons/fa'; +import styled from 'styled-components'; import { booleanToYesNoUnknownString, stringToBoolean } from 'utils/formUtils'; import { Section } from '../../Section'; import { SectionField, StyledFieldLabel } from '../../SectionField'; -import { InlineContainer, LeftBorderCol, StyledReadOnlyForm } from '../../SectionStyles'; +import { InlineContainer, LeftBorderCol } from '../../SectionStyles'; import { LandMeasurementTable } from './components/LandMeasurementTable'; import { VolumetricMeasurementTable } from './components/VolumetricMeasurementTable'; -import { - defaultPropertyInfo, - IPropertyDetailsForm, - readOnlyMultiSelectStyle, - toFormValues, -} from './PropertyDetailsTabView.helpers'; +import { IPropertyDetailsForm, readOnlyMultiSelectStyle } from './PropertyDetailsTabView.helpers'; export interface IPropertyDetailsTabView { property?: IPropertyDetailsForm; loading: boolean; + setEditMode?: (isEditing: boolean) => void; } /** * Provides basic property information, as displayed under "Property Details" tab on the Property Information slide-out * @returns the rendered property details panel */ -export const PropertyDetailsTabView: React.FC = ({ +export const PropertyDetailsTabView: React.FunctionComponent = ({ property, loading, + setEditMode, }) => { - const values = property !== undefined ? property : toFormValues(defaultPropertyInfo); - - return ( - <> - - - - ); -}; - -const FormComponent: React.FC> = ({ values }) => { const { getOptionsByType } = useLookupCodeHelpers(); + const pphTypeOptions = getOptionsByType(API.PPH_STATUS_TYPES); - // multi-selects - const anomalies = getIn(values, 'anomalies') as Api_TypeCode[]; - const tenureStatus = getIn(values, 'tenure') as Api_TypeCode[]; - const roadType = getIn(values, 'roadType') as Api_TypeCode[]; - const adjacentLand = getIn(values, 'adjacentLand') as Api_TypeCode[]; + + const pphStatusTypeCodeDesc = pphTypeOptions.find( + pph => pph.value === property?.pphStatusTypeCode, + )?.label; + + const anomalies = property?.anomalies as Api_TypeCode[]; + const tenureStatus = property?.tenure as Api_TypeCode[]; + const roadType = property?.roadType as Api_TypeCode[]; + const adjacentLand = property?.adjacentLand as Api_TypeCode[]; + // measurement tables - const landMeasurement = getIn(values, 'landMeasurementTable'); - const volumeMeasurement = getIn(values, 'volumetricMeasurementTable'); + const landMeasurement = property?.landMeasurementTable; + const volumeMeasurement = property?.volumetricMeasurementTable; + // show/hide conditionals const isHighwayRoad = tenureStatus?.some(obj => obj.id === PropertyTenureTypes.HighwayRoad); const isAdjacentLand = tenureStatus?.some(obj => obj.id === PropertyTenureTypes.AdjacentLand); const isIndianReserve = isAdjacentLand && adjacentLand?.some(obj => obj.id === PropertyAdjacentLandTypes.IndianReserve); - const isVolumetricParcel = stringToBoolean(getIn(values, 'isVolumetricParcel')); - const isRwyBeltDomPatent = getIn(values, 'isRwyBeltDomPatent'); - - const pphStatusTypeCodeDesc = pphTypeOptions.find( - pph => pph.value === getIn(values, 'pphStatusTypeCode'), - )?.label; + const isVolumetricParcel = stringToBoolean(property?.isVolumetricParcel || ''); return ( - -
- - - - - - {values.districtType?.description !== 'Cannot determine' && ( - <> - - - - )} - - - - - - - - {values.isALR ? 'Yes' : 'No'} - - - {booleanToYesNoUnknownString(isRwyBeltDomPatent)} - - - - - - - - - - -
- -
- - - - - {pphStatusTypeCodeDesc ?? 'Unknown'} - - {isHighwayRoad && ( - + <> + + + + {setEditMode !== undefined && ( + + )} + +
+ {property?.regionType?.description} + + + {property?.districtType?.description !== 'Cannot determine' && ( + <>{property?.districtType?.id}- + )} + {property?.districtType?.description} + + + + {property?.electoralDistrict?.ED_NAME} + + + {property?.isALR ? 'Yes' : 'No'} + + + {booleanToYesNoUnknownString(property?.isRwyBeltDomPatent)} + + + {property?.propertyType?.description} + + {property?.municipalZoning} + - )} - {isAdjacentLand && ( - +
+ +
+ + + {pphStatusTypeCodeDesc ?? 'Unknown'} + + {isHighwayRoad && ( + + + + )} + {isAdjacentLand && ( + + + + )} +
+ + {isIndianReserve && ( +
+ {property?.firstNations?.bandName} + {property?.firstNations?.reserveName} +
)} -
- {isIndianReserve && ( -
- - - - - - +
+ + + + + + + + + + Is this a volumetric parcel? + + + + + + + + {isVolumetricParcel && ( + <> + {property?.volumetricType?.description} + + + + + + + + )} + +
- )} - -
- - - - - - - - - - Is this a volumetric parcel? - - {isVolumetricParcel && ( - <> - - - - - - - - - - - )} - - -
- -
-

{getIn(values, 'notes')}

-
- +
+

{property?.notes}

+
+ + ); }; + +const StyledSummarySection = styled.div` + background-color: ${props => props.theme.css.filterBackgroundColor}; +`; + +const StyledEditWrapper = styled.div` + color: ${props => props.theme.css.primary}; + + text-align: right; +`; diff --git a/frontend/src/features/mapSideBar/tabs/propertyDetails/detail/__snapshots__/PropertyDetailsTabView.test.tsx.snap b/frontend/src/features/mapSideBar/tabs/propertyDetails/detail/__snapshots__/PropertyDetailsTabView.test.tsx.snap index 25d67d8dd1..597e03e268 100644 --- a/frontend/src/features/mapSideBar/tabs/propertyDetails/detail/__snapshots__/PropertyDetailsTabView.test.tsx.snap +++ b/frontend/src/features/mapSideBar/tabs/propertyDetails/detail/__snapshots__/PropertyDetailsTabView.test.tsx.snap @@ -8,65 +8,7 @@ exports[`PropertyDetailsTabView component renders as expected when provided vali
- .c10 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-wrap: nowrap; - -ms-flex-wrap: nowrap; - flex-wrap: nowrap; -} - -.c9.form-group { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - margin-bottom: 0; -} - -.c9.form-group .radio-group { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: row; - -ms-flex-direction: row; - flex-direction: row; - row-gap: unset; - -webkit-column-gap: 0.4rem; - column-gap: 0.4rem; -} - -.c9.form-group .radio-group .form-check { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-align-items: center; - -webkit-box-align: center; - -ms-flex-align: center; - align-items: center; - -webkit-box-pack: center; - -webkit-justify-content: center; - -ms-flex-pack: center; - justify-content: center; -} - -.c9.form-group .radio-group .form-check .form-check-input { - margin-left: 0; -} - -.c9.form-group .radio-group .form-check-label { - margin-left: 1rem; -} - -.c9 .form-label { - margin-bottom: unset; -} - -.c1 { + .c1 { margin: 1.5rem; padding: 1.5rem; background-color: white; @@ -79,26 +21,6 @@ exports[`PropertyDetailsTabView component renders as expected when provided vali margin-bottom: 2rem; } -.c0 { - position: relative; -} - -.c0.c0.c0 input, -.c0.c0.c0 select, -.c0.c0.c0 textarea { - background: none; - border: none; - resize: none; - height: -webkit-fit-content; - height: -moz-fit-content; - height: fit-content; - padding: 0; -} - -.c0.c0.c0 .form-label { - font-weight: bold; -} - .c5 { display: -webkit-box; display: -webkit-flex; @@ -151,10 +73,16 @@ exports[`PropertyDetailsTabView component renders as expected when provided vali min-height: 3.6rem; } -
+
@@ -191,11 +119,7 @@ exports[`PropertyDetailsTabView component renders as expected when provided vali
- -
+ />
- - - - + -
@@ -239,11 +157,7 @@ exports[`PropertyDetailsTabView component renders as expected when provided vali
- -
+ />
- - No - + No
- - Unknown - + Unknown
- - Titled - + Titled
- - Some municipal zoning comments - + Some municipal zoning comments
- - Unknown - + Unknown
@@ -699,52 +593,45 @@ exports[`PropertyDetailsTabView component renders as expected when provided vali Is this a volumetric parcel?
-
- -
+
-
- -
+ @@ -782,6 +669,6 @@ exports[`PropertyDetailsTabView component renders as expected when provided vali

- +
`; diff --git a/frontend/src/features/mapSideBar/tabs/propertyDetails/hooks/useGetProperty.ts b/frontend/src/features/mapSideBar/tabs/propertyDetails/hooks/useGetProperty.ts index 6af949c4fd..c34cb907d1 100644 --- a/frontend/src/features/mapSideBar/tabs/propertyDetails/hooks/useGetProperty.ts +++ b/frontend/src/features/mapSideBar/tabs/propertyDetails/hooks/useGetProperty.ts @@ -9,11 +9,11 @@ import { toast } from 'react-toastify'; * hook that retrieves a property from the inventory. */ export const useGetProperty = () => { - const { getPropertyConceptWithPid } = useApiProperties(); + const { getPropertyConceptWithId } = useApiProperties(); const { execute, loading } = useApiRequestWrapper({ - requestFunction: useCallback(async (pid: string) => await getPropertyConceptWithPid(pid), [ - getPropertyConceptWithPid, + requestFunction: useCallback(async (id: number) => await getPropertyConceptWithId(id), [ + getPropertyConceptWithId, ]), requestName: 'retrievePropertyConcept', onSuccess: useCallback(() => toast.success('Property information retrieved'), []), diff --git a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsContainer.test.tsx b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsContainer.test.tsx deleted file mode 100644 index b01b0d395c..0000000000 --- a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsContainer.test.tsx +++ /dev/null @@ -1,278 +0,0 @@ -import { createMemoryHistory } from 'history'; -import { useQueryMapLayersByLocation } from 'hooks/useQueryMapLayersByLocation'; -import { mockLookups } from 'mocks/mockLookups'; -import { Api_Property } from 'models/api/Property'; -import { lookupCodesSlice } from 'store/slices/lookupCodes'; -import { fillInput, render, RenderOptions, userEvent, waitFor } from 'utils/test-utils'; - -import { useGetProperty, useUpdateProperty } from '../hooks'; -import { UpdatePropertyDetailsFormModel } from './models'; -import { - IUpdatePropertyDetailsContainerProps, - UpdatePropertyDetailsContainer, -} from './UpdatePropertyDetailsContainer'; - -const history = createMemoryHistory(); -const storeState = { - [lookupCodesSlice.name]: { lookupCodes: mockLookups }, -}; - -// Mock API service calls -jest.mock('../hooks'); -jest.mock('hooks/useQueryMapLayersByLocation'); - -const mockUseGetProperty: jest.Mocked> = { - retrieveProperty: jest.fn(), - retrievePropertyLoading: false, -}; -(useGetProperty as jest.Mock).mockReturnValue(mockUseGetProperty); - -const mockUseUpdateProperty: jest.Mocked> = { - updateProperty: jest.fn(), - updatePropertyLoading: false, -}; -(useUpdateProperty as jest.Mock).mockReturnValue(mockUseUpdateProperty); - -const mockUseQueryMapLayers: jest.Mocked> = { - queryAll: jest.fn(), -}; -(useQueryMapLayersByLocation as jest.Mock).mockReturnValue(mockUseQueryMapLayers); - -const fakeProperty: Api_Property = { - id: 205, - propertyType: { - id: 'TITLED', - description: 'Titled', - isDisabled: false, - }, - anomalies: [ - { - id: 1, - propertyId: 205, - propertyAnomalyTypeCode: { - id: 'ACCESS', - description: 'Access', - isDisabled: false, - }, - rowVersion: 17, - }, - { - id: 3, - propertyId: 205, - propertyAnomalyTypeCode: { - id: 'DISTURB', - description: 'Disturbance', - isDisabled: false, - }, - rowVersion: 12, - }, - ], - tenures: [ - { - id: 453, - propertyId: 205, - propertyTenureTypeCode: { - id: 'HWYROAD', - description: 'Highway/Road', - isDisabled: false, - }, - rowVersion: 16, - }, - { - id: 454, - propertyId: 205, - propertyTenureTypeCode: { - id: 'ADJLAND', - description: 'Adjacent Land', - isDisabled: false, - }, - rowVersion: 16, - }, - ], - roadTypes: [ - { - id: 1, - propertyId: 205, - propertyRoadTypeCode: { - id: 'CTRLACC', - description: 'Controlled Access', - isDisabled: false, - }, - rowVersion: 16, - }, - { - id: 3, - propertyId: 205, - propertyRoadTypeCode: { - id: 'OIC', - description: 'Order in Council (OIC)', - isDisabled: false, - }, - rowVersion: 13, - }, - ], - adjacentLands: [ - { - id: 1, - propertyId: 205, - propertyAdjacentLandTypeCode: { - id: 'INDIANR', - description: 'Indian Reserve (IR)', - isDisabled: false, - }, - rowVersion: 16, - }, - ], - status: { - id: 'MOTIADMIN', - description: 'Under MoTI administration', - isDisabled: false, - }, - dataSource: { - id: 'PAIMS', - description: 'Property Acquisition and Inventory Management System (PAIMS)', - isDisabled: false, - }, - region: { - id: 1, - description: 'South Coast Region', - isDisabled: false, - }, - district: { - id: 1, - description: 'Lower Mainland District', - isDisabled: false, - }, - dataSourceEffectiveDate: '2021-08-31T00:00:00', - latitude: 925866.6022023489, - longitude: 1406876.1727310908, - isSensitive: false, - address: { - id: 1, - streetAddress1: '45 - 904 Hollywood Crescent', - streetAddress2: 'Living in a van', - streetAddress3: 'Down by the River', - municipality: 'Hollywood North', - province: { - id: 1, - code: 'BC', - description: 'British Columbia', - displayOrder: 10, - }, - country: { - id: 1, - code: 'CA', - description: 'Canada', - displayOrder: 1, - }, - postal: 'V6Z 5G7', - rowVersion: 2, - }, - pid: 1234, - pin: 5498101, - areaUnit: { - id: 'M2', - description: 'Meters sq', - isDisabled: false, - }, - landArea: 25000, - isVolumetricParcel: true, - volumetricMeasurement: 1000, - volumetricUnit: { - id: 'M3', - description: 'Cubic Meters', - isDisabled: false, - }, - volumetricType: { - id: 'SUBSURF', - description: 'Sub-surface', - isDisabled: false, - }, - municipalZoning: 'Zoning # 1', - location: { - coordinate: { - x: 1406876.1727310908, - y: 925866.6022023489, - }, - }, - notes: 'I edited this Test notes for this property - again', - rowVersion: 5, -}; - -describe('UpdatePropertyDetailsContainer component', () => { - // render component under test - const setup = (renderOptions: RenderOptions & IUpdatePropertyDetailsContainerProps = {}) => { - const utils = render(, { - ...renderOptions, - store: storeState, - history, - }); - - return { - ...utils, - getSaveButton: () => utils.getByText(/Save/i), - getCancelButton: () => utils.getByText(/Cancel/i), - }; - }; - - let initialValues: UpdatePropertyDetailsFormModel; - - beforeEach(() => { - history.push('/mapview/property/1234/edit'); - initialValues = UpdatePropertyDetailsFormModel.fromApi(fakeProperty); - mockUseGetProperty.retrieveProperty.mockResolvedValue(fakeProperty); - mockUseUpdateProperty.updateProperty.mockResolvedValue(fakeProperty); - mockUseQueryMapLayers.queryAll.mockResolvedValue({ - isALR: false, - motiRegion: {}, - highwaysDistrict: {}, - electoralDistrict: {}, - firstNations: {}, - }); - }); - - afterEach(() => { - jest.clearAllMocks(); - }); - - it('renders as expected', async () => { - const { asFragment, findByText } = setup(); - expect(await findByText(/Titled/i)).toBeInTheDocument(); - expect(asFragment()).toMatchSnapshot(); - }); - - it('cancels the form when Cancel is clicked', async () => { - const { getCancelButton, findByText } = setup(); - expect(await findByText(/Titled/i)).toBeInTheDocument(); - userEvent.click(getCancelButton()); - - await waitFor(() => expect(history.location.pathname).toBe('/mapview/property/1234')); - }); - - it('saves the form with minimal data when Save is clicked', async () => { - const expected = initialValues.toApi(); - const { getSaveButton, findByText } = setup(); - expect(await findByText(/Titled/i)).toBeInTheDocument(); - userEvent.click(getSaveButton()); - - await waitFor(() => expect(mockUseUpdateProperty.updateProperty).toBeCalledWith(expected)); - }); - - it('saves the form with updated values when Save is clicked', async () => { - const expected = Object.assign(new UpdatePropertyDetailsFormModel(), initialValues); - expected.municipalZoning = 'Lorem ipsum'; - expected.notes = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'; - - const { getSaveButton, findByText, container } = setup(); - expect(await findByText(/Titled/i)).toBeInTheDocument(); - - // modify form values - await fillInput(container, 'municipalZoning', expected.municipalZoning); - await fillInput(container, 'notes', expected.notes, 'textarea'); - userEvent.click(getSaveButton()); - - await waitFor(() => - expect(mockUseUpdateProperty.updateProperty).toBeCalledWith(expected.toApi()), - ); - }); -}); diff --git a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsContainer.tsx b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsContainer.tsx index 5e6a001f87..aba4344f77 100644 --- a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsContainer.tsx +++ b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsContainer.tsx @@ -1,11 +1,11 @@ import LoadingBackdrop from 'components/maps/leaflet/LoadingBackdrop/LoadingBackdrop'; -import { Formik, FormikHelpers } from 'formik'; +import { Formik, FormikHelpers, FormikProps } from 'formik'; import useIsMounted from 'hooks/useIsMounted'; import { useQueryMapLayersByLocation } from 'hooks/useQueryMapLayersByLocation'; import isNumber from 'lodash/isNumber'; import { Api_Property } from 'models/api/Property'; -import React, { useCallback, useEffect, useState } from 'react'; -import { useHistory } from 'react-router-dom'; +import React, { useEffect, useRef, useState } from 'react'; +import styled from 'styled-components'; import { useGetProperty, useUpdateProperty } from '../hooks'; import { UpdatePropertyDetailsFormModel } from './models'; @@ -13,22 +13,27 @@ import { UpdatePropertyDetailsForm } from './UpdatePropertyDetailsForm'; import { UpdatePropertyDetailsYupSchema } from './validation'; export interface IUpdatePropertyDetailsContainerProps { - pid?: string; + id: number; + setFormikRef: (ref: React.RefObject> | undefined) => void; + onSuccess: () => void; } export const UpdatePropertyDetailsContainer: React.FC = props => { const isMounted = useIsMounted(); - const history = useHistory(); const { retrieveProperty, retrievePropertyLoading } = useGetProperty(); const { updateProperty } = useUpdateProperty(); const { queryAll } = useQueryMapLayersByLocation(); + const formikRef = useRef>(null); + + props.setFormikRef(formikRef); + const [initialForm, setForm] = useState(undefined); useEffect(() => { async function fetchProperty() { - if (!!props.pid) { - const retrieved = await retrieveProperty(props.pid); + if (!!props.id) { + const retrieved = await retrieveProperty(props.id); if (retrieved !== undefined && isMounted()) { const formValues = UpdatePropertyDetailsFormModel.fromApi(retrieved); @@ -47,9 +52,9 @@ export const UpdatePropertyDetailsContainer: React.FC, @@ -57,32 +62,42 @@ export const UpdatePropertyDetailsContainer: React.FC { - if (!!initialForm?.pid) { - history.push(`/mapview/property/${initialForm.pid}`); + if (!!response?.id) { + formikHelpers.resetForm(); + props.onSuccess(); } - }, [history, initialForm?.pid]); - - if (retrievePropertyLoading) { - return ; - } + }; return ( enableReinitialize + innerRef={formikRef} validationSchema={UpdatePropertyDetailsYupSchema} initialValues={initialForm || new UpdatePropertyDetailsFormModel()} onSubmit={savePropertyInformation} > - {formikProps => } + {formikProps => ( + + + + + )} ); }; + +const StyledFormWrapper = styled.div` + display: flex; + flex-direction: column; + flex-grow: 1; + text-align: left; + height: 100%; + overflow-y: auto; + padding-right: 1rem; + padding-bottom: 1rem; +`; diff --git a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsForm.test.tsx b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsForm.test.tsx index edb5b30c2f..0fa2f7c7cb 100644 --- a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsForm.test.tsx +++ b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsForm.test.tsx @@ -5,7 +5,7 @@ import { createMemoryHistory } from 'history'; import { mockLookups } from 'mocks/mockLookups'; import { Api_Property } from 'models/api/Property'; import { lookupCodesSlice } from 'store/slices/lookupCodes'; -import { fillInput, render, RenderOptions, userEvent, waitFor } from 'utils/test-utils'; +import { render, RenderOptions } from 'utils/test-utils'; import { UpdatePropertyDetailsFormModel } from './models'; import { UpdatePropertyDetailsForm } from './UpdatePropertyDetailsForm'; @@ -16,7 +16,6 @@ const storeState = { }; const onSubmit = jest.fn(); -const onCancel = jest.fn(); const mockAxios = new MockAdapter(axios); const fakeProperty: Api_Property = { @@ -193,7 +192,7 @@ describe('UpdatePropertyDetailsForm component', () => { ) => { const utils = render( - {formikProps => } + {formikProps => } , { ...renderOptions, @@ -204,8 +203,6 @@ describe('UpdatePropertyDetailsForm component', () => { return { ...utils, - getSaveButton: () => utils.getByText(/Save/i), - getCancelButton: () => utils.getByText(/Cancel/i), }; }; @@ -224,33 +221,4 @@ describe('UpdatePropertyDetailsForm component', () => { const { asFragment } = setup({ initialValues }); expect(asFragment()).toMatchSnapshot(); }); - - it('cancels the form when Cancel is clicked', () => { - const { getCancelButton } = setup({ initialValues }); - userEvent.click(getCancelButton()); - expect(onCancel).toBeCalled(); - }); - - it('saves the form with minimal data when Save is clicked', async () => { - const { getSaveButton } = setup({ - initialValues, - }); - userEvent.click(getSaveButton()); - await waitFor(() => expect(onSubmit).toBeCalledWith(initialValues, expect.anything())); - }); - - it('saves the form with updated values when Save is clicked', async () => { - const expectedValues = Object.assign(new UpdatePropertyDetailsFormModel(), initialValues); - expectedValues.municipalZoning = 'Lorem ipsum'; - expectedValues.notes = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'; - - const { getSaveButton, container } = setup({ initialValues }); - - // modify form values - await fillInput(container, 'municipalZoning', expectedValues.municipalZoning); - await fillInput(container, 'notes', expectedValues.notes, 'textarea'); - userEvent.click(getSaveButton()); - - await waitFor(() => expect(onSubmit).toBeCalledWith(expectedValues, expect.anything())); - }); }); diff --git a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsForm.tsx b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsForm.tsx index 34cfd94c5d..278ac9a3a8 100644 --- a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsForm.tsx +++ b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/UpdatePropertyDetailsForm.tsx @@ -1,16 +1,14 @@ -import { Button } from 'components/common/buttons'; import { Input, Multiselect, Select, Text, TextArea } from 'components/common/form'; import { RadioGroup } from 'components/common/form/RadioGroup'; import { UnsavedChangesPrompt } from 'components/common/form/UnsavedChangesPrompt'; import { YesNoSelect } from 'components/common/form/YesNoSelect'; -import { Scrollable } from 'components/common/Scrollable/Scrollable'; import { UserNameTooltip } from 'components/common/UserNameTooltip'; import * as API from 'constants/API'; import { PropertyAdjacentLandTypes, PropertyTenureTypes } from 'constants/index'; -import { Form, FormikProps, getIn } from 'formik'; +import { FormikProps, getIn, useFormikContext } from 'formik'; import { useLookupCodeHelpers } from 'hooks/useLookupCodeHelpers'; import React, { useEffect } from 'react'; -import { ButtonToolbar, Col, Row } from 'react-bootstrap'; +import { Col, Row } from 'react-bootstrap'; import styled from 'styled-components'; import { prettyFormatDate } from 'utils'; import { stringToBoolean } from 'utils/formUtils'; @@ -28,16 +26,15 @@ import { UpdatePropertyDetailsFormModel, } from './models'; -export interface IUpdatePropertyDetailsFormProps - extends FormikProps { - onCancel: () => void; +export interface IUpdatePropertyDetailsFormProps { + formikProps: FormikProps; } -export const UpdatePropertyDetailsForm: React.FC = ({ - values, - setFieldValue, - onCancel, +export const UpdatePropertyDetailsForm: React.FunctionComponent = ({ + formikProps, }) => { + const { values } = useFormikContext(); + // Lookup codes const { getByType, getOptionsByType } = useLookupCodeHelpers(); const volumetricTypeOptions = getOptionsByType(API.PROPERTY_VOLUMETRIC_TYPES); @@ -77,6 +74,7 @@ export const UpdatePropertyDetailsForm: React.FC { if (!isVolumetricParcel) { @@ -100,216 +98,190 @@ export const UpdatePropertyDetailsForm: React.FC + - -
- - - {districtOptions.find(x => x.code?.toString() === values.districtTypeCode?.toString()) - ?.label === 'Cannot determine' && ( - {cannotDetermineInfoText} - )} - - - - - - {values.isALR ? 'Yes' : 'No'} - - - - - - - - +
+ + + {districtOptions.find(x => x.code?.toString() === values.districtTypeCode?.toString()) + ?.label === 'Cannot determine' && ( + {cannotDetermineInfoText} + )} + + + + + + {values.isALR ? 'Yes' : 'No'} + + + + + + + + + + +
+ +
+ + + + + - {values?.pphStatusUpdateTimestamp && ( -

- PPH status last updated by{' '} - {' '} - on {prettyFormatDate(values?.pphStatusUpdateTimestamp)} -

- )} + )} +
+ + {isIndianReserve && ( +
+ + + + + - {isHighwayRoad && ( - - - - )} - {isAdjacentLand && ( - - - - )}
+ )} - {isIndianReserve && ( -
- - - - - - -
- )} +
+ + + + + { + formikProps.setFieldValue('landArea', landArea); + formikProps.setFieldValue('areaUnitTypeCode', areaUnitTypeCode); + }} + /> + + + + + Is this a volumetric parcel? + -
- - - - - { - setFieldValue('landArea', landArea); - setFieldValue('areaUnitTypeCode', areaUnitTypeCode); - }} + {isVolumetricParcel && ( + <> + + + + { + formikProps.setFieldValue('volumetricMeasurement', volume); + formikProps.setFieldValue('volumetricUnitTypeCode', volumeUnitTypeCode); + }} /> - - - - - { - setFieldValue('volumetricMeasurement', volume); - setFieldValue('volumetricUnitTypeCode', volumeUnitTypeCode); - }} - /> - - - - )} - - -
- -
- -
-
-
-
-
- -
- -
-`; diff --git a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/__snapshots__/UpdatePropertyDetailsForm.test.tsx.snap b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/__snapshots__/UpdatePropertyDetailsForm.test.tsx.snap index 2d2761d6f9..f4f5ef8c95 100644 --- a/frontend/src/features/mapSideBar/tabs/propertyDetails/update/__snapshots__/UpdatePropertyDetailsForm.test.tsx.snap +++ b/frontend/src/features/mapSideBar/tabs/propertyDetails/update/__snapshots__/UpdatePropertyDetailsForm.test.tsx.snap @@ -8,145 +8,12 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = `
- .c14.btn { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-align-items: center; - -webkit-box-align: center; - -ms-flex-align: center; - align-items: center; - -webkit-box-pack: center; - -webkit-justify-content: center; - -ms-flex-pack: center; - justify-content: center; - padding: 0.4rem 1.2rem; - min-height: 3rem; - border: 0.2rem solid transparent; - border-radius: 0.4rem; - text-align: center; - -webkit-text-decoration: none; - text-decoration: none; - font-size: 1.8rem; - font-family: 'BCSans','Noto Sans',Verdana,Arial,sans-serif; - font-weight: 700; - -webkit-letter-spacing: 0.1rem; - -moz-letter-spacing: 0.1rem; - -ms-letter-spacing: 0.1rem; - letter-spacing: 0.1rem; - cursor: pointer; -} - -.c14.btn:hover { - -webkit-text-decoration: underline; - text-decoration: underline; - opacity: 0.8; -} - -.c14.btn:focus { - outline-width: 0.4rem; - outline-style: solid; - outline-offset: 1px; - box-shadow: none; -} - -.c14.btn.btn-primary { - border: none; -} - -.c14.btn.btn-secondary { - background: none; -} - -.c14.btn.btn-info { - border: none; - background: none; - padding-left: 0.6rem; - padding-right: 0.6rem; -} - -.c14.btn.btn-info:hover, -.c14.btn.btn-info:active, -.c14.btn.btn-info:focus { - background: none; -} - -.c14.btn.btn-light { - border: none; -} - -.c14.btn.btn-dark { - border: none; -} - -.c14.btn.btn-link { - font-size: 1.6rem; - font-weight: 400; - background: none; - border: none; - -webkit-text-decoration: none; - text-decoration: none; - min-height: 2.5rem; - line-height: 3rem; - -webkit-box-pack: left; - -webkit-justify-content: left; - -ms-flex-pack: left; - justify-content: left; - -webkit-letter-spacing: unset; - -moz-letter-spacing: unset; - -ms-letter-spacing: unset; - letter-spacing: unset; - padding: 0; -} - -.c14.btn.btn-link:hover, -.c14.btn.btn-link:active, -.c14.btn.btn-link:focus { - -webkit-text-decoration: underline; - text-decoration: underline; - border: none; - background: none; - box-shadow: none; - outline: none; -} - -.c14.btn.btn-link:disabled, -.c14.btn.btn-link.disabled { - background: none; - pointer-events: none; -} - -.c14.btn:disabled, -.c14.btn:disabled:hover { - box-shadow: none; - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; - user-select: none; - pointer-events: none; - cursor: not-allowed; - opacity: 0.65; -} - -.c14.Button .Button__icon { - margin-right: 1.6rem; -} - -.c14.Button--icon-only:focus { - outline: none; -} - -.c14.Button--icon-only .Button__icon { - margin-right: 0; -} - -.c6 { + .c4 { margin-left: 0.5rem; cursor: pointer; } -.c12 { +.c10 { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -156,7 +23,7 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` flex-wrap: nowrap; } -.c11.form-group { +.c9.form-group { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -164,7 +31,7 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` margin-bottom: 0; } -.c11.form-group .radio-group { +.c9.form-group .radio-group { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -177,7 +44,7 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` column-gap: 0.4rem; } -.c11.form-group .radio-group .form-check { +.c9.form-group .radio-group .form-check { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -192,49 +59,40 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` justify-content: center; } -.c11.form-group .radio-group .form-check .form-check-input { +.c9.form-group .radio-group .form-check .form-check-input { margin-left: 0; } -.c11.form-group .radio-group .form-check-label { +.c9.form-group .radio-group .form-check-label { margin-left: 1rem; } -.c11 .form-label { +.c9 .form-label { margin-bottom: unset; } -.c0 { - width: 100%; - -webkit-box-flex: 1; - -webkit-flex-grow: 1; - -ms-flex-positive: 1; - flex-grow: 1; - overflow-y: auto; -} - -.c7 { +.c5 { font-weight: bold; } -.c2 { +.c0 { margin: 1.5rem; padding: 1.5rem; background-color: white; text-align: left; } -.c3 { +.c1 { font-weight: bold; border-bottom: 0.2rem solid; margin-bottom: 2rem; } -.c10 { +.c8 { border-left: 1px solid #8c8c8c; } -.c8 { +.c6 { width: 100%; font-weight: bold; padding-bottom: 0.7rem; @@ -242,25 +100,25 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` border-bottom: 2px solid #8c8c8c; } -.c5.required::before { +.c3.required::before { content: '*'; position: absolute; top: 0.75rem; left: 0rem; } -.c4 { +.c2 { font-weight: bold; } -.c9.table .no-rows-message { +.c7.table .no-rows-message { -webkit-align-items: flex-start; -webkit-box-align: flex-start; -ms-flex-align: flex-start; align-items: flex-start; } -.c9.table .tbody .tr { +.c7.table .tbody .tr { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -271,7 +129,7 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` min-width: 60px; } -.c9.table .tbody .tr .td { +.c7.table .tbody .tr .td { display: -webkit-box; display: -webkit-flex; display: -ms-flexbox; @@ -292,7 +150,7 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` align-items: center; } -.c9.table .tbody .tr .td.right { +.c7.table .tbody .tr .td.right { -webkit-box-pack: right; -webkit-justify-content: right; -ms-flex-pack: right; @@ -300,7 +158,7 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` text-align: right; } -.c9.table .tbody .tr .td.left { +.c7.table .tbody .tr .td.left { -webkit-box-pack: left; -webkit-justify-content: left; -ms-flex-pack: left; @@ -308,440 +166,409 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = ` text-align: left; } -.c9.table .tbody .tr .td input { +.c7.table .tbody .tr .td input { max-width: 12.5rem; } -.c1 { - display: -webkit-box; - display: -webkit-flex; - display: -ms-flexbox; - display: flex; - -webkit-flex-direction: column; - -ms-flex-direction: column; - flex-direction: column; - -webkit-box-flex: 1; - -webkit-flex-grow: 1; - -ms-flex-positive: 1; - flex-grow: 1; - text-align: left; - height: 100%; - padding-right: 1rem; - padding-bottom: 1rem; -} - -.c13 { - margin: 0; - -webkit-box-pack: end; - -webkit-justify-content: end; - -ms-flex-pack: end; - justify-content: end; -} - -
-
-

-
- Property Attributes -
-
+ Property Attributes
-

+
+
+ +
-
- -
+ MOTI region: + +
+
-
- -
+ South Coast Region + + + +
+
+
-
- -
+ Highways district: + +
+
-
- -
+ Please Select + +
+
+
-
- -
-
- -
+ Electoral district: +
-
+
+
+
+
+
-
+
+
+ - - No - -
+ No +
+
+
-
- -
+ Railway belt / Dominion patent: + +
+
-
- -
+ Unknown + + + +
+
+
-
- -
+ Land parcel type: + +
+
-
- -
+ Crown - Federal - Surveyed + + + + + + + + + + +
+
+
-
- -
+ Municipal zoning: + +
+
-
- -
+
+
+
-
- -
+ Anomalies: + +
+
-
-
+
+
-
- - Access - - - - - - - + + + + + Disturbance + - Disturbance - - - - - - - -
-
+ + + + +
+
+
    -
      - - No Options Available - -
    -
+ No Options Available + +
@@ -749,384 +576,384 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = `
-
+
+

-

-
- Tenure Status -
-
+ Tenure Status
-

+
+
+ +
-
- -
+ Tenure status: + +
+
-
-
+
+
-
- - Highway/Road - - - - - - - + + + + + Adjacent Land + - Adjacent Land - - - - - - - -
-
+ + + + +
+
+
    -
      -
    • - Closed Road -
    • -
    • - Unknown -
    • -
    -
+ Closed Road + +
  • + Unknown +
  • +
    +
    +
    -
    - -
    + Provincial Public Hwy: + +
    +
    -
    - -
    -

    + + + + +

    +

    + PPH status last updated by + - PPH status last updated by - - USER - + USER - on May 10, 2020 -

    -
    + + on May 10, 2020 +

    +
    +
    -
    - -
    + Highway / Road: + +
    +
    -
    -
    +
    +
    -
    - - Controlled Access - - - - - - - + + + + + Order in Council (OIC) + - Order in Council (OIC) - - - - - - - -
    -
    + + + + +
    +
    +
      -
        - - No Options Available - -
      -
    + No Options Available + +
    +
    +
    -
    - -
    + Adjacent land: + +
    +
    -
    -
    +
    +
    -
    - - Indian Reserve (IR) - - - - - - - -
    -
    + + + + +
    +
    +
      -
        - - No Options Available - -
      -
    + No Options Available + +
    @@ -1134,231 +961,231 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = `
    +
    +
    +

    +
    +
    + First Nations Information +
    +
    +
    +

    -

    -
    - First Nations Information -
    -
    +
    +
    +
    -

    +
    -
    - -
    -
    - -
    + Reserve name: +
    -
    - -
    -
    - -
    +
    -
    +
    +

    -

    -
    - Area -
    -
    + Area
    -

    +
    +
    + +
    +
    -
    + +
    +
    -
    - -
    -
    - sq. metres -
    + sq. metres
    +
    +
    + +
    +
    -
    - -
    -
    - sq. feet -
    + sq. feet
    +
    +
    + +
    +
    -
    - -
    -
    - hectares -
    + hectares
    +
    +
    + +
    +
    -
    - -
    -
    - acres -
    + acres
    @@ -1366,176 +1193,176 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = `
    +
    +
    +
    -
    -
    - -
    - -
    -
    -
    - -
    - +
    -
    -
    -
    -
    - +
    +
    +
    +
    +
    + +
    -
    + +
    +
    -
    - -
    -
    - - metres - - 3 - - -
    + + metres + + 3 + +
    +
    +
    + +
    +
    -
    - -
    -
    - - feet - - 3 - - -
    + + feet + + 3 + +
    @@ -1546,73 +1373,44 @@ exports[`UpdatePropertyDetailsForm component renders as expected 1`] = `
    -
    +
    +

    -

    -
    -
    - Notes -
    -
    -
    -

    - + Notes
    +
    -
    -
    -
    +
    - +
    `; diff --git a/frontend/src/features/notes/NoteContainer.tsx b/frontend/src/features/notes/NoteContainer.tsx new file mode 100644 index 0000000000..9ad0e5b0a6 --- /dev/null +++ b/frontend/src/features/notes/NoteContainer.tsx @@ -0,0 +1,69 @@ +import { NoteTypes } from 'constants/index'; +import { useEffect, useState } from 'react'; + +import { NoteDetailsFormModal } from './detail/NoteDetailsFormModal'; +import { useNoteRepository } from './hooks/useNoteRepository'; +import { UpdateNoteContainer } from './update/UpdateNoteContainer'; + +export interface INotesDetailContainerProps { + /** The parent entity type for adding notes - e.g. 'activity' */ + type: NoteTypes; + /** The note's ID */ + noteId: number; + /** Initial edit mode value */ + editMode?: boolean; + /** Whether to show the notes modal. Default: false */ + isOpened: boolean; + /** set the value of the externally tracked 'isOpened' prop above. */ + openModal: () => void; + /** set the value of the externally tracked 'isOpened' prop above. */ + closeModal: () => void; + /** Success callback */ + onSuccess?: () => void; +} + +export const NoteContainer: React.FC = props => { + const [isEditMode, setEditMode] = useState(!!props.editMode); + const { + getNote: { execute, loading, response }, + } = useNoteRepository(); + + useEffect(() => { + execute(props.type, props.noteId); + }, [execute, props.noteId, props.type]); + + // re-fetch note from API after update + const onSuccess = () => { + execute(props.type, props.noteId); + props.onSuccess && props.onSuccess(); + }; + + const close = () => { + props.closeModal(); + setEditMode(false); + }; + + if (isEditMode) { + return ( + + ); + } else { + return ( + setEditMode(true)} + > + ); + } +}; diff --git a/frontend/src/features/notes/add/AddNotesContainer.test.tsx b/frontend/src/features/notes/add/AddNotesContainer.test.tsx new file mode 100644 index 0000000000..a775c9ff78 --- /dev/null +++ b/frontend/src/features/notes/add/AddNotesContainer.test.tsx @@ -0,0 +1,133 @@ +import axios from 'axios'; +import MockAdapter from 'axios-mock-adapter'; +import { NoteTypes } from 'constants/index'; +import { createMemoryHistory } from 'history'; +import { mockLookups } from 'mocks/mockLookups'; +import { mockEntityNote } from 'mocks/mockNoteResponses'; +import { Api_EntityNote } from 'models/api/Note'; +import { lookupCodesSlice } from 'store/slices/lookupCodes'; +import { render, RenderOptions, userEvent, waitFor } from 'utils/test-utils'; + +import { AddNotesContainer, IAddNotesContainerProps } from './AddNotesContainer'; +import { EntityNoteForm } from './models'; + +const history = createMemoryHistory(); +const mockAxios = new MockAdapter(axios); + +const openModal = jest.fn(); +const closeModal = jest.fn(); +const onSuccess = jest.fn(); + +const BASIC_PROPS: IAddNotesContainerProps = { + isOpened: true, + openModal, + closeModal, + parentId: 1, + type: NoteTypes.Activity, + onSuccess, +}; + +describe('AddNotesContainer component', () => { + // render component under test + const setup = ( + props: IAddNotesContainerProps = BASIC_PROPS, + renderOptions: RenderOptions = {}, + ) => { + const utils = render(, { + ...renderOptions, + store: { + [lookupCodesSlice.name]: { lookupCodes: mockLookups }, + }, + history, + }); + + return { + ...utils, + getSaveButton: () => utils.getByText(/Save/i), + getCancelButton: () => utils.getByText(/Cancel/i), + }; + }; + + beforeEach(() => { + mockAxios.resetHistory(); + }); + + afterEach(() => { + jest.clearAllMocks(); + }); + + it('renders as expected', () => { + setup(); + expect(document.body).toMatchSnapshot(); + }); + + it('renders the underlying form', () => { + const { getByLabelText, getByText } = setup(); + + const modalTitle = getByText(/Notes/i); + const textarea = getByLabelText(/Type a note/i); + + expect(modalTitle).toBeVisible(); + expect(textarea).toBeVisible(); + expect(textarea.tagName).toBe('TEXTAREA'); + }); + + it('should cancel form when Cancel button is clicked', async () => { + const { getCancelButton, getByText } = setup(); + + expect(getByText(/Notes/i)).toBeVisible(); + await waitFor(() => { + userEvent.click(getCancelButton()); + }); + + expect(closeModal).toBeCalled(); + }); + + it('should save the form and close the modal when Submit button is clicked', async () => { + const formValues = new EntityNoteForm(); + formValues.parentId = BASIC_PROPS.parentId; + formValues.note.note = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'; + + const { getSaveButton, findByLabelText } = setup(BASIC_PROPS); + + const textarea = await findByLabelText(/Type a note/i); + userEvent.type(textarea, formValues.note.note); + + mockAxios.onPost().reply(200, mockEntityNote(1)); + await waitFor(() => { + userEvent.click(getSaveButton()); + }); + + expect(closeModal).toBeCalled(); + expect(onSuccess).toBeCalled(); + + const axiosData: Api_EntityNote = JSON.parse(mockAxios.history.post[0].data); + const expectedValues = formValues.toApi(); + + expect(mockAxios.history.post[0].url).toBe('/notes/activity'); + expect(axiosData.parent).toEqual(expectedValues.parent); + expect({ ...axiosData.note, id: undefined, rowVersion: undefined }).toEqual( + expectedValues.note, + ); + }); + + it('should support adding notes to other entity types', async () => { + const formValues = new EntityNoteForm(); + formValues.parentId = BASIC_PROPS.parentId; + formValues.note.note = 'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'; + + const { getSaveButton, findByLabelText } = setup({ ...BASIC_PROPS, type: NoteTypes.File }); + + const textarea = await findByLabelText(/Type a note/i); + userEvent.type(textarea, formValues.note.note); + + mockAxios.onPost().reply(200, mockEntityNote(1)); + await waitFor(() => { + userEvent.click(getSaveButton()); + }); + + expect(closeModal).toBeCalled(); + expect(onSuccess).toBeCalled(); + expect(mockAxios.history.post[0].url).toBe('/notes/file'); + }); +}); diff --git a/frontend/src/features/notes/add/AddNotesContainer.tsx b/frontend/src/features/notes/add/AddNotesContainer.tsx index e40d6d7bed..07c9567f3f 100644 --- a/frontend/src/features/notes/add/AddNotesContainer.tsx +++ b/frontend/src/features/notes/add/AddNotesContainer.tsx @@ -1,60 +1,79 @@ -import { Formik, FormikHelpers, FormikProps } from 'formik'; -import { useHistory } from 'react-router-dom'; +import { CancelConfirmationModal } from 'components/common/CancelConfirmationModal'; +import { NoteTypes } from 'constants/index'; +import { FormikProps } from 'formik'; +import { useModalManagement } from 'hooks/useModalManagement'; +import { useRef } from 'react'; -import { useAddNote } from '../hooks/useAddNote'; -import { AddNotesForm } from './AddNotesForm'; +import { useAddNotesFormManagement } from '../hooks/useAddNotesFormManagement'; +import { AddNotesFormModal } from './AddNotesFormModal'; import { EntityNoteForm } from './models'; export interface IAddNotesContainerProps { /** The parent entity type for adding notes - e.g. 'activity' */ - parentType: string; + type: NoteTypes; /** The parent's ID */ parentId: number; /** Whether to show the notes modal. Default: false */ - showNotes: boolean; - /** set the value of the externally tracked 'showNotes' prop above. */ - setShowNotes: (show: boolean) => void; + isOpened: boolean; + /** set the value of the externally tracked 'isOpened' prop above. */ + openModal: () => void; + /** set the value of the externally tracked 'isOpened' prop above. */ + closeModal: () => void; + /** Optional - callback to execute after note has been added to the datastore */ + onSuccess?: () => void; } export const AddNotesContainer: React.FC = props => { - const history = useHistory(); - const { addNote } = useAddNote(); - - // save handler - const saveNote = async (values: EntityNoteForm, formikHelpers: FormikHelpers) => { - const apiNote = values.toApi(); - const response = await addNote(props.parentType, apiNote); - formikHelpers?.setSubmitting(false); - - if (!!response?.id) { - formikHelpers?.resetForm(); - // TODO: navigate to Notes LIST VIEW - history.replace(`/mapview`); + const [showConfirmModal, openConfirmModal, closeConfirmModal] = useModalManagement(); + const formikRef = useRef>(null); + + const { handleSubmit, initialValues, validationSchema } = useAddNotesFormManagement({ + type: props.type, + parentId: props.parentId, + onSuccess: props.onSuccess, + }); + + const handleSaveClick = async () => { + if (formikRef.current !== null) { + formikRef.current.setSubmitting(true); + await formikRef.current.submitForm(); + if (formikRef.current.isValid) { + props.closeModal && props.closeModal(); + } } }; - const onSaveClick = (noteForm: EntityNoteForm, formikProps: FormikProps) => { - formikProps?.setSubmitting(true); - formikProps?.submitForm(); + const handleCancelClick = () => { + if (formikRef.current?.dirty) { + openConfirmModal(); + } else { + handleCancelConfirm(); + } }; - const onCancelClick = (formikProps: FormikProps) => { - formikProps?.resetForm(); + const handleCancelConfirm = () => { + closeConfirmModal(); + formikRef.current?.resetForm(); + props.closeModal && props.closeModal(); }; - const noteForm = new EntityNoteForm(); - noteForm.parentId = props.parentId; - return ( - enableReinitialize initialValues={noteForm} onSubmit={saveNote}> - {() => ( - - )} - + <> + + + + ); }; diff --git a/frontend/src/features/notes/add/AddNotesForm.tsx b/frontend/src/features/notes/add/AddNotesForm.tsx deleted file mode 100644 index 9ce093010c..0000000000 --- a/frontend/src/features/notes/add/AddNotesForm.tsx +++ /dev/null @@ -1,71 +0,0 @@ -import { TextArea } from 'components/common/form'; -import { GenericModal } from 'components/common/GenericModal'; -import { FormikProps, useFormikContext } from 'formik'; -import styled from 'styled-components'; - -import { EntityNoteForm } from './models'; - -export interface IAddNotesFormProps { - /** Whether to show the notes modal. Default: false */ - showNotes: boolean; - /** set the value of the externally tracked 'showNotes' prop above. */ - setShowNotes: (show: boolean) => void; - /** Optional - callback to notify when save button is pressed. */ - onSave?: (noteForm: EntityNoteForm, formikProps: FormikProps) => void; - /** Optional - callback to notify when cancel button is pressed. */ - onCancel?: (formikProps: FormikProps) => void; -} - -export const AddNotesForm: React.FC = props => { - const { showNotes, setShowNotes, onSave, onCancel } = props; - const formikProps = useFormikContext(); - - return ( - - } - closeButton - okButtonText="Save" - cancelButtonText="Cancel" - handleOk={() => { - onSave && onSave(formikProps.values, formikProps); - setShowNotes(false); - }} - handleCancel={() => { - onCancel && onCancel(formikProps); - setShowNotes(false); - }} - > - ); -}; - -const StyledModal = styled(GenericModal)` - min-width: 70rem; - - .modal-body { - padding-left: 2rem; - padding-right: 2rem; - } - - .modal-footer { - padding-left: 2rem; - padding-right: 2rem; - } - - .form-group { - label { - font-family: BcSans-Bold; - line-height: 2rem; - color: ${props => props.theme.css.textColor}; - } - } -`; diff --git a/frontend/src/features/notes/add/AddNotesFormModal.test.tsx b/frontend/src/features/notes/add/AddNotesFormModal.test.tsx new file mode 100644 index 0000000000..a9a02e3613 --- /dev/null +++ b/frontend/src/features/notes/add/AddNotesFormModal.test.tsx @@ -0,0 +1,117 @@ +import { FormikProps } from 'formik'; +import { createMemoryHistory } from 'history'; +import { mockLookups } from 'mocks/mockLookups'; +import { lookupCodesSlice } from 'store/slices/lookupCodes'; +import { fakeText, render, RenderOptions, userEvent, waitFor } from 'utils/test-utils'; + +import { AddNotesFormModal } from './AddNotesFormModal'; +import { AddNotesYupSchema } from './AddNotesYupSchema'; +import { EntityNoteForm } from './models'; + +const history = createMemoryHistory(); + +const handleSubmit = jest.fn(); +const validationSchema = jest.fn().mockReturnValue(AddNotesYupSchema); +const handleSaveClick = jest.fn(); +const handleCancelClick = jest.fn(); + +describe('AddNotesFormModal component', () => { + // render component under test + const setup = (renderOptions: RenderOptions & { initialValues: EntityNoteForm }) => { + const utils = render( + , + { + ...renderOptions, + store: { + [lookupCodesSlice.name]: { lookupCodes: mockLookups }, + }, + history, + }, + ); + + return { + ...utils, + getSaveButton: () => utils.getByText(/Save/i), + getCancelButton: () => utils.getByText(/Cancel/i), + }; + }; + + let initialValues: EntityNoteForm; + + beforeEach(() => { + initialValues = new EntityNoteForm(); + initialValues.parentId = 1; + }); + + afterEach(() => { + jest.clearAllMocks(); + }); + + it('renders as expected', () => { + setup({ initialValues }); + expect(document.body).toMatchSnapshot(); + }); + + it('renders the Note field', () => { + const { getByLabelText } = setup({ initialValues }); + const textarea = getByLabelText(/Type a note/i); + + expect(textarea).toBeVisible(); + expect(textarea.tagName).toBe('TEXTAREA'); + }); + + it('displays existing values if they exist', async () => { + initialValues.note.note = 'foo bar baz'; + const { findByLabelText } = setup({ initialValues }); + const textarea = await findByLabelText(/Type a note/i); + + expect(textarea).toBeVisible(); + expect(textarea).toHaveValue('foo bar baz'); + }); + + it('should validate character limits', async () => { + const { getSaveButton, findByText, findByLabelText } = setup({ initialValues }); + + // note cannot exceed 4000 characters + const textarea = await findByLabelText(/Type a note/i); + userEvent.paste(textarea, fakeText(4001)); + userEvent.click(getSaveButton()); + + expect(validationSchema).toBeCalled(); + expect(await findByText(/Notes must be at most 4000 characters/i)).toBeVisible(); + }); + + it('should cancel form when Cancel button is clicked', () => { + const { getCancelButton } = setup({ initialValues }); + + userEvent.click(getCancelButton()); + + expect(handleCancelClick).toBeCalled(); + expect(validationSchema).not.toBeCalled(); + expect(handleSubmit).not.toBeCalled(); + }); + + it('should submit form when Submit button is clicked', async () => { + // submit form upon save click + handleSaveClick.mockImplementation( + (values: EntityNoteForm, formikProps: FormikProps) => + formikProps?.submitForm(), + ); + + initialValues.note.note = 'foo bar baz'; + const { getSaveButton } = setup({ initialValues }); + + await waitFor(() => userEvent.click(getSaveButton())); + + expect(validationSchema).toBeCalled(); + expect(handleSubmit).toBeCalledWith(initialValues, expect.anything()); + expect(handleCancelClick).not.toBeCalled(); + }); +}); diff --git a/frontend/src/features/notes/add/AddNotesFormModal.tsx b/frontend/src/features/notes/add/AddNotesFormModal.tsx new file mode 100644 index 0000000000..2f60626b73 --- /dev/null +++ b/frontend/src/features/notes/add/AddNotesFormModal.tsx @@ -0,0 +1,88 @@ +import { TextArea } from 'components/common/form'; +import { GenericModal } from 'components/common/GenericModal'; +import { Formik, FormikHelpers, FormikProps } from 'formik'; +import React from 'react'; +import styled from 'styled-components'; + +import { EntityNoteForm } from './models'; + +export interface IAddNotesFormModalProps { + /** Whether to show the notes modal. Default: false */ + isOpened: boolean; + /** Initial values of the form */ + initialValues: EntityNoteForm; + /** A Yup Schema or a function that returns a Yup schema */ + validationSchema?: any | (() => any); + /** Submission handler */ + onSubmit: ( + values: EntityNoteForm, + formikHelpers: FormikHelpers, + ) => void | Promise; + /** Optional - callback to notify when save button is pressed. */ + onSaveClick?: (noteForm: EntityNoteForm, formikProps: FormikProps) => void; + /** Optional - callback to notify when cancel button is pressed. */ + onCancelClick?: (formikProps: FormikProps) => void; +} + +export const AddNotesFormModal = React.forwardRef< + FormikProps, + IAddNotesFormModalProps +>((props, ref) => { + const { isOpened, onSaveClick, onCancelClick, initialValues, validationSchema, onSubmit } = props; + + return ( + + enableReinitialize + innerRef={ref} + validationSchema={validationSchema} + initialValues={initialValues} + onSubmit={onSubmit} + > + {formikProps => ( + + } + closeButton + okButtonText="Save" + cancelButtonText="Cancel" + handleOk={() => { + onSaveClick && onSaveClick(formikProps.values, formikProps); + }} + handleCancel={() => { + onCancelClick && onCancelClick(formikProps); + }} + > + )} + + ); +}); + +const StyledModal = styled(GenericModal)` + min-width: 70rem; + + .modal-body { + padding-left: 2rem; + padding-right: 2rem; + } + + .modal-footer { + padding-left: 2rem; + padding-right: 2rem; + } + + .form-group { + label { + font-family: BcSans-Bold; + line-height: 2rem; + color: ${props => props.theme.css.textColor}; + } + } +`; diff --git a/frontend/src/features/notes/add/AddNotesYupSchema.ts b/frontend/src/features/notes/add/AddNotesYupSchema.ts new file mode 100644 index 0000000000..ca086c57cb --- /dev/null +++ b/frontend/src/features/notes/add/AddNotesYupSchema.ts @@ -0,0 +1,9 @@ +import * as Yup from 'yup'; + +export const AddNotesYupSchema = Yup.object().shape({ + note: Yup.object().shape({ + note: Yup.string() + .required('Notes are required') + .max(4000, 'Notes must be at most 4000 characters'), + }), +}); diff --git a/frontend/src/features/notes/add/__snapshots__/AddNotesContainer.test.tsx.snap b/frontend/src/features/notes/add/__snapshots__/AddNotesContainer.test.tsx.snap new file mode 100644 index 0000000000..bfd21b186f --- /dev/null +++ b/frontend/src/features/notes/add/__snapshots__/AddNotesContainer.test.tsx.snap @@ -0,0 +1,286 @@ +// Jest Snapshot v1, https://goo.gl/fbAQLP + +exports[`AddNotesContainer component renders as expected 1`] = ` +.c2.btn { + display: -webkit-box; + display: -webkit-flex; + display: -ms-flexbox; + display: flex; + -webkit-align-items: center; + -webkit-box-align: center; + -ms-flex-align: center; + align-items: center; + -webkit-box-pack: center; + -webkit-justify-content: center; + -ms-flex-pack: center; + justify-content: center; + padding: 0.4rem 1.2rem; + min-height: 3rem; + border: 0.2rem solid transparent; + border-radius: 0.4rem; + text-align: center; + -webkit-text-decoration: none; + text-decoration: none; + font-size: 1.8rem; + font-family: 'BCSans','Noto Sans',Verdana,Arial,sans-serif; + font-weight: 700; + -webkit-letter-spacing: 0.1rem; + -moz-letter-spacing: 0.1rem; + -ms-letter-spacing: 0.1rem; + letter-spacing: 0.1rem; + cursor: pointer; +} + +.c2.btn:hover { + -webkit-text-decoration: underline; + text-decoration: underline; + opacity: 0.8; +} + +.c2.btn:focus { + outline-width: 0.4rem; + outline-style: solid; + outline-offset: 1px; + box-shadow: none; +} + +.c2.btn.btn-primary { + border: none; +} + +.c2.btn.btn-secondary { + background: none; +} + +.c2.btn.btn-info { + border: none; + background: none; + padding-left: 0.6rem; + padding-right: 0.6rem; +} + +.c2.btn.btn-info:hover, +.c2.btn.btn-info:active, +.c2.btn.btn-info:focus { + background: none; +} + +.c2.btn.btn-light { + border: none; +} + +.c2.btn.btn-dark { + border: none; +} + +.c2.btn.btn-link { + font-size: 1.6rem; + font-weight: 400; + background: none; + border: none; + -webkit-text-decoration: none; + text-decoration: none; + min-height: 2.5rem; + line-height: 3rem; + -webkit-box-pack: left; + -webkit-justify-content: left; + -ms-flex-pack: left; + justify-content: left; + -webkit-letter-spacing: unset; + -moz-letter-spacing: unset; + -ms-letter-spacing: unset; + letter-spacing: unset; + padding: 0; +} + +.c2.btn.btn-link:hover, +.c2.btn.btn-link:active, +.c2.btn.btn-link:focus { + -webkit-text-decoration: underline; + text-decoration: underline; + border: none; + background: none; + box-shadow: none; + outline: none; +} + +.c2.btn.btn-link:disabled, +.c2.btn.btn-link.disabled { + background: none; + pointer-events: none; +} + +.c2.btn:disabled, +.c2.btn:disabled:hover { + box-shadow: none; + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + pointer-events: none; + cursor: not-allowed; + opacity: 0.65; +} + +.c2.Button .Button__icon { + margin-right: 1.6rem; +} + +.c2.Button--icon-only:focus { + outline: none; +} + +.c2.Button--icon-only .Button__icon { + margin-right: 0; +} + +.c0 .modal-header { + height: 3.8rem; + padding: 0 1rem; +} + +.c0 .modal-header .h4 { + color: white; + font-family: BcSans-Bold; + font-size: 2.2rem; + height: 2.75rem; +} + +.c0 .modal-header .close { + color: white; + opacity: 1; +} + +.c1 { + min-width: 70rem; +} + +.c1 .modal-body { + padding-left: 2rem; + padding-right: 2rem; +} + +.c1 .modal-footer { + padding-left: 2rem; + padding-right: 2rem; +} + +.c1 .form-group label { + font-family: BcSans-Bold; + line-height: 2rem; +} + + +