/*
SQLyog Community Edition- MySQL GUI v5.22a
Host - 5.0.19-nt : Database - onlinexamination
*********************************************************************
Server version : 5.0.19-nt
*/

/*!40101 SET NAMES utf8 */;

/*!40101 SET SQL_MODE=''*/;

create database if not exists `onlinexamination`;

USE `onlinexamination`;

/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;

/*Table structure for table `new_ques` */

DROP TABLE IF EXISTS `new_ques`;

CREATE TABLE `new_ques` (
  `quesno` int(10) NOT NULL auto_increment,
  `language` varchar(15) NOT NULL,
  `question` varchar(800) NOT NULL,
  `ans1` varbinary(150) NOT NULL,
  `ans2` varchar(150) NOT NULL,
  `ans3` varchar(150) default NULL,
  `ans4` varchar(150) default NULL,
  `rightans` varchar(150) NOT NULL,
  PRIMARY KEY  (`quesno`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*Data for the table `new_ques` */

insert  into `new_ques`(`quesno`,`language`,`question`,`ans1`,`ans2`,`ans3`,`ans4`,`rightans`) values (6,'java','What is an example of polymorphism? ','Inner class ','Anonymous classes ','Method overloading ','operater overloading ','Method overloading '),(8,'C++','C++ was originally developed by','Nicolas Wirth ','Donald Knuth ','Bjarne Stroustrup ','Ken Thompson ','Bjarne Stroustrup '),(10,'C++','The preprocessor directive #include is required if ','Console output is used ','Console input is used','Both console input and output is used ','None of these ','Both console input and output is used '),(13,'C++','The fields in a class of a c++ program are by default','protected ','public ','private ','None of these ','private  '),(14,'C++','In C++ a function contained with in a class is called ','A member function','An operator','A class function','A method','A member function'),(15,'JAVA','What will be the result of compiling and running the given program? \r\nSelect one correct answer. \r\n1 class AA{}\r\n2 class BB extends AA{}\r\n3 class Q6\r\n4 {\r\n5 public static void main(String arg[])\r\n6 {\r\n7 AA a=null;\r\n8 BB b=(BB)a;\r\n9 System.out.println(b);\r\n10 System.out.println(b instanceof BB);\r\n11 System.out.println(b instanceof AA); \r\n12 }\r\n13 }\r\n','Program compiles correctly and print null,true,false.','Program compiles correctly and print null,true,true.        ','Program compiles correctly and print null,false,false.',' Program compiles correctly and print null,false,true.','Program compiles correctly and print null,false,false.'),(17,'JAVA','Here are three proposed alternatives to be used in a method to return false if the object reference x has the null value. Which statement will work?','if ( x == null ) return false;',' if ( x.equals(null) ) return false;','if ( x instanceof null ) return false;','if ( x instanceof null ) return false;','if ( x == null ) return false;'),(20,'java','Which of the following are primitive types?','','',NULL,NULL,''),(21,'JAVA','Which of the following methods are methods of the String class? ','delete( ) ','append( ) ','reverse( ) ','replace( ) ','replace( ) ');

/*Table structure for table `result_info` */

DROP TABLE IF EXISTS `result_info`;

CREATE TABLE `result_info` (
  `username` varchar(20) default NULL,
  `quesno` int(10) NOT NULL,
  `selectopt` varchar(150) NOT NULL,
  `language` varchar(100) default NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*Data for the table `result_info` */

insert  into `result_info`(`username`,`quesno`,`selectopt`,`language`) values ('gangwar',17,'if ( x.equals(null) ) return false;','JAVA'),('gangwar',15,'Program compiles correctly and print null,true,true.','JAVA'),('bharatgangwar',5,'byte,','JAVA'),('bharatgangwar',6,'Anonymous classes','JAVA');

/*Table structure for table `s_registration` */

DROP TABLE IF EXISTS `s_registration`;

CREATE TABLE `s_registration` (
  `name` varchar(50) default NULL,
  `address` varchar(100) default NULL,
  `dob` datetime default NULL,
  `phone` varchar(12) default NULL,
  `gender` varchar(2) default NULL,
  `branch` varchar(20) default NULL,
  `year` varchar(4) default NULL,
  `rollno` int(10) default NULL,
  `username` varchar(20) NOT NULL,
  `password` varchar(10) default NULL,
  PRIMARY KEY  (`username`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*Data for the table `s_registration` */

insert  into `s_registration`(`name`,`address`,`dob`,`phone`,`gender`,`branch`,`year`,`rollno`,`username`,`password`) values ('dsaf','dsaf','1986-01-19 00:00:00','1545','m','jhm','jkmj',2511,'',''),('jhkj','jhjkg','1986-01-01 00:00:00','lkkl','m','m','m',2,'2125','21212'),('ankit','luvknow','1986-11-06 00:00:00','9999999785','m','cs','2004',74574,'ankit@gmail.com','111111'),('Bharat','Bareilly','1986-01-01 00:00:00','8261543684','m','cs','2010',21,'bhara@gmail.com','111111'),('Bharat','Bareilly','1986-01-01 00:00:00','8261543684','m','cs','2010',21,'bharat@gmail.com','111111'),('bharat','bareil;ly','1986-09-09 00:00:00','12','m','cs','2044',251,'bharatgangwar','GANGWAR'),('bharat','Bareilly','1986-01-09 00:00:00','25','m','cs','2004',54,'gangwar','11111'),('gyan','Bareilly','1986-01-03 00:00:00','2222222222','m','cs','2010',25415,'gyan@gmail.com','111111'),('dsaf','dsaf','1986-01-19 00:00:00','1545','m','jhm','jkmj',2511,'hfgh','fdh'),('DFGD','DFGD','1986-02-03 00:00:00','55451','M','J','M',2125,'M',''),('vinay','bihar','1986-01-01 00:00:00','1321','e','fd','dfdf',12,'vinay','vinay');

/*Table structure for table `userinfo` */

DROP TABLE IF EXISTS `userinfo`;

CREATE TABLE `userinfo` (
  `id` int(10) NOT NULL auto_increment,
  `firstname` varchar(100) NOT NULL,
  `lastname` varchar(100) NOT NULL,
  `gender` varchar(10) NOT NULL,
  `age` varchar(3) NOT NULL,
  `address` varchar(200) NOT NULL,
  PRIMARY KEY  (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

/*Data for the table `userinfo` */

insert  into `userinfo`(`id`,`firstname`,`lastname`,`gender`,`age`,`address`) values (1,'Bharat','Gangwar','Male','25','Bareilly'),(4,'Bharat','Gangwar','Male','26','BLY'),(5,'Bharat','Gangwar','Male','26','BLY'),(6,'Bharat','Gangwar','Male','26','BLY'),(7,'Bharat','Gangwar','Male','26','BLY'),(9,'bgn','gh','Male','gf','fgh'),(12,'Bhartat','dfjg','Male','df','fd'),(14,'Bhartat','dfjg','Male','df','fd'),(16,'Bharta','dfjg','Male','df','fd'),(25,'sadsad','sdafa','','fds','daf'),(26,'sadsad','sdafa','','fds','daf'),(28,'sadsad','sdafa','','fds','daf'),(38,'Bharat','GFangwar','Male','24','sxdsad'),(43,'','','','',''),(44,'Bharat','Gangwar','','','');

/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
