SC701_MAILDAT contains property ownership information exported from Fiscal Office CAMA system
Visit: Fiscal Office CAMA Data Downloads
Run Report: SC701_MAILDAT


--
-- Structure for table `sc701_tmp`
--

CREATE TABLE IF NOT EXISTS `sc701_tmp` (
  `sc701string` text
) ENGINE=MyISAM DEFAULT CHARSET=utf8;

--------------------------------------------------------------

-- UPLOAD SC701_MAILDAT.DAT to /home/YourFolderName/SC701_MAILDAT.DAT
-- Run SQL query against database using phpMyAdmin
LOAD DATA LOCAL INFILE '/home/[ YourFolderName ]/SC701_MAILDAT.DAT' INTO TABLE `sc701_tmp`;

--------------------------------------------------------------

--
-- Structure for table `sc701_maildat`
--

CREATE TABLE IF NOT EXISTS `sc701_maildat` (
  `MediaCreateDate` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `ParcelID` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `TaxYear` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `Sequence#` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `AddressType` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MailingNameLine1` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MailingNameLine2` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MailingAddressLine1` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MailingAddressLine2` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MailingAddressLine3` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `ZipCode1` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `ZipCode2` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MailingNamePointer` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `ParcelLinkage` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `PostalIndex` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MailingReasonCode` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `LandContractFlag` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `PaymentCode` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MortgageCompany` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `MortgageNumber` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `ConveyanceLetterCode` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `DateRequestedChange` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `Note1` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `Note2` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `ProcessingStatus` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `UserLastMaint` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `DateLastMaintenance` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `DateDeactivated` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `City` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `StateCode` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL,
  `RecordSeperator` varchar(100) COLLATE utf8_unicode_ci DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

--------------------------------------------------------------

--
-- Insert sc701_tmp to sc701_maildat
--

INSERT INTO `sc701_maildat` SELECT SUBSTRING(sc701string,1,11), SUBSTRING(sc701string,12,7), SUBSTRING(sc701string,19,5), SUBSTRING(sc701string,24,4), SUBSTRING(sc701string,28,1), SUBSTRING(sc701string,29,40), SUBSTRING(sc701string,69,40), SUBSTRING(sc701string,109,80), SUBSTRING(sc701string,189,80), SUBSTRING(sc701string,269,80), SUBSTRING(sc701string,349,5), SUBSTRING(sc701string,354,4), SUBSTRING(sc701string,358,6), SUBSTRING(sc701string,364,15), SUBSTRING(sc701string,379,10), SUBSTRING(sc701string,389,1), SUBSTRING(sc701string,390,1), SUBSTRING(sc701string,391,4), SUBSTRING(sc701string,395,6), SUBSTRING(sc701string,401,20), SUBSTRING(sc701string,421,1), SUBSTRING(sc701string,422,11), SUBSTRING(sc701string,433,40), SUBSTRING(sc701string,473,40), SUBSTRING(sc701string,513,1), SUBSTRING(sc701string,514,10), SUBSTRING(sc701string,524,11), SUBSTRING(sc701string,535,11), SUBSTRING(sc701string,546,40), SUBSTRING(sc701string,586,2), SUBSTRING(sc701string,588,1) from `sc701_tmp`;