-- phpMyAdmin SQL Dump
-- version 4.2.11
-- http://www.phpmyadmin.net
--
-- Host: 127.0.0.1
-- Generation Time: Aug 22, 2016 at 07:58 AM
-- Server version: 5.6.21
-- PHP Version: 5.6.3

SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
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 utf8 */;

--
-- Database: `nextbill`
--

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

--
-- Table structure for table `accesibility`
--

CREATE TABLE IF NOT EXISTS `accesibility` (
`ID` int(50) NOT NULL,
  `Login_ID` varchar(50) NOT NULL,
  `Login_Name` varchar(300) NOT NULL,
  `Login_Type` varchar(100) NOT NULL,
  `Email` varchar(100) NOT NULL,
  `Inventory_Master` tinyint(1) NOT NULL,
  `Account_Master` tinyint(1) NOT NULL,
  `Purchase` tinyint(1) NOT NULL,
  `Sales` tinyint(1) NOT NULL,
  `Tax` tinyint(1) NOT NULL,
  `Flat` tinyint(1) NOT NULL,
  `Entry` tinyint(1) NOT NULL,
  `Books` tinyint(1) NOT NULL,
  `Reports` tinyint(1) NOT NULL,
  `Delivery` tinyint(1) NOT NULL,
  `POrder` tinyint(1) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

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

--
-- Table structure for table `accountgroup`
--

CREATE TABLE IF NOT EXISTS `accountgroup` (
`ID` int(50) NOT NULL,
  `Group_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Group_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Under_Group` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Remarks` text COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=30 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

--
-- Dumping data for table `accountgroup`
--

INSERT INTO `accountgroup` (`ID`, `Group_ID`, `Group_Name`, `Under_Group`, `Remarks`) VALUES
(1, 'AG000001', 'BRANCH / DIVISION', 'BRANCH / DIVISIONS', 'BDA'),
(3, 'AG000003', 'CAPITAL ACCOUNT', 'CAPITAL ACCOUNT', 'CA'),
(4, 'AG000004', 'CURRENT ASSETS', 'CURRENT ASSETS', 'CASS'),
(5, 'AG000005', 'CURRENT LIABILITIES', 'CURRENT LIABILITIES', 'CL'),
(6, 'AG000006', 'DIRECT EXPENSES', 'DIRECT EXPENSES', 'DE'),
(7, 'AG000007', 'DIRECT INCOMES', 'DIRECT INCOMES', 'DI'),
(8, 'AG000008', 'FIXED ASSETS', 'FIXED ASSETS', 'FA'),
(9, 'AG000009', 'INDIRECT EXPENSES', 'INDIRECT EXPENSES', 'IE'),
(10, 'AG000010', 'INDIRECT INCOMES', 'INDIRECT INCOMES', 'II'),
(11, 'AG000011', 'INVESTMENTS', 'INVESTMENTS', 'IN'),
(12, 'AG000012', 'LOANS (LIABILITY)', 'LOANS (LIABILITY)', 'LL'),
(13, 'AG000013', 'MISC. EXPENSES (ASSET)', 'MISC. EXPENSES (ASSET)', 'MEA'),
(14, 'AG000014', 'PURCHASE ACCOUNTS', 'PURCHASE ACCOUNTS', 'PA'),
(15, 'AG000015', 'SALES ACCOUNTS', 'SALES ACCOUNTS', 'SA'),
(16, 'AG000016', 'SUSPENSE A/C', 'SUSPENSE A/C', 'SAC'),
(17, 'AG000017', 'BANK ACCOUNTS', 'CURRENT ASSETS', 'BA'),
(18, 'AG000018', 'BANK OD A/C', 'LOANS (LIABILITY)', 'BOAC'),
(19, 'AG000019', 'CASH-IN-HAND', 'CURRENT ASSETS', 'CIH'),
(20, 'AG000020', 'DEPOSITS (ASSET)', 'CURRENT ASSETS', 'DEP'),
(21, 'AG000021', 'DUTIES & TAXES', 'CURRENT LIABILITIES', 'DAT'),
(22, 'AG000022', 'LOANS & ADVANCES (ASSET)', 'CURRENT ASSETS', 'LAA'),
(23, 'AG000023', 'PROVISIONS', 'CURRENT LIABILITIES', 'PRO'),
(24, 'AG000024', 'RESERVES & SURPLUS', 'CAPITAL ACCOUNT', 'RAS'),
(25, 'AG000025', 'SECURED LOANS', 'LOANS (LIABILITY)', 'SL'),
(26, 'AG000026', 'STOCK-IN-HAND', 'CURRENT ASSETS', 'SIA'),
(27, 'AG000027', 'SUNDRY CREDITORS', 'CURRENT LIABILITIES', 'SC'),
(28, 'AG000028', 'SUNDRY DEBTORS', 'CURRENT ASSETS', 'SD'),
(29, 'AG000029', 'UNSECURED LOANS', 'LOANS (LIABILITY)', 'UL');

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

--
-- Table structure for table `barcodesetting`
--

CREATE TABLE IF NOT EXISTS `barcodesetting` (
`ID` int(50) NOT NULL,
  `Apply_Key` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Barcode_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Border_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Fore_Color` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Font_Family` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Font_Size` int(50) NOT NULL,
  `Bar_Width` double NOT NULL,
  `Bar_Height` double NOT NULL,
  `Show_Text` tinyint(1) NOT NULL,
  `Show_Border` tinyint(1) NOT NULL,
  `Show_Checksum` tinyint(1) NOT NULL,
  `Top_Text` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Unit` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Label_Width` double NOT NULL,
  `Label_Height` double NOT NULL,
  `Columns` int(50) NOT NULL,
  `Rows` int(50) NOT NULL,
  `Left_Gap` double NOT NULL,
  `Top_Gap` double NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

--
-- Dumping data for table `barcodesetting`
--

INSERT INTO `barcodesetting` (`ID`, `Apply_Key`, `Barcode_Type`, `Border_Type`, `Fore_Color`, `Font_Family`, `Font_Size`, `Bar_Width`, `Bar_Height`, `Show_Text`, `Show_Border`, `Show_Checksum`, `Top_Text`, `Unit`, `Label_Width`, `Label_Height`, `Columns`, `Rows`, `Left_Gap`, `Top_Gap`) VALUES
(1, 'ASD7K-ZGGCL-CWKH2-LZC28-38RN1', 'Codabar', 'Solid', 'Black', 'Verdana', 6, 0.6, 7, 1, 0, 0, 'NEXTSOFT', 'INCH', 1.969, 0.791, 4, 14, 0, 0.25);

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

--
-- Table structure for table `cloudsetting`
--

CREATE TABLE IF NOT EXISTS `cloudsetting` (
`ID` int(100) NOT NULL,
  `DataSource` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Username` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Password` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `DBName` varchar(100) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `company`
--

CREATE TABLE IF NOT EXISTS `company` (
`ID` int(50) NOT NULL,
  `Company_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Company_Name` varchar(200) COLLATE utf8_unicode_ci NOT NULL,
  `Contact_Person` varchar(200) COLLATE utf8_unicode_ci NOT NULL,
  `Phone` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Mobile` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Email` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Address` varchar(500) COLLATE utf8_unicode_ci NOT NULL,
  `Remark` varchar(500) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `currency`
--

CREATE TABLE IF NOT EXISTS `currency` (
`ID` int(10) NOT NULL,
  `Code` varchar(10) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `customer`
--

CREATE TABLE IF NOT EXISTS `customer` (
`ID` int(50) NOT NULL,
  `Customer_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Customer_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Organization_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Phone` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Mobile` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Email` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Address` text COLLATE utf8_unicode_ci NOT NULL,
  `Remark` text COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `damage`
--

CREATE TABLE IF NOT EXISTS `damage` (
`ID` int(50) NOT NULL,
  `Damage_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Date` date NOT NULL,
  `Barcode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Code` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `P_Rate` double NOT NULL,
  `No_Damage` double NOT NULL,
  `Loss_Amt` double NOT NULL,
  `Remarks` text COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `delivery`
--

CREATE TABLE IF NOT EXISTS `delivery` (
`ID` int(50) NOT NULL,
  `Bill_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Delivery_Date` date NOT NULL,
  `Delivery_Time` time NOT NULL,
  `Party_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Email` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Mobile` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Address` text COLLATE utf8_unicode_ci NOT NULL,
  `Total_Item` int(50) NOT NULL,
  `Total_Amt` double NOT NULL,
  `Status` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `DeliveredOn` datetime NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `emailsetting`
--

CREATE TABLE IF NOT EXISTS `emailsetting` (
`ID` int(50) NOT NULL,
  `SmtpServer_Name` varchar(100) NOT NULL,
  `EMail_From` varchar(100) NOT NULL,
  `Credentials_Email` varchar(100) NOT NULL,
  `Credentials_Password` varchar(100) NOT NULL,
  `Smtp_Port` varchar(100) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

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

--
-- Table structure for table `entry`
--

CREATE TABLE IF NOT EXISTS `entry` (
`ID` int(50) NOT NULL,
  `Voucher_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Voucher_Date` date NOT NULL,
  `Voucher_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Day` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Ledger_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Open_Bal` double NOT NULL,
  `Open_BalType` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Cr_Amt` double NOT NULL,
  `Dr_Amt` double NOT NULL,
  `Closing_Bal` double NOT NULL,
  `Closing_BalType` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Narration` text COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `expense`
--

CREATE TABLE IF NOT EXISTS `expense` (
`ID` int(50) NOT NULL,
  `ExpenseID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Date` date NOT NULL,
  `Expense_Head` varchar(200) COLLATE utf8_unicode_ci NOT NULL,
  `Mode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Mode_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Bank_Name` varchar(200) COLLATE utf8_unicode_ci NOT NULL,
  `Mode_Date` date NOT NULL,
  `Amt` double NOT NULL,
  `Remarks` text COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `expensehead`
--

CREATE TABLE IF NOT EXISTS `expensehead` (
`ID` int(50) NOT NULL,
  `HeadID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Expense_Head` varchar(200) COLLATE utf8_unicode_ci NOT NULL,
  `Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `generateid`
--

CREATE TABLE IF NOT EXISTS `generateid` (
`ID` int(50) NOT NULL,
  `SalesInvoice` int(100) NOT NULL,
  `ItemGroup` int(100) NOT NULL,
  `Item` int(100) NOT NULL,
  `Vendor` int(100) NOT NULL,
  `Company` int(100) NOT NULL,
  `Damage` int(100) NOT NULL,
  `Offer` int(100) NOT NULL,
  `AccGroup` int(100) NOT NULL,
  `Ledger` int(100) NOT NULL,
  `Customer` int(100) NOT NULL,
  `SaleTax` int(100) NOT NULL,
  `PurchaseTax` int(100) NOT NULL,
  `Voucher` int(100) NOT NULL,
  `PurchaseOrder` int(100) NOT NULL,
  `DebitNote` int(100) NOT NULL,
  `CreditNote` int(100) NOT NULL,
  `ExpHead` int(100) NOT NULL,
  `ExpID` int(100) NOT NULL
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

--
-- Dumping data for table `generateid`
--

INSERT INTO `generateid` (`ID`, `SalesInvoice`, `ItemGroup`, `Item`, `Vendor`, `Company`, `Damage`, `Offer`, `AccGroup`, `Ledger`, `Customer`, `SaleTax`, `PurchaseTax`, `Voucher`, `PurchaseOrder`, `DebitNote`, `CreditNote`, `ExpHead`, `ExpID`) VALUES
(1, 0, 0, 0, 0, 0, 0, 0, 29, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

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

--
-- Table structure for table `item`
--

CREATE TABLE IF NOT EXISTS `item` (
`ID` int(50) NOT NULL,
  `Barcode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Code` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Company_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Unit` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Stock` double NOT NULL,
  `Rack` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Group_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `P_Rate` double NOT NULL,
  `S_Rate` double NOT NULL,
  `MRP` double NOT NULL,
  `Reorder` double NOT NULL,
  `Tax_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Per` double NOT NULL,
  `Barcode_Img` longblob NOT NULL,
  `Tax_Included` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Box_Pack` int(100) NOT NULL,
  `PCode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `SCode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Color` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Size` varchar(100) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `itemgroup`
--

CREATE TABLE IF NOT EXISTS `itemgroup` (
`ID` int(50) NOT NULL,
  `Group_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Group_Name` varchar(200) COLLATE utf8_unicode_ci NOT NULL,
  `Description` varchar(500) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `ledger`
--

CREATE TABLE IF NOT EXISTS `ledger` (
`ID` int(50) NOT NULL,
  `Ledger_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Ledger_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Place` varchar(200) COLLATE utf8_unicode_ci NOT NULL,
  `Group_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Credit_Limit` double NOT NULL,
  `Contact_Person` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Designation` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Email` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Phone` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Mobile` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Address` text COLLATE utf8_unicode_ci NOT NULL,
  `Website` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Account_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `TIN_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `TExp_Date` date NOT NULL,
  `PAN_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `ST_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `SExp_Date` date NOT NULL,
  `Bank_Name` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Open_Bal` double NOT NULL,
  `Bal_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Remarks` text COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `login`
--

CREATE TABLE IF NOT EXISTS `login` (
`ID` int(50) NOT NULL,
  `Reg_Date` varchar(200) NOT NULL,
  `Login_ID` varchar(100) NOT NULL,
  `Login_Name` varchar(100) NOT NULL,
  `Login_Type` varchar(100) NOT NULL,
  `Email` varchar(100) NOT NULL,
  `Password` varchar(8) NOT NULL,
  `Login_Status` varchar(100) NOT NULL,
  `Phone` varchar(50) NOT NULL,
  `Mobile` varchar(50) NOT NULL,
  `Country` varchar(300) NOT NULL,
  `State` varchar(300) NOT NULL,
  `City` varchar(300) NOT NULL,
  `Address` varchar(300) NOT NULL,
  `Account_Status` varchar(50) NOT NULL,
  `Last_Login` datetime NOT NULL,
  `Serial_Key` varchar(100) NOT NULL,
  `Exp_Date` text NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=latin1;

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

--
-- Table structure for table `offer`
--

CREATE TABLE IF NOT EXISTS `offer` (
`ID` int(50) NOT NULL,
  `Offer_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Offer_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Lower_Value` double NOT NULL,
  `Upper_Value` double NOT NULL,
  `Free_Value` double NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `printsetting`
--

CREATE TABLE IF NOT EXISTS `printsetting` (
`ID` int(50) NOT NULL,
  `Print_Format` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Header_Line_1` text COLLATE utf8_unicode_ci NOT NULL,
  `Header_Line_2` text COLLATE utf8_unicode_ci NOT NULL,
  `Footer_Line` text COLLATE utf8_unicode_ci NOT NULL,
  `Footer_Line_2` text COLLATE utf8_unicode_ci NOT NULL,
  `Logo` longblob NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `purchaseinvoice`
--

CREATE TABLE IF NOT EXISTS `purchaseinvoice` (
`ID` int(50) NOT NULL,
  `Invoice_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Invoice_Date` date NOT NULL,
  `Vendor_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Purchase_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Address` varchar(500) COLLATE utf8_unicode_ci NOT NULL,
  `Barcode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Code` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Unit` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Qty` double NOT NULL,
  `Free_Qty` double NOT NULL,
  `P_Rate` double NOT NULL,
  `S_Rate` double NOT NULL,
  `MRP` double NOT NULL,
  `Item_Amt` double NOT NULL,
  `Dis_Amt` double NOT NULL,
  `Tax_Amt` double NOT NULL,
  `Total_Amt` double NOT NULL,
  `Total_Value` double NOT NULL,
  `Total_Dis` double NOT NULL,
  `Total_Tax` double NOT NULL,
  `Total_Bill` double NOT NULL,
  `Ex_Dis_Per` double NOT NULL,
  `Ex_Dis_Amt` double NOT NULL,
  `Gross_Bill` double NOT NULL,
  `Remark` varchar(500) COLLATE utf8_unicode_ci NOT NULL,
  `Vendor_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Login_Name` varchar(100) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `purchaseorder`
--

CREATE TABLE IF NOT EXISTS `purchaseorder` (
`ID` int(50) NOT NULL,
  `Order_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Order_Date` date NOT NULL,
  `Vendor_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Address` text COLLATE utf8_unicode_ci NOT NULL,
  `Mobile` varchar(50) COLLATE utf8_unicode_ci NOT NULL,
  `Email` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Barcode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Avail_Qty` int(100) NOT NULL,
  `Order_Qty` int(100) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `purchasereturn`
--

CREATE TABLE IF NOT EXISTS `purchasereturn` (
`ID` int(50) NOT NULL,
  `DN_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Invoice_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Return_Date` date NOT NULL,
  `Vendor_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Purchase_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Address` varchar(500) COLLATE utf8_unicode_ci NOT NULL,
  `Barcode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Code` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Unit` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Qty_Ret` double NOT NULL,
  `Free_Qty` double NOT NULL,
  `P_Rate` double NOT NULL,
  `S_Rate` double NOT NULL,
  `MRP` double NOT NULL,
  `Item_Amt` double NOT NULL,
  `Ded_Amt` double NOT NULL,
  `Tax_Amt` double NOT NULL,
  `Total_Amt` double NOT NULL,
  `Total_Value` double NOT NULL,
  `Total_Ded` double NOT NULL,
  `Total_Tax` double NOT NULL,
  `Total_Refund` double NOT NULL,
  `Ex_Ded_Per` double NOT NULL,
  `Ex_Ded_Amt` double NOT NULL,
  `Gross_Refund` double NOT NULL,
  `Remark` varchar(500) COLLATE utf8_unicode_ci NOT NULL,
  `Login_Name` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Vendor_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `purchasetax`
--

CREATE TABLE IF NOT EXISTS `purchasetax` (
`ID` int(50) NOT NULL,
  `PurchaseTax_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Per` double NOT NULL,
  `Purchase_Group` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Purchase_Ledger` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Group` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Ledger` varchar(300) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `salesinvoice`
--

CREATE TABLE IF NOT EXISTS `salesinvoice` (
`ID` int(50) NOT NULL,
  `Bill_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Party_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Sales_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Bill_Date` date NOT NULL,
  `Email` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Mobile` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Barcode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Code` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `MRP` double NOT NULL,
  `Qty` double NOT NULL,
  `S_Rate` double NOT NULL,
  `Item_Amt` double NOT NULL,
  `Dis_Amt` double NOT NULL,
  `Tax_Amt` double NOT NULL,
  `Total_Amt` double NOT NULL,
  `Total_Value` double NOT NULL,
  `Total_Dis` double NOT NULL,
  `Total_Tax` double NOT NULL,
  `Total_Bill` double NOT NULL,
  `Ex_Dis_Per` double NOT NULL,
  `Ex_Dis_Amt` double NOT NULL,
  `Gross_Bill` double NOT NULL,
  `Remark` varchar(500) COLLATE utf8_unicode_ci NOT NULL,
  `Cash_Received` double NOT NULL,
  `Login_Name` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Customer_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `P_Rate` double(10,2) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `salesreturn`
--

CREATE TABLE IF NOT EXISTS `salesreturn` (
`ID` int(50) NOT NULL,
  `CN_No` varchar(50) COLLATE utf8_unicode_ci NOT NULL,
  `Bill_No` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Party_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Return_Date` date NOT NULL,
  `Sales_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Type` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Barcode` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Code` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Item_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `MRP` double NOT NULL,
  `Qty_Ret` double NOT NULL,
  `S_Rate` double NOT NULL,
  `Item_Amt` double NOT NULL,
  `Ded_Amt` double NOT NULL,
  `Tax_Amt` double NOT NULL,
  `Total_Amt` double NOT NULL,
  `Total_Value` double NOT NULL,
  `Total_Ded` double NOT NULL,
  `Total_Tax` double NOT NULL,
  `Total_Refund` double NOT NULL,
  `Ex_Ded_Per` double NOT NULL,
  `Ex_Ded_Amt` double NOT NULL,
  `Gross_Refund` double NOT NULL,
  `Remark` varchar(500) COLLATE utf8_unicode_ci NOT NULL,
  `Login_Name` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Customer_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `saletax`
--

CREATE TABLE IF NOT EXISTS `saletax` (
`ID` int(50) NOT NULL,
  `SaleTax_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Name` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Per` double NOT NULL,
  `Sale_Group` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Sale_Ledger` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Group` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Tax_Ledger` varchar(300) COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `smsconfig`
--

CREATE TABLE IF NOT EXISTS `smsconfig` (
`ID` int(100) NOT NULL,
  `Username` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Password` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Mask` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Def` tinyint(1) NOT NULL,
  `Host` text COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `stockinhand`
--

CREATE TABLE IF NOT EXISTS `stockinhand` (
`ID` int(50) NOT NULL,
  `Date` date NOT NULL,
  `OpenStock` double NOT NULL,
  `Purchase` double NOT NULL,
  `Sales` double NOT NULL,
  `PurchaseReturn` double NOT NULL,
  `SalesReturn` double NOT NULL,
  `ClosingStock` double NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

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

--
-- Table structure for table `vendor`
--

CREATE TABLE IF NOT EXISTS `vendor` (
`ID` int(50) NOT NULL,
  `Vendor_ID` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Vendor_Name` varchar(200) COLLATE utf8_unicode_ci NOT NULL,
  `Contact_Person` varchar(300) COLLATE utf8_unicode_ci NOT NULL,
  `Phone` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Mobile` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Email` varchar(100) COLLATE utf8_unicode_ci NOT NULL,
  `Address` text COLLATE utf8_unicode_ci NOT NULL,
  `Remark` text COLLATE utf8_unicode_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;

--
-- Indexes for dumped tables
--

--
-- Indexes for table `accesibility`
--
ALTER TABLE `accesibility`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `accountgroup`
--
ALTER TABLE `accountgroup`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `barcodesetting`
--
ALTER TABLE `barcodesetting`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `cloudsetting`
--
ALTER TABLE `cloudsetting`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `company`
--
ALTER TABLE `company`
 ADD PRIMARY KEY (`ID`), ADD UNIQUE KEY `Company_Name` (`Company_Name`);

--
-- Indexes for table `currency`
--
ALTER TABLE `currency`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `customer`
--
ALTER TABLE `customer`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `damage`
--
ALTER TABLE `damage`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `delivery`
--
ALTER TABLE `delivery`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `emailsetting`
--
ALTER TABLE `emailsetting`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `entry`
--
ALTER TABLE `entry`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `expense`
--
ALTER TABLE `expense`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `expensehead`
--
ALTER TABLE `expensehead`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `generateid`
--
ALTER TABLE `generateid`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `item`
--
ALTER TABLE `item`
 ADD PRIMARY KEY (`ID`), ADD UNIQUE KEY `Item_Code` (`Item_Code`);

--
-- Indexes for table `itemgroup`
--
ALTER TABLE `itemgroup`
 ADD PRIMARY KEY (`ID`), ADD UNIQUE KEY `Group_ID` (`Group_ID`);

--
-- Indexes for table `ledger`
--
ALTER TABLE `ledger`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `login`
--
ALTER TABLE `login`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `offer`
--
ALTER TABLE `offer`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `printsetting`
--
ALTER TABLE `printsetting`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `purchaseinvoice`
--
ALTER TABLE `purchaseinvoice`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `purchaseorder`
--
ALTER TABLE `purchaseorder`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `purchasereturn`
--
ALTER TABLE `purchasereturn`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `purchasetax`
--
ALTER TABLE `purchasetax`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `salesinvoice`
--
ALTER TABLE `salesinvoice`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `salesreturn`
--
ALTER TABLE `salesreturn`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `saletax`
--
ALTER TABLE `saletax`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `smsconfig`
--
ALTER TABLE `smsconfig`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `stockinhand`
--
ALTER TABLE `stockinhand`
 ADD PRIMARY KEY (`ID`);

--
-- Indexes for table `vendor`
--
ALTER TABLE `vendor`
 ADD PRIMARY KEY (`ID`), ADD UNIQUE KEY `Vendor_Name` (`Vendor_Name`);

--
-- AUTO_INCREMENT for dumped tables
--

--
-- AUTO_INCREMENT for table `accesibility`
--
ALTER TABLE `accesibility`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `accountgroup`
--
ALTER TABLE `accountgroup`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=30;
--
-- AUTO_INCREMENT for table `barcodesetting`
--
ALTER TABLE `barcodesetting`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=2;
--
-- AUTO_INCREMENT for table `cloudsetting`
--
ALTER TABLE `cloudsetting`
MODIFY `ID` int(100) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `company`
--
ALTER TABLE `company`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `currency`
--
ALTER TABLE `currency`
MODIFY `ID` int(10) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `customer`
--
ALTER TABLE `customer`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `damage`
--
ALTER TABLE `damage`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `delivery`
--
ALTER TABLE `delivery`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `emailsetting`
--
ALTER TABLE `emailsetting`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `entry`
--
ALTER TABLE `entry`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `expense`
--
ALTER TABLE `expense`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `expensehead`
--
ALTER TABLE `expensehead`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `generateid`
--
ALTER TABLE `generateid`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT,AUTO_INCREMENT=2;
--
-- AUTO_INCREMENT for table `item`
--
ALTER TABLE `item`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `itemgroup`
--
ALTER TABLE `itemgroup`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `ledger`
--
ALTER TABLE `ledger`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `login`
--
ALTER TABLE `login`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `offer`
--
ALTER TABLE `offer`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `printsetting`
--
ALTER TABLE `printsetting`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `purchaseinvoice`
--
ALTER TABLE `purchaseinvoice`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `purchaseorder`
--
ALTER TABLE `purchaseorder`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `purchasereturn`
--
ALTER TABLE `purchasereturn`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `purchasetax`
--
ALTER TABLE `purchasetax`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `salesinvoice`
--
ALTER TABLE `salesinvoice`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `salesreturn`
--
ALTER TABLE `salesreturn`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `saletax`
--
ALTER TABLE `saletax`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `smsconfig`
--
ALTER TABLE `smsconfig`
MODIFY `ID` int(100) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `stockinhand`
--
ALTER TABLE `stockinhand`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
--
-- AUTO_INCREMENT for table `vendor`
--
ALTER TABLE `vendor`
MODIFY `ID` int(50) NOT NULL AUTO_INCREMENT;
/*!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 */;
