-- https://www.phpmyadmin.net/
--

START TRANSACTION;



--
-- Database: `signup`
--

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

--
-- Table structure for table `checklist`
--

CREATE TABLE `checklist` (
  `id` int(8) NOT NULL,
  `UserId` int(8) NOT NULL,
  `Date` date NOT NULL,
  `StartTime` datetime NOT NULL,
  `EndTime` datetime NOT NULL,
  `Location` varchar(50) NOT NULL,
  `LocalId` int(8) NOT NULL,
  `Status` int(8) NOT NULL,
  `CreatedDate` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `ModifiedDate` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `checklist`
--

INSERT INTO `checklist` (`id`, `UserId`, `Date`, `StartTime`, `EndTime`, `Location`, `LocalId`, `Status`, `CreatedDate`, `ModifiedDate`) VALUES
(1, 1, '1993-03-14', '1993-03-15 01:11:10', '1993-03-15 01:50:10', 'Gondia', 1, 1, '2019-05-02 10:48:55', '0000-00-00 00:00:00'),
(2, 1, '1993-03-14', '1993-03-14 14:00:00', '1993-03-14 14:01:00', 'Nagpur', 1, 1, '2019-05-02 10:51:22', '0000-00-00 00:00:00'),
(3, 1, '1993-03-14', '1993-03-14 14:00:00', '1993-03-14 14:01:00', 'Aurangabad', 1, 1, '2019-05-02 10:52:24', '0000-00-00 00:00:00'),
(4, 1, '1993-03-14', '1993-03-14 14:00:00', '1993-03-14 14:01:00', 'Gondia', 1, 1, '2019-05-02 11:24:58', '0000-00-00 00:00:00'),
(5, 1, '1993-03-15', '1993-03-14 14:00:00', '1993-03-14 15:00:10', 'Aurangabad', 1, 1, '2019-05-08 11:02:00', '0000-00-00 00:00:00');

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

--
-- Table structure for table `checklistitems`
--

CREATE TABLE `checklistitems` (
  `Id` int(8) NOT NULL,
  `UserId` int(8) NOT NULL,
  `CheckListId` int(8) NOT NULL,
  `Name` varchar(60) NOT NULL,
  `Count` int(8) NOT NULL,
  `Gender` varchar(7) NOT NULL,
  `IdentifiedBy` varchar(60) NOT NULL,
  `LocalId` int(8) NOT NULL,
  `Status` int(8) NOT NULL,
  `CreatedDate` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
  `ModifiedDate` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

--
-- Dumping data for table `checklistitems`
--

INSERT INTO `checklistitems` (`Id`, `UserId`, `CheckListId`, `Name`, `Count`, `Gender`, `IdentifiedBy`, `LocalId`, `Status`, `CreatedDate`, `ModifiedDate`) VALUES
(1, 1, 1, 'TDR', 10, 'Male', 'Vishal', 1, 1, '2019-05-02 12:10:36', '0000-00-00 00:00:00'),
(2, 1, 1, 'Vishal', 10, 'Male', 'Chin', 1, 1, '2019-05-02 12:13:46', '0000-00-00 00:00:00'),
(3, 1, 1, 'TDR', 16, 'Male', 'Vishal', 1, 1, '2019-05-08 11:15:17', '0000-00-00 00:00:00');

--
-- Indexes for dumped tables
--

--
-- Indexes for table `checklist`
--
ALTER TABLE `checklist`
  ADD PRIMARY KEY (`id`),
  ADD KEY `checklist_UserId` (`UserId`);

--
-- Indexes for table `checklistitems`
--
ALTER TABLE `checklistitems`
  ADD PRIMARY KEY (`Id`),
  ADD KEY `checklistitem_UserId` (`UserId`),
  ADD KEY `checklistitem_cheklistId` (`CheckListId`);

--
-- AUTO_INCREMENT for dumped tables
--

--
-- AUTO_INCREMENT for table `checklist`
--
ALTER TABLE `checklist`
  MODIFY `id` int(8) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=6;

--
-- AUTO_INCREMENT for table `checklistitems`
--
ALTER TABLE `checklistitems`
  MODIFY `Id` int(8) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=4;

--
-- Constraints for dumped tables
--

--
-- Constraints for table `checklist`
--
ALTER TABLE `checklist`
  ADD CONSTRAINT `checklist_UserId` FOREIGN KEY (`UserId`) REFERENCES `users` (`Id`);

--
-- Constraints for table `checklistitems`
--
ALTER TABLE `checklistitems`
  ADD CONSTRAINT `checklistitem_UserId` FOREIGN KEY (`UserId`) REFERENCES `users` (`Id`),
  ADD CONSTRAINT `checklistitem_cheklistId` FOREIGN KEY (`CheckListId`) REFERENCES `checklist` (`id`);
COMMIT;

