INSERT INTO salesanalysis (typeabbrev,
												periodno,
												amt,
												cost,
												cust,
												custbranch,
												qty,
												disc,
												stockid,
												area,
												budgetoractual,
												salesperson,
												stkcategory )
								SELECT 'DE',
										'94',
										'96',
										'0',
										'94',
										'99',
										'6',
										'0',
										'LM',
										custbranch.area,
										1,
										'Jhairud',
										stockmaster.categoryid
								FROM stockmaster, custbranch
								WHERE stockmaster.stockid = 'LM'
								AND custbranch.debtorno = '94'
								AND custbranch.branchcode='99'