File: D:/data/secure/csl/csl_bam1.sql
-- MySQL dump 10.13 Distrib 5.1.63, for Win64 (unknown)
--
-- Host: localhost Database: csl_bam1
-- ------------------------------------------------------
-- Server version 5.1.63-community
/*!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 utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!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' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
--
-- Current Database: `csl_bam1`
--
CREATE DATABASE /*!32312 IF NOT EXISTS*/ `csl_bam1` /*!40100 DEFAULT CHARACTER SET latin1 */;
--
-- Table structure for table `audit`
--
DROP TABLE IF EXISTS `audit`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `audit` (
`ID` int(11) NOT NULL AUTO_INCREMENT,
`Type` varchar(50) DEFAULT NULL,
`UserID` varchar(50) DEFAULT NULL,
`SessionID` varchar(50) DEFAULT NULL,
`TimeOn` datetime DEFAULT NULL,
`TimeOff` datetime DEFAULT NULL,
`Length` double DEFAULT NULL,
`EndType` varchar(1) DEFAULT NULL,
`Notes` varchar(255) DEFAULT NULL,
PRIMARY KEY (`ID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `audit`
--
LOCK TABLES `audit` WRITE;
/*!40000 ALTER TABLE `audit` DISABLE KEYS */;
/*!40000 ALTER TABLE `audit` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `bookingnights`
--
DROP TABLE IF EXISTS `bookingnights`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `bookingnights` (
`BookingNo` int(11) NOT NULL,
`RoomNo` int(11) NOT NULL,
`Date` date NOT NULL,
`HotelID` int(11) DEFAULT NULL COMMENT '(SS,6/12/14) replaced HotelName with HotelID',
`RoomTypeID` int(11) DEFAULT NULL COMMENT '(SS,6/12/14) replaced RoomType with RoomTypeID',
PRIMARY KEY (`BookingNo`,`RoomNo`,`Date`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `bookingnights`
--
LOCK TABLES `bookingnights` WRITE;
/*!40000 ALTER TABLE `bookingnights` DISABLE KEYS */;
/*!40000 ALTER TABLE `bookingnights` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `bookingnightstemp`
--
DROP TABLE IF EXISTS `bookingnightstemp`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `bookingnightstemp` (
`SessionID` int(11) NOT NULL,
`RoomNo` int(11) NOT NULL,
`Date` date NOT NULL,
`HotelID` int(11) DEFAULT NULL COMMENT '(SS,6/12/15) HotelName replaced with HotelID',
`RoomTypeID` int(11) DEFAULT NULL COMMENT '(SS,6/12/14) RoomTypeID replaced with RoomTypeID',
PRIMARY KEY (`SessionID`,`RoomNo`,`Date`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AVG_ROW_LENGTH=2730;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `bookingnightstemp`
--
LOCK TABLES `bookingnightstemp` WRITE;
/*!40000 ALTER TABLE `bookingnightstemp` DISABLE KEYS */;
/*!40000 ALTER TABLE `bookingnightstemp` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `bookingrooms`
--
DROP TABLE IF EXISTS `bookingrooms`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `bookingrooms` (
`BookingNo` int(11) NOT NULL,
`RoomNo` int(11) NOT NULL,
`FullName` varchar(50) DEFAULT NULL,
`ArrivalDate` date DEFAULT NULL,
`NoOfNights` smallint(6) DEFAULT NULL,
`RoomTypeID` int(11) DEFAULT NULL,
`NonSmoking` bit(1) DEFAULT b'0',
`SharingWith` varchar(50) DEFAULT NULL,
`SpecialRequirements` varchar(50) DEFAULT NULL,
PRIMARY KEY (`BookingNo`,`RoomNo`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `bookingrooms`
--
LOCK TABLES `bookingrooms` WRITE;
/*!40000 ALTER TABLE `bookingrooms` DISABLE KEYS */;
/*!40000 ALTER TABLE `bookingrooms` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `bookings`
--
DROP TABLE IF EXISTS `bookings`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `bookings` (
`BookingNo` int(11) NOT NULL AUTO_INCREMENT,
`BookingDate` datetime DEFAULT NULL,
`Title` varchar(50) DEFAULT NULL,
`FirstName` varchar(50) DEFAULT NULL,
`Surname` varchar(50) DEFAULT NULL,
`Organisation` varchar(50) DEFAULT NULL,
`Address1` varchar(50) DEFAULT NULL,
`Address2` varchar(50) DEFAULT NULL,
`Address3` varchar(50) DEFAULT NULL,
`Address4` varchar(50) DEFAULT NULL,
`Postcode` varchar(50) DEFAULT NULL,
`Country` varchar(50) DEFAULT NULL,
`Telephone` varchar(50) DEFAULT NULL,
`Mobile` varchar(50) DEFAULT NULL,
`Email` varchar(100) DEFAULT NULL,
`HotelID` int(11) DEFAULT NULL,
`CreditCardType` varchar(50) DEFAULT NULL,
`CreditCardOther` varchar(50) DEFAULT NULL,
`NameOnCard` varchar(50) DEFAULT NULL,
`CreditCardNo` varchar(200) DEFAULT NULL,
`ExpiryMonth` varchar(2) DEFAULT NULL,
`ExpiryYear` varchar(2) DEFAULT NULL,
`AmountToCharge` double DEFAULT NULL,
`LastChange` datetime DEFAULT NULL,
`Cancelled` bit(1) DEFAULT b'0',
`DateCancelled` datetime DEFAULT NULL,
PRIMARY KEY (`BookingNo`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `bookings`
--
LOCK TABLES `bookings` WRITE;
/*!40000 ALTER TABLE `bookings` DISABLE KEYS */;
/*!40000 ALTER TABLE `bookings` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `countries_not_used`
--
DROP TABLE IF EXISTS `countries_not_used`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `countries_not_used` (
`CountryCode` int(11) DEFAULT NULL,
`CountryName` varchar(255) DEFAULT NULL
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `countries_not_used`
--
LOCK TABLES `countries_not_used` WRITE;
/*!40000 ALTER TABLE `countries_not_used` DISABLE KEYS */;
INSERT INTO `countries_not_used` VALUES (1,'France'),(3,'Netherlands'),(4,'Germany'),(5,'Italy'),(6,'United Kingdom'),(7,'Ireland'),(8,'Denmark'),(9,'Greece'),(10,'Portugal'),(11,'Spain'),(21,'Canary Islands'),(22,'Ceuta'),(24,'Iceland'),(25,'Faroe Islands'),(27,'Svalbard'),(28,'Norway'),(30,'Sweden'),(32,'Finland'),(37,'Liechtenstein'),(38,'Austria'),(39,'Switzerland'),(43,'Andorra'),(44,'Gibraltar'),(45,'Vatican City State'),(46,'Malta'),(47,'San Marino'),(52,'Turkey'),(53,'Estonia'),(54,'Latvia'),(55,'Lithuania'),(60,'Poland'),(61,'Czech Republic'),(63,'Slovakia'),(64,'Hungary'),(66,'Romania'),(68,'Bulgaria'),(70,'Albania'),(72,'Ukraine'),(73,'Belarus'),(74,'Moldova'),(75,'Russia'),(76,'Georgia'),(77,'Armenia'),(78,'Azerbaijan'),(79,'Kazakhstan'),(80,'Turkmenistan'),(81,'Uzbekistan'),(82,'Tajikistan'),(83,'Kyrgyzstan'),(85,'Channel Islands (UK)'),(91,'Slovenia'),(92,'Croatia'),(93,'Bosnia and Herzegovina'),(94,'Serbia'),(95,'Monaco'),(96,'Macedonia'),(97,'Yugoslavia'),(102,'Belgium'),(104,'Luxembourg'),(204,'Morocco'),(208,'Algeria'),(212,'Tunisia'),(216,'Libya'),(220,'Egypt'),(224,'Sudan'),(228,'Mauritania'),(232,'Mali'),(236,'Burkina Faso'),(240,'Niger'),(244,'Chad'),(247,'Cape Verde'),(248,'Senegal'),(252,'Gambia'),(257,'Guinea-Bissau'),(260,'Guinea'),(264,'Sierra Leone'),(268,'Liberia'),(272,'Cote d\'Ivoire'),(276,'Ghana'),(280,'Togo'),(284,'Benin'),(288,'Nigeria'),(302,'Cameroon'),(306,'Central African Republic'),(310,'Equatorial Guinea'),(311,'Sao Tome and Principe'),(314,'Gabon'),(318,'Congo, Democratic Republic'),(322,'Congo, Republic'),(324,'Rwanda'),(328,'Burundi'),(329,'St. Helena'),(330,'Angola'),(334,'Ethiopia'),(336,'Eritrea'),(338,'Djibouti'),(342,'Somalia'),(346,'Kenya'),(350,'Uganda'),(352,'Tanzania'),(355,'Seychelles'),(357,'British Indian Ocean Territory'),(366,'Mozambique'),(370,'Madagascar'),(372,'Reunion'),(373,'Mauritius'),(375,'Comoros'),(377,'Mayotte'),(378,'Zambia'),(382,'Zimbabwe'),(386,'Malawi'),(388,'South Africa'),(389,'Namibia'),(391,'Botswana'),(393,'Swaziland'),(395,'Lesotho'),(400,'USA'),(404,'Canada'),(406,'Greenland'),(408,'St. Pierre and Miquelon'),(412,'Mexico'),(413,'Bermuda'),(416,'Guatemala'),(421,'Belize'),(424,'Honduras'),(428,'El Salvador'),(432,'Nicaragua'),(436,'Costa Rica'),(442,'Panama'),(446,'Anguilla'),(448,'Cuba'),(449,'St. Kitts and Nevis'),(452,'Haiti'),(453,'Bahamas'),(454,'Turks and Caicos Islands'),(456,'Dominican Republic'),(457,'Virgin Islands (U.S.)'),(458,'Guadeloupe'),(459,'Antigua and Barbuda'),(460,'Dominica'),(462,'Martinique'),(463,'Cayman Islands'),(464,'Jamaica'),(465,'St. Lucia'),(467,'St. Vincent and the Grenadines'),(468,'Virgin Islands (British)'),(469,'Barbados'),(470,'Montserrat'),(472,'Trinidad and Tobago'),(473,'Grenada'),(474,'Aruba'),(478,'Netherlands Antilles'),(480,'Colombia'),(484,'Venezuela'),(488,'Guyana'),(492,'Suriname'),(496,'French Guiana'),(500,'Ecuador'),(504,'Peru'),(508,'Brazil'),(512,'Chile'),(516,'Bolivia'),(520,'Paraguay'),(524,'Uruguay'),(528,'Argentina'),(529,'Falkland Islands'),(600,'Cyprus'),(604,'Lebanon'),(608,'Syrian'),(612,'Iraq'),(616,'Iran'),(624,'Israel'),(628,'Jordan'),(632,'Saudi Arabia'),(636,'Kuwait'),(640,'Bahrain'),(644,'Qatar'),(647,'United Arab Emirates'),(649,'Oman'),(653,'Yemen'),(660,'Afghanistan'),(662,'Pakistan'),(664,'India'),(666,'Bangladesh'),(667,'Maldives'),(669,'Sri Lanka'),(672,'Nepal'),(675,'Bhutan'),(676,'Myanmar'),(680,'Thailand'),(684,'Laos'),(690,'Viet Nam'),(696,'Cambodia'),(700,'Indonesia'),(701,'Malaysia'),(703,'Brunei Darussalam'),(706,'Singapore'),(708,'Philippines'),(716,'Mongolia'),(720,'China'),(724,'Korea, North'),(728,'Korea, South'),(732,'Japan'),(736,'Taiwan'),(740,'Hong Kong'),(743,'Macau'),(800,'Australia'),(801,'Papua New Guinea'),(802,'Oceania'),(803,'Nauru'),(804,'New Zealand'),(806,'Solomon Islands'),(807,'Tuvalu'),(808,'American Oceanian Territories'),(809,'New Caledonia'),(810,'American Samoa'),(811,'Wallis and Futuna'),(812,'Kiribati'),(813,'Pitcairn Islands'),(814,'New Zealand\'s Oceania'),(815,'Fiji'),(816,'Vanuatu'),(817,'Tonga'),(819,'Samoa'),(820,'Northern Mariana Islands'),(822,'French Polynesia'),(823,'Micronesia'),(824,'Marshall Islands'),(825,'Palau');
/*!40000 ALTER TABLE `countries_not_used` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `editdetail`
--
DROP TABLE IF EXISTS `editdetail`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `editdetail` (
`EditID` varchar(12) NOT NULL,
`OrderNo` int(11) NOT NULL,
`FieldName` varchar(50) NOT NULL,
`PromptName` varchar(50) DEFAULT NULL,
`FieldType` varchar(1) DEFAULT NULL,
`EditType` varchar(3) DEFAULT NULL,
`ReadOnly` bit(1) DEFAULT b'0',
`LookupID` varchar(12) DEFAULT NULL,
`Width` int(11) DEFAULT NULL,
`Height` int(11) DEFAULT NULL,
`Required` bit(1) DEFAULT b'0',
`Validation` varchar(10) DEFAULT NULL,
`Picture` varchar(50) DEFAULT NULL,
PRIMARY KEY (`EditID`,`OrderNo`,`FieldName`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `editdetail`
--
LOCK TABLES `editdetail` WRITE;
/*!40000 ALTER TABLE `editdetail` DISABLE KEYS */;
INSERT INTO `editdetail` VALUES ('ARRIVALDATES',10,'ArrivalDate','','D','TXT','\0','',NULL,NULL,'',NULL,NULL),('CREDITTYPES',10,'CreditCardType','','S','TXT','\0','',NULL,NULL,'',NULL,NULL),('CREDITTYPES',20,'SortOrder','','N','TXT','\0','',NULL,NULL,'\0',NULL,NULL),('CREDITYEARS',10,'Year','','S','TXT','\0','',2,NULL,'',NULL,NULL),('HOTELROOMS',10,'HotelRoomID','','N','TXT','','',NULL,NULL,'\0',NULL,NULL),('HOTELROOMS',20,'HotelID','Hotel','N','TXT','\0','HOTELS',NULL,NULL,'',NULL,NULL),('HOTELROOMS',30,'DateAvailable','Date Available','D','TXT','\0','ARRIVALDATES',NULL,NULL,'',NULL,NULL),('HOTELROOMS',40,'RoomTypeID','Room Type','S','TXT','\0','ROOMTYPES',NULL,NULL,'',NULL,NULL),('HOTELROOMS',50,'RoomCost','Room Cost','N','TXT','\0','',NULL,NULL,'',NULL,NULL),('HOTELROOMS',60,'MaxAvailable','Max Available','N','TXT','\0','',NULL,NULL,'',NULL,NULL),('HOTELROOMS',70,'DisableWarning','','S','CMB','\0','YESNO',NULL,NULL,'\0',NULL,NULL),('HOTELS',10,'HotelName','','S','TXT','\0','',50,NULL,'',NULL,NULL),('HOTELS',20,'SortOrder','','N','TXT','\0','',NULL,NULL,'',NULL,NULL),('HOTELS',30,'FootNotes','','S','TXT','\0','',60,20,'\0',NULL,NULL),('NOOFNIGHTS',10,'NoOfNights','','N','TXT','\0','',NULL,NULL,'',NULL,NULL),('RESULTS',10,'Prize',NULL,'N','TXT','\0','',NULL,NULL,'',NULL,NULL),('RESULTS',20,'Ticket',NULL,'S','TXT','\0','',NULL,NULL,'',NULL,NULL),('RESULTS',30,'Winner','','S','TXT','\0','',NULL,NULL,'',NULL,NULL),('ROOMTYPES',10,'RoomType','','S','TXT','\0','',30,NULL,'',NULL,NULL),('ROOMTYPES',20,'SortOrder','','N','TXT','\0','',NULL,NULL,'',NULL,NULL),('USER',10,'UserID','User ID','S','TXT','\0','',NULL,NULL,'\0',NULL,'*!'),('USER',20,'Name','','S','TXT','\0','',NULL,NULL,'\0',NULL,NULL),('USER',30,'Password','','S','TXT','\0','',NULL,NULL,'\0',NULL,NULL),('USER',40,'Rights','','S','CMB','\0','RIGHTS',NULL,NULL,'\0',NULL,NULL),('SETTINGS',10,'ID',NULL,'N','TXT','',NULL,NULL,NULL,'',NULL,NULL),('SETTINGS',20,'ConferenceName','Conference Name','S','TXT','\0',NULL,60,NULL,'',NULL,NULL),('SETTINGS',30,'Subtitle1','Subtitle 1','S','TXT','\0',NULL,60,3,'\0',NULL,NULL),('SETTINGS',40,'Subtitle2','Subtitle 2','S','TXT','\0',NULL,60,3,'\0',NULL,NULL),('SETTINGS',50,'Subtitle3','Subtitle 3','S','TXT','\0',NULL,60,3,'\0',NULL,NULL),('SETTINGS',15,'BookingNoPrefix','Booking No Prefix','S','TXT','\0',NULL,10,NULL,'',NULL,'*&'),('SETTINGS',90,'AvailabilityMessage','Availability Message','S','TXT','\0',NULL,60,3,'\0',NULL,NULL),('SETTINGS',100,'RoomRateMessage','Room Rate Message','S','TXT','\0',NULL,60,3,'\0',NULL,NULL),('SETTINGS',110,'SpecialRequirementsMessage','Special Requirements <br>Message','S','TXT','\0',NULL,60,3,'\0',NULL,NULL),('SETTINGS',120,'CancellationMessage','Cancellation Message','S','TXT','\0',NULL,60,3,'\0',NULL,NULL),('SETTINGS',130,'CurrencyCode','Currency Code','S','TXT','\0',NULL,10,NULL,'',NULL,'*!'),('SETTINGS',200,'SiteClosed','Site Closed','S','CMB','\0','YESNO',NULL,NULL,'',NULL,NULL),('SETTINGS',150,'MaxRoomsPerBooking','Max Rooms Per Booking','N','TXT','\0',NULL,NULL,NULL,'',NULL,NULL),('SETTINGS',160,'OrganisationLabel','Organisation Label','S','TXT','\0',NULL,30,NULL,'\0',NULL,NULL),('SETTINGS',170,'OrganisationRequired','Organisation Required','S','CMB','\0','YESNO',NULL,NULL,'',NULL,NULL),('SETTINGS',180,'AddressEnabled','Address Enabled','S','CMB','\0','YESNO',NULL,NULL,'',NULL,NULL),('SETTINGS',190,'CreditCardEnabled','Credit Card Enabled','S','CMB','\0','YESNO',NULL,NULL,'',NULL,NULL),('HOTELS',0,'HotelID',NULL,'N','TXT','',NULL,NULL,NULL,'',NULL,NULL),('ROOMTYPES',0,'RoomTypeID',NULL,'N','TXT','',NULL,NULL,NULL,'',NULL,NULL),('SETTINGS',210,'EmailConfirmationHeader','Email Confirmation Header','S','TXT','\0',NULL,60,10,'\0',NULL,NULL),('SETTINGS',220,'EmailFooter','Email Footer','S','TXT','\0',NULL,60,10,'\0',NULL,NULL),('SETTINGS',140,'TotalCostSuffix','Total Cost Suffix','S','TXT','\0',NULL,NULL,NULL,'\0',NULL,NULL);
/*!40000 ALTER TABLE `editdetail` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `edits`
--
DROP TABLE IF EXISTS `edits`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `edits` (
`EditID` varchar(12) NOT NULL,
`TableName` varchar(50) DEFAULT NULL,
`KeyField` varchar(50) DEFAULT NULL,
`ShowAll` bit(1) DEFAULT NULL,
`AllowView` bit(1) DEFAULT NULL,
`AllowEdit` bit(1) DEFAULT NULL,
`AllowAdd` bit(1) DEFAULT NULL,
`AllowDelete` bit(1) DEFAULT NULL,
`AccessView` int(11) DEFAULT NULL,
`AccessEdit` int(11) DEFAULT NULL,
`AccessAdd` int(11) DEFAULT NULL,
`AccessDelete` int(11) DEFAULT NULL,
`ViewOrderBy` varchar(50) DEFAULT NULL,
`ViewTable` varchar(50) DEFAULT NULL,
PRIMARY KEY (`EditID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `edits`
--
LOCK TABLES `edits` WRITE;
/*!40000 ALTER TABLE `edits` DISABLE KEYS */;
INSERT INTO `edits` VALUES ('ARRIVALDATES','L_ArrivalDates','ArrivalDate','','','','','',0,0,0,0,'ArrivalDate',NULL),('BOOKINGS','Bookings','BookingID','','','','','',0,0,0,0,NULL,NULL),('CREDITTYPES','L_CreditCardTypes','CreditCardTYpe','','','','','',0,0,0,0,NULL,NULL),('CREDITYEARS','L_CreditCardYears','Year','','','','','',0,0,0,0,'Year',NULL),('DRAW','Draw','Draw','','','','','',0,9,9,9,NULL,NULL),('EVENTS','Events','EventID','','','','','',0,0,0,0,NULL,NULL),('HOTELROOMS','HotelRooms','HotelRoomID','','','','','',0,0,0,0,'HotelName, DateAvailable, RoomType','qryRoomsAvailable'),('HOTELS','Hotels','HotelID','','','','','',0,0,0,0,NULL,NULL),('NOOFNIGHTS','L_NoOfNights','NoOfNights','','','','','',0,0,0,0,NULL,NULL),('ORDERS','Orders','OrderNo','','','\0','\0','\0',0,0,0,0,NULL,NULL),('RESULTS','Results','ItemNo','','','','','',0,0,0,0,NULL,NULL),('ROOMTYPES','L_RoomTypes','RoomTypeID','','','','','',0,0,0,0,'RoomType',NULL),('USER','Users','UserID','','','','','',9,9,9,9,NULL,NULL),('SETTINGS','Settings','ID','','','','\0','\0',0,0,0,NULL,NULL,NULL);
/*!40000 ALTER TABLE `edits` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `editview`
--
DROP TABLE IF EXISTS `editview`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `editview` (
`EditID` varchar(12) NOT NULL,
`OrderNo` int(11) NOT NULL,
`FieldName` varchar(50) NOT NULL,
`PromptName` varchar(50) DEFAULT NULL,
`FieldType` varchar(1) DEFAULT NULL,
`Width` int(11) DEFAULT NULL,
`Link` bit(1) DEFAULT b'0',
PRIMARY KEY (`EditID`,`OrderNo`,`FieldName`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `editview`
--
LOCK TABLES `editview` WRITE;
/*!40000 ALTER TABLE `editview` DISABLE KEYS */;
INSERT INTO `editview` VALUES ('ARRIVALDATES',10,'ArrivalDate','','S',NULL,''),('CREDITTYPES',10,'CreditCardType','','S',NULL,''),('CREDITTYPES',20,'SortOrder','','N',NULL,'\0'),('CREDITYEARS',10,'Year','','S',2,''),('HOTELROOMS',10,'HotelRoomID','ID','N',NULL,''),('HOTELROOMS',20,'HotelName','Hotel Name','S',NULL,'\0'),('HOTELROOMS',30,'DateAvailable','Date Available','S',NULL,'\0'),('HOTELROOMS',40,'RoomType','Room Type','S',NULL,'\0'),('HOTELROOMS',50,'RoomCost','Room Cost','N',NULL,'\0'),('HOTELROOMS',60,'MaxAvailable','Max Available','N',NULL,'\0'),('HOTELROOMS',70,'Taken','','N',NULL,'\0'),('HOTELROOMS',80,'Remaining','','N',NULL,'\0'),('HOTELROOMS',90,'DisableWarning','','S',NULL,'\0'),('HOTELS',10,'HotelName','','S',NULL,''),('HOTELS',20,'SortOrder','','N',NULL,'\0'),('HOTELS',30,'FootNotes','','S',NULL,'\0'),('NOOFNIGHTS',10,'NoOfNights','','S',NULL,''),('ORDERS',10,'OrderNo','','N',NULL,'\0'),('ORDERS',20,'DateTime','','D',NULL,'\0'),('ORDERS',30,'Type','','S',NULL,'\0'),('ORDERS',40,'Description','','S',NULL,'\0'),('ORDERS',50,'Amount','','N',NULL,'\0'),('ORDERS',60,'Name','','S',NULL,'\0'),('ORDERS',70,'Address','','S',NULL,'\0'),('ORDERS',80,'Postcode','','S',NULL,'\0'),('ORDERS',90,'Country','','S',NULL,'\0'),('ORDERS',100,'Email','','S',NULL,'\0'),('ORDERS',110,'Telephone','','S',NULL,'\0'),('ORDERs',120,'OtherDetails','','S',NULL,'\0'),('SETTINGS',140,'TotalCostSuffix',NULL,'S',NULL,'\0'),('ROOMTYPES',10,'RoomType','','S',NULL,''),('ROOMTYPES',20,'SortOrder','','N',NULL,'\0'),('USER',10,'UserID','User ID','S',NULL,''),('USER',20,'Name','','S',NULL,'\0'),('USER',30,'Password','','S',NULL,'\0'),('USER',40,'Rights','','S',NULL,'\0'),('SETTINGS',10,'ID',NULL,'N',NULL,''),('SETTINGS',30,'ConferenceName',NULL,'S',NULL,''),('SETTINGS',40,'Subtitle1',NULL,'S',NULL,'\0'),('SETTINGS',50,'Subtitle2',NULL,'S',NULL,'\0'),('SETTINGS',60,'Subtitle3',NULL,'S',NULL,'\0'),('SETTINGS',20,'BookingNoPrefix',NULL,'S',NULL,''),('SETTINGS',90,'AvailabilityMessage',NULL,'S',NULL,'\0'),('SETTINGS',100,'RoomRateMessage',NULL,'S',NULL,'\0'),('SETTINGS',110,'SpecialRequirementsMessage',NULL,'S',NULL,'\0'),('SETTINGS',120,'CancellationMessage',NULL,'S',NULL,'\0'),('SETTINGS',130,'CurrencyCode',NULL,'S',NULL,'\0'),('SETTINGS',200,'SiteClosed',NULL,'S',NULL,'\0'),('SETTINGS',150,'MaxRoomsPerBooking',NULL,'N',NULL,'\0'),('SETTINGS',160,'OrganisationLabel',NULL,'S',NULL,'\0'),('SETTINGS',170,'OrganisationRequired',NULL,'S',NULL,'\0'),('SETTINGS',180,'AddressEnabled',NULL,'S',NULL,'\0'),('SETTINGS',190,'CreditCardEnabled',NULL,'S',NULL,'\0'),('HOTELS',0,'HotelID',NULL,'N',NULL,''),('ROOMTYPES',0,'RoomTypeID',NULL,'N',NULL,'');
/*!40000 ALTER TABLE `editview` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `hotelrooms`
--
DROP TABLE IF EXISTS `hotelrooms`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `hotelrooms` (
`HotelRoomID` int(11) NOT NULL AUTO_INCREMENT,
`HotelID` int(11) DEFAULT NULL COMMENT '(SS,6/12/14) replaced HotelName with HotelID',
`DateAvailable` date DEFAULT NULL,
`RoomTypeID` int(11) DEFAULT NULL COMMENT '(SS,6/12/14) replaced RoomType with RoomTypeID',
`RoomCost` double DEFAULT NULL,
`MaxAvailable` int(11) DEFAULT NULL,
`DisableWarning` enum('No','Yes') NOT NULL DEFAULT 'No',
PRIMARY KEY (`HotelRoomID`),
UNIQUE KEY `idxHotelIDDateAvailableRoomTypeID` (`HotelID`,`DateAvailable`,`RoomTypeID`)
) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `hotelrooms`
--
LOCK TABLES `hotelrooms` WRITE;
/*!40000 ALTER TABLE `hotelrooms` DISABLE KEYS */;
INSERT INTO `hotelrooms` VALUES (1,1,'2008-01-15',1,155,31,'No'),(2,1,'2008-01-16',1,155,32,'No'),(3,1,'2008-01-17',1,155,2,'No');
/*!40000 ALTER TABLE `hotelrooms` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `hotels`
--
DROP TABLE IF EXISTS `hotels`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `hotels` (
`HotelID` int(11) NOT NULL AUTO_INCREMENT,
`HotelName` varchar(50) DEFAULT NULL,
`SortOrder` int(11) DEFAULT NULL,
`FootNotes` mediumtext,
PRIMARY KEY (`HotelID`),
UNIQUE KEY `idxHotelName` (`HotelName`)
) ENGINE=MyISAM AUTO_INCREMENT=2 DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `hotels`
--
LOCK TABLES `hotels` WRITE;
/*!40000 ALTER TABLE `hotels` DISABLE KEYS */;
INSERT INTO `hotels` VALUES (1,'Meliá White House, London',1,'YOUR ACCOUNT IS TO BE SETTLED ON DEPARTURE, UNLESS PRIOR ARRANGEMENT HAS BEEN MADE.\r\nPlease note that the cancellation policy is 48 hours prior to arrival. Cancellations or amendments to your booking after this time may result in a 1 night\'s charge to your nominated credit card.\r\n\r\nMELIÁ WHITE HOUSE\r\nRegents Park\r\nAlbany Street\r\nLondon\r\nNW1 3UP');
/*!40000 ALTER TABLE `hotels` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `l_arrivaldates`
--
DROP TABLE IF EXISTS `l_arrivaldates`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `l_arrivaldates` (
`ArrivalDate` date NOT NULL,
PRIMARY KEY (`ArrivalDate`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `l_arrivaldates`
--
LOCK TABLES `l_arrivaldates` WRITE;
/*!40000 ALTER TABLE `l_arrivaldates` DISABLE KEYS */;
INSERT INTO `l_arrivaldates` VALUES ('2008-01-15'),('2008-01-16'),('2008-01-17');
/*!40000 ALTER TABLE `l_arrivaldates` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `l_creditcardmonths`
--
DROP TABLE IF EXISTS `l_creditcardmonths`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `l_creditcardmonths` (
`Month` char(2) NOT NULL,
PRIMARY KEY (`Month`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `l_creditcardmonths`
--
LOCK TABLES `l_creditcardmonths` WRITE;
/*!40000 ALTER TABLE `l_creditcardmonths` DISABLE KEYS */;
INSERT INTO `l_creditcardmonths` VALUES ('01'),('02'),('03'),('04'),('05'),('06'),('07'),('08'),('09'),('10'),('11'),('12');
/*!40000 ALTER TABLE `l_creditcardmonths` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `l_creditcardtypes`
--
DROP TABLE IF EXISTS `l_creditcardtypes`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `l_creditcardtypes` (
`CreditCardType` varchar(50) NOT NULL,
`SortOrder` int(11) DEFAULT NULL,
PRIMARY KEY (`CreditCardType`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `l_creditcardtypes`
--
LOCK TABLES `l_creditcardtypes` WRITE;
/*!40000 ALTER TABLE `l_creditcardtypes` DISABLE KEYS */;
INSERT INTO `l_creditcardtypes` VALUES ('AmExCard',3),('DinersClubCard',4),('MasterCard',2),('VisaCard',1);
/*!40000 ALTER TABLE `l_creditcardtypes` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `l_creditcardyears`
--
DROP TABLE IF EXISTS `l_creditcardyears`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `l_creditcardyears` (
`Year` smallint(6) NOT NULL,
PRIMARY KEY (`Year`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `l_creditcardyears`
--
LOCK TABLES `l_creditcardyears` WRITE;
/*!40000 ALTER TABLE `l_creditcardyears` DISABLE KEYS */;
INSERT INTO `l_creditcardyears` VALUES (14),(15),(16),(17),(18),(19),(20),(21),(22),(23),(24),(25),(26),(27),(28),(29),(30),(31),(32),(33),(34);
/*!40000 ALTER TABLE `l_creditcardyears` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `l_noofnights`
--
DROP TABLE IF EXISTS `l_noofnights`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `l_noofnights` (
`NoOfNights` smallint(6) NOT NULL,
PRIMARY KEY (`NoOfNights`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `l_noofnights`
--
LOCK TABLES `l_noofnights` WRITE;
/*!40000 ALTER TABLE `l_noofnights` DISABLE KEYS */;
INSERT INTO `l_noofnights` VALUES (1),(2),(3);
/*!40000 ALTER TABLE `l_noofnights` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `l_roomtypes`
--
DROP TABLE IF EXISTS `l_roomtypes`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `l_roomtypes` (
`RoomTypeID` int(11) NOT NULL AUTO_INCREMENT,
`RoomType` varchar(50) DEFAULT NULL,
`SortOrder` int(11) DEFAULT NULL,
PRIMARY KEY (`RoomTypeID`)
) ENGINE=MyISAM AUTO_INCREMENT=2 DEFAULT CHARSET=latin1 AVG_ROW_LENGTH=32;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `l_roomtypes`
--
LOCK TABLES `l_roomtypes` WRITE;
/*!40000 ALTER TABLE `l_roomtypes` DISABLE KEYS */;
INSERT INTO `l_roomtypes` VALUES (1,'Single Occupancy',10);
/*!40000 ALTER TABLE `l_roomtypes` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `l_yesno`
--
DROP TABLE IF EXISTS `l_yesno`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `l_yesno` (
`YesNo` char(20) NOT NULL,
PRIMARY KEY (`YesNo`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `l_yesno`
--
LOCK TABLES `l_yesno` WRITE;
/*!40000 ALTER TABLE `l_yesno` DISABLE KEYS */;
INSERT INTO `l_yesno` VALUES ('No'),('Yes');
/*!40000 ALTER TABLE `l_yesno` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `lookups`
--
DROP TABLE IF EXISTS `lookups`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `lookups` (
`LookupID` varchar(12) NOT NULL,
`Type` varchar(3) DEFAULT NULL,
`FieldName` varchar(50) DEFAULT NULL,
`DisplayFieldName` varchar(50) DEFAULT NULL COMMENT '(SS,6/12/14) added this field',
`TableName` varchar(50) DEFAULT NULL,
`Prompt` varchar(50) DEFAULT NULL,
`AllowBlank` bit(1) DEFAULT NULL,
PRIMARY KEY (`LookupID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `lookups`
--
LOCK TABLES `lookups` WRITE;
/*!40000 ALTER TABLE `lookups` DISABLE KEYS */;
INSERT INTO `lookups` VALUES ('ARRIVALDATES','L','ArrivalDate',NULL,'L_ArrivalDates',NULL,'\0'),('CREDITTYPES','L','CreditCardType',NULL,'L_CreditCardTypes',NULL,'\0'),('HOTELS','L','HotelID','HotelName','Hotels',NULL,'\0'),('NOOFNIGHTS','L','NoOfNights',NULL,'L_NoOfNights',NULL,'\0'),('RIGHTS','L','Rights',NULL,'Rights',NULL,'\0'),('ROOMTYPES','L','RoomTypeID','RoomType','L_RoomTypes',NULL,'\0'),('YESNO','L','YesNo',NULL,'L_YesNo',NULL,'\0');
/*!40000 ALTER TABLE `lookups` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Temporary table structure for view `qrybookingnightsavailablepersession`
--
DROP TABLE IF EXISTS `qrybookingnightsavailablepersession`;
/*!50001 DROP VIEW IF EXISTS `qrybookingnightsavailablepersession`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qrybookingnightsavailablepersession` (
`SessionID` int(11),
`HotelID` int(11),
`Date` date,
`RoomTypeID` int(11),
`Required` bigint(21),
`MaxAvailable` int(11),
`Remaining` bigint(21),
`RoomCost` double
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qrybookingnightsrequired`
--
DROP TABLE IF EXISTS `qrybookingnightsrequired`;
/*!50001 DROP VIEW IF EXISTS `qrybookingnightsrequired`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qrybookingnightsrequired` (
`SessionID` int(11),
`Date` date,
`RoomTypeID` int(11),
`Required` bigint(21),
`HotelID` int(11)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qrybookingnightstotal`
--
DROP TABLE IF EXISTS `qrybookingnightstotal`;
/*!50001 DROP VIEW IF EXISTS `qrybookingnightstotal`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qrybookingnightstotal` (
`HotelID` int(11),
`Date` date,
`Taken` bigint(21),
`RoomTypeID` int(11)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qrybookingtotalcost`
--
DROP TABLE IF EXISTS `qrybookingtotalcost`;
/*!50001 DROP VIEW IF EXISTS `qrybookingtotalcost`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qrybookingtotalcost` (
`BookingNo` int(11),
`TotalCost` double
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qryhotelguestlist`
--
DROP TABLE IF EXISTS `qryhotelguestlist`;
/*!50001 DROP VIEW IF EXISTS `qryhotelguestlist`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qryhotelguestlist` (
`Hotel` varchar(50),
`BookingNo` int(11),
`RoomNo` int(11),
`FullName` varchar(50),
`ArrivalDate` date,
`NoOfNights` smallint(6),
`RoomType` varchar(50),
`NonSmoking` bit(1),
`SharingWith` varchar(50),
`SpecialRequirements` varchar(50),
`Organisation` varchar(50),
`HotelID` int(11)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qryhotelsavailable`
--
DROP TABLE IF EXISTS `qryhotelsavailable`;
/*!50001 DROP VIEW IF EXISTS `qryhotelsavailable`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qryhotelsavailable` (
`HotelName` varchar(50),
`SortOrder` int(11),
`HotelID` int(11)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qryproblembookings`
--
DROP TABLE IF EXISTS `qryproblembookings`;
/*!50001 DROP VIEW IF EXISTS `qryproblembookings`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qryproblembookings` (
`BookingNo` int(11),
`RoomNo` int(11),
`Date` date,
`RoomTypeID` int(11),
`HotelID` int(11)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qryroomsavailable`
--
DROP TABLE IF EXISTS `qryroomsavailable`;
/*!50001 DROP VIEW IF EXISTS `qryroomsavailable`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qryroomsavailable` (
`HotelRoomID` int(11),
`HotelID` int(11),
`DateAvailable` date,
`RoomCost` double,
`MaxAvailable` int(11),
`Taken` bigint(21),
`Remaining` bigint(21),
`DisableWarning` enum('No','Yes'),
`HotelName` varchar(50),
`RoomTypeID` int(11),
`RoomType` varchar(50)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qryroomsavailabletotal`
--
DROP TABLE IF EXISTS `qryroomsavailabletotal`;
/*!50001 DROP VIEW IF EXISTS `qryroomsavailabletotal`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qryroomsavailabletotal` (
`HotelName` varchar(50),
`DateAvailable` date,
`MaxAvailable` decimal(32,0),
`Taken` decimal(41,0),
`Remaining` decimal(41,0),
`HotelID` int(11)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Temporary table structure for view `qryroomsavailablewarning`
--
DROP TABLE IF EXISTS `qryroomsavailablewarning`;
/*!50001 DROP VIEW IF EXISTS `qryroomsavailablewarning`*/;
SET @saved_cs_client = @@character_set_client;
SET character_set_client = utf8;
/*!50001 CREATE TABLE `qryroomsavailablewarning` (
`HotelRoomID` int(11),
`HotelID` int(11),
`DateAvailable` date,
`RoomTypeID` int(11),
`RoomCost` double,
`MaxAvailable` int(11),
`Taken` bigint(21),
`Remaining` bigint(21)
) ENGINE=MyISAM */;
SET character_set_client = @saved_cs_client;
--
-- Table structure for table `reports`
--
DROP TABLE IF EXISTS `reports`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `reports` (
`ReportNo` int(11) NOT NULL AUTO_INCREMENT,
`ReportName` varchar(70) DEFAULT NULL,
`ReportType` varchar(50) DEFAULT NULL,
`Lookup1` varchar(12) DEFAULT NULL,
`Lookup2` varchar(12) DEFAULT NULL,
`Lookup3` varchar(12) DEFAULT NULL,
`Lookup4` varchar(12) DEFAULT NULL,
`SQL` mediumtext,
PRIMARY KEY (`ReportNo`)
) ENGINE=MyISAM AUTO_INCREMENT=4 DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `reports`
--
LOCK TABLES `reports` WRITE;
/*!40000 ALTER TABLE `reports` DISABLE KEYS */;
INSERT INTO `reports` VALUES (1,'Hotel Guest Listing','LIST','HOTELS',NULL,NULL,NULL,'SELECT * FROM qryHotelGuestList WHERE HotelID=\"#HOTELS#\" ORDER BY ArrivalDate, BookingNo'),(2,'Bookings with Credit Card Details','LIST','HOTELS',NULL,NULL,NULL,'SELECT * FROM qryBookingsWithCreditCardDetails WHERE Hotel=\"#HOTELS#\"'),(3,'Guest Listing for All Hotels','LIST',NULL,NULL,NULL,NULL,'SELECT *\r\nFROM Bookings\r\nINNER JOIN BookingRooms ON Bookings.BookingNo = BookingRooms.BookingNo\r\nINNER JOIN Hotels ON Bookings.HotelID = Hotels.HotelID\r\nORDER BY Bookings.Surname, Bookings.FirstName;');
/*!40000 ALTER TABLE `reports` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `rights`
--
DROP TABLE IF EXISTS `rights`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `rights` (
`Rights` varchar(50) NOT NULL,
`AccessLevel` int(11) DEFAULT NULL,
PRIMARY KEY (`Rights`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `rights`
--
LOCK TABLES `rights` WRITE;
/*!40000 ALTER TABLE `rights` DISABLE KEYS */;
INSERT INTO `rights` VALUES ('ADMIN',9),('UPDATE',5),('VIEW',0);
/*!40000 ALTER TABLE `rights` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `settings`
--
DROP TABLE IF EXISTS `settings`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `settings` (
`ID` int(11) NOT NULL AUTO_INCREMENT,
`BookingNoPrefix` varchar(10) NOT NULL,
`ConferenceName` varchar(1000) NOT NULL,
`Subtitle1` varchar(1000) DEFAULT NULL,
`Subtitle2` varchar(1000) DEFAULT NULL,
`Subtitle3` varchar(1000) DEFAULT NULL,
`AvailabilityMessage` mediumtext,
`RoomRateMessage` mediumtext,
`SpecialRequirementsMessage` mediumtext,
`CancellationMessage` mediumtext,
`CurrencyCode` char(20) NOT NULL,
`TotalCostSuffix` varchar(50) DEFAULT NULL,
`MaxRoomsPerBooking` int(11) NOT NULL,
`OrganisationLabel` varchar(100) DEFAULT NULL,
`OrganisationRequired` enum('No','Yes') NOT NULL DEFAULT 'No',
`AddressEnabled` enum('No','Yes') NOT NULL DEFAULT 'Yes',
`CreditCardEnabled` enum('No','Yes') NOT NULL DEFAULT 'Yes',
`SiteClosed` enum('No','Yes') NOT NULL DEFAULT 'No',
`EmailConfirmationHeader` mediumtext,
`EmailFooter` mediumtext,
PRIMARY KEY (`ID`)
) ENGINE=MyISAM AUTO_INCREMENT=2 DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `settings`
--
LOCK TABLES `settings` WRITE;
/*!40000 ALTER TABLE `settings` DISABLE KEYS */;
INSERT INTO `settings` VALUES (1,'BAMA','Hotel booking for Blah Blah in Gobbledygook Week 2015','<b>Grosvenor Victoria</b>, 101 Buckingham Palace Road, London, SW1W 0SJ, <a href=\"http://www.guoman.com/en/hotels/united_kingdom/london/the_grosvenor_hotel/index.html\">Web</a>','<b>Rate: 175 GBP</b> per person per night including VAT, breakfast and WIFI','<br>Accommodation booking form','','This rate includes full English breakfast and VAT at the current rate 20%','NB if you would like to book accommodation for any additional nights, please note this <br> in the SPECIAL REQUIREMENTS section and Conference Search will contact you.','<b>Note: Cancellation charges will apply for rooms cancelled less than 48 hours<br>before the arrival date and for any non-arrivals.</b>','GBP','',20,'Organisation','No','Yes','Yes','No','We have received your hotel accommodation booking and would like you to check that the details you have provided are correct.\r\n\r\nPlease note that this is a GUARANTEED reservation, cancellations or amendments after the cancellation policy time which is specified below, will result in a minimum 1 nights charge to your nominated credit card.\r\n\r\nIf you have any changes, we would like to remind you that additional nights will be subject to availability and cannot be guaranteed.\r\n\r\nShould you have any problems regarding your accommodation booking, please contact the Conference Search office on: 0161 427 7057 or by e-mail: ruth@conferencesearch.co.uk\r\n','If you have any queries or would like to change\r\nyour booking. Please contact: \r\n\r\nRuth Thompson\r\nConference Search Ltd\r\n92 Church Lane\r\nMarple\r\nCheshire\r\nSK6 7AR, UK\r\n\r\nTel: +44 (0)161 427 7057\r\nFax: +44 (0)161 427 2415\r\n\r\nEmail: ruth@conferencesearch.co.uk\r\nWebsite: http://www.conferencesearch.co.uk\r\n');
/*!40000 ALTER TABLE `settings` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `users`
--
DROP TABLE IF EXISTS `users`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `users` (
`UserID` varchar(50) NOT NULL,
`Name` varchar(50) DEFAULT NULL,
`Password` varchar(50) DEFAULT NULL,
`Rights` varchar(50) DEFAULT NULL,
PRIMARY KEY (`UserID`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `users`
--
LOCK TABLES `users` WRITE;
/*!40000 ALTER TABLE `users` DISABLE KEYS */;
INSERT INTO `users` VALUES ('CSL','Conference Search','5e3a0cace54e29749f5ee8116f32774bbaec44da','ADMIN');
/*!40000 ALTER TABLE `users` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Dumping routines for database 'csl_bam1'
--
--
-- Current Database: `csl_bam1`
--
--
-- Final view structure for view `qrybookingnightsavailablepersession`
--
/*!50001 DROP TABLE IF EXISTS `qrybookingnightsavailablepersession`*/;
/*!50001 DROP VIEW IF EXISTS `qrybookingnightsavailablepersession`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qrybookingnightsavailablepersession` AS select `qrybookingnightsrequired`.`SessionID` AS `SessionID`,`qrybookingnightsrequired`.`HotelID` AS `HotelID`,`qrybookingnightsrequired`.`Date` AS `Date`,`qrybookingnightsrequired`.`RoomTypeID` AS `RoomTypeID`,`qrybookingnightsrequired`.`Required` AS `Required`,`qryroomsavailable`.`MaxAvailable` AS `MaxAvailable`,`qryroomsavailable`.`Remaining` AS `Remaining`,`qryroomsavailable`.`RoomCost` AS `RoomCost` from (`qrybookingnightsrequired` left join `qryroomsavailable` on(((`qrybookingnightsrequired`.`RoomTypeID` = `qryroomsavailable`.`RoomTypeID`) and (`qrybookingnightsrequired`.`Date` = `qryroomsavailable`.`DateAvailable`) and (`qrybookingnightsrequired`.`HotelID` = `qryroomsavailable`.`HotelID`)))) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qrybookingnightsrequired`
--
/*!50001 DROP TABLE IF EXISTS `qrybookingnightsrequired`*/;
/*!50001 DROP VIEW IF EXISTS `qrybookingnightsrequired`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qrybookingnightsrequired` AS select `bookingnightstemp`.`SessionID` AS `SessionID`,`bookingnightstemp`.`Date` AS `Date`,`bookingnightstemp`.`RoomTypeID` AS `RoomTypeID`,count(`bookingnightstemp`.`SessionID`) AS `Required`,`bookingnightstemp`.`HotelID` AS `HotelID` from `bookingnightstemp` group by `bookingnightstemp`.`SessionID`,`bookingnightstemp`.`Date`,`bookingnightstemp`.`RoomTypeID`,`bookingnightstemp`.`HotelID` */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qrybookingnightstotal`
--
/*!50001 DROP TABLE IF EXISTS `qrybookingnightstotal`*/;
/*!50001 DROP VIEW IF EXISTS `qrybookingnightstotal`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qrybookingnightstotal` AS select `bookingnights`.`HotelID` AS `HotelID`,`bookingnights`.`Date` AS `Date`,count(`bookingnights`.`BookingNo`) AS `Taken`,`bookingnights`.`RoomTypeID` AS `RoomTypeID` from `bookingnights` group by `bookingnights`.`HotelID`,`bookingnights`.`Date`,`bookingnights`.`RoomTypeID` */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qrybookingtotalcost`
--
/*!50001 DROP TABLE IF EXISTS `qrybookingtotalcost`*/;
/*!50001 DROP VIEW IF EXISTS `qrybookingtotalcost`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qrybookingtotalcost` AS select `bookingnights`.`BookingNo` AS `BookingNo`,sum(`hotelrooms`.`RoomCost`) AS `TotalCost` from (`bookingnights` join `hotelrooms` on(((`bookingnights`.`RoomTypeID` = `hotelrooms`.`RoomTypeID`) and (`bookingnights`.`Date` = `hotelrooms`.`DateAvailable`) and (`bookingnights`.`HotelID` = `hotelrooms`.`HotelID`)))) group by `bookingnights`.`BookingNo` */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qryhotelguestlist`
--
/*!50001 DROP TABLE IF EXISTS `qryhotelguestlist`*/;
/*!50001 DROP VIEW IF EXISTS `qryhotelguestlist`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qryhotelguestlist` AS select `hotels`.`HotelName` AS `Hotel`,`bookingrooms`.`BookingNo` AS `BookingNo`,`bookingrooms`.`RoomNo` AS `RoomNo`,`bookingrooms`.`FullName` AS `FullName`,`bookingrooms`.`ArrivalDate` AS `ArrivalDate`,`bookingrooms`.`NoOfNights` AS `NoOfNights`,`l_roomtypes`.`RoomType` AS `RoomType`,`bookingrooms`.`NonSmoking` AS `NonSmoking`,`bookingrooms`.`SharingWith` AS `SharingWith`,`bookingrooms`.`SpecialRequirements` AS `SpecialRequirements`,`bookings`.`Organisation` AS `Organisation`,`hotels`.`HotelID` AS `HotelID` from (((`bookings` join `bookingrooms` on((`bookings`.`BookingNo` = `bookingrooms`.`BookingNo`))) join `hotels` on((`hotels`.`HotelID` = `bookings`.`HotelID`))) join `l_roomtypes` on((`l_roomtypes`.`RoomTypeID` = `bookingrooms`.`RoomTypeID`))) order by `bookingrooms`.`FullName` */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qryhotelsavailable`
--
/*!50001 DROP TABLE IF EXISTS `qryhotelsavailable`*/;
/*!50001 DROP VIEW IF EXISTS `qryhotelsavailable`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qryhotelsavailable` AS select `qryroomsavailabletotal`.`HotelName` AS `HotelName`,`hotels`.`SortOrder` AS `SortOrder`,`qryroomsavailabletotal`.`HotelID` AS `HotelID` from (`qryroomsavailabletotal` join `hotels` on((`qryroomsavailabletotal`.`HotelID` = `hotels`.`HotelID`))) group by `qryroomsavailabletotal`.`HotelName`,`hotels`.`SortOrder`,`qryroomsavailabletotal`.`HotelID` having (sum(`qryroomsavailabletotal`.`Remaining`) > 0) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qryproblembookings`
--
/*!50001 DROP TABLE IF EXISTS `qryproblembookings`*/;
/*!50001 DROP VIEW IF EXISTS `qryproblembookings`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qryproblembookings` AS select `bookingnights`.`BookingNo` AS `BookingNo`,`bookingnights`.`RoomNo` AS `RoomNo`,`bookingnights`.`Date` AS `Date`,`bookingnights`.`RoomTypeID` AS `RoomTypeID`,`bookingnights`.`HotelID` AS `HotelID` from (`bookingnights` left join `hotelrooms` on(((`bookingnights`.`HotelID` = `hotelrooms`.`HotelID`) and (`bookingnights`.`RoomTypeID` = `hotelrooms`.`RoomTypeID`) and (`bookingnights`.`Date` = `hotelrooms`.`DateAvailable`)))) where isnull(`hotelrooms`.`HotelID`) */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qryroomsavailable`
--
/*!50001 DROP TABLE IF EXISTS `qryroomsavailable`*/;
/*!50001 DROP VIEW IF EXISTS `qryroomsavailable`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qryroomsavailable` AS select `hotelrooms`.`HotelRoomID` AS `HotelRoomID`,`hotelrooms`.`HotelID` AS `HotelID`,`hotelrooms`.`DateAvailable` AS `DateAvailable`,`hotelrooms`.`RoomCost` AS `RoomCost`,`hotelrooms`.`MaxAvailable` AS `MaxAvailable`,`qrybookingnightstotal`.`Taken` AS `Taken`,(`hotelrooms`.`MaxAvailable` - if(isnull(`qrybookingnightstotal`.`Taken`),0,`qrybookingnightstotal`.`Taken`)) AS `Remaining`,`hotelrooms`.`DisableWarning` AS `DisableWarning`,`hotels`.`HotelName` AS `HotelName`,`hotelrooms`.`RoomTypeID` AS `RoomTypeID`,`l_roomtypes`.`RoomType` AS `RoomType` from (((`hotelrooms` left join `qrybookingnightstotal` on(((`hotelrooms`.`HotelID` = `qrybookingnightstotal`.`HotelID`) and (`hotelrooms`.`DateAvailable` = `qrybookingnightstotal`.`Date`) and (`hotelrooms`.`RoomTypeID` = `qrybookingnightstotal`.`RoomTypeID`)))) join `hotels` on((`hotelrooms`.`HotelID` = `hotels`.`HotelID`))) join `l_roomtypes` on((`hotelrooms`.`RoomTypeID` = `l_roomtypes`.`RoomTypeID`))) order by `hotels`.`SortOrder`,`hotelrooms`.`DateAvailable`,`l_roomtypes`.`SortOrder` */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qryroomsavailabletotal`
--
/*!50001 DROP TABLE IF EXISTS `qryroomsavailabletotal`*/;
/*!50001 DROP VIEW IF EXISTS `qryroomsavailabletotal`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qryroomsavailabletotal` AS select `qryroomsavailable`.`HotelName` AS `HotelName`,`qryroomsavailable`.`DateAvailable` AS `DateAvailable`,sum(`qryroomsavailable`.`MaxAvailable`) AS `MaxAvailable`,sum(`qryroomsavailable`.`Taken`) AS `Taken`,sum(`qryroomsavailable`.`Remaining`) AS `Remaining`,`qryroomsavailable`.`HotelID` AS `HotelID` from `qryroomsavailable` group by `qryroomsavailable`.`HotelName`,`qryroomsavailable`.`DateAvailable`,`qryroomsavailable`.`HotelID` order by `qryroomsavailable`.`HotelName`,`qryroomsavailable`.`DateAvailable` */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
--
-- Final view structure for view `qryroomsavailablewarning`
--
/*!50001 DROP TABLE IF EXISTS `qryroomsavailablewarning`*/;
/*!50001 DROP VIEW IF EXISTS `qryroomsavailablewarning`*/;
/*!50001 SET @saved_cs_client = @@character_set_client */;
/*!50001 SET @saved_cs_results = @@character_set_results */;
/*!50001 SET @saved_col_connection = @@collation_connection */;
/*!50001 SET character_set_client = latin1 */;
/*!50001 SET character_set_results = latin1 */;
/*!50001 SET collation_connection = latin1_swedish_ci */;
/*!50001 CREATE ALGORITHM=UNDEFINED */
/*!50013 DEFINER=`csl_bam`@`%` SQL SECURITY DEFINER */
/*!50001 VIEW `qryroomsavailablewarning` AS select `hotelrooms`.`HotelRoomID` AS `HotelRoomID`,`hotelrooms`.`HotelID` AS `HotelID`,`hotelrooms`.`DateAvailable` AS `DateAvailable`,`hotelrooms`.`RoomTypeID` AS `RoomTypeID`,`hotelrooms`.`RoomCost` AS `RoomCost`,`hotelrooms`.`MaxAvailable` AS `MaxAvailable`,`qrybookingnightstotal`.`Taken` AS `Taken`,(`hotelrooms`.`MaxAvailable` - if(isnull(`qrybookingnightstotal`.`Taken`),0,`qrybookingnightstotal`.`Taken`)) AS `Remaining` from (((`hotelrooms` left join `qrybookingnightstotal` on(((`hotelrooms`.`RoomTypeID` = `qrybookingnightstotal`.`RoomTypeID`) and (`hotelrooms`.`DateAvailable` = `qrybookingnightstotal`.`Date`) and (`hotelrooms`.`HotelID` = `qrybookingnightstotal`.`HotelID`)))) join `hotels` on((`hotelrooms`.`HotelID` = `hotels`.`HotelID`))) join `l_roomtypes` on((`hotelrooms`.`RoomTypeID` = `l_roomtypes`.`RoomTypeID`))) where (`hotelrooms`.`DisableWarning` = 'No') order by `hotels`.`SortOrder`,`hotelrooms`.`DateAvailable`,`l_roomtypes`.`SortOrder` */;
/*!50001 SET character_set_client = @saved_cs_client */;
/*!50001 SET character_set_results = @saved_cs_results */;
/*!50001 SET collation_connection = @saved_col_connection */;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!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 */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2014-12-08 17:17:08