diff --git a/app/schemas/org.piramalswasthya.sakhi.database.room.InAppDb/78.json b/app/schemas/org.piramalswasthya.sakhi.database.room.InAppDb/78.json new file mode 100644 index 000000000..8f2d58d8f --- /dev/null +++ b/app/schemas/org.piramalswasthya.sakhi.database.room.InAppDb/78.json @@ -0,0 +1,12885 @@ +{ + "formatVersion": 1, + "database": { + "version": 78, + "identityHash": "95b1461920e35956dd4acb5799e171b2", + "entities": [ + { + "tableName": "HOUSEHOLD", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`householdId` INTEGER NOT NULL, `ashaId` INTEGER NOT NULL, `benId` INTEGER, `registrationType` TEXT, `serverUpdatedStatus` INTEGER NOT NULL, `createdBy` TEXT, `createdTimeStamp` INTEGER, `updatedBy` TEXT, `updatedTimeStamp` INTEGER, `processed` TEXT NOT NULL, `isDraft` INTEGER NOT NULL, `isDeactivate` INTEGER NOT NULL, `fam_familyHeadName` TEXT, `fam_familyName` TEXT, `fam_familyHeadPhoneNo` INTEGER, `fam_houseNo` TEXT, `fam_wardNo` TEXT, `fam_wardName` TEXT, `fam_mohallaName` TEXT, `fam_rationCardDetails` TEXT, `fam_povertyLine` TEXT, `fam_povertyLineId` INTEGER, `det_residentialArea` TEXT, `det_residentialAreaId` INTEGER, `det_otherResidentialArea` TEXT, `det_houseType` TEXT, `det_houseTypeId` INTEGER, `det_otherHouseType` TEXT, `det_isHouseOwned` TEXT, `det_isHouseOwnedId` INTEGER, `det_isLandOwned` INTEGER, `det_isLandIrrigated` INTEGER, `det_isLivestockOwned` INTEGER, `det_street` TEXT, `det_colony` TEXT, `det_pincode` INTEGER, `amn_separateKitchen` TEXT, `amn_separateKitchenId` INTEGER, `amn_fuelUsed` TEXT, `amn_fuelUsedId` INTEGER, `amn_otherFuelUsed` TEXT, `amn_sourceOfDrinkingWater` TEXT, `amn_sourceOfDrinkingWaterId` INTEGER, `amn_otherSourceOfDrinkingWater` TEXT, `amn_availabilityOfElectricity` TEXT, `amn_availabilityOfElectricityId` INTEGER, `amn_otherAvailabilityOfElectricity` TEXT, `amn_availabilityOfToilet` TEXT, `amn_availabilityOfToiletId` INTEGER, `amn_otherAvailabilityOfToilet` TEXT, `amn_motorizedVehicle` TEXT, `amn_motorizedVehicleId` INTEGER, `amn_otherMotorizedVehicle` TEXT, `loc_country_id` INTEGER NOT NULL, `loc_country_name` TEXT NOT NULL, `loc_country_nameHindi` TEXT, `loc_country_nameAssamese` TEXT, `loc_country_nameBangla` TEXT, `loc_state_id` INTEGER NOT NULL, `loc_state_name` TEXT NOT NULL, `loc_state_nameHindi` TEXT, `loc_state_nameAssamese` TEXT, `loc_state_nameBangla` TEXT, `loc_district_id` INTEGER NOT NULL, `loc_district_name` TEXT NOT NULL, `loc_district_nameHindi` TEXT, `loc_district_nameAssamese` TEXT, `loc_district_nameBangla` TEXT, `loc_block_id` INTEGER NOT NULL, `loc_block_name` TEXT NOT NULL, `loc_block_nameHindi` TEXT, `loc_block_nameAssamese` TEXT, `loc_block_nameBangla` TEXT, `loc_village_id` INTEGER NOT NULL, `loc_village_name` TEXT NOT NULL, `loc_village_nameHindi` TEXT, `loc_village_nameAssamese` TEXT, `loc_village_nameBangla` TEXT, PRIMARY KEY(`householdId`))", + "fields": [ + { + "fieldPath": "householdId", + "columnName": "householdId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ashaId", + "columnName": "ashaId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "registrationType", + "columnName": "registrationType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "serverUpdatedStatus", + "columnName": "serverUpdatedStatus", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdTimeStamp", + "columnName": "createdTimeStamp", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "updatedTimeStamp", + "columnName": "updatedTimeStamp", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isDraft", + "columnName": "isDraft", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isDeactivate", + "columnName": "isDeactivate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "family.familyHeadName", + "columnName": "fam_familyHeadName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "family.familyName", + "columnName": "fam_familyName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "family.familyHeadPhoneNo", + "columnName": "fam_familyHeadPhoneNo", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "family.houseNo", + "columnName": "fam_houseNo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "family.wardNo", + "columnName": "fam_wardNo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "family.wardName", + "columnName": "fam_wardName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "family.mohallaName", + "columnName": "fam_mohallaName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "family.rationCardDetails", + "columnName": "fam_rationCardDetails", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "family.povertyLine", + "columnName": "fam_povertyLine", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "family.povertyLineId", + "columnName": "fam_povertyLineId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "details.residentialArea", + "columnName": "det_residentialArea", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "details.residentialAreaId", + "columnName": "det_residentialAreaId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "details.otherResidentialArea", + "columnName": "det_otherResidentialArea", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "details.houseType", + "columnName": "det_houseType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "details.houseTypeId", + "columnName": "det_houseTypeId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "details.otherHouseType", + "columnName": "det_otherHouseType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "details.isHouseOwned", + "columnName": "det_isHouseOwned", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "details.isHouseOwnedId", + "columnName": "det_isHouseOwnedId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "details.isLandOwned", + "columnName": "det_isLandOwned", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "details.isLandIrrigated", + "columnName": "det_isLandIrrigated", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "details.isLivestockOwned", + "columnName": "det_isLivestockOwned", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "details.street", + "columnName": "det_street", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "details.colony", + "columnName": "det_colony", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "details.pincode", + "columnName": "det_pincode", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "amenities.separateKitchen", + "columnName": "amn_separateKitchen", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.separateKitchenId", + "columnName": "amn_separateKitchenId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "amenities.fuelUsed", + "columnName": "amn_fuelUsed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.fuelUsedId", + "columnName": "amn_fuelUsedId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "amenities.otherFuelUsed", + "columnName": "amn_otherFuelUsed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.sourceOfDrinkingWater", + "columnName": "amn_sourceOfDrinkingWater", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.sourceOfDrinkingWaterId", + "columnName": "amn_sourceOfDrinkingWaterId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "amenities.otherSourceOfDrinkingWater", + "columnName": "amn_otherSourceOfDrinkingWater", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.availabilityOfElectricity", + "columnName": "amn_availabilityOfElectricity", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.availabilityOfElectricityId", + "columnName": "amn_availabilityOfElectricityId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "amenities.otherAvailabilityOfElectricity", + "columnName": "amn_otherAvailabilityOfElectricity", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.availabilityOfToilet", + "columnName": "amn_availabilityOfToilet", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.availabilityOfToiletId", + "columnName": "amn_availabilityOfToiletId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "amenities.otherAvailabilityOfToilet", + "columnName": "amn_otherAvailabilityOfToilet", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.motorizedVehicle", + "columnName": "amn_motorizedVehicle", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "amenities.motorizedVehicleId", + "columnName": "amn_motorizedVehicleId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "amenities.otherMotorizedVehicle", + "columnName": "amn_otherMotorizedVehicle", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.country.id", + "columnName": "loc_country_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.country.name", + "columnName": "loc_country_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.country.nameHindi", + "columnName": "loc_country_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.country.nameAssamese", + "columnName": "loc_country_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.country.nameBangla", + "columnName": "loc_country_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.state.id", + "columnName": "loc_state_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.state.name", + "columnName": "loc_state_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.state.nameHindi", + "columnName": "loc_state_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.state.nameAssamese", + "columnName": "loc_state_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.state.nameBangla", + "columnName": "loc_state_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.district.id", + "columnName": "loc_district_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.district.name", + "columnName": "loc_district_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.district.nameHindi", + "columnName": "loc_district_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.district.nameAssamese", + "columnName": "loc_district_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.district.nameBangla", + "columnName": "loc_district_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.block.id", + "columnName": "loc_block_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.block.name", + "columnName": "loc_block_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.block.nameHindi", + "columnName": "loc_block_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.block.nameAssamese", + "columnName": "loc_block_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.block.nameBangla", + "columnName": "loc_block_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.village.id", + "columnName": "loc_village_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.village.name", + "columnName": "loc_village_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.village.nameHindi", + "columnName": "loc_village_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.village.nameAssamese", + "columnName": "loc_village_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.village.nameBangla", + "columnName": "loc_village_nameBangla", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "householdId" + ] + }, + "indices": [ + { + "name": "index_HOUSEHOLD_ashaId", + "unique": false, + "columnNames": [ + "ashaId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_HOUSEHOLD_ashaId` ON `${TABLE_NAME}` (`ashaId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "BENEFICIARY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`householdId` INTEGER NOT NULL, `beneficiaryId` INTEGER NOT NULL, `isDeath` INTEGER NOT NULL, `isDeathValue` TEXT, `dateOfDeath` TEXT, `timeOfDeath` TEXT, `reasonOfDeath` TEXT, `reasonOfDeathId` INTEGER NOT NULL, `placeOfDeath` TEXT, `placeOfDeathId` INTEGER NOT NULL, `otherPlaceOfDeath` TEXT, `benRegId` INTEGER NOT NULL, `ashaId` INTEGER NOT NULL, `isKid` INTEGER NOT NULL, `isAdult` INTEGER NOT NULL, `userImage` TEXT, `regDate` INTEGER NOT NULL, `firstName` TEXT, `lastName` TEXT, `gender` TEXT, `genderId` INTEGER NOT NULL, `dob` INTEGER NOT NULL, `age` INTEGER NOT NULL, `ageUnit` TEXT, `ageUnitId` INTEGER NOT NULL, `fatherName` TEXT, `motherName` TEXT, `familyHeadRelation` TEXT, `familyHeadRelationPosition` INTEGER NOT NULL, `familyHeadRelationOther` TEXT, `mobileNoOfRelation` TEXT, `mobileNoOfRelationId` INTEGER NOT NULL, `tempMobileNoOfRelationId` INTEGER NOT NULL, `mobileOthers` TEXT, `contactNumber` INTEGER NOT NULL, `literacy` TEXT, `literacyId` INTEGER NOT NULL, `community` TEXT, `communityId` INTEGER NOT NULL, `religion` TEXT, `religionId` INTEGER NOT NULL, `religionOthers` TEXT, `rchId` TEXT, `latitude` REAL NOT NULL, `longitude` REAL NOT NULL, `hasAadhar` INTEGER, `hasAadharId` INTEGER NOT NULL, `aadharNum` TEXT, `aadharNumId` INTEGER NOT NULL, `bankAccountId` INTEGER NOT NULL, `bankAccount` TEXT, `nameOfBank` TEXT, `nameOfBranch` TEXT, `ifscCode` TEXT, `needOpCare` TEXT, `needOpCareId` INTEGER NOT NULL, `ncdPriority` INTEGER NOT NULL, `cbacAvailable` INTEGER NOT NULL, `guidelineId` TEXT, `isHrpStatus` INTEGER NOT NULL, `immunizationStatus` INTEGER NOT NULL, `hrpIdentificationDate` TEXT, `hrpLastVisitDate` TEXT, `suspectedNcd` TEXT, `suspectedNcdDiseases` TEXT, `suspectedTb` TEXT, `confirmed_Ncd` TEXT, `confirmedHrp` TEXT, `suspectedHrp` TEXT, `confirmedTb` TEXT, `confirmedNcdDiseases` TEXT, `diagnosisStatus` TEXT, `processed` TEXT, `serverUpdatedStatus` INTEGER NOT NULL, `createdBy` TEXT, `createdDate` INTEGER, `updatedBy` TEXT, `updatedDate` INTEGER, `syncState` INTEGER NOT NULL, `isDraft` INTEGER NOT NULL, `isConsent` INTEGER NOT NULL DEFAULT 0, `isNewAbha` INTEGER NOT NULL, `isSpouseAdded` INTEGER NOT NULL, `isChildrenAdded` INTEGER NOT NULL, `isMarried` INTEGER NOT NULL, `doYouHavechildren` INTEGER NOT NULL, `noOfChildren` INTEGER NOT NULL, `noOfAliveChildren` INTEGER NOT NULL, `isDeactivate` INTEGER NOT NULL, `livingPlace` TEXT, `otherLivingPlace` TEXT, `institutionName` TEXT, `kid_childName` TEXT, `kid_childRegisteredAWC` TEXT, `kid_childRegisteredAWCId` INTEGER, `kid_childRegisteredSchool` TEXT, `kid_childRegisteredSchoolId` INTEGER, `kid_typeOfSchool` TEXT, `kid_typeOfSchoolId` INTEGER, `kid_birthPlace` TEXT, `kid_birthPlaceId` INTEGER, `kid_facilityName` TEXT, `kid_facilityId` INTEGER, `kid_facilityOther` TEXT, `kid_placeName` TEXT, `kid_conductedDelivery` TEXT, `kid_conductedDeliveryId` INTEGER, `kid_conductedDeliveryOther` TEXT, `kid_deliveryType` TEXT, `kid_deliveryTypeId` INTEGER, `kid_complications` TEXT, `kid_complicationsId` INTEGER, `kid_complicationsOther` TEXT, `kid_term` TEXT, `kid_termId` INTEGER, `kid_gestationalAge` TEXT, `kid_gestationalAgeId` INTEGER, `kid_corticosteroidGivenMother` TEXT, `kid_corticosteroidGivenMotherId` INTEGER, `kid_criedImmediately` TEXT, `kid_criedImmediatelyId` INTEGER, `kid_birthDefects` TEXT, `kid_birthDefectsId` INTEGER, `kid_birthDefectsOthers` TEXT, `kid_heightAtBirth` REAL, `kid_weightAtBirth` REAL, `kid_feedingStarted` TEXT, `kid_feedingStartedId` INTEGER, `kid_birthDosage` TEXT, `kid_birthDosageId` INTEGER, `kid_opvBatchNo` TEXT, `kid_opvGivenDueDate` TEXT, `kid_opvDate` TEXT, `kid_bcdBatchNo` TEXT, `kid_bcgGivenDueDate` TEXT, `kid_bcgDate` TEXT, `kid_hptBatchNo` TEXT, `kid_hptGivenDueDate` TEXT, `kid_hptDate` TEXT, `kid_vitaminKBatchNo` TEXT, `kid_vitaminKGivenDueDate` TEXT, `kid_vitaminKDate` TEXT, `kid_deliveryTypeOther` TEXT, `kid_birthCertificateNumber` TEXT, `kid_motherBenId` INTEGER, `kid_childMotherName` TEXT, `kid_motherPosition` INTEGER, `kid_birthBCG` INTEGER, `kid_birthHepB` INTEGER, `kid_birthOPV` INTEGER, `kid_isConsent` INTEGER, `kid_birthCertificateFileFrontView` TEXT, `kid_birthCertificateFileBackView` TEXT, `gen_maritalStatus` TEXT, `gen_maritalStatusId` INTEGER, `gen_spouseName` TEXT, `gen_ageAtMarriage` INTEGER, `gen_marriageDate` INTEGER, `gen_lastMenstrualPeriod` INTEGER, `gen_reproductiveStatus` TEXT, `gen_reproductiveStatusId` INTEGER, `loc_country_id` INTEGER NOT NULL, `loc_country_name` TEXT NOT NULL, `loc_country_nameHindi` TEXT, `loc_country_nameAssamese` TEXT, `loc_country_nameBangla` TEXT, `loc_state_id` INTEGER NOT NULL, `loc_state_name` TEXT NOT NULL, `loc_state_nameHindi` TEXT, `loc_state_nameAssamese` TEXT, `loc_state_nameBangla` TEXT, `loc_district_id` INTEGER NOT NULL, `loc_district_name` TEXT NOT NULL, `loc_district_nameHindi` TEXT, `loc_district_nameAssamese` TEXT, `loc_district_nameBangla` TEXT, `loc_block_id` INTEGER NOT NULL, `loc_block_name` TEXT NOT NULL, `loc_block_nameHindi` TEXT, `loc_block_nameAssamese` TEXT, `loc_block_nameBangla` TEXT, `loc_village_id` INTEGER NOT NULL, `loc_village_name` TEXT NOT NULL, `loc_village_nameHindi` TEXT, `loc_village_nameAssamese` TEXT, `loc_village_nameBangla` TEXT, `abha_healthId` TEXT, `abha_healthIdNumber` TEXT, `abha_isNewAbha` INTEGER, `abha_familyId` TEXT, PRIMARY KEY(`beneficiaryId`), FOREIGN KEY(`householdId`) REFERENCES `HOUSEHOLD`(`householdId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "householdId", + "columnName": "householdId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "beneficiaryId", + "columnName": "beneficiaryId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isDeath", + "columnName": "isDeath", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isDeathValue", + "columnName": "isDeathValue", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "timeOfDeath", + "columnName": "timeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonOfDeath", + "columnName": "reasonOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonOfDeathId", + "columnName": "reasonOfDeathId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfDeathId", + "columnName": "placeOfDeathId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "otherPlaceOfDeath", + "columnName": "otherPlaceOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "benRegId", + "columnName": "benRegId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ashaId", + "columnName": "ashaId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isKid", + "columnName": "isKid", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isAdult", + "columnName": "isAdult", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "userImage", + "columnName": "userImage", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "regDate", + "columnName": "regDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "firstName", + "columnName": "firstName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "lastName", + "columnName": "lastName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "gender", + "columnName": "gender", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "genderId", + "columnName": "genderId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dob", + "columnName": "dob", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "age", + "columnName": "age", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ageUnit", + "columnName": "ageUnit", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ageUnitId", + "columnName": "ageUnitId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "fatherName", + "columnName": "fatherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "motherName", + "columnName": "motherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "familyHeadRelation", + "columnName": "familyHeadRelation", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "familyHeadRelationPosition", + "columnName": "familyHeadRelationPosition", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "familyHeadRelationOther", + "columnName": "familyHeadRelationOther", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mobileNoOfRelation", + "columnName": "mobileNoOfRelation", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mobileNoOfRelationId", + "columnName": "mobileNoOfRelationId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "tempMobileNoOfRelationId", + "columnName": "tempMobileNoOfRelationId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mobileOthers", + "columnName": "mobileOthers", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "contactNumber", + "columnName": "contactNumber", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "literacy", + "columnName": "literacy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "literacyId", + "columnName": "literacyId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "community", + "columnName": "community", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "communityId", + "columnName": "communityId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "religion", + "columnName": "religion", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "religionId", + "columnName": "religionId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "religionOthers", + "columnName": "religionOthers", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "rchId", + "columnName": "rchId", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "latitude", + "columnName": "latitude", + "affinity": "REAL", + "notNull": true + }, + { + "fieldPath": "longitude", + "columnName": "longitude", + "affinity": "REAL", + "notNull": true + }, + { + "fieldPath": "hasAadhar", + "columnName": "hasAadhar", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hasAadharId", + "columnName": "hasAadharId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "aadharNum", + "columnName": "aadharNum", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "aadharNumId", + "columnName": "aadharNumId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "bankAccountId", + "columnName": "bankAccountId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "bankAccount", + "columnName": "bankAccount", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "nameOfBank", + "columnName": "nameOfBank", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "nameOfBranch", + "columnName": "nameOfBranch", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ifscCode", + "columnName": "ifscCode", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "needOpCare", + "columnName": "needOpCare", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "needOpCareId", + "columnName": "needOpCareId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ncdPriority", + "columnName": "ncdPriority", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbacAvailable", + "columnName": "cbacAvailable", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "guidelineId", + "columnName": "guidelineId", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isHrpStatus", + "columnName": "isHrpStatus", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "immunizationStatus", + "columnName": "immunizationStatus", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hrpIdentificationDate", + "columnName": "hrpIdentificationDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hrpLastVisitDate", + "columnName": "hrpLastVisitDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "suspectedNcd", + "columnName": "suspectedNcd", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "suspectedNcdDiseases", + "columnName": "suspectedNcdDiseases", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "suspectedTb", + "columnName": "suspectedTb", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "confirmed_Ncd", + "columnName": "confirmed_Ncd", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "confirmedHrp", + "columnName": "confirmedHrp", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "suspectedHrp", + "columnName": "suspectedHrp", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "confirmedTb", + "columnName": "confirmedTb", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "confirmedNcdDiseases", + "columnName": "confirmedNcdDiseases", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "diagnosisStatus", + "columnName": "diagnosisStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "serverUpdatedStatus", + "columnName": "serverUpdatedStatus", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isDraft", + "columnName": "isDraft", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isConsent", + "columnName": "isConsent", + "affinity": "INTEGER", + "notNull": true, + "defaultValue": "0" + }, + { + "fieldPath": "isNewAbha", + "columnName": "isNewAbha", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isSpouseAdded", + "columnName": "isSpouseAdded", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isChildrenAdded", + "columnName": "isChildrenAdded", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isMarried", + "columnName": "isMarried", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "doYouHavechildren", + "columnName": "doYouHavechildren", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "noOfChildren", + "columnName": "noOfChildren", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "noOfAliveChildren", + "columnName": "noOfAliveChildren", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isDeactivate", + "columnName": "isDeactivate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "livingPlace", + "columnName": "livingPlace", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherLivingPlace", + "columnName": "otherLivingPlace", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "institutionName", + "columnName": "institutionName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.childName", + "columnName": "kid_childName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.childRegisteredAWC", + "columnName": "kid_childRegisteredAWC", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.childRegisteredAWCId", + "columnName": "kid_childRegisteredAWCId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.childRegisteredSchool", + "columnName": "kid_childRegisteredSchool", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.childRegisteredSchoolId", + "columnName": "kid_childRegisteredSchoolId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.typeOfSchool", + "columnName": "kid_typeOfSchool", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.typeOfSchoolId", + "columnName": "kid_typeOfSchoolId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthPlace", + "columnName": "kid_birthPlace", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthPlaceId", + "columnName": "kid_birthPlaceId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.facilityName", + "columnName": "kid_facilityName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.facilityId", + "columnName": "kid_facilityId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.facilityOther", + "columnName": "kid_facilityOther", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.placeName", + "columnName": "kid_placeName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.conductedDelivery", + "columnName": "kid_conductedDelivery", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.conductedDeliveryId", + "columnName": "kid_conductedDeliveryId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.conductedDeliveryOther", + "columnName": "kid_conductedDeliveryOther", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.deliveryType", + "columnName": "kid_deliveryType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.deliveryTypeId", + "columnName": "kid_deliveryTypeId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.complications", + "columnName": "kid_complications", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.complicationsId", + "columnName": "kid_complicationsId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.complicationsOther", + "columnName": "kid_complicationsOther", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.term", + "columnName": "kid_term", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.termId", + "columnName": "kid_termId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.gestationalAge", + "columnName": "kid_gestationalAge", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.gestationalAgeId", + "columnName": "kid_gestationalAgeId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.corticosteroidGivenMother", + "columnName": "kid_corticosteroidGivenMother", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.corticosteroidGivenMotherId", + "columnName": "kid_corticosteroidGivenMotherId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.criedImmediately", + "columnName": "kid_criedImmediately", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.criedImmediatelyId", + "columnName": "kid_criedImmediatelyId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthDefects", + "columnName": "kid_birthDefects", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthDefectsId", + "columnName": "kid_birthDefectsId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthDefectsOthers", + "columnName": "kid_birthDefectsOthers", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.heightAtBirth", + "columnName": "kid_heightAtBirth", + "affinity": "REAL", + "notNull": false + }, + { + "fieldPath": "kidDetails.weightAtBirth", + "columnName": "kid_weightAtBirth", + "affinity": "REAL", + "notNull": false + }, + { + "fieldPath": "kidDetails.feedingStarted", + "columnName": "kid_feedingStarted", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.feedingStartedId", + "columnName": "kid_feedingStartedId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthDosage", + "columnName": "kid_birthDosage", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthDosageId", + "columnName": "kid_birthDosageId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.opvBatchNo", + "columnName": "kid_opvBatchNo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.opvGivenDueDate", + "columnName": "kid_opvGivenDueDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.opvDate", + "columnName": "kid_opvDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.bcdBatchNo", + "columnName": "kid_bcdBatchNo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.bcgGivenDueDate", + "columnName": "kid_bcgGivenDueDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.bcgDate", + "columnName": "kid_bcgDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.hptBatchNo", + "columnName": "kid_hptBatchNo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.hptGivenDueDate", + "columnName": "kid_hptGivenDueDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.hptDate", + "columnName": "kid_hptDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.vitaminKBatchNo", + "columnName": "kid_vitaminKBatchNo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.vitaminKGivenDueDate", + "columnName": "kid_vitaminKGivenDueDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.vitaminKDate", + "columnName": "kid_vitaminKDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.deliveryTypeOther", + "columnName": "kid_deliveryTypeOther", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthCertificateNumber", + "columnName": "kid_birthCertificateNumber", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.motherBenId", + "columnName": "kid_motherBenId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.childMotherName", + "columnName": "kid_childMotherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.motherPosition", + "columnName": "kid_motherPosition", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthBCG", + "columnName": "kid_birthBCG", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthHepB", + "columnName": "kid_birthHepB", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthOPV", + "columnName": "kid_birthOPV", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.isConsent", + "columnName": "kid_isConsent", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthCertificateFileFrontView", + "columnName": "kid_birthCertificateFileFrontView", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kidDetails.birthCertificateFileBackView", + "columnName": "kid_birthCertificateFileBackView", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "genDetails.maritalStatus", + "columnName": "gen_maritalStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "genDetails.maritalStatusId", + "columnName": "gen_maritalStatusId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "genDetails.spouseName", + "columnName": "gen_spouseName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "genDetails.ageAtMarriage", + "columnName": "gen_ageAtMarriage", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "genDetails.marriageDate", + "columnName": "gen_marriageDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "genDetails.lastMenstrualPeriod", + "columnName": "gen_lastMenstrualPeriod", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "genDetails.reproductiveStatus", + "columnName": "gen_reproductiveStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "genDetails.reproductiveStatusId", + "columnName": "gen_reproductiveStatusId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "locationRecord.country.id", + "columnName": "loc_country_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.country.name", + "columnName": "loc_country_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.country.nameHindi", + "columnName": "loc_country_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.country.nameAssamese", + "columnName": "loc_country_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.country.nameBangla", + "columnName": "loc_country_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.state.id", + "columnName": "loc_state_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.state.name", + "columnName": "loc_state_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.state.nameHindi", + "columnName": "loc_state_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.state.nameAssamese", + "columnName": "loc_state_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.state.nameBangla", + "columnName": "loc_state_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.district.id", + "columnName": "loc_district_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.district.name", + "columnName": "loc_district_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.district.nameHindi", + "columnName": "loc_district_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.district.nameAssamese", + "columnName": "loc_district_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.district.nameBangla", + "columnName": "loc_district_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.block.id", + "columnName": "loc_block_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.block.name", + "columnName": "loc_block_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.block.nameHindi", + "columnName": "loc_block_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.block.nameAssamese", + "columnName": "loc_block_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.block.nameBangla", + "columnName": "loc_block_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.village.id", + "columnName": "loc_village_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "locationRecord.village.name", + "columnName": "loc_village_name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "locationRecord.village.nameHindi", + "columnName": "loc_village_nameHindi", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.village.nameAssamese", + "columnName": "loc_village_nameAssamese", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "locationRecord.village.nameBangla", + "columnName": "loc_village_nameBangla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "healthIdDetails.healthId", + "columnName": "abha_healthId", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "healthIdDetails.healthIdNumber", + "columnName": "abha_healthIdNumber", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "healthIdDetails.isNewAbha", + "columnName": "abha_isNewAbha", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "healthIdDetails.familyId", + "columnName": "abha_familyId", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "beneficiaryId" + ] + }, + "indices": [ + { + "name": "ind_ben", + "unique": false, + "columnNames": [ + "beneficiaryId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_ben` ON `${TABLE_NAME}` (`beneficiaryId`)" + }, + { + "name": "index_BENEFICIARY_householdId", + "unique": false, + "columnNames": [ + "householdId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_BENEFICIARY_householdId` ON `${TABLE_NAME}` (`householdId`)" + }, + { + "name": "index_BENEFICIARY_ashaId", + "unique": false, + "columnNames": [ + "ashaId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_BENEFICIARY_ashaId` ON `${TABLE_NAME}` (`ashaId`)" + } + ], + "foreignKeys": [ + { + "table": "HOUSEHOLD", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "householdId" + ], + "referencedColumns": [ + "householdId" + ] + } + ] + }, + { + "tableName": "BEN_ID_LIST", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `userId` INTEGER NOT NULL, `benId` INTEGER NOT NULL, `benRegId` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "userId", + "columnName": "userId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benRegId", + "columnName": "benRegId", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_BEN_ID_LIST_userId", + "unique": false, + "columnNames": [ + "userId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_BEN_ID_LIST_userId` ON `${TABLE_NAME}` (`userId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "CBAC", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `ashaId` INTEGER NOT NULL, `fillDate` INTEGER NOT NULL, `cbac_age_posi` INTEGER NOT NULL, `cbac_smoke_posi` INTEGER NOT NULL, `cbac_alcohol_posi` INTEGER NOT NULL, `cbac_waist_posi` INTEGER NOT NULL, `cbac_pa_posi` INTEGER NOT NULL, `cbac_familyhistory_posi` INTEGER NOT NULL, `total_score` INTEGER NOT NULL, `cbac_sufferingtb_pos` INTEGER NOT NULL, `cbac_antitbdrugs_pos` INTEGER NOT NULL, `cbac_tbhistory_pos` INTEGER NOT NULL, `cbac_sortnesofbirth_pos` INTEGER NOT NULL, `cbac_coughing_pos` INTEGER NOT NULL, `cbac_bloodsputum_pos` INTEGER NOT NULL, `cbac_fivermore_pos` INTEGER NOT NULL, `cbac_loseofweight_pos` INTEGER NOT NULL, `cbac_nightsweats_pos` INTEGER NOT NULL, `cbac_historyoffits_pos` INTEGER NOT NULL, `cbac_difficultyinmouth_pos` INTEGER NOT NULL, `cbac_uicers_pos` INTEGER NOT NULL, `cbac_toneofvoice_pos` INTEGER NOT NULL, `cbac_lumpinbreast_pos` INTEGER NOT NULL, `cbac_blooddischage_pos` INTEGER NOT NULL, `cbac_changeinbreast_pos` INTEGER NOT NULL, `cbac_bleedingbtwnperiods_pos` INTEGER NOT NULL, `cbac_bleedingaftermenopause_pos` INTEGER NOT NULL, `cbac_bleedingafterintercourse_pos` INTEGER NOT NULL, `cbac_foulveginaldischarge_pos` INTEGER NOT NULL, `cbac_cloudy_posi` INTEGER NOT NULL, `cbac_diffreading_posi` INTEGER NOT NULL, `cbac_pain_ineyes_posi` INTEGER NOT NULL, `cbac_diff_inhearing_posi` INTEGER NOT NULL, `cbac_redness_ineyes_posi` INTEGER NOT NULL, `cbac_growth_in_mouth_posi` INTEGER NOT NULL, `cbac_white_or_red_patch_posi` INTEGER NOT NULL, `cbac_Pain_while_chewing_posi` INTEGER NOT NULL, `cbac_hyper_pigmented_patch_posi` INTEGER NOT NULL, `cbac_any_thickend_skin_posi` INTEGER NOT NULL, `cbac_nodules_on_skin_posi` INTEGER NOT NULL, `cbac_numbness_on_palm_posi` INTEGER NOT NULL, `cbac_clawing_of_fingers_posi` INTEGER NOT NULL, `cbac_tingling_palm_posi` INTEGER NOT NULL, `cbac_tingling_or_numbness_posi` INTEGER NOT NULL, `cbac_inability_close_eyelid_posi` INTEGER NOT NULL, `cbac_diff_holding_obj_posi` INTEGER NOT NULL, `cbac_weekness_in_feet_posi` INTEGER NOT NULL, `cbac_fuel_used_posi` INTEGER NOT NULL, `cbac_occupational_exposure_posi` INTEGER NOT NULL, `cbac_occupational_exposure_other` TEXT, `cbac_feeling_unsteady_posi` INTEGER NOT NULL, `cbac_suffer_physical_disability_posi` INTEGER NOT NULL, `cbac_needing_help_posi` INTEGER NOT NULL, `cbac_forgetting_names_posi` INTEGER NOT NULL, `cbac_little_interest_posi` INTEGER NOT NULL, `cbac_feeling_down_posi` INTEGER NOT NULL, `cbac_little_interest_score` INTEGER NOT NULL, `cbac_feeling_down_score` INTEGER NOT NULL, `cbac_referpatient_mo` TEXT, `cbac_tracing_all_fm` TEXT, `cbac_sputemcollection` TEXT, `serverUpdatedStatus` INTEGER NOT NULL, `createdBy` TEXT, `createdDate` INTEGER NOT NULL, `ProviderServiceMapID` INTEGER NOT NULL, `VanID` INTEGER NOT NULL, `Processed` TEXT, `Countyid` INTEGER NOT NULL, `stateid` INTEGER NOT NULL, `districtid` INTEGER NOT NULL, `districtname` TEXT, `villageid` INTEGER NOT NULL, `cbac_reg_id` INTEGER NOT NULL, `hrp_suspected` INTEGER, `suspected_hrp` TEXT, `confirmed_hrp` TEXT, `ncd_suspected` TEXT, `suspected_ncd` TEXT, `ncd_confirmed` INTEGER, `confirmed_ncd` TEXT, `suspected_tb` TEXT, `confirmed_tb` TEXT, `suspected_ncd_diseases` TEXT, `confirmed_ncd_diseases` TEXT, `diagnosis_status` TEXT, `isReffered` INTEGER, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ashaId", + "columnName": "ashaId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "fillDate", + "columnName": "fillDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_age_posi", + "columnName": "cbac_age_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_smoke_posi", + "columnName": "cbac_smoke_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_alcohol_posi", + "columnName": "cbac_alcohol_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_waist_posi", + "columnName": "cbac_waist_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_pa_posi", + "columnName": "cbac_pa_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_familyhistory_posi", + "columnName": "cbac_familyhistory_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "total_score", + "columnName": "total_score", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_sufferingtb_pos", + "columnName": "cbac_sufferingtb_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_antitbdrugs_pos", + "columnName": "cbac_antitbdrugs_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_tbhistory_pos", + "columnName": "cbac_tbhistory_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_sortnesofbirth_pos", + "columnName": "cbac_sortnesofbirth_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_coughing_pos", + "columnName": "cbac_coughing_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_bloodsputum_pos", + "columnName": "cbac_bloodsputum_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_fivermore_pos", + "columnName": "cbac_fivermore_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_loseofweight_pos", + "columnName": "cbac_loseofweight_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_nightsweats_pos", + "columnName": "cbac_nightsweats_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_historyoffits_pos", + "columnName": "cbac_historyoffits_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_difficultyinmouth_pos", + "columnName": "cbac_difficultyinmouth_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_uicers_pos", + "columnName": "cbac_uicers_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_toneofvoice_pos", + "columnName": "cbac_toneofvoice_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_lumpinbreast_pos", + "columnName": "cbac_lumpinbreast_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_blooddischage_pos", + "columnName": "cbac_blooddischage_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_changeinbreast_pos", + "columnName": "cbac_changeinbreast_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_bleedingbtwnperiods_pos", + "columnName": "cbac_bleedingbtwnperiods_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_bleedingaftermenopause_pos", + "columnName": "cbac_bleedingaftermenopause_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_bleedingafterintercourse_pos", + "columnName": "cbac_bleedingafterintercourse_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_foulveginaldischarge_pos", + "columnName": "cbac_foulveginaldischarge_pos", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_cloudy_posi", + "columnName": "cbac_cloudy_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_diffreading_posi", + "columnName": "cbac_diffreading_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_pain_ineyes_posi", + "columnName": "cbac_pain_ineyes_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_diff_inhearing_posi", + "columnName": "cbac_diff_inhearing_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_redness_ineyes_posi", + "columnName": "cbac_redness_ineyes_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_growth_in_mouth_posi", + "columnName": "cbac_growth_in_mouth_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_white_or_red_patch_posi", + "columnName": "cbac_white_or_red_patch_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_Pain_while_chewing_posi", + "columnName": "cbac_Pain_while_chewing_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_hyper_pigmented_patch_posi", + "columnName": "cbac_hyper_pigmented_patch_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_any_thickend_skin_posi", + "columnName": "cbac_any_thickend_skin_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_nodules_on_skin_posi", + "columnName": "cbac_nodules_on_skin_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_numbness_on_palm_posi", + "columnName": "cbac_numbness_on_palm_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_clawing_of_fingers_posi", + "columnName": "cbac_clawing_of_fingers_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_tingling_palm_posi", + "columnName": "cbac_tingling_palm_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_tingling_or_numbness_posi", + "columnName": "cbac_tingling_or_numbness_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_inability_close_eyelid_posi", + "columnName": "cbac_inability_close_eyelid_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_diff_holding_obj_posi", + "columnName": "cbac_diff_holding_obj_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_weekness_in_feet_posi", + "columnName": "cbac_weekness_in_feet_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_fuel_used_posi", + "columnName": "cbac_fuel_used_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_occupational_exposure_posi", + "columnName": "cbac_occupational_exposure_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_occupational_exposure_other", + "columnName": "cbac_occupational_exposure_other", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "cbac_feeling_unsteady_posi", + "columnName": "cbac_feeling_unsteady_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_suffer_physical_disability_posi", + "columnName": "cbac_suffer_physical_disability_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_needing_help_posi", + "columnName": "cbac_needing_help_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_forgetting_names_posi", + "columnName": "cbac_forgetting_names_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_little_interest_posi", + "columnName": "cbac_little_interest_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_feeling_down_posi", + "columnName": "cbac_feeling_down_posi", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_little_interest_score", + "columnName": "cbac_little_interest_score", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_feeling_down_score", + "columnName": "cbac_feeling_down_score", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_referpatient_mo", + "columnName": "cbac_referpatient_mo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "cbac_tracing_all_fm", + "columnName": "cbac_tracing_all_fm", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "cbac_sputemcollection", + "columnName": "cbac_sputemcollection", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "serverUpdatedStatus", + "columnName": "serverUpdatedStatus", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ProviderServiceMapID", + "columnName": "ProviderServiceMapID", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "VanID", + "columnName": "VanID", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "Processed", + "columnName": "Processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "Countyid", + "columnName": "Countyid", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "stateid", + "columnName": "stateid", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "districtid", + "columnName": "districtid", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "districtname", + "columnName": "districtname", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "villageid", + "columnName": "villageid", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cbac_reg_id", + "columnName": "cbac_reg_id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hrp_suspected", + "columnName": "hrp_suspected", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "suspected_hrp", + "columnName": "suspected_hrp", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "confirmed_hrp", + "columnName": "confirmed_hrp", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ncd_suspected", + "columnName": "ncd_suspected", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "suspected_ncd", + "columnName": "suspected_ncd", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ncd_confirmed", + "columnName": "ncd_confirmed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "confirmed_ncd", + "columnName": "confirmed_ncd", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "suspected_tb", + "columnName": "suspected_tb", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "confirmed_tb", + "columnName": "confirmed_tb", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "suspected_ncd_diseases", + "columnName": "suspected_ncd_diseases", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "confirmed_ncd_diseases", + "columnName": "confirmed_ncd_diseases", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "diagnosis_status", + "columnName": "diagnosis_status", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isReffered", + "columnName": "isReffered", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_cbac", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_cbac` ON `${TABLE_NAME}` (`benId`)" + }, + { + "name": "index_CBAC_ashaId", + "unique": false, + "columnNames": [ + "ashaId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_CBAC_ashaId` ON `${TABLE_NAME}` (`ashaId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "CDR", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDate` INTEGER, `cdr1File` TEXT, `cdr2File` TEXT, `cdrDeathCertFile` TEXT, `motherName` TEXT, `fatherName` TEXT, `address` TEXT, `houseNumber` TEXT, `mohalla` TEXT, `landmarks` TEXT, `pincode` INTEGER, `landline` INTEGER, `mobileNumber` INTEGER NOT NULL, `dateOfDeath` INTEGER NOT NULL, `timeOfDeath` INTEGER, `placeOfDeath` TEXT, `firstInformant` TEXT, `ashaSign` TEXT, `dateOfNotification` INTEGER, `createdBy` TEXT, `createdDate` INTEGER, `updatedBy` TEXT, `updatedDate` INTEGER, `processed` TEXT NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "cdr1File", + "columnName": "cdr1File", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "cdr2File", + "columnName": "cdr2File", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "cdrDeathCertFile", + "columnName": "cdrDeathCertFile", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "motherName", + "columnName": "motherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fatherName", + "columnName": "fatherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "address", + "columnName": "address", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "houseNumber", + "columnName": "houseNumber", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mohalla", + "columnName": "mohalla", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "landmarks", + "columnName": "landmarks", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "pincode", + "columnName": "pincode", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "landline", + "columnName": "landline", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "mobileNumber", + "columnName": "mobileNumber", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "timeOfDeath", + "columnName": "timeOfDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "firstInformant", + "columnName": "firstInformant", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ashaSign", + "columnName": "ashaSign", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateOfNotification", + "columnName": "dateOfNotification", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_cdr", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_cdr` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "MDSR", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `mdsr1File` TEXT, `mdsr2File` TEXT, `mdsrDeathCertFile` TEXT, `dateOfDeath` INTEGER, `address` TEXT, `husbandName` TEXT, `causeOfDeath` TEXT, `reasonOfDeath` TEXT, `investigationDate` INTEGER, `actionTaken` INTEGER, `blockMOSign` TEXT, `dateIc` INTEGER, `processed` TEXT NOT NULL, `syncState` INTEGER NOT NULL, `createdBy` TEXT, `createdDate` INTEGER, `updatedBy` TEXT, `updatedDate` INTEGER, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mdsr1File", + "columnName": "mdsr1File", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mdsr2File", + "columnName": "mdsr2File", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mdsrDeathCertFile", + "columnName": "mdsrDeathCertFile", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "address", + "columnName": "address", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "husbandName", + "columnName": "husbandName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "causeOfDeath", + "columnName": "causeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonOfDeath", + "columnName": "reasonOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "investigationDate", + "columnName": "investigationDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "actionTaken", + "columnName": "actionTaken", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "blockMOSign", + "columnName": "blockMOSign", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateIc", + "columnName": "dateIc", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_mdsr", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_mdsr` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "PNC_VISIT", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `pncPeriod` INTEGER NOT NULL, `isActive` INTEGER NOT NULL, `pncDate` INTEGER NOT NULL, `ifaTabsGiven` INTEGER, `anyContraceptionMethod` INTEGER, `contraceptionMethod` TEXT, `sterilisationDate` INTEGER, `otherPpcMethod` TEXT, `anyDangerSign` TEXT, `motherDangerSign` TEXT, `otherDangerSign` TEXT, `referralFacility` TEXT, `motherDeath` INTEGER NOT NULL, `deathDate` INTEGER, `causeOfDeath` TEXT, `otherDeathCause` TEXT, `placeOfDeath` TEXT, `otherPlaceOfDeath` TEXT, `remarks` TEXT, `deliveryDischargeSummary1` TEXT, `deliveryDischargeSummary2` TEXT, `deliveryDischargeSummary3` TEXT, `deliveryDischargeSummary4` TEXT, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "pncPeriod", + "columnName": "pncPeriod", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isActive", + "columnName": "isActive", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "pncDate", + "columnName": "pncDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ifaTabsGiven", + "columnName": "ifaTabsGiven", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "anyContraceptionMethod", + "columnName": "anyContraceptionMethod", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "contraceptionMethod", + "columnName": "contraceptionMethod", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "sterilisationDate", + "columnName": "sterilisationDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "otherPpcMethod", + "columnName": "otherPpcMethod", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "anyDangerSign", + "columnName": "anyDangerSign", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "motherDangerSign", + "columnName": "motherDangerSign", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherDangerSign", + "columnName": "otherDangerSign", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referralFacility", + "columnName": "referralFacility", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "motherDeath", + "columnName": "motherDeath", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "deathDate", + "columnName": "deathDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "causeOfDeath", + "columnName": "causeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherDeathCause", + "columnName": "otherDeathCause", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherPlaceOfDeath", + "columnName": "otherPlaceOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "remarks", + "columnName": "remarks", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryDischargeSummary1", + "columnName": "deliveryDischargeSummary1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryDischargeSummary2", + "columnName": "deliveryDischargeSummary2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryDischargeSummary3", + "columnName": "deliveryDischargeSummary3", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryDischargeSummary4", + "columnName": "deliveryDischargeSummary4", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_pnc", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_pnc` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "PMSMA", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDate` INTEGER, `visitNumber` INTEGER NOT NULL, `anyOtherHighRiskCondition` TEXT, `isActive` INTEGER NOT NULL, `mctsNumberOrRchNumber` TEXT, `haveMCPCard` INTEGER NOT NULL, `givenMCPCard` INTEGER, `husbandName` TEXT, `address` TEXT, `mobileNumber` INTEGER, `numANC` INTEGER NOT NULL, `weight` INTEGER NOT NULL, `systolicBloodPressure` TEXT, `bloodPressure` TEXT, `abdominalCheckUp` TEXT, `fetalHRPM` INTEGER NOT NULL, `twinPregnancy` INTEGER NOT NULL, `urineAlbumin` TEXT, `haemoglobinAndBloodGroup` TEXT, `hiv` TEXT, `vdrl` TEXT, `hbsc` TEXT, `malaria` TEXT, `hivTestDuringANC` INTEGER, `swollenCondtion` INTEGER, `bloodSugarTest` INTEGER, `ultraSound` INTEGER, `ironFolicAcid` INTEGER, `calciumSupplementation` INTEGER, `tetanusToxoid` TEXT, `lastMenstrualPeriod` INTEGER NOT NULL, `expectedDateOfDelivery` INTEGER NOT NULL, `highriskSymbols` INTEGER, `highRiskReason` TEXT, `highRiskPregnant` INTEGER, `highRiskPregnancyReferred` INTEGER, `birthPrepAndNutritionAndFamilyPlanning` INTEGER, `medicalOfficerSign` TEXT, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitNumber", + "columnName": "visitNumber", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "anyOtherHighRiskCondition", + "columnName": "anyOtherHighRiskCondition", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isActive", + "columnName": "isActive", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mctsNumberOrRchNumber", + "columnName": "mctsNumberOrRchNumber", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "haveMCPCard", + "columnName": "haveMCPCard", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "givenMCPCard", + "columnName": "givenMCPCard", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "husbandName", + "columnName": "husbandName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "address", + "columnName": "address", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mobileNumber", + "columnName": "mobileNumber", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "numANC", + "columnName": "numANC", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "weight", + "columnName": "weight", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "systolicBloodPressure", + "columnName": "systolicBloodPressure", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "bloodPressure", + "columnName": "bloodPressure", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "abdominalCheckUp", + "columnName": "abdominalCheckUp", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fetalHRPM", + "columnName": "fetalHRPM", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "twinPregnancy", + "columnName": "twinPregnancy", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "urineAlbumin", + "columnName": "urineAlbumin", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "haemoglobinAndBloodGroup", + "columnName": "haemoglobinAndBloodGroup", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hiv", + "columnName": "hiv", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "vdrl", + "columnName": "vdrl", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hbsc", + "columnName": "hbsc", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "malaria", + "columnName": "malaria", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hivTestDuringANC", + "columnName": "hivTestDuringANC", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "swollenCondtion", + "columnName": "swollenCondtion", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bloodSugarTest", + "columnName": "bloodSugarTest", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "ultraSound", + "columnName": "ultraSound", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "ironFolicAcid", + "columnName": "ironFolicAcid", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "calciumSupplementation", + "columnName": "calciumSupplementation", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "tetanusToxoid", + "columnName": "tetanusToxoid", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "lastMenstrualPeriod", + "columnName": "lastMenstrualPeriod", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "expectedDateOfDelivery", + "columnName": "expectedDateOfDelivery", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "highriskSymbols", + "columnName": "highriskSymbols", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "highRiskReason", + "columnName": "highRiskReason", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "highRiskPregnant", + "columnName": "highRiskPregnant", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "highRiskPregnancyReferred", + "columnName": "highRiskPregnancyReferred", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "birthPrepAndNutritionAndFamilyPlanning", + "columnName": "birthPrepAndNutritionAndFamilyPlanning", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "medicalOfficerSign", + "columnName": "medicalOfficerSign", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_pmsma", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_pmsma` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "PMJAY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `registrationDate` INTEGER, `registeredHospital` TEXT, `contactNumber` INTEGER, `communicationContactNumber` INTEGER, `patientAddress` TEXT, `communicationAddress` TEXT, `hospitalAddress` TEXT, `familyId` INTEGER, `isAadhaarBeneficiary` INTEGER, `memberType` TEXT, `patientType` TEXT, `scheme` TEXT, `createdBy` TEXT, `createdDate` INTEGER, `processed` TEXT, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "registrationDate", + "columnName": "registrationDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "registeredHospital", + "columnName": "registeredHospital", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "contactNumber", + "columnName": "contactNumber", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "communicationContactNumber", + "columnName": "communicationContactNumber", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "patientAddress", + "columnName": "patientAddress", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "communicationAddress", + "columnName": "communicationAddress", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hospitalAddress", + "columnName": "hospitalAddress", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "familyId", + "columnName": "familyId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isAadhaarBeneficiary", + "columnName": "isAadhaarBeneficiary", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "memberType", + "columnName": "memberType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "patientType", + "columnName": "patientType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "scheme", + "columnName": "scheme", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_pmjay", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_pmjay` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "FPOT", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `monthlySerialNumber` TEXT, `annualSerialNumber` TEXT, `spouseName` TEXT, `category` TEXT, `benAddress` TEXT, `contactNumber` TEXT, `educationalQualification` TEXT, `numChildren` TEXT, `youngestChildAge` TEXT, `sterilization` INTEGER, `mrCheckListFilled` INTEGER, `dateOfOperation` INTEGER NOT NULL, `femaleSterilization` TEXT, `secondFollowUpExpectedDate` INTEGER NOT NULL, `followUpActualDate` INTEGER NOT NULL, `followUpDetails` TEXT, `secondPostFollowUpCounselling` TEXT, `thirdFollowUpExpectedDate` INTEGER NOT NULL, `menstruationStarted` INTEGER, `spermatozoaFoundInSemen` TEXT, `thirdPostFollowUpCounselling` TEXT, `sterilizationOrVasectomyIssueDate` INTEGER NOT NULL, `notIssuedReason` TEXT, `sterilizationOrVasectomyDocSubmitted` TEXT, `remarks` TEXT, `createdBy` TEXT, `createdDate` INTEGER, `processed` TEXT, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "monthlySerialNumber", + "columnName": "monthlySerialNumber", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "annualSerialNumber", + "columnName": "annualSerialNumber", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "spouseName", + "columnName": "spouseName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "category", + "columnName": "category", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "benAddress", + "columnName": "benAddress", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "contactNumber", + "columnName": "contactNumber", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "educationalQualification", + "columnName": "educationalQualification", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "numChildren", + "columnName": "numChildren", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "youngestChildAge", + "columnName": "youngestChildAge", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "sterilization", + "columnName": "sterilization", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "mrCheckListFilled", + "columnName": "mrCheckListFilled", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dateOfOperation", + "columnName": "dateOfOperation", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "femaleSterilization", + "columnName": "femaleSterilization", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "secondFollowUpExpectedDate", + "columnName": "secondFollowUpExpectedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "followUpActualDate", + "columnName": "followUpActualDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "followUpDetails", + "columnName": "followUpDetails", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "secondPostFollowUpCounselling", + "columnName": "secondPostFollowUpCounselling", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "thirdFollowUpExpectedDate", + "columnName": "thirdFollowUpExpectedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "menstruationStarted", + "columnName": "menstruationStarted", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "spermatozoaFoundInSemen", + "columnName": "spermatozoaFoundInSemen", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "thirdPostFollowUpCounselling", + "columnName": "thirdPostFollowUpCounselling", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "sterilizationOrVasectomyIssueDate", + "columnName": "sterilizationOrVasectomyIssueDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "notIssuedReason", + "columnName": "notIssuedReason", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "sterilizationOrVasectomyDocSubmitted", + "columnName": "sterilizationOrVasectomyDocSubmitted", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "remarks", + "columnName": "remarks", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_fpot", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_fpot` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "HBNC", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `homeVisitDate` INTEGER NOT NULL, `processed` TEXT, `syncState` INTEGER NOT NULL, `card_ashaName` TEXT, `card_villageName` TEXT, `card_subCenterName` TEXT, `card_blockName` TEXT, `card_motherName` TEXT, `card_fatherName` TEXT, `card_dateOfDelivery` INTEGER, `card_placeOfDelivery` INTEGER, `card_babyGender` INTEGER, `card_typeOfDelivery` INTEGER, `card_stillBirth` INTEGER, `card_startedBreastFeeding` INTEGER, `card_dischargeDateMother` INTEGER, `card_dischargeDateBaby` INTEGER, `card_weightInGrams` INTEGER, `card_registrationOfBirth` INTEGER, `part_I_dateOfVisit` INTEGER, `part_I_babyAlive` INTEGER, `part_I_dateOfBabyDeath` INTEGER, `part_I_timeOfBabyDeath` TEXT, `part_I_placeOfBabyDeath` INTEGER, `part_I_otherPlaceOfBabyDeath` TEXT, `part_I_isBabyPreterm` INTEGER, `part_I_gestationalAge` INTEGER, `part_I_dateOfFirstExamination` INTEGER, `part_I_timeOfFirstExamination` TEXT, `part_I_motherAlive` INTEGER, `part_I_dateOfMotherDeath` INTEGER, `part_I_timeOfMotherDeath` TEXT, `part_I_placeOfMotherDeath` INTEGER, `part_I_otherPlaceOfMotherDeath` TEXT, `part_I_motherAnyProblem` TEXT, `part_I_babyFirstFed` INTEGER, `part_I_otherBabyFirstFed` TEXT, `part_I_timeBabyFirstFed` TEXT, `part_I_howBabyTookFirstFeed` INTEGER, `part_I_motherHasBreastFeedProblem` INTEGER, `part_I_motherBreastFeedProblem` TEXT, `part_II_dateOfVisit` INTEGER, `part_II_babyTemperature` TEXT, `part_II_babyEyeCondition` INTEGER, `part_II_babyUmbilicalBleed` INTEGER, `part_II_actionBabyUmbilicalBleed` INTEGER, `part_II_babyWeight` TEXT, `part_II_babyWeightMatchesColor` INTEGER, `part_II_babyWeightColorOnScale` INTEGER, `part_II_allLimbsLimp` INTEGER, `part_II_feedLessStop` INTEGER, `part_II_cryWeakStop` INTEGER, `part_II_dryBaby` INTEGER, `part_II_wrapClothCloseToMother` INTEGER, `part_II_exclusiveBreastFeeding` INTEGER, `part_II_cordCleanDry` INTEGER, `part_II_unusualInBaby` INTEGER, `part_II_otherUnusualInBaby` TEXT, `visit_dateOfVisit` INTEGER, `visit_babyAlive` INTEGER, `visit_numTimesFullMeal24hr` INTEGER, `visit_numPadChanged24hr` INTEGER, `visit_babyKeptWarmWinter` INTEGER, `visit_babyFedProperly` INTEGER, `visit_babyCryContinuously` INTEGER, `visit_motherTemperature` TEXT, `visit_foulDischargeFever` INTEGER, `visit_motherSpeakAbnormallyFits` INTEGER, `visit_motherLessNoMilk` INTEGER, `visit_motherBreastProblem` INTEGER, `visit_babyEyesSwollen` INTEGER, `visit_babyWeight` TEXT, `visit_babyTemperature` TEXT, `visit_babyYellow` INTEGER, `visit_babyImmunizationStatus` TEXT, `visit_babyReferred` INTEGER, `visit_dateOfBabyReferral` INTEGER, `visit_placeOfBabyReferral` INTEGER, `visit_otherPlaceOfBabyReferral` TEXT, `visit_motherReferred` INTEGER, `visit_dateOfMotherReferral` INTEGER, `visit_placeOfMotherReferral` INTEGER, `visit_otherPlaceOfMotherReferral` TEXT, `visit_allLimbsLimp` INTEGER, `visit_feedingLessStopped` INTEGER, `visit_cryWeakStopped` INTEGER, `visit_bloatedStomach` INTEGER, `visit_coldOnTouch` INTEGER, `visit_chestDrawing` INTEGER, `visit_breathFast` INTEGER, `visit_pusNavel` INTEGER, `visit_sup` INTEGER, `visit_supName` TEXT, `visit_supComment` TEXT, `visit_supSignDate` INTEGER, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "homeVisitDate", + "columnName": "homeVisitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitCard.ashaName", + "columnName": "card_ashaName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitCard.villageName", + "columnName": "card_villageName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitCard.subCenterName", + "columnName": "card_subCenterName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitCard.blockName", + "columnName": "card_blockName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitCard.motherName", + "columnName": "card_motherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitCard.fatherName", + "columnName": "card_fatherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitCard.dateOfDelivery", + "columnName": "card_dateOfDelivery", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.placeOfDelivery", + "columnName": "card_placeOfDelivery", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.babyGender", + "columnName": "card_babyGender", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.typeOfDelivery", + "columnName": "card_typeOfDelivery", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.stillBirth", + "columnName": "card_stillBirth", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.startedBreastFeeding", + "columnName": "card_startedBreastFeeding", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.dischargeDateMother", + "columnName": "card_dischargeDateMother", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.dischargeDateBaby", + "columnName": "card_dischargeDateBaby", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.weightInGrams", + "columnName": "card_weightInGrams", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCard.registrationOfBirth", + "columnName": "card_registrationOfBirth", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.dateOfVisit", + "columnName": "part_I_dateOfVisit", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.babyAlive", + "columnName": "part_I_babyAlive", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.dateOfBabyDeath", + "columnName": "part_I_dateOfBabyDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.timeOfBabyDeath", + "columnName": "part_I_timeOfBabyDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part1.placeOfBabyDeath", + "columnName": "part_I_placeOfBabyDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.otherPlaceOfBabyDeath", + "columnName": "part_I_otherPlaceOfBabyDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part1.isBabyPreterm", + "columnName": "part_I_isBabyPreterm", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.gestationalAge", + "columnName": "part_I_gestationalAge", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.dateOfFirstExamination", + "columnName": "part_I_dateOfFirstExamination", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.timeOfFirstExamination", + "columnName": "part_I_timeOfFirstExamination", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part1.motherAlive", + "columnName": "part_I_motherAlive", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.dateOfMotherDeath", + "columnName": "part_I_dateOfMotherDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.timeOfMotherDeath", + "columnName": "part_I_timeOfMotherDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part1.placeOfMotherDeath", + "columnName": "part_I_placeOfMotherDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.otherPlaceOfMotherDeath", + "columnName": "part_I_otherPlaceOfMotherDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part1.motherAnyProblem", + "columnName": "part_I_motherAnyProblem", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part1.babyFirstFed", + "columnName": "part_I_babyFirstFed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.otherBabyFirstFed", + "columnName": "part_I_otherBabyFirstFed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part1.timeBabyFirstFed", + "columnName": "part_I_timeBabyFirstFed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part1.howBabyTookFirstFeed", + "columnName": "part_I_howBabyTookFirstFeed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.motherHasBreastFeedProblem", + "columnName": "part_I_motherHasBreastFeedProblem", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part1.motherBreastFeedProblem", + "columnName": "part_I_motherBreastFeedProblem", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part2.dateOfVisit", + "columnName": "part_II_dateOfVisit", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.babyTemperature", + "columnName": "part_II_babyTemperature", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part2.babyEyeCondition", + "columnName": "part_II_babyEyeCondition", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.babyUmbilicalBleed", + "columnName": "part_II_babyUmbilicalBleed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.actionBabyUmbilicalBleed", + "columnName": "part_II_actionBabyUmbilicalBleed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.babyWeight", + "columnName": "part_II_babyWeight", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "part2.babyWeightMatchesColor", + "columnName": "part_II_babyWeightMatchesColor", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.babyWeightColorOnScale", + "columnName": "part_II_babyWeightColorOnScale", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.allLimbsLimp", + "columnName": "part_II_allLimbsLimp", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.feedLessStop", + "columnName": "part_II_feedLessStop", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.cryWeakStop", + "columnName": "part_II_cryWeakStop", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.dryBaby", + "columnName": "part_II_dryBaby", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.wrapClothCloseToMother", + "columnName": "part_II_wrapClothCloseToMother", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.exclusiveBreastFeeding", + "columnName": "part_II_exclusiveBreastFeeding", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.cordCleanDry", + "columnName": "part_II_cordCleanDry", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.unusualInBaby", + "columnName": "part_II_unusualInBaby", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "part2.otherUnusualInBaby", + "columnName": "part_II_otherUnusualInBaby", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.dateOfVisit", + "columnName": "visit_dateOfVisit", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyAlive", + "columnName": "visit_babyAlive", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.numTimesFullMeal24hr", + "columnName": "visit_numTimesFullMeal24hr", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.numPadChanged24hr", + "columnName": "visit_numPadChanged24hr", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyKeptWarmWinter", + "columnName": "visit_babyKeptWarmWinter", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyFedProperly", + "columnName": "visit_babyFedProperly", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyCryContinuously", + "columnName": "visit_babyCryContinuously", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.motherTemperature", + "columnName": "visit_motherTemperature", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.foulDischargeFever", + "columnName": "visit_foulDischargeFever", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.motherSpeakAbnormallyFits", + "columnName": "visit_motherSpeakAbnormallyFits", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.motherLessNoMilk", + "columnName": "visit_motherLessNoMilk", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.motherBreastProblem", + "columnName": "visit_motherBreastProblem", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyEyesSwollen", + "columnName": "visit_babyEyesSwollen", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyWeight", + "columnName": "visit_babyWeight", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyTemperature", + "columnName": "visit_babyTemperature", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyYellow", + "columnName": "visit_babyYellow", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyImmunizationStatus", + "columnName": "visit_babyImmunizationStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.babyReferred", + "columnName": "visit_babyReferred", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.dateOfBabyReferral", + "columnName": "visit_dateOfBabyReferral", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.placeOfBabyReferral", + "columnName": "visit_placeOfBabyReferral", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.otherPlaceOfBabyReferral", + "columnName": "visit_otherPlaceOfBabyReferral", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.motherReferred", + "columnName": "visit_motherReferred", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.dateOfMotherReferral", + "columnName": "visit_dateOfMotherReferral", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.placeOfMotherReferral", + "columnName": "visit_placeOfMotherReferral", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.otherPlaceOfMotherReferral", + "columnName": "visit_otherPlaceOfMotherReferral", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.allLimbsLimp", + "columnName": "visit_allLimbsLimp", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.feedingLessStopped", + "columnName": "visit_feedingLessStopped", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.cryWeakStopped", + "columnName": "visit_cryWeakStopped", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.bloatedStomach", + "columnName": "visit_bloatedStomach", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.coldOnTouch", + "columnName": "visit_coldOnTouch", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.chestDrawing", + "columnName": "visit_chestDrawing", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.breathFast", + "columnName": "visit_breathFast", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.pusNavel", + "columnName": "visit_pusNavel", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.sup", + "columnName": "visit_sup", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.supName", + "columnName": "visit_supName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.supComment", + "columnName": "visit_supComment", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitForm.supSignDate", + "columnName": "visit_supSignDate", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_hbnc", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_hbnc` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "HBYC", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `month` TEXT, `subcenterName` TEXT, `year` TEXT, `primaryHealthCenterName` TEXT, `villagePopulation` TEXT, `infantPopulation` TEXT, `visitdate` INTEGER, `hbycAgeCategory` TEXT, `orsPacketDelivered` INTEGER NOT NULL, `ironFolicAcidGiven` INTEGER NOT NULL, `isVaccinatedByAge` INTEGER NOT NULL, `wasIll` INTEGER NOT NULL, `referred` INTEGER NOT NULL, `supplementsGiven` INTEGER NOT NULL, `byHeightLength` INTEGER NOT NULL, `childrenWeighingLessReferred` INTEGER NOT NULL, `weightAccordingToAge` INTEGER NOT NULL, `delayInDevelopment` INTEGER NOT NULL, `referredToHealthInstitite` INTEGER NOT NULL, `vitaminASupplementsGiven` INTEGER NOT NULL, `deathAge` TEXT, `deathCause` TEXT, `qmOrAnmInformed` INTEGER NOT NULL, `deathPlace` INTEGER, `superVisorOn` INTEGER NOT NULL, `orsShortage` INTEGER NOT NULL, `ifaDecreased` INTEGER NOT NULL, `processed` TEXT NOT NULL, `syncState` INTEGER NOT NULL, `createdBy` TEXT, `createdDate` INTEGER, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "month", + "columnName": "month", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "subcenterName", + "columnName": "subcenterName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "year", + "columnName": "year", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "primaryHealthCenterName", + "columnName": "primaryHealthCenterName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "villagePopulation", + "columnName": "villagePopulation", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "infantPopulation", + "columnName": "infantPopulation", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitdate", + "columnName": "visitdate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hbycAgeCategory", + "columnName": "hbycAgeCategory", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "orsPacketDelivered", + "columnName": "orsPacketDelivered", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ironFolicAcidGiven", + "columnName": "ironFolicAcidGiven", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isVaccinatedByAge", + "columnName": "isVaccinatedByAge", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "wasIll", + "columnName": "wasIll", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referred", + "columnName": "referred", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "supplementsGiven", + "columnName": "supplementsGiven", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "byHeightLength", + "columnName": "byHeightLength", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "childrenWeighingLessReferred", + "columnName": "childrenWeighingLessReferred", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "weightAccordingToAge", + "columnName": "weightAccordingToAge", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "delayInDevelopment", + "columnName": "delayInDevelopment", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referredToHealthInstitite", + "columnName": "referredToHealthInstitite", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "vitaminASupplementsGiven", + "columnName": "vitaminASupplementsGiven", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "deathAge", + "columnName": "deathAge", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deathCause", + "columnName": "deathCause", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "qmOrAnmInformed", + "columnName": "qmOrAnmInformed", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "deathPlace", + "columnName": "deathPlace", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "superVisorOn", + "columnName": "superVisorOn", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "orsShortage", + "columnName": "orsShortage", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ifaDecreased", + "columnName": "ifaDecreased", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "hbycInd", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `hbycInd` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "ELIGIBLE_COUPLE_REG", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `dateOfReg` INTEGER NOT NULL, `bankAccount` INTEGER, `bankName` TEXT, `branchName` TEXT, `ifsc` TEXT, `lmpDate` INTEGER NOT NULL DEFAULT 0, `noOfChildren` INTEGER NOT NULL, `noOfLiveChildren` INTEGER NOT NULL, `noOfMaleChildren` INTEGER NOT NULL, `noOfFemaleChildren` INTEGER NOT NULL, `isRegistered` INTEGER NOT NULL, `dob1` INTEGER, `age1` INTEGER, `gender1` TEXT, `marriageFirstChildGap` INTEGER, `dob2` INTEGER, `age2` INTEGER, `gender2` TEXT, `firstAndSecondChildGap` INTEGER, `dob3` INTEGER, `age3` INTEGER, `gender3` TEXT, `secondAndThirdChildGap` INTEGER, `dob4` INTEGER, `age4` INTEGER, `gender4` TEXT, `thirdAndFourthChildGap` INTEGER, `dob5` INTEGER, `age5` INTEGER, `gender5` TEXT, `fourthAndFifthChildGap` INTEGER, `dob6` INTEGER, `age6` INTEGER, `gender6` TEXT, `fifthANdSixthChildGap` INTEGER, `dob7` INTEGER, `age7` INTEGER, `gender7` TEXT, `sixthAndSeventhChildGap` INTEGER, `dob8` INTEGER, `age8` INTEGER, `gender8` TEXT, `seventhAndEighthChildGap` INTEGER, `dob9` INTEGER, `age9` INTEGER, `gender9` TEXT, `eighthAndNinthChildGap` INTEGER, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `lmp_date` INTEGER NOT NULL DEFAULT 0, `isKitHandedOver` INTEGER, `kitHandedOverDate` INTEGER, `kitPhoto1` TEXT, `kitPhoto2` TEXT, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfReg", + "columnName": "dateOfReg", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "bankAccount", + "columnName": "bankAccount", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bankName", + "columnName": "bankName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "branchName", + "columnName": "branchName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ifsc", + "columnName": "ifsc", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "lmpDate", + "columnName": "lmpDate", + "affinity": "INTEGER", + "notNull": true, + "defaultValue": "0" + }, + { + "fieldPath": "noOfChildren", + "columnName": "noOfChildren", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "noOfLiveChildren", + "columnName": "noOfLiveChildren", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "noOfMaleChildren", + "columnName": "noOfMaleChildren", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "noOfFemaleChildren", + "columnName": "noOfFemaleChildren", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isRegistered", + "columnName": "isRegistered", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dob1", + "columnName": "dob1", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age1", + "columnName": "age1", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender1", + "columnName": "gender1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "marriageFirstChildGap", + "columnName": "marriageFirstChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dob2", + "columnName": "dob2", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age2", + "columnName": "age2", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender2", + "columnName": "gender2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "firstAndSecondChildGap", + "columnName": "firstAndSecondChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dob3", + "columnName": "dob3", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age3", + "columnName": "age3", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender3", + "columnName": "gender3", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "secondAndThirdChildGap", + "columnName": "secondAndThirdChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dob4", + "columnName": "dob4", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age4", + "columnName": "age4", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender4", + "columnName": "gender4", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "thirdAndFourthChildGap", + "columnName": "thirdAndFourthChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dob5", + "columnName": "dob5", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age5", + "columnName": "age5", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender5", + "columnName": "gender5", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fourthAndFifthChildGap", + "columnName": "fourthAndFifthChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dob6", + "columnName": "dob6", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age6", + "columnName": "age6", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender6", + "columnName": "gender6", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fifthANdSixthChildGap", + "columnName": "fifthANdSixthChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dob7", + "columnName": "dob7", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age7", + "columnName": "age7", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender7", + "columnName": "gender7", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "sixthAndSeventhChildGap", + "columnName": "sixthAndSeventhChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dob8", + "columnName": "dob8", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age8", + "columnName": "age8", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender8", + "columnName": "gender8", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "seventhAndEighthChildGap", + "columnName": "seventhAndEighthChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dob9", + "columnName": "dob9", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age9", + "columnName": "age9", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gender9", + "columnName": "gender9", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "eighthAndNinthChildGap", + "columnName": "eighthAndNinthChildGap", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "lmp_date", + "columnName": "lmp_date", + "affinity": "INTEGER", + "notNull": true, + "defaultValue": "0" + }, + { + "fieldPath": "isKitHandedOver", + "columnName": "isKitHandedOver", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kitHandedOverDate", + "columnName": "kitHandedOverDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "kitPhoto1", + "columnName": "kitPhoto1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "kitPhoto2", + "columnName": "kitPhoto2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ecrInd", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ecrInd` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "VACCINE", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`vaccineId` INTEGER NOT NULL, `vaccineName` TEXT NOT NULL, `minAllowedAgeInMillis` INTEGER NOT NULL, `maxAllowedAgeInMillis` INTEGER NOT NULL, `category` TEXT NOT NULL, `immunizationService` TEXT NOT NULL, `overdueDurationSinceMinInMillis` INTEGER NOT NULL, `dependantVaccineId` INTEGER, `dependantCoolDuration` INTEGER, PRIMARY KEY(`vaccineId`))", + "fields": [ + { + "fieldPath": "vaccineId", + "columnName": "vaccineId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "vaccineName", + "columnName": "vaccineName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "minAllowedAgeInMillis", + "columnName": "minAllowedAgeInMillis", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "maxAllowedAgeInMillis", + "columnName": "maxAllowedAgeInMillis", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "category", + "columnName": "category", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "immunizationService", + "columnName": "immunizationService", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "overdueDurationSinceMinInMillis", + "columnName": "overdueDurationSinceMinInMillis", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dependantVaccineId", + "columnName": "dependantVaccineId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dependantCoolDuration", + "columnName": "dependantCoolDuration", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "vaccineId" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "IMMUNIZATION", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `beneficiaryId` INTEGER NOT NULL, `vaccineId` INTEGER NOT NULL, `date` INTEGER, `placeId` INTEGER NOT NULL, `place` TEXT NOT NULL, `byWhoId` INTEGER NOT NULL, `byWho` TEXT NOT NULL, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, `mcpCardSummary1` TEXT, `mcpCardSummary2` TEXT, PRIMARY KEY(`beneficiaryId`, `vaccineId`), FOREIGN KEY(`beneficiaryId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE , FOREIGN KEY(`vaccineId`) REFERENCES `VACCINE`(`vaccineId`) ON UPDATE NO ACTION ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "beneficiaryId", + "columnName": "beneficiaryId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "vaccineId", + "columnName": "vaccineId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "date", + "columnName": "date", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "placeId", + "columnName": "placeId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "place", + "columnName": "place", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "byWhoId", + "columnName": "byWhoId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "byWho", + "columnName": "byWho", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mcpCardSummary1", + "columnName": "mcpCardSummary1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mcpCardSummary2", + "columnName": "mcpCardSummary2", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "beneficiaryId", + "vaccineId" + ] + }, + "indices": [ + { + "name": "ind_imm", + "unique": false, + "columnNames": [ + "beneficiaryId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_imm` ON `${TABLE_NAME}` (`beneficiaryId`)" + }, + { + "name": "ind_vaccine", + "unique": false, + "columnNames": [ + "vaccineId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_vaccine` ON `${TABLE_NAME}` (`vaccineId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "beneficiaryId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + }, + { + "table": "VACCINE", + "onDelete": "CASCADE", + "onUpdate": "NO ACTION", + "columns": [ + "vaccineId" + ], + "referencedColumns": [ + "vaccineId" + ] + } + ] + }, + { + "tableName": "PREGNANCY_REGISTER", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `dateOfRegistration` INTEGER NOT NULL, `mcpCardNumber` INTEGER, `rchId` INTEGER, `lmpDate` INTEGER NOT NULL, `bloodGroup` TEXT, `bloodGroupId` INTEGER NOT NULL, `weight` INTEGER, `height` INTEGER, `vdrlRprTestResult` TEXT, `vdrlRprTestResultId` INTEGER NOT NULL, `dateOfVdrlRprTest` INTEGER, `hivTestResult` TEXT, `hivTestResultId` INTEGER NOT NULL, `dateOfHivTest` INTEGER, `hbsAgTestResult` TEXT, `hbsAgTestResultId` INTEGER NOT NULL, `dateOfHbsAgTest` INTEGER, `pastIllness` TEXT, `otherPastIllness` TEXT, `is1st` INTEGER NOT NULL, `numPrevPregnancy` INTEGER, `complicationPrevPregnancy` TEXT, `complicationPrevPregnancyId` INTEGER, `otherComplication` TEXT, `isHrp` INTEGER NOT NULL, `hrpIdBy` TEXT, `hrpIdById` INTEGER NOT NULL, `active` INTEGER NOT NULL, `tt1` INTEGER, `tt2` INTEGER, `ttBooster` INTEGER, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfRegistration", + "columnName": "dateOfRegistration", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mcpCardNumber", + "columnName": "mcpCardNumber", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "rchId", + "columnName": "rchId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "lmpDate", + "columnName": "lmpDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "bloodGroup", + "columnName": "bloodGroup", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "bloodGroupId", + "columnName": "bloodGroupId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "weight", + "columnName": "weight", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "height", + "columnName": "height", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "vdrlRprTestResult", + "columnName": "vdrlRprTestResult", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "vdrlRprTestResultId", + "columnName": "vdrlRprTestResultId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfVdrlRprTest", + "columnName": "dateOfVdrlRprTest", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hivTestResult", + "columnName": "hivTestResult", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hivTestResultId", + "columnName": "hivTestResultId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfHivTest", + "columnName": "dateOfHivTest", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hbsAgTestResult", + "columnName": "hbsAgTestResult", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hbsAgTestResultId", + "columnName": "hbsAgTestResultId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfHbsAgTest", + "columnName": "dateOfHbsAgTest", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "pastIllness", + "columnName": "pastIllness", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherPastIllness", + "columnName": "otherPastIllness", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "is1st", + "columnName": "is1st", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "numPrevPregnancy", + "columnName": "numPrevPregnancy", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "complicationPrevPregnancy", + "columnName": "complicationPrevPregnancy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "complicationPrevPregnancyId", + "columnName": "complicationPrevPregnancyId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "otherComplication", + "columnName": "otherComplication", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isHrp", + "columnName": "isHrp", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hrpIdBy", + "columnName": "hrpIdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hrpIdById", + "columnName": "hrpIdById", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "active", + "columnName": "active", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "tt1", + "columnName": "tt1", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "tt2", + "columnName": "tt2", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "ttBooster", + "columnName": "ttBooster", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_pwc", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_pwc` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "ELIGIBLE_COUPLE_TRACKING", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `lmpDate` INTEGER NOT NULL DEFAULT 0, `visitDate` INTEGER NOT NULL, `dateOfSterilisation` INTEGER NOT NULL, `dateOfAntraInjection` TEXT, `dueDateOfAntraInjection` TEXT, `mpaFile` TEXT, `dischargeSummary1` TEXT, `dischargeSummary2` TEXT, `antraDose` TEXT, `isPregnancyTestDone` TEXT, `pregnancyTestResult` TEXT, `isPregnant` TEXT, `usingFamilyPlanning` INTEGER, `methodOfContraception` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `processed` TEXT, `isActive` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, `lmp_date` INTEGER NOT NULL DEFAULT 0, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "lmpDate", + "columnName": "lmpDate", + "affinity": "INTEGER", + "notNull": true, + "defaultValue": "0" + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfSterilisation", + "columnName": "dateOfSterilisation", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfAntraInjection", + "columnName": "dateOfAntraInjection", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dueDateOfAntraInjection", + "columnName": "dueDateOfAntraInjection", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mpaFile", + "columnName": "mpaFile", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dischargeSummary1", + "columnName": "dischargeSummary1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dischargeSummary2", + "columnName": "dischargeSummary2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "antraDose", + "columnName": "antraDose", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isPregnancyTestDone", + "columnName": "isPregnancyTestDone", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "pregnancyTestResult", + "columnName": "pregnancyTestResult", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isPregnant", + "columnName": "isPregnant", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "usingFamilyPlanning", + "columnName": "usingFamilyPlanning", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "methodOfContraception", + "columnName": "methodOfContraception", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isActive", + "columnName": "isActive", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "lmp_date", + "columnName": "lmp_date", + "affinity": "INTEGER", + "notNull": true, + "defaultValue": "0" + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_ect", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_ect` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "TB_SCREENING", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDate` INTEGER NOT NULL, `coughMoreThan2Weeks` INTEGER, `bloodInSputum` INTEGER, `feverMoreThan2Weeks` INTEGER, `lossOfWeight` INTEGER, `nightSweats` INTEGER, `historyOfTb` INTEGER, `takingAntiTBDrugs` INTEGER, `familySufferingFromTB` INTEGER, `riseOfFever` INTEGER, `lossOfAppetite` INTEGER, `age` INTEGER, `diabetic` INTEGER, `tobaccoUser` INTEGER, `bmi` INTEGER, `contactWithTBPatient` INTEGER, `historyOfTBInLastFiveYrs` INTEGER, `fatigue` INTEGER, `shortBreath` INTEGER, `chestPain` INTEGER, `failureToGainWeight` INTEGER, `decreasedActivityOrPlayfulness` INTEGER, `sympotomatic` TEXT, `asymptomatic` TEXT, `recommandateTest` TEXT, `keyPopulationRiskFactorIds` TEXT, `keyPopulationRiskFactors` TEXT, `hivStatusId` INTEGER, `hivStatus` TEXT, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "coughMoreThan2Weeks", + "columnName": "coughMoreThan2Weeks", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bloodInSputum", + "columnName": "bloodInSputum", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "feverMoreThan2Weeks", + "columnName": "feverMoreThan2Weeks", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "lossOfWeight", + "columnName": "lossOfWeight", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "nightSweats", + "columnName": "nightSweats", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "historyOfTb", + "columnName": "historyOfTb", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "takingAntiTBDrugs", + "columnName": "takingAntiTBDrugs", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "familySufferingFromTB", + "columnName": "familySufferingFromTB", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "riseOfFever", + "columnName": "riseOfFever", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "lossOfAppetite", + "columnName": "lossOfAppetite", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "age", + "columnName": "age", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "diabetic", + "columnName": "diabetic", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "tobaccoUser", + "columnName": "tobaccoUser", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bmi", + "columnName": "bmi", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "contactWithTBPatient", + "columnName": "contactWithTBPatient", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "historyOfTBInLastFiveYrs", + "columnName": "historyOfTBInLastFiveYrs", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "fatigue", + "columnName": "fatigue", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "shortBreath", + "columnName": "shortBreath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "chestPain", + "columnName": "chestPain", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "failureToGainWeight", + "columnName": "failureToGainWeight", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "decreasedActivityOrPlayfulness", + "columnName": "decreasedActivityOrPlayfulness", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "sympotomatic", + "columnName": "sympotomatic", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "asymptomatic", + "columnName": "asymptomatic", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "recommandateTest", + "columnName": "recommandateTest", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "keyPopulationRiskFactorIds", + "columnName": "keyPopulationRiskFactorIds", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "keyPopulationRiskFactors", + "columnName": "keyPopulationRiskFactors", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hivStatusId", + "columnName": "hivStatusId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hivStatus", + "columnName": "hivStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_tbsn", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_tbsn` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "TB_SUSPECTED", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDate` INTEGER NOT NULL, `visitLabel` TEXT, `typeOfTBCase` TEXT, `reasonForSuspicion` TEXT, `hasSymptoms` INTEGER NOT NULL, `isSputumCollected` INTEGER, `sputumSubmittedAt` TEXT, `nikshayId` TEXT, `sputumTestResult` TEXT, `isChestXRayDone` INTEGER, `chestXRayResult` TEXT, `referralFacility` TEXT, `isTBConfirmed` INTEGER, `isDRTBConfirmed` INTEGER, `isRecommendedForTpt` INTEGER, `isConfirmed` INTEGER NOT NULL, `referred` INTEGER, `followUps` TEXT, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitLabel", + "columnName": "visitLabel", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "typeOfTBCase", + "columnName": "typeOfTBCase", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonForSuspicion", + "columnName": "reasonForSuspicion", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hasSymptoms", + "columnName": "hasSymptoms", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isSputumCollected", + "columnName": "isSputumCollected", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "sputumSubmittedAt", + "columnName": "sputumSubmittedAt", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "nikshayId", + "columnName": "nikshayId", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "sputumTestResult", + "columnName": "sputumTestResult", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isChestXRayDone", + "columnName": "isChestXRayDone", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "chestXRayResult", + "columnName": "chestXRayResult", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referralFacility", + "columnName": "referralFacility", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isTBConfirmed", + "columnName": "isTBConfirmed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isDRTBConfirmed", + "columnName": "isDRTBConfirmed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isRecommendedForTpt", + "columnName": "isRecommendedForTpt", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isConfirmed", + "columnName": "isConfirmed", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referred", + "columnName": "referred", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "followUps", + "columnName": "followUps", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_tbs", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_tbs` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "PREGNANCY_ANC", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitNumber` INTEGER NOT NULL, `isActive` INTEGER NOT NULL, `ancDate` INTEGER NOT NULL, `lmpDate` INTEGER, `visitDate` INTEGER, `weekOfPregnancy` INTEGER, `serialNo` TEXT, `methodOfTermination` TEXT, `methodOfTerminationId` INTEGER, `terminationDoneBy` TEXT, `terminationDoneById` INTEGER, `placeOfAnc` TEXT, `placeOfAncId` INTEGER, `isPaiucdId` INTEGER, `isYesOrNo` INTEGER, `isPaiucd` TEXT, `dateSterilisation` INTEGER, `remarks` TEXT, `abortionImg1` TEXT, `abortionImg2` TEXT, `placeOfDeath` TEXT, `placeOfDeathId` INTEGER, `otherPlaceOfDeath` TEXT, `isAborted` INTEGER NOT NULL, `abortionType` TEXT, `abortionTypeId` INTEGER NOT NULL, `abortionFacility` TEXT, `abortionFacilityId` INTEGER NOT NULL, `abortionDate` INTEGER, `weight` INTEGER, `bpSystolic` INTEGER, `bpDiastolic` INTEGER, `pulseRate` TEXT, `hb` REAL, `fundalHeight` INTEGER, `urineAlbumin` TEXT, `urineAlbuminId` INTEGER NOT NULL, `randomBloodSugarTest` TEXT, `randomBloodSugarTestId` INTEGER NOT NULL, `numFolicAcidTabGiven` INTEGER NOT NULL, `numIfaAcidTabGiven` INTEGER NOT NULL, `anyHighRisk` INTEGER, `highRisk` TEXT, `highRiskId` INTEGER NOT NULL, `otherHighRisk` TEXT, `referralFacility` TEXT, `referralFacilityId` INTEGER NOT NULL, `hrpConfirmed` INTEGER, `hrpConfirmedBy` TEXT, `hrpConfirmedById` INTEGER NOT NULL, `maternalDeath` INTEGER, `maternalDeathProbableCause` TEXT, `maternalDeathProbableCauseId` INTEGER NOT NULL, `otherMaternalDeathProbableCause` TEXT, `deathDate` INTEGER, `pregnantWomanDelivered` INTEGER, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, `frontFilePath` TEXT, `backFilePath` TEXT, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitNumber", + "columnName": "visitNumber", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isActive", + "columnName": "isActive", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ancDate", + "columnName": "ancDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "lmpDate", + "columnName": "lmpDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "weekOfPregnancy", + "columnName": "weekOfPregnancy", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "serialNo", + "columnName": "serialNo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "methodOfTermination", + "columnName": "methodOfTermination", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "methodOfTerminationId", + "columnName": "methodOfTerminationId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "terminationDoneBy", + "columnName": "terminationDoneBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "terminationDoneById", + "columnName": "terminationDoneById", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "placeOfAnc", + "columnName": "placeOfAnc", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfAncId", + "columnName": "placeOfAncId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isPaiucdId", + "columnName": "isPaiucdId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isYesOrNo", + "columnName": "isYesOrNo", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isPaiucd", + "columnName": "isPaiucd", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateSterilisation", + "columnName": "dateSterilisation", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "remarks", + "columnName": "remarks", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "abortionImg1", + "columnName": "abortionImg1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "abortionImg2", + "columnName": "abortionImg2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfDeathId", + "columnName": "placeOfDeathId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "otherPlaceOfDeath", + "columnName": "otherPlaceOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isAborted", + "columnName": "isAborted", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "abortionType", + "columnName": "abortionType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "abortionTypeId", + "columnName": "abortionTypeId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "abortionFacility", + "columnName": "abortionFacility", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "abortionFacilityId", + "columnName": "abortionFacilityId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "abortionDate", + "columnName": "abortionDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "weight", + "columnName": "weight", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bpSystolic", + "columnName": "bpSystolic", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bpDiastolic", + "columnName": "bpDiastolic", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "pulseRate", + "columnName": "pulseRate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hb", + "columnName": "hb", + "affinity": "REAL", + "notNull": false + }, + { + "fieldPath": "fundalHeight", + "columnName": "fundalHeight", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "urineAlbumin", + "columnName": "urineAlbumin", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "urineAlbuminId", + "columnName": "urineAlbuminId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "randomBloodSugarTest", + "columnName": "randomBloodSugarTest", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "randomBloodSugarTestId", + "columnName": "randomBloodSugarTestId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "numFolicAcidTabGiven", + "columnName": "numFolicAcidTabGiven", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "numIfaAcidTabGiven", + "columnName": "numIfaAcidTabGiven", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "anyHighRisk", + "columnName": "anyHighRisk", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "highRisk", + "columnName": "highRisk", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "highRiskId", + "columnName": "highRiskId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "otherHighRisk", + "columnName": "otherHighRisk", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referralFacility", + "columnName": "referralFacility", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referralFacilityId", + "columnName": "referralFacilityId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hrpConfirmed", + "columnName": "hrpConfirmed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hrpConfirmedBy", + "columnName": "hrpConfirmedBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hrpConfirmedById", + "columnName": "hrpConfirmedById", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "maternalDeath", + "columnName": "maternalDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "maternalDeathProbableCause", + "columnName": "maternalDeathProbableCause", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "maternalDeathProbableCauseId", + "columnName": "maternalDeathProbableCauseId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "otherMaternalDeathProbableCause", + "columnName": "otherMaternalDeathProbableCause", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deathDate", + "columnName": "deathDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "pregnantWomanDelivered", + "columnName": "pregnantWomanDelivered", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "frontFilePath", + "columnName": "frontFilePath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "backFilePath", + "columnName": "backFilePath", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_mha", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_mha` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "DELIVERY_OUTCOME", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `isActive` INTEGER NOT NULL, `dateOfDelivery` INTEGER, `timeOfDelivery` TEXT, `placeOfDelivery` TEXT, `typeOfDelivery` TEXT, `hadComplications` INTEGER, `complication` TEXT, `causeOfDeath` TEXT, `otherCauseOfDeath` TEXT, `otherComplication` TEXT, `deliveryOutcome` INTEGER, `liveBirth` INTEGER, `stillBirth` INTEGER, `dateOfDischarge` INTEGER, `timeOfDischarge` TEXT, `isJSYBenificiary` INTEGER, `isDeath` INTEGER, `isDeathValue` TEXT, `dateOfDeath` TEXT, `placeOfDeath` TEXT, `placeOfDeathId` INTEGER, `otherPlaceOfDeath` TEXT, `mcp1File` TEXT, `mcp2File` TEXT, `jsyFile` TEXT, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isActive", + "columnName": "isActive", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfDelivery", + "columnName": "dateOfDelivery", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "timeOfDelivery", + "columnName": "timeOfDelivery", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfDelivery", + "columnName": "placeOfDelivery", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "typeOfDelivery", + "columnName": "typeOfDelivery", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hadComplications", + "columnName": "hadComplications", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "complication", + "columnName": "complication", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "causeOfDeath", + "columnName": "causeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherCauseOfDeath", + "columnName": "otherCauseOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherComplication", + "columnName": "otherComplication", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryOutcome", + "columnName": "deliveryOutcome", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "liveBirth", + "columnName": "liveBirth", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "stillBirth", + "columnName": "stillBirth", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "dateOfDischarge", + "columnName": "dateOfDischarge", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "timeOfDischarge", + "columnName": "timeOfDischarge", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isJSYBenificiary", + "columnName": "isJSYBenificiary", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isDeath", + "columnName": "isDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isDeathValue", + "columnName": "isDeathValue", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfDeathId", + "columnName": "placeOfDeathId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "otherPlaceOfDeath", + "columnName": "otherPlaceOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mcp1File", + "columnName": "mcp1File", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mcp2File", + "columnName": "mcp2File", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "jsyFile", + "columnName": "jsyFile", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "delOutInd", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `delOutInd` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "INFANT_REG", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `childBenId` INTEGER NOT NULL, `motherBenId` INTEGER NOT NULL, `isActive` INTEGER NOT NULL, `babyName` TEXT, `babyIndex` INTEGER NOT NULL, `infantTerm` TEXT, `corticosteroidGiven` TEXT, `gender` TEXT, `babyCriedAtBirth` INTEGER, `resuscitation` INTEGER, `referred` TEXT, `hadBirthDefect` TEXT, `birthDefect` TEXT, `isSNCU` TEXT, `deliveryDischargeSummary1` TEXT, `deliveryDischargeSummary2` TEXT, `deliveryDischargeSummary3` TEXT, `deliveryDischargeSummary4` TEXT, `otherDefect` TEXT, `weight` REAL, `breastFeedingStarted` INTEGER, `opv0Dose` INTEGER, `bcgDose` INTEGER, `hepBDose` INTEGER, `vitkDose` INTEGER, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`motherBenId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "childBenId", + "columnName": "childBenId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "motherBenId", + "columnName": "motherBenId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isActive", + "columnName": "isActive", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "babyName", + "columnName": "babyName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "babyIndex", + "columnName": "babyIndex", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "infantTerm", + "columnName": "infantTerm", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "corticosteroidGiven", + "columnName": "corticosteroidGiven", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "gender", + "columnName": "gender", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "babyCriedAtBirth", + "columnName": "babyCriedAtBirth", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "resuscitation", + "columnName": "resuscitation", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "referred", + "columnName": "referred", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hadBirthDefect", + "columnName": "hadBirthDefect", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "birthDefect", + "columnName": "birthDefect", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isSNCU", + "columnName": "isSNCU", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryDischargeSummary1", + "columnName": "deliveryDischargeSummary1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryDischargeSummary2", + "columnName": "deliveryDischargeSummary2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryDischargeSummary3", + "columnName": "deliveryDischargeSummary3", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deliveryDischargeSummary4", + "columnName": "deliveryDischargeSummary4", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherDefect", + "columnName": "otherDefect", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "weight", + "columnName": "weight", + "affinity": "REAL", + "notNull": false + }, + { + "fieldPath": "breastFeedingStarted", + "columnName": "breastFeedingStarted", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "opv0Dose", + "columnName": "opv0Dose", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bcgDose", + "columnName": "bcgDose", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hepBDose", + "columnName": "hepBDose", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "vitkDose", + "columnName": "vitkDose", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "infRegInd", + "unique": false, + "columnNames": [ + "motherBenId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `infRegInd` ON `${TABLE_NAME}` (`motherBenId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "motherBenId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "CHILD_REG", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `motherBenId` INTEGER NOT NULL, `babyName` TEXT, `infantTerm` TEXT, `corticosteroidGiven` TEXT, `gender` TEXT, `babyCriedAtBirth` INTEGER, `resuscitation` INTEGER, `referred` TEXT, `hadBirthDefect` TEXT, `birthDefect` TEXT, `otherDefect` TEXT, `weight` REAL, `breastFeedingStarted` INTEGER, `opv0Dose` INTEGER, `bcgDose` INTEGER, `hepBDose` INTEGER, `vitkDose` INTEGER, `syncState` INTEGER NOT NULL, FOREIGN KEY(`motherBenId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "motherBenId", + "columnName": "motherBenId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "babyName", + "columnName": "babyName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "infantTerm", + "columnName": "infantTerm", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "corticosteroidGiven", + "columnName": "corticosteroidGiven", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "gender", + "columnName": "gender", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "babyCriedAtBirth", + "columnName": "babyCriedAtBirth", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "resuscitation", + "columnName": "resuscitation", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "referred", + "columnName": "referred", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hadBirthDefect", + "columnName": "hadBirthDefect", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "birthDefect", + "columnName": "birthDefect", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherDefect", + "columnName": "otherDefect", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "weight", + "columnName": "weight", + "affinity": "REAL", + "notNull": false + }, + { + "fieldPath": "breastFeedingStarted", + "columnName": "breastFeedingStarted", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "opv0Dose", + "columnName": "opv0Dose", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bcgDose", + "columnName": "bcgDose", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hepBDose", + "columnName": "hepBDose", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "vitkDose", + "columnName": "vitkDose", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "childRegInd", + "unique": false, + "columnNames": [ + "motherBenId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `childRegInd` ON `${TABLE_NAME}` (`motherBenId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "motherBenId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "HRP_PREGNANT_ASSESS", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `noOfDeliveries` TEXT, `timeLessThan18m` TEXT, `heightShort` TEXT, `age` TEXT, `rhNegative` TEXT, `homeDelivery` TEXT, `badObstetric` TEXT, `multiplePregnancy` TEXT, `lmpDate` INTEGER NOT NULL, `edd` INTEGER NOT NULL, `isHighRisk` INTEGER NOT NULL, `visitDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "noOfDeliveries", + "columnName": "noOfDeliveries", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "timeLessThan18m", + "columnName": "timeLessThan18m", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "heightShort", + "columnName": "heightShort", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "age", + "columnName": "age", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "rhNegative", + "columnName": "rhNegative", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeDelivery", + "columnName": "homeDelivery", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "badObstetric", + "columnName": "badObstetric", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "multiplePregnancy", + "columnName": "multiplePregnancy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "lmpDate", + "columnName": "lmpDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "edd", + "columnName": "edd", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isHighRisk", + "columnName": "isHighRisk", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_hpa", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_hpa` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "HRP_NON_PREGNANT_ASSESS", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `noOfDeliveries` TEXT, `timeLessThan18m` TEXT, `heightShort` TEXT, `age` TEXT, `misCarriage` TEXT, `homeDelivery` TEXT, `medicalIssues` TEXT, `pastCSection` TEXT, `isHighRisk` INTEGER NOT NULL, `visitDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "noOfDeliveries", + "columnName": "noOfDeliveries", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "timeLessThan18m", + "columnName": "timeLessThan18m", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "heightShort", + "columnName": "heightShort", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "age", + "columnName": "age", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "misCarriage", + "columnName": "misCarriage", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeDelivery", + "columnName": "homeDelivery", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "medicalIssues", + "columnName": "medicalIssues", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "pastCSection", + "columnName": "pastCSection", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isHighRisk", + "columnName": "isHighRisk", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_hnpa", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_hnpa` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "HRP_PREGNANT_TRACK", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDate` INTEGER, `rdPmsa` TEXT, `rdDengue` TEXT, `rdFilaria` TEXT, `severeAnemia` TEXT, `hemoglobinTest` TEXT, `ifaGiven` TEXT, `ifaQuantity` INTEGER, `pregInducedHypertension` TEXT, `systolic` INTEGER, `diastolic` INTEGER, `gestDiabetesMellitus` TEXT, `bloodGlucoseTest` TEXT, `fbg` INTEGER, `rbg` INTEGER, `ppbg` INTEGER, `fastingOgtt` INTEGER, `after2hrsOgtt` INTEGER, `hypothyrodism` TEXT, `polyhydromnios` TEXT, `oligohydromnios` TEXT, `antepartumHem` TEXT, `malPresentation` TEXT, `hivsyph` TEXT, `visit` TEXT, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "rdPmsa", + "columnName": "rdPmsa", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "rdDengue", + "columnName": "rdDengue", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "rdFilaria", + "columnName": "rdFilaria", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "severeAnemia", + "columnName": "severeAnemia", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hemoglobinTest", + "columnName": "hemoglobinTest", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ifaGiven", + "columnName": "ifaGiven", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ifaQuantity", + "columnName": "ifaQuantity", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "pregInducedHypertension", + "columnName": "pregInducedHypertension", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "systolic", + "columnName": "systolic", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "diastolic", + "columnName": "diastolic", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "gestDiabetesMellitus", + "columnName": "gestDiabetesMellitus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "bloodGlucoseTest", + "columnName": "bloodGlucoseTest", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fbg", + "columnName": "fbg", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "rbg", + "columnName": "rbg", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "ppbg", + "columnName": "ppbg", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "fastingOgtt", + "columnName": "fastingOgtt", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "after2hrsOgtt", + "columnName": "after2hrsOgtt", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hypothyrodism", + "columnName": "hypothyrodism", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "polyhydromnios", + "columnName": "polyhydromnios", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "oligohydromnios", + "columnName": "oligohydromnios", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "antepartumHem", + "columnName": "antepartumHem", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "malPresentation", + "columnName": "malPresentation", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hivsyph", + "columnName": "hivsyph", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visit", + "columnName": "visit", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_hpt", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_hpt` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "HRP_NON_PREGNANT_TRACK", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDate` INTEGER, `anemia` TEXT, `hypertension` TEXT, `systolic` INTEGER, `diastolic` INTEGER, `diabetes` TEXT, `bloodGlucoseTest` TEXT, `fbg` INTEGER, `rbg` INTEGER, `ppbg` INTEGER, `severeAnemia` TEXT, `hemoglobinTest` TEXT, `ifaGiven` TEXT, `ifaQuantity` INTEGER, `fp` TEXT, `lmp` INTEGER, `missedPeriod` TEXT, `isPregnant` TEXT, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "anemia", + "columnName": "anemia", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hypertension", + "columnName": "hypertension", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "systolic", + "columnName": "systolic", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "diastolic", + "columnName": "diastolic", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "diabetes", + "columnName": "diabetes", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "bloodGlucoseTest", + "columnName": "bloodGlucoseTest", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fbg", + "columnName": "fbg", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "rbg", + "columnName": "rbg", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "ppbg", + "columnName": "ppbg", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "severeAnemia", + "columnName": "severeAnemia", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hemoglobinTest", + "columnName": "hemoglobinTest", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ifaGiven", + "columnName": "ifaGiven", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ifaQuantity", + "columnName": "ifaQuantity", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "fp", + "columnName": "fp", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "lmp", + "columnName": "lmp", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "missedPeriod", + "columnName": "missedPeriod", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isPregnant", + "columnName": "isPregnant", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_hnpt", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_hnpt` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "HRP_MICRO_BIRTH_PLAN", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `nearestSc` TEXT, `bloodGroup` TEXT, `contactNumber1` TEXT, `contactNumber2` TEXT, `scHosp` TEXT, `usg` TEXT, `block` TEXT, `nearestPhc` TEXT, `nearestFru` TEXT, `bloodDonors1` TEXT, `bloodDonors2` TEXT, `birthCompanion` TEXT, `careTaker` TEXT, `communityMember` TEXT, `communityMemberContact` TEXT, `modeOfTransportation` TEXT, `processed` TEXT, `syncState` INTEGER, `bankac` TEXT, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "nearestSc", + "columnName": "nearestSc", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "bloodGroup", + "columnName": "bloodGroup", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "contactNumber1", + "columnName": "contactNumber1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "contactNumber2", + "columnName": "contactNumber2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "scHosp", + "columnName": "scHosp", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "usg", + "columnName": "usg", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "block", + "columnName": "block", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "nearestPhc", + "columnName": "nearestPhc", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "nearestFru", + "columnName": "nearestFru", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "bloodDonors1", + "columnName": "bloodDonors1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "bloodDonors2", + "columnName": "bloodDonors2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "birthCompanion", + "columnName": "birthCompanion", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "careTaker", + "columnName": "careTaker", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "communityMember", + "columnName": "communityMember", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "communityMemberContact", + "columnName": "communityMemberContact", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "modeOfTransportation", + "columnName": "modeOfTransportation", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "bankac", + "columnName": "bankac", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_mbp", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_mbp` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "INCENTIVE_ACTIVITY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `name` TEXT NOT NULL, `description` TEXT NOT NULL, `paymentParam` TEXT NOT NULL, `isPaid` INTEGER NOT NULL, `rate` INTEGER NOT NULL, `state` INTEGER NOT NULL, `district` INTEGER NOT NULL, `group` TEXT NOT NULL, `groupName` TEXT NOT NULL, `fmrCode` TEXT, `fmrCodeOld` TEXT, PRIMARY KEY(`id`))", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "name", + "columnName": "name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "description", + "columnName": "description", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "paymentParam", + "columnName": "paymentParam", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isPaid", + "columnName": "isPaid", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "rate", + "columnName": "rate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "state", + "columnName": "state", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "district", + "columnName": "district", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "group", + "columnName": "group", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "groupName", + "columnName": "groupName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "fmrCode", + "columnName": "fmrCode", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fmrCodeOld", + "columnName": "fmrCodeOld", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "INCENTIVE_RECORD", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `activityId` INTEGER NOT NULL, `ashaId` INTEGER NOT NULL, `benId` INTEGER NOT NULL, `amount` INTEGER NOT NULL, `name` TEXT, `startDate` INTEGER NOT NULL, `endDate` INTEGER NOT NULL, `createdDate` INTEGER NOT NULL, `createdBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `isEligible` INTEGER NOT NULL DEFAULT 0, `verifiedByUserName` TEXT NOT NULL, `reason` TEXT NOT NULL, `otherReason` TEXT NOT NULL, `approvalStatus` INTEGER NOT NULL, `verifiedByUserId` INTEGER NOT NULL, `isClaimed` INTEGER NOT NULL, `approvalDate` TEXT NOT NULL, `calimedDate` TEXT NOT NULL, `supervisorRole` TEXT NOT NULL, PRIMARY KEY(`id`), FOREIGN KEY(`activityId`) REFERENCES `INCENTIVE_ACTIVITY`(`id`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "activityId", + "columnName": "activityId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ashaId", + "columnName": "ashaId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "amount", + "columnName": "amount", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "name", + "columnName": "name", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "startDate", + "columnName": "startDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "endDate", + "columnName": "endDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isEligible", + "columnName": "isEligible", + "affinity": "INTEGER", + "notNull": true, + "defaultValue": "0" + }, + { + "fieldPath": "verifiedByUserName", + "columnName": "verifiedByUserName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "reason", + "columnName": "reason", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "otherReason", + "columnName": "otherReason", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "approvalStatus", + "columnName": "approvalStatus", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "verifiedByUserId", + "columnName": "verifiedByUserId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "isClaimed", + "columnName": "isClaimed", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "approvalDate", + "columnName": "approvalDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "calimedDate", + "columnName": "calimedDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "supervisorRole", + "columnName": "supervisorRole", + "affinity": "TEXT", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "incentiveInd", + "unique": false, + "columnNames": [ + "activityId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `incentiveInd` ON `${TABLE_NAME}` (`activityId`)" + } + ], + "foreignKeys": [ + { + "table": "INCENTIVE_ACTIVITY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "activityId" + ], + "referencedColumns": [ + "id" + ] + } + ] + }, + { + "tableName": "VHND", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `vhndDate` TEXT NOT NULL, `place` TEXT, `noOfBeneficiariesAttended` INTEGER, `image1` TEXT, `image2` TEXT, `vhndPlaceId` INTEGER, `pregnantWomenAnc` TEXT, `lactatingMothersPnc` TEXT, `childrenImmunization` TEXT, `knowledgeBalancedDiet` TEXT, `careDuringPregnancy` TEXT, `importanceBreastfeeding` TEXT, `complementaryFeeding` TEXT, `hygieneSanitation` TEXT, `familyPlanningHealthcare` TEXT, `selectAllEducation` INTEGER, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "vhndDate", + "columnName": "vhndDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "place", + "columnName": "place", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "noOfBeneficiariesAttended", + "columnName": "noOfBeneficiariesAttended", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "image1", + "columnName": "image1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "image2", + "columnName": "image2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "vhndPlaceId", + "columnName": "vhndPlaceId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "pregnantWomenAnc", + "columnName": "pregnantWomenAnc", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "lactatingMothersPnc", + "columnName": "lactatingMothersPnc", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "childrenImmunization", + "columnName": "childrenImmunization", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "knowledgeBalancedDiet", + "columnName": "knowledgeBalancedDiet", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "careDuringPregnancy", + "columnName": "careDuringPregnancy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "importanceBreastfeeding", + "columnName": "importanceBreastfeeding", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "complementaryFeeding", + "columnName": "complementaryFeeding", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hygieneSanitation", + "columnName": "hygieneSanitation", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "familyPlanningHealthcare", + "columnName": "familyPlanningHealthcare", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "selectAllEducation", + "columnName": "selectAllEducation", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "VHNC", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `vhncDate` TEXT NOT NULL, `place` TEXT, `noOfBeneficiariesAttended` INTEGER, `image1` TEXT, `image2` TEXT, `villageName` TEXT, `anm` INTEGER, `aww` INTEGER, `noOfPragnentWoment` INTEGER, `noOfLactingMother` INTEGER, `noOfCommittee` INTEGER, `followupPrevius` INTEGER, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "vhncDate", + "columnName": "vhncDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "place", + "columnName": "place", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "noOfBeneficiariesAttended", + "columnName": "noOfBeneficiariesAttended", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "image1", + "columnName": "image1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "image2", + "columnName": "image2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "villageName", + "columnName": "villageName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "anm", + "columnName": "anm", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "aww", + "columnName": "aww", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "noOfPragnentWoment", + "columnName": "noOfPragnentWoment", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "noOfLactingMother", + "columnName": "noOfLactingMother", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "noOfCommittee", + "columnName": "noOfCommittee", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "followupPrevius", + "columnName": "followupPrevius", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "PHCReviewMeeting", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `placeId` INTEGER, `phcReviewDate` TEXT NOT NULL, `place` TEXT, `villageName` TEXT, `mitaninHistory` TEXT, `mitaninActivityCheckList` TEXT, `noOfBeneficiariesAttended` INTEGER, `image1` TEXT, `image2` TEXT, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "placeId", + "columnName": "placeId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "phcReviewDate", + "columnName": "phcReviewDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "place", + "columnName": "place", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "villageName", + "columnName": "villageName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mitaninHistory", + "columnName": "mitaninHistory", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mitaninActivityCheckList", + "columnName": "mitaninActivityCheckList", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "noOfBeneficiariesAttended", + "columnName": "noOfBeneficiariesAttended", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "image1", + "columnName": "image1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "image2", + "columnName": "image2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_PHCReviewMeeting_id", + "unique": true, + "columnNames": [ + "id" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_PHCReviewMeeting_id` ON `${TABLE_NAME}` (`id`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "AHDMeeting", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `mobilizedForAHD` TEXT, `ahdPlace` TEXT, `ahdDate` TEXT, `image1` TEXT, `image2` TEXT, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mobilizedForAHD", + "columnName": "mobilizedForAHD", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ahdPlace", + "columnName": "ahdPlace", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ahdDate", + "columnName": "ahdDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "image1", + "columnName": "image1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "image2", + "columnName": "image2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "DewormingMeeting", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `dewormingDone` TEXT, `dewormingDate` TEXT, `dewormingLocation` TEXT, `ageGroup` INTEGER, `image1` TEXT, `image2` TEXT, `regDate` TEXT, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dewormingDone", + "columnName": "dewormingDone", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dewormingDate", + "columnName": "dewormingDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dewormingLocation", + "columnName": "dewormingLocation", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ageGroup", + "columnName": "ageGroup", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "image1", + "columnName": "image1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "image2", + "columnName": "image2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "regDate", + "columnName": "regDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_DewormingMeeting_dewormingDate", + "unique": true, + "columnNames": [ + "dewormingDate" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_DewormingMeeting_dewormingDate` ON `${TABLE_NAME}` (`dewormingDate`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "PulsePolioCampaign", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `formDataJson` TEXT, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "ORSCampaign", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `formDataJson` TEXT, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "MALARIA_SCREENING", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitId` INTEGER NOT NULL, `caseDate` INTEGER NOT NULL, `houseHoldDetailsId` INTEGER NOT NULL, `screeningDate` INTEGER NOT NULL, `beneficiaryStatus` TEXT, `beneficiaryStatusId` INTEGER NOT NULL, `dateOfDeath` INTEGER NOT NULL, `placeOfDeath` TEXT, `otherPlaceOfDeath` TEXT, `reasonForDeath` TEXT, `otherReasonForDeath` TEXT, `rapidDiagnosticTest` TEXT, `dateOfRdt` INTEGER NOT NULL, `slideTestPf` TEXT, `slideTestPv` TEXT, `slideTestName` TEXT, `dateOfSlideTest` INTEGER NOT NULL, `dateOfVisitBySupervisor` INTEGER NOT NULL, `caseStatus` TEXT, `referredTo` INTEGER, `referToName` TEXT, `otherReferredFacility` TEXT, `remarks` TEXT, `diseaseTypeID` INTEGER, `followUpDate` INTEGER NOT NULL, `feverMoreThanTwoWeeks` INTEGER, `fluLikeIllness` INTEGER, `shakingChills` INTEGER, `headache` INTEGER, `muscleAches` INTEGER, `tiredness` INTEGER, `nausea` INTEGER, `vomiting` INTEGER, `diarrhea` INTEGER, `createdBy` TEXT, `malariaTestType` INTEGER, `malariaSlideTestType` INTEGER, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitId", + "columnName": "visitId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "caseDate", + "columnName": "caseDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldDetailsId", + "columnName": "houseHoldDetailsId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "screeningDate", + "columnName": "screeningDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "beneficiaryStatus", + "columnName": "beneficiaryStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "beneficiaryStatusId", + "columnName": "beneficiaryStatusId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherPlaceOfDeath", + "columnName": "otherPlaceOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonForDeath", + "columnName": "reasonForDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherReasonForDeath", + "columnName": "otherReasonForDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "rapidDiagnosticTest", + "columnName": "rapidDiagnosticTest", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateOfRdt", + "columnName": "dateOfRdt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "slideTestPf", + "columnName": "slideTestPf", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "slideTestPv", + "columnName": "slideTestPv", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "slideTestName", + "columnName": "slideTestName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateOfSlideTest", + "columnName": "dateOfSlideTest", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfVisitBySupervisor", + "columnName": "dateOfVisitBySupervisor", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "caseStatus", + "columnName": "caseStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referredTo", + "columnName": "referredTo", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "referToName", + "columnName": "referToName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherReferredFacility", + "columnName": "otherReferredFacility", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "remarks", + "columnName": "remarks", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "diseaseTypeID", + "columnName": "diseaseTypeID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "followUpDate", + "columnName": "followUpDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "feverMoreThanTwoWeeks", + "columnName": "feverMoreThanTwoWeeks", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "fluLikeIllness", + "columnName": "fluLikeIllness", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "shakingChills", + "columnName": "shakingChills", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "headache", + "columnName": "headache", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "muscleAches", + "columnName": "muscleAches", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "tiredness", + "columnName": "tiredness", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "nausea", + "columnName": "nausea", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "vomiting", + "columnName": "vomiting", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "diarrhea", + "columnName": "diarrhea", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "malariaTestType", + "columnName": "malariaTestType", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "malariaSlideTestType", + "columnName": "malariaSlideTestType", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_malariasn", + "unique": true, + "columnNames": [ + "benId", + "visitId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `ind_malariasn` ON `${TABLE_NAME}` (`benId`, `visitId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "AES_SCREENING", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDate` INTEGER NOT NULL, `houseHoldDetailsId` INTEGER NOT NULL, `beneficiaryStatus` TEXT, `beneficiaryStatusId` INTEGER NOT NULL, `dateOfDeath` INTEGER NOT NULL, `placeOfDeath` TEXT, `otherPlaceOfDeath` TEXT, `reasonForDeath` TEXT, `otherReasonForDeath` TEXT, `aesJeCaseStatus` TEXT, `referredTo` INTEGER, `referToName` TEXT, `otherReferredFacility` TEXT, `diseaseTypeID` INTEGER, `createdDate` INTEGER NOT NULL, `createdBy` TEXT, `followUpPoint` INTEGER, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldDetailsId", + "columnName": "houseHoldDetailsId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "beneficiaryStatus", + "columnName": "beneficiaryStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "beneficiaryStatusId", + "columnName": "beneficiaryStatusId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherPlaceOfDeath", + "columnName": "otherPlaceOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonForDeath", + "columnName": "reasonForDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherReasonForDeath", + "columnName": "otherReasonForDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "aesJeCaseStatus", + "columnName": "aesJeCaseStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referredTo", + "columnName": "referredTo", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "referToName", + "columnName": "referToName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherReferredFacility", + "columnName": "otherReferredFacility", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "diseaseTypeID", + "columnName": "diseaseTypeID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "followUpPoint", + "columnName": "followUpPoint", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_aessn", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_aessn` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "KALAZAR_SCREENING", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDate` INTEGER NOT NULL, `houseHoldDetailsId` INTEGER NOT NULL, `beneficiaryStatus` TEXT, `beneficiaryStatusId` INTEGER NOT NULL, `dateOfDeath` INTEGER NOT NULL, `placeOfDeath` TEXT, `otherPlaceOfDeath` TEXT, `reasonForDeath` TEXT, `otherReasonForDeath` TEXT, `rapidDiagnosticTest` TEXT, `dateOfRdt` INTEGER NOT NULL, `kalaAzarCaseStatus` TEXT, `referredTo` INTEGER, `referToName` TEXT, `otherReferredFacility` TEXT, `diseaseTypeID` INTEGER, `createdDate` INTEGER NOT NULL, `createdBy` TEXT, `followUpPoint` INTEGER, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldDetailsId", + "columnName": "houseHoldDetailsId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "beneficiaryStatus", + "columnName": "beneficiaryStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "beneficiaryStatusId", + "columnName": "beneficiaryStatusId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherPlaceOfDeath", + "columnName": "otherPlaceOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonForDeath", + "columnName": "reasonForDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherReasonForDeath", + "columnName": "otherReasonForDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "rapidDiagnosticTest", + "columnName": "rapidDiagnosticTest", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateOfRdt", + "columnName": "dateOfRdt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "kalaAzarCaseStatus", + "columnName": "kalaAzarCaseStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referredTo", + "columnName": "referredTo", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "referToName", + "columnName": "referToName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherReferredFacility", + "columnName": "otherReferredFacility", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "diseaseTypeID", + "columnName": "diseaseTypeID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "followUpPoint", + "columnName": "followUpPoint", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_kalazarsn", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_kalazarsn` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "FILARIA_SCREENING", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `mdaHomeVisitDate` INTEGER NOT NULL, `houseHoldDetailsId` INTEGER NOT NULL, `sufferingFromFilariasis` INTEGER, `doseStatus` TEXT, `affectedBodyPart` TEXT, `otherDoseStatusDetails` TEXT, `filariasisCaseCount` TEXT, `medicineSideEffect` TEXT, `otherSideEffectDetails` TEXT, `createdBy` TEXT, `diseaseTypeID` INTEGER, `createdDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mdaHomeVisitDate", + "columnName": "mdaHomeVisitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldDetailsId", + "columnName": "houseHoldDetailsId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "sufferingFromFilariasis", + "columnName": "sufferingFromFilariasis", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "doseStatus", + "columnName": "doseStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "affectedBodyPart", + "columnName": "affectedBodyPart", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherDoseStatusDetails", + "columnName": "otherDoseStatusDetails", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "filariasisCaseCount", + "columnName": "filariasisCaseCount", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "medicineSideEffect", + "columnName": "medicineSideEffect", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherSideEffectDetails", + "columnName": "otherSideEffectDetails", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "diseaseTypeID", + "columnName": "diseaseTypeID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_filariasn", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_filariasn` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "LEPROSY_SCREENING", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `homeVisitDate` INTEGER NOT NULL, `leprosyStatusDate` INTEGER NOT NULL, `dateOfDeath` INTEGER NOT NULL, `houseHoldDetailsId` INTEGER NOT NULL, `leprosyStatus` TEXT, `referredTo` INTEGER, `leprosyState` TEXT, `referToName` TEXT, `otherReferredTo` TEXT, `typeOfLeprosy` TEXT, `remarks` TEXT, `beneficiaryStatus` TEXT, `placeOfDeath` TEXT, `otherPlaceOfDeath` TEXT, `reasonForDeath` TEXT, `otherReasonForDeath` TEXT, `diseaseTypeID` INTEGER, `beneficiaryStatusId` INTEGER, `leprosySymptoms` TEXT, `leprosySymptomsPosition` INTEGER, `lerosyStatusPosition` INTEGER, `currentVisitNumber` INTEGER NOT NULL, `visitLabel` TEXT, `visitNumber` INTEGER, `isConfirmed` INTEGER NOT NULL, `treatmentStartDate` INTEGER NOT NULL, `totalFollowUpMonthsRequired` INTEGER NOT NULL, `treatmentEndDate` INTEGER NOT NULL, `mdtBlisterPackRecived` TEXT, `treatmentStatus` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `modifiedBy` TEXT NOT NULL, `lastModDate` INTEGER NOT NULL, `recurrentUlceration` TEXT, `recurrentUlcerationId` INTEGER, `recurrentTingling` TEXT, `recurrentTinglingId` INTEGER, `hypopigmentedPatch` TEXT, `hypopigmentedPatchId` INTEGER, `thickenedSkin` TEXT, `thickenedSkinId` INTEGER, `skinNodules` TEXT, `skinNodulesId` INTEGER, `skinPatchDiscoloration` TEXT, `skinPatchDiscolorationId` INTEGER, `recurrentNumbness` TEXT, `recurrentNumbnessId` INTEGER, `clawingFingers` TEXT, `clawingFingersId` INTEGER, `tinglingNumbnessExtremities` TEXT, `tinglingNumbnessExtremitiesId` INTEGER, `inabilityCloseEyelid` TEXT, `inabilityCloseEyelidId` INTEGER, `difficultyHoldingObjects` TEXT, `difficultyHoldingObjectsId` INTEGER, `weaknessFeet` TEXT, `weaknessFeetId` INTEGER, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "homeVisitDate", + "columnName": "homeVisitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "leprosyStatusDate", + "columnName": "leprosyStatusDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldDetailsId", + "columnName": "houseHoldDetailsId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "leprosyStatus", + "columnName": "leprosyStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referredTo", + "columnName": "referredTo", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "leprosyState", + "columnName": "leprosyState", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referToName", + "columnName": "referToName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherReferredTo", + "columnName": "otherReferredTo", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "typeOfLeprosy", + "columnName": "typeOfLeprosy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "remarks", + "columnName": "remarks", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "beneficiaryStatus", + "columnName": "beneficiaryStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherPlaceOfDeath", + "columnName": "otherPlaceOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonForDeath", + "columnName": "reasonForDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "otherReasonForDeath", + "columnName": "otherReasonForDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "diseaseTypeID", + "columnName": "diseaseTypeID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "beneficiaryStatusId", + "columnName": "beneficiaryStatusId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "leprosySymptoms", + "columnName": "leprosySymptoms", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "leprosySymptomsPosition", + "columnName": "leprosySymptomsPosition", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "lerosyStatusPosition", + "columnName": "lerosyStatusPosition", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "currentVisitNumber", + "columnName": "currentVisitNumber", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitLabel", + "columnName": "visitLabel", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitNumber", + "columnName": "visitNumber", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isConfirmed", + "columnName": "isConfirmed", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "treatmentStartDate", + "columnName": "treatmentStartDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "totalFollowUpMonthsRequired", + "columnName": "totalFollowUpMonthsRequired", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "treatmentEndDate", + "columnName": "treatmentEndDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mdtBlisterPackRecived", + "columnName": "mdtBlisterPackRecived", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "treatmentStatus", + "columnName": "treatmentStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "modifiedBy", + "columnName": "modifiedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "lastModDate", + "columnName": "lastModDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "recurrentUlceration", + "columnName": "recurrentUlceration", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "recurrentUlcerationId", + "columnName": "recurrentUlcerationId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "recurrentTingling", + "columnName": "recurrentTingling", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "recurrentTinglingId", + "columnName": "recurrentTinglingId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "hypopigmentedPatch", + "columnName": "hypopigmentedPatch", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "hypopigmentedPatchId", + "columnName": "hypopigmentedPatchId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "thickenedSkin", + "columnName": "thickenedSkin", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "thickenedSkinId", + "columnName": "thickenedSkinId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "skinNodules", + "columnName": "skinNodules", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "skinNodulesId", + "columnName": "skinNodulesId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "skinPatchDiscoloration", + "columnName": "skinPatchDiscoloration", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "skinPatchDiscolorationId", + "columnName": "skinPatchDiscolorationId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "recurrentNumbness", + "columnName": "recurrentNumbness", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "recurrentNumbnessId", + "columnName": "recurrentNumbnessId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "clawingFingers", + "columnName": "clawingFingers", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "clawingFingersId", + "columnName": "clawingFingersId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "tinglingNumbnessExtremities", + "columnName": "tinglingNumbnessExtremities", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "tinglingNumbnessExtremitiesId", + "columnName": "tinglingNumbnessExtremitiesId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "inabilityCloseEyelid", + "columnName": "inabilityCloseEyelid", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "inabilityCloseEyelidId", + "columnName": "inabilityCloseEyelidId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "difficultyHoldingObjects", + "columnName": "difficultyHoldingObjects", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "difficultyHoldingObjectsId", + "columnName": "difficultyHoldingObjectsId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "weaknessFeet", + "columnName": "weaknessFeet", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "weaknessFeetId", + "columnName": "weaknessFeetId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_leprosysn", + "unique": true, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `ind_leprosysn` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "LEPROSY_FOLLOW_UP", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitNumber` INTEGER NOT NULL, `followUpDate` INTEGER NOT NULL, `treatmentStatus` TEXT, `mdtBlisterPackReceived` TEXT, `treatmentCompleteDate` INTEGER NOT NULL, `remarks` TEXT, `homeVisitDate` INTEGER NOT NULL, `leprosySymptoms` TEXT, `typeOfLeprosy` TEXT, `leprosySymptomsPosition` INTEGER, `visitLabel` TEXT, `leprosyStatus` TEXT, `referredTo` INTEGER, `referToName` TEXT, `treatmentEndDate` INTEGER NOT NULL, `mdtBlisterPackRecived` TEXT, `treatmentStartDate` INTEGER NOT NULL, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `modifiedBy` TEXT NOT NULL, `lastModDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitNumber", + "columnName": "visitNumber", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "followUpDate", + "columnName": "followUpDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "treatmentStatus", + "columnName": "treatmentStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "mdtBlisterPackReceived", + "columnName": "mdtBlisterPackReceived", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "treatmentCompleteDate", + "columnName": "treatmentCompleteDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "remarks", + "columnName": "remarks", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "homeVisitDate", + "columnName": "homeVisitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "leprosySymptoms", + "columnName": "leprosySymptoms", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "typeOfLeprosy", + "columnName": "typeOfLeprosy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "leprosySymptomsPosition", + "columnName": "leprosySymptomsPosition", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitLabel", + "columnName": "visitLabel", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "leprosyStatus", + "columnName": "leprosyStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referredTo", + "columnName": "referredTo", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "referToName", + "columnName": "referToName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "treatmentEndDate", + "columnName": "treatmentEndDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mdtBlisterPackRecived", + "columnName": "mdtBlisterPackRecived", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "treatmentStartDate", + "columnName": "treatmentStartDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "modifiedBy", + "columnName": "modifiedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "lastModDate", + "columnName": "lastModDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_leprosy_followup_ben", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_leprosy_followup_ben` ON `${TABLE_NAME}` (`benId`)" + }, + { + "name": "ind_leprosy_followup_visit", + "unique": false, + "columnNames": [ + "benId", + "visitNumber" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_leprosy_followup_visit` ON `${TABLE_NAME}` (`benId`, `visitNumber`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "MALARIA_CONFIRMED", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `diseaseId` INTEGER NOT NULL, `benId` INTEGER NOT NULL, `houseHoldDetailsId` INTEGER NOT NULL, `dateOfDiagnosis` INTEGER NOT NULL, `treatmentStartDate` INTEGER NOT NULL, `treatmentCompletionDate` INTEGER NOT NULL, `treatmentGiven` TEXT, `referralDate` INTEGER NOT NULL, `day` TEXT, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "diseaseId", + "columnName": "diseaseId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldDetailsId", + "columnName": "houseHoldDetailsId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dateOfDiagnosis", + "columnName": "dateOfDiagnosis", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "treatmentStartDate", + "columnName": "treatmentStartDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "treatmentCompletionDate", + "columnName": "treatmentCompletionDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "treatmentGiven", + "columnName": "treatmentGiven", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referralDate", + "columnName": "referralDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "day", + "columnName": "day", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_malariacs", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_malariacs` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "IRS_ROUND", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `date` INTEGER NOT NULL, `rounds` INTEGER NOT NULL, `householdId` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "date", + "columnName": "date", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "rounds", + "columnName": "rounds", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "householdId", + "columnName": "householdId", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_irs_round", + "unique": false, + "columnNames": [ + "householdId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_irs_round` ON `${TABLE_NAME}` (`householdId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "PROFILE_ACTIVITY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER NOT NULL, `name` TEXT, `profileImage` TEXT NOT NULL, `village` TEXT NOT NULL, `employeeId` INTEGER NOT NULL, `dob` TEXT NOT NULL, `age` INTEGER NOT NULL, `mobileNumber` TEXT NOT NULL, `alternateMobileNumber` TEXT NOT NULL, `fatherOrSpouseName` TEXT NOT NULL, `dateOfJoining` TEXT NOT NULL, `bankAccount` TEXT NOT NULL, `ifsc` TEXT NOT NULL, `populationCovered` INTEGER NOT NULL, `choName` TEXT NOT NULL, `choMobile` TEXT NOT NULL, `awwName` TEXT NOT NULL, `awwMobile` TEXT NOT NULL, `anm1Name` TEXT NOT NULL, `anm1Mobile` TEXT NOT NULL, `anm2Name` TEXT NOT NULL, `anm2Mobile` TEXT NOT NULL, `abhaNumber` TEXT NOT NULL, `ashaHouseholdRegistration` TEXT NOT NULL, `ashaFamilyMember` TEXT NOT NULL, `providerServiceMapID` TEXT NOT NULL, `isFatherOrSpouse` INTEGER NOT NULL, `supervisorName` TEXT NOT NULL, `supervisorMobile` TEXT NOT NULL, PRIMARY KEY(`id`))", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "name", + "columnName": "name", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "profileImage", + "columnName": "profileImage", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "village", + "columnName": "village", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "employeeId", + "columnName": "employeeId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dob", + "columnName": "dob", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "age", + "columnName": "age", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "mobileNumber", + "columnName": "mobileNumber", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "alternateMobileNumber", + "columnName": "alternateMobileNumber", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "fatherOrSpouseName", + "columnName": "fatherOrSpouseName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "dateOfJoining", + "columnName": "dateOfJoining", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "bankAccount", + "columnName": "bankAccount", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "ifsc", + "columnName": "ifsc", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "populationCovered", + "columnName": "populationCovered", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "choName", + "columnName": "choName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "choMobile", + "columnName": "choMobile", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "awwName", + "columnName": "awwName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "awwMobile", + "columnName": "awwMobile", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "anm1Name", + "columnName": "anm1Name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "anm1Mobile", + "columnName": "anm1Mobile", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "anm2Name", + "columnName": "anm2Name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "anm2Mobile", + "columnName": "anm2Mobile", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "abhaNumber", + "columnName": "abhaNumber", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "ashaHouseholdRegistration", + "columnName": "ashaHouseholdRegistration", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "ashaFamilyMember", + "columnName": "ashaFamilyMember", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "providerServiceMapID", + "columnName": "providerServiceMapID", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isFatherOrSpouse", + "columnName": "isFatherOrSpouse", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "supervisorName", + "columnName": "supervisorName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "supervisorMobile", + "columnName": "supervisorMobile", + "affinity": "TEXT", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "Adolescent_Health_Form_Data", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT, `userID` INTEGER, `benId` INTEGER, `visitDate` INTEGER NOT NULL, `healthStatus` TEXT, `ifaTabletDistributed` INTEGER, `quantityOfIfaTablets` INTEGER, `menstrualHygieneAwarenessGiven` INTEGER, `sanitaryNapkinDistributed` INTEGER, `isSanitaryNapkinUsed` INTEGER, `noOfPacketsDistributed` INTEGER, `place` TEXT, `distributionDate` INTEGER NOT NULL, `referredToHealthFacility` TEXT, `counselingProvided` INTEGER, `counselingType` TEXT, `followUpDate` INTEGER NOT NULL, `referralStatus` TEXT, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "userID", + "columnName": "userID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "healthStatus", + "columnName": "healthStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ifaTabletDistributed", + "columnName": "ifaTabletDistributed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "quantityOfIfaTablets", + "columnName": "quantityOfIfaTablets", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "menstrualHygieneAwarenessGiven", + "columnName": "menstrualHygieneAwarenessGiven", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "sanitaryNapkinDistributed", + "columnName": "sanitaryNapkinDistributed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "isSanitaryNapkinUsed", + "columnName": "isSanitaryNapkinUsed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "noOfPacketsDistributed", + "columnName": "noOfPacketsDistributed", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "place", + "columnName": "place", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "distributionDate", + "columnName": "distributionDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referredToHealthFacility", + "columnName": "referredToHealthFacility", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "counselingProvided", + "columnName": "counselingProvided", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "counselingType", + "columnName": "counselingType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "followUpDate", + "columnName": "followUpDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referralStatus", + "columnName": "referralStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_adolescentsn", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_adolescentsn` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "ABHA_GENERATED", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `beneficiaryID` INTEGER NOT NULL, `beneficiaryRegID` INTEGER NOT NULL, `benName` TEXT NOT NULL, `createdBy` TEXT NOT NULL, `message` TEXT NOT NULL, `txnId` TEXT NOT NULL, `benSurname` TEXT, `healthId` TEXT NOT NULL, `healthIdNumber` TEXT NOT NULL, `abhaProfileJson` TEXT NOT NULL, `isNewAbha` INTEGER NOT NULL, `providerServiceMapId` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`beneficiaryID`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "beneficiaryID", + "columnName": "beneficiaryID", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "beneficiaryRegID", + "columnName": "beneficiaryRegID", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benName", + "columnName": "benName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "message", + "columnName": "message", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "txnId", + "columnName": "txnId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "benSurname", + "columnName": "benSurname", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "healthId", + "columnName": "healthId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "healthIdNumber", + "columnName": "healthIdNumber", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "abhaProfileJson", + "columnName": "abhaProfileJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isNewAbha", + "columnName": "isNewAbha", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "providerServiceMapId", + "columnName": "providerServiceMapId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_ABHA_GENERATED_beneficiaryID", + "unique": true, + "columnNames": [ + "beneficiaryID" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_ABHA_GENERATED_beneficiaryID` ON `${TABLE_NAME}` (`beneficiaryID`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "beneficiaryID" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "infant", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `rchId` TEXT NOT NULL, `name` TEXT NOT NULL, `motherName` TEXT NOT NULL, `fatherName` TEXT, `dob` TEXT NOT NULL, `gender` TEXT NOT NULL, `phoneNumber` TEXT NOT NULL, `sncuDischarged` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "rchId", + "columnName": "rchId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "name", + "columnName": "name", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "motherName", + "columnName": "motherName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "fatherName", + "columnName": "fatherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dob", + "columnName": "dob", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "gender", + "columnName": "gender", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "phoneNumber", + "columnName": "phoneNumber", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "sncuDischarged", + "columnName": "sncuDischarged", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "form_schema", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`formId` TEXT NOT NULL, `formName` TEXT NOT NULL, `language` TEXT NOT NULL, `version` INTEGER NOT NULL, `schemaJson` TEXT NOT NULL, PRIMARY KEY(`formId`))", + "fields": [ + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formName", + "columnName": "formName", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "language", + "columnName": "language", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "schemaJson", + "columnName": "schemaJson", + "affinity": "TEXT", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "formId" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "SAAS_BAHU_ACTIVITY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `ashaId` INTEGER NOT NULL, `place` TEXT, `participants` INTEGER, `date` INTEGER, `sammelanImages` TEXT, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ashaId", + "columnName": "ashaId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "place", + "columnName": "place", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "participants", + "columnName": "participants", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "date", + "columnName": "date", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "sammelanImages", + "columnName": "sammelanImages", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "MAA_MEETING", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `meetingDate` TEXT, `place` TEXT, `participants` INTEGER, `mitaninActivityCheckList` TEXT, `villageName` TEXT, `noOfPragnentWomen` TEXT, `noOfLactingMother` TEXT, `ashaId` INTEGER, `meetingImages` TEXT, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "meetingDate", + "columnName": "meetingDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "place", + "columnName": "place", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "participants", + "columnName": "participants", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "mitaninActivityCheckList", + "columnName": "mitaninActivityCheckList", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "villageName", + "columnName": "villageName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "noOfPragnentWomen", + "columnName": "noOfPragnentWomen", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "noOfLactingMother", + "columnName": "noOfLactingMother", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ashaId", + "columnName": "ashaId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "meetingImages", + "columnName": "meetingImages", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedAt", + "columnName": "updatedAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_MAA_MEETING_id", + "unique": true, + "columnNames": [ + "id" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_MAA_MEETING_id` ON `${TABLE_NAME}` (`id`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "all_visit_history", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `visitDay` TEXT NOT NULL, `visitDate` TEXT NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `syncedAt` INTEGER)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDay", + "columnName": "visitDay", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_all_visit_history_benId_hhId_visitDay_visitDate_formId", + "unique": true, + "columnNames": [ + "benId", + "hhId", + "visitDay", + "visitDate", + "formId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_all_visit_history_benId_hhId_visitDay_visitDate_formId` ON `${TABLE_NAME}` (`benId`, `hhId`, `visitDay`, `visitDate`, `formId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "ALL_VISIT_HISTORY_HBYC", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `visitDay` TEXT NOT NULL, `visitDate` TEXT NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `syncedAt` INTEGER)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDay", + "columnName": "visitDay", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_ALL_VISIT_HISTORY_HBYC_benId_hhId_visitDay_visitDate_formId", + "unique": true, + "columnNames": [ + "benId", + "hhId", + "visitDay", + "visitDate", + "formId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_ALL_VISIT_HISTORY_HBYC_benId_hhId_visitDay_visitDate_formId` ON `${TABLE_NAME}` (`benId`, `hhId`, `visitDay`, `visitDate`, `formId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "children_under_five_all_visit", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `serverId` INTEGER, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `visitDate` TEXT NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, `syncedAt` INTEGER)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "serverId", + "columnName": "serverId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedAt", + "columnName": "updatedAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_children_under_five_all_visit_serverId_formId", + "unique": true, + "columnNames": [ + "serverId", + "formId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_children_under_five_all_visit_serverId_formId` ON `${TABLE_NAME}` (`serverId`, `formId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "ncd_referal_all_visit", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `visitNo` INTEGER NOT NULL, `followUpNo` INTEGER NOT NULL, `treatmentStartDate` TEXT NOT NULL, `followUpDate` TEXT, `diagnosisCodes` TEXT, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, `syncedAt` INTEGER)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitNo", + "columnName": "visitNo", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "followUpNo", + "columnName": "followUpNo", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "treatmentStartDate", + "columnName": "treatmentStartDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "followUpDate", + "columnName": "followUpDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "diagnosisCodes", + "columnName": "diagnosisCodes", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedAt", + "columnName": "updatedAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_ncd_referal_all_visit_benId_hhId", + "unique": false, + "columnNames": [ + "benId", + "hhId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_ncd_referal_all_visit_benId_hhId` ON `${TABLE_NAME}` (`benId`, `hhId`)" + }, + { + "name": "index_ncd_referal_all_visit_benId_hhId_visitNo_followUpNo", + "unique": true, + "columnNames": [ + "benId", + "hhId", + "visitNo", + "followUpNo" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_ncd_referal_all_visit_benId_hhId_visitNo_followUpNo` ON `${TABLE_NAME}` (`benId`, `hhId`, `visitNo`, `followUpNo`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "GENERAL_OPD_ACTIVITY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`benFlowID` INTEGER, `beneficiaryRegID` INTEGER, `benVisitID` INTEGER, `visitCode` INTEGER, `benVisitNo` INTEGER, `nurseFlag` INTEGER, `doctorFlag` INTEGER, `pharmacist_flag` INTEGER, `lab_technician_flag` INTEGER, `radiologist_flag` INTEGER, `oncologist_flag` INTEGER, `specialist_flag` INTEGER, `agentId` TEXT, `visitDate` TEXT, `modified_by` TEXT, `modified_date` TEXT, `benName` TEXT, `deleted` INTEGER, `firstName` TEXT, `lastName` TEXT, `age` TEXT, `ben_age_val` INTEGER, `genderID` INTEGER, `genderName` TEXT, `preferredPhoneNum` TEXT, `fatherName` TEXT, `spouseName` TEXT, `districtName` TEXT, `servicePointName` TEXT, `registrationDate` TEXT, `benVisitDate` TEXT, `consultationDate` TEXT, `consultantID` INTEGER, `consultantName` TEXT, `visitSession` TEXT, `servicePointID` INTEGER, `districtID` INTEGER, `villageID` INTEGER, `vanID` INTEGER, `beneficiaryId` INTEGER NOT NULL, `dob` TEXT, `tc_SpecialistLabFlag` INTEGER, `visitReason` TEXT, `village` TEXT, `visitCategory` TEXT, PRIMARY KEY(`beneficiaryId`))", + "fields": [ + { + "fieldPath": "benFlowID", + "columnName": "benFlowID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "beneficiaryRegID", + "columnName": "beneficiaryRegID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "benVisitID", + "columnName": "benVisitID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCode", + "columnName": "visitCode", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "benVisitNo", + "columnName": "benVisitNo", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "nurseFlag", + "columnName": "nurseFlag", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "doctorFlag", + "columnName": "doctorFlag", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "pharmacist_flag", + "columnName": "pharmacist_flag", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "lab_technician_flag", + "columnName": "lab_technician_flag", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "radiologist_flag", + "columnName": "radiologist_flag", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "oncologist_flag", + "columnName": "oncologist_flag", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "specialist_flag", + "columnName": "specialist_flag", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "agentId", + "columnName": "agentId", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "modified_by", + "columnName": "modified_by", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "modified_date", + "columnName": "modified_date", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "benName", + "columnName": "benName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "deleted", + "columnName": "deleted", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "firstName", + "columnName": "firstName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "lastName", + "columnName": "lastName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "age", + "columnName": "age", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "ben_age_val", + "columnName": "ben_age_val", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "genderID", + "columnName": "genderID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "genderName", + "columnName": "genderName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "preferredPhoneNum", + "columnName": "preferredPhoneNum", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fatherName", + "columnName": "fatherName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "spouseName", + "columnName": "spouseName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "districtName", + "columnName": "districtName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "servicePointName", + "columnName": "servicePointName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "registrationDate", + "columnName": "registrationDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "benVisitDate", + "columnName": "benVisitDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "consultationDate", + "columnName": "consultationDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "consultantID", + "columnName": "consultantID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "consultantName", + "columnName": "consultantName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitSession", + "columnName": "visitSession", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "servicePointID", + "columnName": "servicePointID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "districtID", + "columnName": "districtID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "villageID", + "columnName": "villageID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "vanID", + "columnName": "vanID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "beneficiaryId", + "columnName": "beneficiaryId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "dob", + "columnName": "dob", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "tc_SpecialistLabFlag", + "columnName": "tc_SpecialistLabFlag", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitReason", + "columnName": "visitReason", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "village", + "columnName": "village", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "visitCategory", + "columnName": "visitCategory", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "beneficiaryId" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "NCD_REFER", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `referredToInstituteID` INTEGER, `refrredToAdditionalServiceList` TEXT, `referredToInstituteName` TEXT, `referralReason` TEXT, `revisitDate` INTEGER NOT NULL, `vanID` INTEGER, `parkingPlaceID` INTEGER, `beneficiaryRegID` INTEGER, `benVisitID` INTEGER, `visitCode` INTEGER, `providerServiceMapID` INTEGER, `createdBy` TEXT, `type` TEXT, `isSpecialist` INTEGER, `syncState` INTEGER NOT NULL, `priority` TEXT, `revisitMonth` INTEGER NOT NULL DEFAULT 0, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referredToInstituteID", + "columnName": "referredToInstituteID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "refrredToAdditionalServiceList", + "columnName": "refrredToAdditionalServiceList", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referredToInstituteName", + "columnName": "referredToInstituteName", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "referralReason", + "columnName": "referralReason", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "revisitDate", + "columnName": "revisitDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "vanID", + "columnName": "vanID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "parkingPlaceID", + "columnName": "parkingPlaceID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "beneficiaryRegID", + "columnName": "beneficiaryRegID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "benVisitID", + "columnName": "benVisitID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "visitCode", + "columnName": "visitCode", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "providerServiceMapID", + "columnName": "providerServiceMapID", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "type", + "columnName": "type", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "isSpecialist", + "columnName": "isSpecialist", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "priority", + "columnName": "priority", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "revisitMonth", + "columnName": "revisitMonth", + "affinity": "INTEGER", + "notNull": true, + "defaultValue": "0" + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_refcache", + "unique": true, + "columnNames": [ + "benId", + "referralReason", + "revisitMonth" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `ind_refcache` ON `${TABLE_NAME}` (`benId`, `referralReason`, `revisitMonth`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "UWIN_SESSION", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `sessionDate` INTEGER NOT NULL, `place` TEXT, `participantsCount` INTEGER NOT NULL, `uploadedFiles1` TEXT, `uploadedFiles2` TEXT, `processed` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedBy` TEXT NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "sessionDate", + "columnName": "sessionDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "place", + "columnName": "place", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "participantsCount", + "columnName": "participantsCount", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "uploadedFiles1", + "columnName": "uploadedFiles1", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "uploadedFiles2", + "columnName": "uploadedFiles2", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "processed", + "columnName": "processed", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedBy", + "columnName": "updatedBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "ALL_EYE_SURGERY_VISIT_HISTORY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `visitDate` TEXT NOT NULL, `visitMonth` TEXT NOT NULL, `eyeSide` TEXT NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `syncedAt` TEXT)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "visitMonth", + "columnName": "visitMonth", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "eyeSide", + "columnName": "eyeSide", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_ALL_EYE_SURGERY_VISIT_HISTORY_benId_formId_eyeSide", + "unique": true, + "columnNames": [ + "benId", + "formId", + "eyeSide" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_ALL_EYE_SURGERY_VISIT_HISTORY_benId_formId_eyeSide` ON `${TABLE_NAME}` (`benId`, `formId`, `eyeSide`)" + }, + { + "name": "index_ALL_EYE_SURGERY_VISIT_HISTORY_benId_visitDate", + "unique": false, + "columnNames": [ + "benId", + "visitDate" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_ALL_EYE_SURGERY_VISIT_HISTORY_benId_visitDate` ON `${TABLE_NAME}` (`benId`, `visitDate`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "ALL_BEN_IFA_VISIT_HISTORY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `visitDate` TEXT NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `syncedAt` INTEGER)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_ALL_BEN_IFA_VISIT_HISTORY_benId_hhId_visitDate_formId", + "unique": true, + "columnNames": [ + "benId", + "hhId", + "visitDate", + "formId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_ALL_BEN_IFA_VISIT_HISTORY_benId_hhId_visitDate_formId` ON `${TABLE_NAME}` (`benId`, `hhId`, `visitDate`, `formId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "mosquito_net_visit", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `hhId` INTEGER NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `visitDate` TEXT NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `syncedAt` TEXT)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_mosquito_net_visit_hhId_visitDate_formId", + "unique": true, + "columnNames": [ + "hhId", + "visitDate", + "formId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_mosquito_net_visit_hhId_visitDate_formId` ON `${TABLE_NAME}` (`hhId`, `visitDate`, `formId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "FILARIA_MDA_VISIT_HISTORY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `hhId` INTEGER NOT NULL, `visitDate` TEXT NOT NULL, `visitMonth` TEXT NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `syncedAt` TEXT)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "visitMonth", + "columnName": "visitMonth", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_FILARIA_MDA_VISIT_HISTORY_hhId_formId_visitMonth", + "unique": true, + "columnNames": [ + "hhId", + "formId", + "visitMonth" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_FILARIA_MDA_VISIT_HISTORY_hhId_formId_visitMonth` ON `${TABLE_NAME}` (`hhId`, `formId`, `visitMonth`)" + }, + { + "name": "index_FILARIA_MDA_VISIT_HISTORY_hhId_visitDate", + "unique": false, + "columnNames": [ + "hhId", + "visitDate" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_FILARIA_MDA_VISIT_HISTORY_hhId_visitDate` ON `${TABLE_NAME}` (`hhId`, `visitDate`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "ALL_VISIT_HISTORY_ANC", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `visitDay` TEXT NOT NULL, `visitDate` TEXT NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `syncedAt` INTEGER)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDay", + "columnName": "visitDay", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "INTEGER", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_ALL_VISIT_HISTORY_ANC_benId_visitDay_visitDate_formId", + "unique": true, + "columnNames": [ + "benId", + "visitDay", + "visitDate", + "formId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_ALL_VISIT_HISTORY_ANC_benId_visitDay_visitDate_formId` ON `${TABLE_NAME}` (`benId`, `visitDay`, `visitDate`, `formId`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "FILARIA_MDA_CAMPAIGN_HISTORY", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `visitDate` TEXT NOT NULL, `visitYear` TEXT NOT NULL, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `formDataJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `syncedAt` TEXT)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitDate", + "columnName": "visitDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "visitYear", + "columnName": "visitYear", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formDataJson", + "columnName": "formDataJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncedAt", + "columnName": "syncedAt", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_FILARIA_MDA_CAMPAIGN_HISTORY_formId_visitYear", + "unique": true, + "columnNames": [ + "formId", + "visitYear" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_FILARIA_MDA_CAMPAIGN_HISTORY_formId_visitYear` ON `${TABLE_NAME}` (`formId`, `visitYear`)" + }, + { + "name": "index_FILARIA_MDA_CAMPAIGN_HISTORY_visitDate", + "unique": false, + "columnNames": [ + "visitDate" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `index_FILARIA_MDA_CAMPAIGN_HISTORY_visitDate` ON `${TABLE_NAME}` (`visitDate`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "TB_CONFIRMED_TREATMENT", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `regimenType` TEXT, `treatmentStartDate` INTEGER NOT NULL, `expectedTreatmentCompletionDate` INTEGER, `followUpDate` INTEGER, `monthlyFollowUpDone` TEXT, `adherenceToMedicines` TEXT, `anyDiscomfort` INTEGER, `treatmentCompleted` INTEGER, `actualTreatmentCompletionDate` INTEGER, `treatmentOutcome` TEXT, `dateOfDeath` INTEGER, `placeOfDeath` TEXT, `reasonForDeath` TEXT NOT NULL, `reasonForNotCompleting` TEXT, `syncState` INTEGER NOT NULL, `createdAt` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "regimenType", + "columnName": "regimenType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "treatmentStartDate", + "columnName": "treatmentStartDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "expectedTreatmentCompletionDate", + "columnName": "expectedTreatmentCompletionDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "followUpDate", + "columnName": "followUpDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "monthlyFollowUpDone", + "columnName": "monthlyFollowUpDone", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "adherenceToMedicines", + "columnName": "adherenceToMedicines", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "anyDiscomfort", + "columnName": "anyDiscomfort", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "treatmentCompleted", + "columnName": "treatmentCompleted", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "actualTreatmentCompletionDate", + "columnName": "actualTreatmentCompletionDate", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "treatmentOutcome", + "columnName": "treatmentOutcome", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "dateOfDeath", + "columnName": "dateOfDeath", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "placeOfDeath", + "columnName": "placeOfDeath", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "reasonForDeath", + "columnName": "reasonForDeath", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "reasonForNotCompleting", + "columnName": "reasonForNotCompleting", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "createdAt", + "columnName": "createdAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedAt", + "columnName": "updatedAt", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_tb_confirmed", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_tb_confirmed` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "tb_referral_follow_up", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `houseHoldId` INTEGER NOT NULL, `referredOnDate` TEXT NOT NULL, `followUpDate` TEXT NOT NULL, `followUpStatus` TEXT, `fieldsJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldId", + "columnName": "houseHoldId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referredOnDate", + "columnName": "referredOnDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "followUpDate", + "columnName": "followUpDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "followUpStatus", + "columnName": "followUpStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fieldsJson", + "columnName": "fieldsJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedAt", + "columnName": "updatedAt", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_tb_referral_follow_up_benId_followUpDate", + "unique": true, + "columnNames": [ + "benId", + "followUpDate" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_tb_referral_follow_up_benId_followUpDate` ON `${TABLE_NAME}` (`benId`, `followUpDate`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "tb_tpt_follow_up", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `houseHoldId` INTEGER NOT NULL, `visitNo` INTEGER NOT NULL, `followUpNo` INTEGER NOT NULL, `treatmentType` TEXT, `treatmentStartDate` TEXT, `followUpDate` TEXT, `formId` TEXT NOT NULL, `version` INTEGER NOT NULL, `fieldsJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldId", + "columnName": "houseHoldId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "visitNo", + "columnName": "visitNo", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "followUpNo", + "columnName": "followUpNo", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "treatmentType", + "columnName": "treatmentType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "treatmentStartDate", + "columnName": "treatmentStartDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "followUpDate", + "columnName": "followUpDate", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "formId", + "columnName": "formId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "version", + "columnName": "version", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "fieldsJson", + "columnName": "fieldsJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedAt", + "columnName": "updatedAt", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_tb_tpt_follow_up_benId_visitNo_followUpNo", + "unique": true, + "columnNames": [ + "benId", + "visitNo", + "followUpNo" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_tb_tpt_follow_up_benId_visitNo_followUpNo` ON `${TABLE_NAME}` (`benId`, `visitNo`, `followUpNo`)" + } + ], + "foreignKeys": [] + }, + { + "tableName": "NOTIFICATION", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`notificationId` INTEGER NOT NULL, `userId` INTEGER NOT NULL, `role` TEXT, `eventType` TEXT NOT NULL, `navId` TEXT, `title` TEXT NOT NULL, `body` TEXT NOT NULL, `priority` TEXT, `createdTs` INTEGER NOT NULL, `read` INTEGER NOT NULL, `cleared` INTEGER NOT NULL, `viewed` INTEGER NOT NULL, `senderUserId` INTEGER, `receiverUserId` INTEGER, `beneficiaryId` INTEGER, `activityId` INTEGER, `referenceId` INTEGER, `appType` TEXT, `redirect` TEXT, `readDate` TEXT, PRIMARY KEY(`notificationId`))", + "fields": [ + { + "fieldPath": "notificationId", + "columnName": "notificationId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "userId", + "columnName": "userId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "role", + "columnName": "role", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "eventType", + "columnName": "eventType", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "navId", + "columnName": "navId", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "title", + "columnName": "title", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "body", + "columnName": "body", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "priority", + "columnName": "priority", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdTs", + "columnName": "createdTs", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "read", + "columnName": "read", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "cleared", + "columnName": "cleared", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "viewed", + "columnName": "viewed", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "senderUserId", + "columnName": "senderUserId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "receiverUserId", + "columnName": "receiverUserId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "beneficiaryId", + "columnName": "beneficiaryId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "activityId", + "columnName": "activityId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "referenceId", + "columnName": "referenceId", + "affinity": "INTEGER", + "notNull": false + }, + { + "fieldPath": "appType", + "columnName": "appType", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "redirect", + "columnName": "redirect", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "readDate", + "columnName": "readDate", + "affinity": "TEXT", + "notNull": false + } + ], + "primaryKey": { + "autoGenerate": false, + "columnNames": [ + "notificationId" + ] + }, + "indices": [], + "foreignKeys": [] + }, + { + "tableName": "GENERAL_CHECKUP", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `checkupId` TEXT NOT NULL, `benId` INTEGER NOT NULL, `hhId` INTEGER NOT NULL, `ashaId` INTEGER NOT NULL, `checkupDate` INTEGER NOT NULL, `problemTypeId` TEXT NOT NULL, `problemTypeLabel` TEXT NOT NULL, `problemIds` TEXT NOT NULL, `problemLabels` TEXT NOT NULL, `otherText` TEXT, `priority` TEXT NOT NULL, `masterVersion` INTEGER NOT NULL, `referralReason` TEXT NOT NULL, `referralDate` INTEGER NOT NULL, `referralMonth` INTEGER NOT NULL, `formData` TEXT, `createdBy` TEXT NOT NULL, `createdDate` INTEGER NOT NULL, `updatedDate` INTEGER NOT NULL, `syncState` INTEGER NOT NULL, FOREIGN KEY(`benId`) REFERENCES `BENEFICIARY`(`beneficiaryId`) ON UPDATE CASCADE ON DELETE CASCADE )", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "checkupId", + "columnName": "checkupId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "hhId", + "columnName": "hhId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "ashaId", + "columnName": "ashaId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "checkupDate", + "columnName": "checkupDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "problemTypeId", + "columnName": "problemTypeId", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "problemTypeLabel", + "columnName": "problemTypeLabel", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "problemIds", + "columnName": "problemIds", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "problemLabels", + "columnName": "problemLabels", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "otherText", + "columnName": "otherText", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "priority", + "columnName": "priority", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "masterVersion", + "columnName": "masterVersion", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referralReason", + "columnName": "referralReason", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "referralDate", + "columnName": "referralDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referralMonth", + "columnName": "referralMonth", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "formData", + "columnName": "formData", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "createdBy", + "columnName": "createdBy", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "createdDate", + "columnName": "createdDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedDate", + "columnName": "updatedDate", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "syncState", + "columnName": "syncState", + "affinity": "INTEGER", + "notNull": true + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "ind_gc_checkup_id", + "unique": true, + "columnNames": [ + "checkupId" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `ind_gc_checkup_id` ON `${TABLE_NAME}` (`checkupId`)" + }, + { + "name": "ind_gc_ben", + "unique": false, + "columnNames": [ + "benId" + ], + "orders": [], + "createSql": "CREATE INDEX IF NOT EXISTS `ind_gc_ben` ON `${TABLE_NAME}` (`benId`)" + } + ], + "foreignKeys": [ + { + "table": "BENEFICIARY", + "onDelete": "CASCADE", + "onUpdate": "CASCADE", + "columns": [ + "benId" + ], + "referencedColumns": [ + "beneficiaryId" + ] + } + ] + }, + { + "tableName": "gc_referral_follow_up", + "createSql": "CREATE TABLE IF NOT EXISTS `${TABLE_NAME}` (`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, `benId` INTEGER NOT NULL, `houseHoldId` INTEGER NOT NULL, `referredOnDate` TEXT NOT NULL, `followUpDate` TEXT NOT NULL, `followUpStatus` TEXT, `fieldsJson` TEXT NOT NULL, `isSynced` INTEGER NOT NULL, `updatedAt` INTEGER NOT NULL, `referralReason` TEXT NOT NULL DEFAULT '', `referralMonth` INTEGER NOT NULL DEFAULT 0)", + "fields": [ + { + "fieldPath": "id", + "columnName": "id", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "benId", + "columnName": "benId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "houseHoldId", + "columnName": "houseHoldId", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referredOnDate", + "columnName": "referredOnDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "followUpDate", + "columnName": "followUpDate", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "followUpStatus", + "columnName": "followUpStatus", + "affinity": "TEXT", + "notNull": false + }, + { + "fieldPath": "fieldsJson", + "columnName": "fieldsJson", + "affinity": "TEXT", + "notNull": true + }, + { + "fieldPath": "isSynced", + "columnName": "isSynced", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "updatedAt", + "columnName": "updatedAt", + "affinity": "INTEGER", + "notNull": true + }, + { + "fieldPath": "referralReason", + "columnName": "referralReason", + "affinity": "TEXT", + "notNull": true, + "defaultValue": "''" + }, + { + "fieldPath": "referralMonth", + "columnName": "referralMonth", + "affinity": "INTEGER", + "notNull": true, + "defaultValue": "0" + } + ], + "primaryKey": { + "autoGenerate": true, + "columnNames": [ + "id" + ] + }, + "indices": [ + { + "name": "index_gc_referral_follow_up_benId_referralReason_referralMonth", + "unique": true, + "columnNames": [ + "benId", + "referralReason", + "referralMonth" + ], + "orders": [], + "createSql": "CREATE UNIQUE INDEX IF NOT EXISTS `index_gc_referral_follow_up_benId_referralReason_referralMonth` ON `${TABLE_NAME}` (`benId`, `referralReason`, `referralMonth`)" + } + ], + "foreignKeys": [] + } + ], + "views": [ + { + "viewName": "BEN_BASIC_CACHE", + "createSql": "CREATE VIEW `${VIEW_NAME}` AS SELECT b.beneficiaryId as benId,b.isMarried,b.noOfAliveChildren, b.noOfChildren, b.doYouHavechildren ,b.isConsent as isConsent, b.motherName as motherName, b.householdId as hhId, b.regDate, b.createdDate as createdDate, b.updatedDate as updatedDate, b.firstName as benName, b.lastName as benSurname, b.gender, b.dob as dob,b.isDeactivate, b.isDeath,b.isDeathValue,b.dateOfDeath,b.timeOfDeath,b.reasonOfDeath,b.reasonOfDeathId,b.placeOfDeath,b.placeOfDeathId,b.otherPlaceOfDeath,b.isSpouseAdded,b.isChildrenAdded, b.familyHeadRelationPosition as relToHeadId, b.contactNumber as mobileNo, b.fatherName,h.fam_familyHeadName as familyHeadName, b.gen_spouseName as spouseName, b.rchId, b.gen_lastMenstrualPeriod as lastMenstrualPeriod, b.isHrpStatus as hrpStatus, b.syncState, b.gen_reproductiveStatusId as reproductiveStatusId, b.isKid, b.immunizationStatus, b.loc_village_id as villageId, b.abha_healthIdNumber as abhaId, b.isNewAbha, IFNULL(cbac.benId IS NOT NULL, 0) as cbacFilled, cbac.syncState as cbacSyncState, IFNULL(cdr.benId IS NOT NULL, 0) as cdrFilled, cdr.syncState as cdrSyncState, IFNULL(mdsr.benId IS NOT NULL, 0) as mdsrFilled, mdsr.syncState as mdsrSyncState, IFNULL(pmsma.benId IS NOT NULL, 0) as pmsmaFilled, pmsma.syncState as pmsmaSyncState, IFNULL(hbnc.benId IS NOT NULL, 0) as hbncFilled, IFNULL(hbyc.benId IS NOT NULL, 0) as hbycFilled, IFNULL(pwr.benId IS NOT NULL, 0) as pwrFilled, pwr.syncState as pwrSyncState, IFNULL(pwa.pregnantWomanDelivered, 0) as isDelivered, IFNULL(pwa.hrpConfirmed, 0) as pwHrp, IFNULL(ecr.benId IS NOT NULL, 0) as ecrFilled, IFNULL(ect.benId IS NOT NULL, 0) as ectFilled, IFNULL((pwa.maternalDeath OR do.complication = 'DEATH' OR pnc.motherDeath), 0) as isMdsr, IFNULL(tbsn.benId IS NOT NULL, 0) as tbsnFilled, tbsn.syncState as tbsnSyncState, IFNULL(tbsp.benId IS NOT NULL, 0) as tbspFilled, tbsp.syncState as tbspSyncState, IFNULL(ir.motherBenId IS NOT NULL, 0) as irFilled, ir.syncState as irSyncState, IFNULL(cr.motherBenId IS NOT NULL, 0) as crFilled, cr.syncState as crSyncState, IFNULL(do.benId IS NOT NULL, 0) as doFilled, do.syncState as doSyncState, IFNULL((hrppa.benId IS NOT NULL AND hrppa.noOfDeliveries IS NOT NULL AND hrppa.timeLessThan18m IS NOT NULL AND hrppa.heightShort IS NOT NULL AND hrppa.age IS NOT NULL AND hrppa.rhNegative IS NOT NULL AND hrppa.homeDelivery IS NOT NULL AND hrppa.badObstetric IS NOT NULL AND hrppa.multiplePregnancy IS NOT NULL), 0) as hrppaFilled, hrppa.syncState as hrppaSyncState, IFNULL((hrpnpa.benId IS NOT NULL AND hrpnpa.noOfDeliveries IS NOT NULL AND hrpnpa.timeLessThan18m IS NOT NULL AND hrpnpa.heightShort IS NOT NULL AND hrpnpa.age IS NOT NULL AND hrpnpa.misCarriage IS NOT NULL AND hrpnpa.homeDelivery IS NOT NULL AND hrpnpa.medicalIssues IS NOT NULL AND hrpnpa.pastCSection IS NOT NULL), 0) as hrpnpaFilled, hrpnpa.syncState as hrpnpaSyncState, IFNULL(hrpmbp.benId IS NOT NULL, 0) as hrpmbpFilled, hrpmbp.syncState as hrpmbpSyncState, IFNULL(hrpt.benId IS NOT NULL, 0) as hrptFilled, IFNULL(((count(distinct hrpt.id) > 3) OR (((JulianDay('now')) - JulianDay(date(max(hrpt.visitDate)/1000,'unixepoch','localtime'))) < 1)), 0) as hrptrackingDone, hrpt.syncState as hrptSyncState, IFNULL(hrnpt.benId IS NOT NULL, 0) as hrnptFilled, IFNULL(((JulianDay('now') - JulianDay(date(max(hrnpt.visitDate)/1000,'unixepoch','localtime'))) < 1), 0) as hrnptrackingDone, hrnpt.syncState as hrnptSyncState FROM BENEFICIARY b JOIN HOUSEHOLD h ON b.householdId = h.householdId LEFT OUTER JOIN CBAC cbac ON b.beneficiaryId = cbac.benId LEFT OUTER JOIN CDR cdr ON b.beneficiaryId = cdr.benId LEFT OUTER JOIN MDSR mdsr ON b.beneficiaryId = mdsr.benId LEFT OUTER JOIN PMSMA pmsma ON b.beneficiaryId = pmsma.benId LEFT OUTER JOIN HBNC hbnc ON b.beneficiaryId = hbnc.benId LEFT OUTER JOIN HBYC hbyc ON b.beneficiaryId = hbyc.benId LEFT OUTER JOIN PREGNANCY_REGISTER pwr ON b.beneficiaryId = pwr.benId LEFT OUTER JOIN PREGNANCY_ANC pwa ON b.beneficiaryId = pwa.benId LEFT OUTER JOIN pnc_visit pnc ON b.beneficiaryId = pnc.benId LEFT OUTER JOIN ELIGIBLE_COUPLE_REG ecr ON b.beneficiaryId = ecr.benId LEFT OUTER JOIN ELIGIBLE_COUPLE_TRACKING ect ON (b.beneficiaryId = ect.benId AND CAST((strftime('%s','now') - ect.visitDate/1000)/60/60/24 AS INTEGER) < 30) LEFT OUTER JOIN TB_SCREENING tbsn ON b.beneficiaryId = tbsn.benId LEFT OUTER JOIN TB_SUSPECTED tbsp ON b.beneficiaryId = tbsp.benId LEFT OUTER JOIN MALARIA_SCREENING masp on b.beneficiaryId = masp.benId LEFT OUTER JOIN MALARIA_CONFIRMED macp on b.beneficiaryId = macp.benId LEFT OUTER JOIN HRP_PREGNANT_ASSESS hrppa ON b.beneficiaryId = hrppa.benId LEFT OUTER JOIN HRP_NON_PREGNANT_ASSESS hrpnpa ON b.beneficiaryId = hrpnpa.benId LEFT OUTER JOIN HRP_MICRO_BIRTH_PLAN hrpmbp ON b.beneficiaryId = hrpmbp.benId LEFT OUTER JOIN HRP_NON_PREGNANT_TRACK hrnpt ON b.beneficiaryId = hrnpt.benId LEFT OUTER JOIN HRP_PREGNANT_TRACK hrpt ON b.beneficiaryId = hrpt.benId LEFT OUTER JOIN DELIVERY_OUTCOME do ON b.beneficiaryId = do.benId LEFT OUTER JOIN INFANT_REG ir ON b.beneficiaryId = ir.motherBenId LEFT OUTER JOIN CHILD_REG cr ON b.beneficiaryId = cr.motherBenId WHERE b.isDraft = 0 GROUP BY b.beneficiaryId ORDER BY MAX(IFNULL(b.updatedDate, 0), IFNULL(b.createdDate, 0), IFNULL(b.regDate, 0)) DESC, b.beneficiaryId DESC" + } + ], + "setupQueries": [ + "CREATE TABLE IF NOT EXISTS room_master_table (id INTEGER PRIMARY KEY,identity_hash TEXT)", + "INSERT OR REPLACE INTO room_master_table (id,identity_hash) VALUES(42, '95b1461920e35956dd4acb5799e171b2')" + ] + } +} \ No newline at end of file diff --git a/app/src/main/java/org/piramalswasthya/sakhi/database/room/InAppDb.kt b/app/src/main/java/org/piramalswasthya/sakhi/database/room/InAppDb.kt index 6d1993cfd..d95d8eebe 100644 --- a/app/src/main/java/org/piramalswasthya/sakhi/database/room/InAppDb.kt +++ b/app/src/main/java/org/piramalswasthya/sakhi/database/room/InAppDb.kt @@ -217,7 +217,7 @@ import org.piramalswasthya.sakhi.model.dynamicEntity.mosquitonetEntity.MosquitoN GCReferralFollowUpEntity::class ], views = [BenBasicCache::class], - version = 77, exportSchema = true + version = 78, exportSchema = true ) @TypeConverters( diff --git a/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migration74To75.kt b/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migration74To75.kt index 2457545a0..58e4cf986 100644 --- a/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migration74To75.kt +++ b/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migration74To75.kt @@ -9,6 +9,7 @@ import org.piramalswasthya.sakhi.database.room.migrations.MigrationHelpers.colum // are linked when the beneficiary has exactly one General Check-up referral. object Migration74To75 : Migration(74, 75) { override fun migrate(database: SupportSQLiteDatabase) { + Migration73To74.migrate(database) if (!columnExists(database, "gc_referral_follow_up", "referralReason")) { database.execSQL("ALTER TABLE gc_referral_follow_up ADD COLUMN referralReason TEXT NOT NULL DEFAULT ''") } diff --git a/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migration77To78.kt b/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migration77To78.kt new file mode 100644 index 000000000..084c851d9 --- /dev/null +++ b/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migration77To78.kt @@ -0,0 +1,27 @@ +package org.piramalswasthya.sakhi.database.room.migrations + +import androidx.room.migration.Migration +import androidx.sqlite.db.SupportSQLiteDatabase + +object Migration77To78 : Migration(77, 78) { + override fun migrate(database: SupportSQLiteDatabase) { + database.execSQL( + "CREATE TABLE IF NOT EXISTS `gc_referral_follow_up` (" + + "`id` INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, " + + "`benId` INTEGER NOT NULL, " + + "`houseHoldId` INTEGER NOT NULL, " + + "`referredOnDate` TEXT NOT NULL, " + + "`followUpDate` TEXT NOT NULL, " + + "`followUpStatus` TEXT, " + + "`fieldsJson` TEXT NOT NULL, " + + "`isSynced` INTEGER NOT NULL, " + + "`updatedAt` INTEGER NOT NULL, " + + "`referralReason` TEXT NOT NULL DEFAULT '', " + + "`referralMonth` INTEGER NOT NULL DEFAULT 0)" + ) + database.execSQL( + "CREATE UNIQUE INDEX IF NOT EXISTS `index_gc_referral_follow_up_benId_referralReason_referralMonth` " + + "ON `gc_referral_follow_up` (`benId`, `referralReason`, `referralMonth`)" + ) + } +} diff --git a/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migrations.kt b/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migrations.kt index bd7d42b8f..16e923457 100644 --- a/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migrations.kt +++ b/app/src/main/java/org/piramalswasthya/sakhi/database/room/migrations/Migrations.kt @@ -66,5 +66,6 @@ val ALL_MIGRATIONS: Array = arrayOf( Migration73To74, Migration74To75, Migration75To76, - Migration76To77 + Migration76To77, + Migration77To78 ) diff --git a/app/src/test/java/org/piramalswasthya/sakhi/database/room/InAppDbRecentMigrationsTest.kt b/app/src/test/java/org/piramalswasthya/sakhi/database/room/InAppDbRecentMigrationsTest.kt index 62fd11fda..260626dcc 100644 --- a/app/src/test/java/org/piramalswasthya/sakhi/database/room/InAppDbRecentMigrationsTest.kt +++ b/app/src/test/java/org/piramalswasthya/sakhi/database/room/InAppDbRecentMigrationsTest.kt @@ -76,7 +76,7 @@ class InAppDbRecentMigrationsTest { @Test fun `migrations form one unbroken chain up to the database version`() { val recent = ALL_MIGRATIONS.filter { it.startVersion >= 70 }.sortedBy { it.startVersion } - assertEquals((70..76).toList(), recent.map { it.startVersion }) + assertEquals((70..77).toList(), recent.map { it.startVersion }) recent.forEach { assertEquals(it.startVersion + 1, it.endVersion) } } @@ -141,7 +141,9 @@ class InAppDbRecentMigrationsTest { // The new key is created only after duplicates are removed. assertTrue( executedSql.indexOfFirst { it.startsWith("DELETE FROM gc_referral_follow_up") } < - executedSql.indexOfFirst { it.contains("CREATE UNIQUE INDEX") } + executedSql.indexOfFirst { + it.contains("CREATE UNIQUE INDEX") && it.contains("benId_referralReason_referralMonth") + } ) } diff --git a/app/src/test/java/org/piramalswasthya/sakhi/database/room/migrations/Migration77To78Test.kt b/app/src/test/java/org/piramalswasthya/sakhi/database/room/migrations/Migration77To78Test.kt new file mode 100644 index 000000000..bcf78e7d9 --- /dev/null +++ b/app/src/test/java/org/piramalswasthya/sakhi/database/room/migrations/Migration77To78Test.kt @@ -0,0 +1,72 @@ +package org.piramalswasthya.sakhi.database.room.migrations + +import android.database.Cursor +import androidx.sqlite.db.SupportSQLiteDatabase +import io.mockk.every +import io.mockk.mockk +import org.junit.Assert.assertEquals +import org.junit.Assert.assertTrue +import org.junit.Test + +class Migration77To78Test { + + private val executedSql = mutableListOf() + + private fun mockDb(existingColumns: List = emptyList()): SupportSQLiteDatabase { + val db = mockk(relaxed = true) + every { db.execSQL(any()) } answers { + executedSql.add(firstArg()) + Unit + } + every { db.query(any()) } answers { + val cursor = mockk(relaxed = true) + var index = -1 + every { cursor.moveToNext() } answers { + index += 1 + index < existingColumns.size + } + every { cursor.getColumnIndexOrThrow("name") } returns 0 + every { cursor.getString(0) } answers { existingColumns[index] } + cursor + } + return db + } + + @Test + fun `migrates from 77 to 78`() { + assertEquals(77, Migration77To78.startVersion) + assertEquals(78, Migration77To78.endVersion) + } + + @Test + fun `creates the gc referral follow up table with its final columns when missing`() { + Migration77To78.migrate(mockDb()) + + assertEquals(2, executedSql.size) + val createTable = executedSql[0] + assertTrue(createTable.startsWith("CREATE TABLE IF NOT EXISTS `gc_referral_follow_up`")) + assertTrue(createTable.contains("`referralReason` TEXT NOT NULL DEFAULT ''")) + assertTrue(createTable.contains("`referralMonth` INTEGER NOT NULL DEFAULT 0")) + assertTrue(createTable.contains("`followUpStatus` TEXT,")) + assertEquals( + "CREATE UNIQUE INDEX IF NOT EXISTS `index_gc_referral_follow_up_benId_referralReason_referralMonth` " + + "ON `gc_referral_follow_up` (`benId`, `referralReason`, `referralMonth`)", + executedSql[1] + ) + } + + @Test + fun `74 to 75 creates the table before altering it when an earlier build skipped it`() { + Migration74To75.migrate(mockDb()) + + assertTrue(executedSql[0].startsWith("CREATE TABLE IF NOT EXISTS `gc_referral_follow_up`")) + assertTrue(executedSql.indexOfFirst { it.startsWith("ALTER TABLE gc_referral_follow_up") } > 0) + } + + @Test + fun `74 to 75 skips the column adds when the columns already exist`() { + Migration74To75.migrate(mockDb(listOf("referralReason", "referralMonth"))) + + assertTrue(executedSql.none { it.startsWith("ALTER TABLE") }) + } +} diff --git a/app/src/test/java/org/piramalswasthya/sakhi/database/room/migrations/MigrationsTest.kt b/app/src/test/java/org/piramalswasthya/sakhi/database/room/migrations/MigrationsTest.kt index 0b3e8cec0..35faa28df 100644 --- a/app/src/test/java/org/piramalswasthya/sakhi/database/room/migrations/MigrationsTest.kt +++ b/app/src/test/java/org/piramalswasthya/sakhi/database/room/migrations/MigrationsTest.kt @@ -10,8 +10,8 @@ class MigrationsTest { private fun pairs() = ALL_MIGRATIONS.map { it.startVersion to it.endVersion } @Test - fun `registry lists all 64 migrations`() { - assertEquals(64, ALL_MIGRATIONS.size) + fun `registry lists all 65 migrations`() { + assertEquals(65, ALL_MIGRATIONS.size) } @Test @@ -27,9 +27,9 @@ class MigrationsTest { } @Test - fun `oldest supported version is 13 and newest is 77`() { + fun `oldest supported version is 13 and newest is 78`() { assertEquals(13, ALL_MIGRATIONS.minOf { it.startVersion }) - assertEquals(77, ALL_MIGRATIONS.maxOf { it.endVersion }) + assertEquals(78, ALL_MIGRATIONS.maxOf { it.endVersion }) } @Test @@ -39,28 +39,28 @@ class MigrationsTest { } @Test - fun `every version from 13 to 76 has a path up to 77`() { + fun `every version from 13 to 77 has a path up to 78`() { val byStart = ALL_MIGRATIONS.groupBy { it.startVersion } - for (start in 13..76) { + for (start in 13..77) { var version = start - while (version < 77) { + while (version < 78) { val next = byStart[version]?.maxOf { it.endVersion } assertNotNull("no migration from $version", next) version = next!! } - assertEquals(77, version) + assertEquals(78, version) } } @Test - fun `current production version 64 upgrades through 65 to 77 one step at a time`() { + fun `current production version 64 upgrades through 65 to 78 one step at a time`() { val path = mutableListOf(64) var version = 64 - while (version < 77) { + while (version < 78) { version = ALL_MIGRATIONS.single { it.startVersion == version }.endVersion path.add(version) } - assertEquals(listOf(64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77), path) + assertEquals(listOf(64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78), path) } @Test @@ -75,5 +75,6 @@ class MigrationsTest { assertTrue(ALL_MIGRATIONS.contains(Migration74To75)) assertTrue(ALL_MIGRATIONS.contains(Migration75To76)) assertTrue(ALL_MIGRATIONS.contains(Migration76To77)) + assertTrue(ALL_MIGRATIONS.contains(Migration77To78)) } }