-
Notifications
You must be signed in to change notification settings - Fork 0
/
turf_booking.sql
231 lines (189 loc) · 7.02 KB
/
turf_booking.sql
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
-- phpMyAdmin SQL Dump
-- version 5.0.2
-- https://www.phpmyadmin.net/
--
-- Host: localhost
-- Generation Time: Jun 05, 2022 at 07:15 PM
-- Server version: 10.4.11-MariaDB
-- PHP Version: 7.4.5
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
START TRANSACTION;
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8mb4 */;
--
-- Database: `turf_booking`
--
-- --------------------------------------------------------
--
-- Table structure for table `booking_details`
--
CREATE TABLE `booking_details` (
`id` int(11) NOT NULL,
`player_id` int(11) NOT NULL,
`team_id` int(11) NOT NULL,
`turf_id` int(11) NOT NULL,
`turf_owner_id` int(11) NOT NULL,
`booking_date` varchar(255) DEFAULT NULL,
`booking_time` varchar(255) DEFAULT NULL,
`closing_time` varchar(255) DEFAULT NULL,
`player_name` varchar(255) DEFAULT NULL,
`team_name` varchar(255) DEFAULT NULL,
`turf_name` varchar(255) DEFAULT NULL,
`turf_owner_name` varchar(255) DEFAULT NULL,
`booking_payment` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
--
-- Dumping data for table `booking_details`
--
INSERT INTO `booking_details` (`id`, `player_id`, `team_id`, `turf_id`, `turf_owner_id`, `booking_date`, `booking_time`, `closing_time`, `player_name`, `team_name`, `turf_name`, `turf_owner_name`, `booking_payment`) VALUES
(2, 1, 1, 1, 2, '2022-03-12', '12:24', '01:24', 'Jitendra Kumar', 'RCV', 'Test Turf', 'Jitendra Kumar', NULL);
-- --------------------------------------------------------
--
-- Table structure for table `challenges`
--
CREATE TABLE `challenges` (
`id` int(11) NOT NULL,
`game_name` varchar(255) DEFAULT NULL,
`challenge_name` varchar(255) DEFAULT NULL,
`details` text DEFAULT NULL,
`team_id_creating` int(11) DEFAULT NULL,
`team_leader_id_creating` int(11) DEFAULT NULL,
`team_id_accepting` int(11) DEFAULT NULL,
`team_leader_id_accepting` int(11) DEFAULT NULL,
`turf_id` int(11) DEFAULT NULL,
`booking_date` varchar(255) DEFAULT NULL,
`starting_date` varchar(255) DEFAULT NULL,
`ending_date` varchar(255) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
--
-- Dumping data for table `challenges`
--
INSERT INTO `challenges` (`id`, `game_name`, `challenge_name`, `details`, `team_id_creating`, `team_leader_id_creating`, `team_id_accepting`, `team_leader_id_accepting`, `turf_id`, `booking_date`, `starting_date`, `ending_date`) VALUES
(2, 'Cricket', 'IPL Challenge', ' Lorem ipsum dolor sit, amet consectetur adipisicing elit. Animi voluptatum recusandae non quisquam eos dolor architecto perferendis illum eaque nobis? Veniam, voluptates. Cupiditate repellat nihil, aut corrupti alias enim quidem?\r\n', 1, 1, 2, 6, 1, '2022-08-12', '01:05', '04:00');
-- --------------------------------------------------------
--
-- Table structure for table `teams`
--
CREATE TABLE `teams` (
`id` int(11) NOT NULL,
`team_name` varchar(255) DEFAULT NULL,
`team_leader_id` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
--
-- Dumping data for table `teams`
--
INSERT INTO `teams` (`id`, `team_name`, `team_leader_id`) VALUES
(1, 'RCV', 1),
(2, 'Mumbai Indians', 6);
-- --------------------------------------------------------
--
-- Table structure for table `turf`
--
CREATE TABLE `turf` (
`id` int(11) NOT NULL,
`turf_name` varchar(255) DEFAULT NULL,
`turf_location` varchar(255) DEFAULT NULL,
`turf_image` varchar(255) DEFAULT NULL,
`turf_owner_id` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
--
-- Dumping data for table `turf`
--
INSERT INTO `turf` (`id`, `turf_name`, `turf_location`, `turf_image`, `turf_owner_id`) VALUES
(1, 'Sports Turf', 'Aman Vihar Delhi 247632', 'Turf_up.jpg', 2),
(3, 'Excellent Turf ', 'Rajeev Nagar Mumbai 345', 'ec8dbe661b8185f220df02e5f70abd3d.jpg', 9),
(4, 'New Sports', 'Gandhi Park Delhi 23412', '97f132614ccdb40575b38df5467fda83.jpg', 10);
-- --------------------------------------------------------
--
-- Table structure for table `users`
--
CREATE TABLE `users` (
`id` int(11) NOT NULL,
`name` varchar(255) DEFAULT NULL,
`user_type` int(11) DEFAULT NULL,
`email` varchar(255) DEFAULT NULL,
`contact` varchar(255) DEFAULT NULL,
`password` varchar(255) DEFAULT NULL,
`turf_name` varchar(255) DEFAULT NULL,
`turf_owner_contact` varchar(255) DEFAULT NULL,
`team_id` int(11) DEFAULT NULL,
`is_captain` varchar(255) DEFAULT NULL,
`player_age` varchar(255) DEFAULT NULL,
`address` text DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
--
-- Dumping data for table `users`
--
INSERT INTO `users` (`id`, `name`, `user_type`, `email`, `contact`, `password`, `turf_name`, `turf_owner_contact`, `team_id`, `is_captain`, `player_age`, `address`) VALUES
(1, 'Jitendra Kumar', 1, '[email protected]', '0976009423', '12312312', NULL, NULL, 1, NULL, '22', 'dehradun'),
(2, 'Jitendra Kumar', 2, '[email protected]', '9050316445', '12312312', NULL, NULL, NULL, NULL, NULL, NULL),
(3, 'Jadeja', 1, NULL, '9050316432', NULL, NULL, NULL, 1, NULL, '25', NULL),
(4, 'Rohit', 1, NULL, '9050316455', NULL, NULL, NULL, 1, NULL, '22', NULL),
(5, 'Jitendra Kumar', 1, NULL, '9050316499', NULL, NULL, NULL, 1, NULL, '21', NULL),
(6, 'MS Dhoni', 1, '[email protected]', '7906748534', '12312312', NULL, NULL, NULL, NULL, '26', 'Delhi'),
(7, 'Virat', 1, NULL, '09760094234', NULL, NULL, NULL, 2, NULL, '23', NULL),
(9, 'Viren', 2, '[email protected]', '9050316445', '12312312', NULL, NULL, NULL, NULL, NULL, NULL),
(10, 'Rajeev Singh', 2, '[email protected]', '9760094234', '12312312', NULL, NULL, NULL, NULL, NULL, NULL);
--
-- Indexes for dumped tables
--
--
-- Indexes for table `booking_details`
--
ALTER TABLE `booking_details`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `challenges`
--
ALTER TABLE `challenges`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `teams`
--
ALTER TABLE `teams`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `turf`
--
ALTER TABLE `turf`
ADD PRIMARY KEY (`id`);
--
-- Indexes for table `users`
--
ALTER TABLE `users`
ADD PRIMARY KEY (`id`);
--
-- AUTO_INCREMENT for dumped tables
--
--
-- AUTO_INCREMENT for table `booking_details`
--
ALTER TABLE `booking_details`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;
--
-- AUTO_INCREMENT for table `challenges`
--
ALTER TABLE `challenges`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;
--
-- AUTO_INCREMENT for table `teams`
--
ALTER TABLE `teams`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=3;
--
-- AUTO_INCREMENT for table `turf`
--
ALTER TABLE `turf`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=5;
--
-- AUTO_INCREMENT for table `users`
--
ALTER TABLE `users`
MODIFY `id` int(11) NOT NULL AUTO_INCREMENT, AUTO_INCREMENT=11;
COMMIT;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;