亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? weeksql.cpp

?? 銷售分析,JUSCO,日月周查詢,待完善.
?? CPP
?? 第 1 頁 / 共 2 頁
字號:

void __fastcall Tsumm::suiDBComboBox2DblClick(TObject *Sender)
{
AnsiString str;
if (flag==1){
 str="select store,weeklastd ,itmaster.dept_code,itmaster.section_code,itmaster.article_code,itmaster.vendor_code,sellweek.item_code,itmaster.item_desc ,quantity, customs,round((SELL/customs),2) as price , sell   FROM sellweek left join itmaster on sellweek.item_code=itmaster.item_code" ;
str=str+" where quantity<>0 and weeklastd >=# "+StrToDate(DateTimePicker1->Date.DateString())+"# and weeklastd <=#"+StrToDate(DateTimePicker2->Date.DateString())+"#" ;
 if(!suiComboBox1->Text.IsEmpty()){
str=str+" and store='"+suiComboBox1->Text.Trim()+"' ";
}
}
if (flag==2){
str="select store,itmaster.dept_code,itmaster.section_code,itmaster.article_code,itmaster.vendor_code,sellweek.item_code,itmaster.item_desc,stock_onhand ,SUM(quantity) AS quantities ,SUM(customs) AS allcustoms ,itmaster.price ,SUM(SELL) as total  FROM sellweek left join itmaster on sellweek.item_code=itmaster.item_code" ;
str=str+" where weeklastd >=#"+StrToDate(DateTimePicker1->Date.DateString())+"# and weeklastd <=#"+StrToDate(DateTimePicker2->Date.DateString())+"#    ";
 if(!suiComboBox1->Text.IsEmpty()){
str=str+" and store='"+suiComboBox1->Text.Trim()+"' ";
}
}

if(! suiDBComboBox2->Text.IsEmpty()&&suiDBComboBox2->Text.Length()==3){
str=str+" and itmaster.section_code='"+suiDBComboBox2->Text.Trim()+"'";
tempstr=str;
 if (flag==2){
  if ( suiRadioButton2->Checked)
str=str+"  group by store,article_code,itmaster.dept_code,itmaster.section_code,sellweek.item_code,itmaster.vendor_code,itmaster.item_desc,price,stock_onhand  order by SUM(SELL) desc  " ;
else
str=str+"  group by store,article_code,itmaster.dept_code,itmaster.section_code,sellweek.item_code,itmaster.vendor_code,itmaster.item_desc,price,stock_onhand order by SUM(quantity) desc ";

}



 try{
dm->dayseq->Active=false;
dm->dayseq->SQL->Clear();
dm->dayseq->SQL->Add(str);
 dm->dayseq->Active=true;
 }
 catch(...){
 dm->dayseq->Active=false;
 }




 suiDBComboBox1->Text=dm->dayseq->FieldByName("dept_code")->AsString;
 suiDBComboBox3->Text="";
 suiEdit1->Text="";

suiStatusBar1->SimpleText="  查詢時間從"+DateTimePicker1->Date.DateString()+"至"+DateTimePicker2->Date.DateString()+"  庫存為本店庫存";;

 }       
}
//---------------------------------------------------------------------------

void __fastcall Tsumm::suiDBComboBox3DblClick(TObject *Sender)
{
 AnsiString str;
if (flag==1){
 str="select store,weeklastd ,itmaster.dept_code,itmaster.section_code,itmaster.article_code,itmaster.vendor_code,sellweek.item_code,itmaster.item_desc ,quantity, customs,round((SELL/customs),2) as price , sell   FROM sellweek left join itmaster on sellweek.item_code=itmaster.item_code" ;
str=str+" where quantity<>0 and weeklastd >=# "+StrToDate(DateTimePicker1->Date.DateString())+"# and weeklastd <=#"+StrToDate(DateTimePicker2->Date.DateString())+"#" ;
 if(!suiComboBox1->Text.IsEmpty()){
str=str+" and store='"+suiComboBox1->Text.Trim()+"' ";
}
}
if (flag==2){
str="select store,itmaster.dept_code,itmaster.section_code,itmaster.article_code,itmaster.vendor_code,sellweek.item_code,itmaster.item_desc,stock_onhand ,SUM(quantity) AS quantities ,SUM(customs) AS allcustoms ,itmaster.price ,SUM(SELL) as total  FROM sellweek left join itmaster on sellweek.item_code=itmaster.item_code" ;
str=str+" where weeklastd >=#"+StrToDate(DateTimePicker1->Date.DateString())+"# and weeklastd <=#"+StrToDate(DateTimePicker2->Date.DateString())+"#    ";
 if(!suiComboBox1->Text.IsEmpty()){
str=str+" and store='"+suiComboBox1->Text.Trim()+"' ";
}
}


if(!suiDBComboBox3->Text.IsEmpty()&&suiDBComboBox3->Text.Length()==4){
str=str+ " and itmaster.article_code='"+suiDBComboBox3->Text.Trim()+"'";
 tempstr=str;
if (flag==2){
  if ( suiRadioButton2->Checked)
str=str+"  group by  store,article_code,itmaster.dept_code,itmaster.section_code,sellweek.item_code,itmaster.vendor_code,itmaster.item_desc,price,stock_onhand  order by SUM(SELL) desc  " ;
else
str=str+"  group by store,article_code,itmaster.dept_code,itmaster.section_code,sellweek.item_code,itmaster.vendor_code,itmaster.item_desc,price,stock_onhand order by SUM(quantity) desc ";

}

  ShowMessage(str);

 try{
dm->dayseq->Active=false;
dm->dayseq->SQL->Clear();
dm->dayseq->SQL->Add(str);
 dm->dayseq->Active=true;
 }
 catch(...){
 dm->dayseq->Active=false;
 }


suiDBComboBox1->Text=dm->dayseq->FieldByName("dept_code")->AsString;
suiDBComboBox2->Text=dm->dayseq->FieldByName("section_code")->AsString;
suiEdit1->Text=""  ;

suiStatusBar1->SimpleText=" 查詢時間從"+DateTimePicker1->Date.DateString()+"至"+DateTimePicker2->Date.DateString()+"  庫存為本店庫存";;


}
}
//---------------------------------------------------------------------------

void __fastcall Tsumm::suiEdit1DblClick(TObject *Sender)
{
  AnsiString str;
if (flag==1){
 str="select store,weeklastd ,itmaster.dept_code,itmaster.section_code,itmaster.article_code,itmaster.vendor_code,sellweek.item_code,itmaster.item_desc ,quantity, customs,round((SELL/customs),2) as price , sell   FROM sellweek left join itmaster on sellweek.item_code=itmaster.item_code" ;
str=str+" where quantity<>0 and weeklastd >=# "+StrToDate(DateTimePicker1->Date.DateString())+"# and weeklastd <=#"+StrToDate(DateTimePicker2->Date.DateString())+"#" ;
 if(!suiComboBox1->Text.IsEmpty()){
str=str+" and store='"+suiComboBox1->Text.Trim()+"' ";
}
}
if (flag==2){
str="select store,itmaster.dept_code,itmaster.section_code,itmaster.article_code,itmaster.vendor_code,sellweek.item_code,itmaster.item_desc,stock_onhand ,SUM(quantity) AS quantities ,SUM(customs) AS allcustoms ,itmaster.price ,SUM(SELL) as total  FROM sellweek left join itmaster on sellweek.item_code=itmaster.item_code" ;
str=str+" where weeklastd >=#"+StrToDate(DateTimePicker1->Date.DateString())+"# and weeklastd <=#"+StrToDate(DateTimePicker2->Date.DateString())+"#    ";
 if(!suiComboBox1->Text.IsEmpty()){
str=str+" and store='"+suiComboBox1->Text.Trim()+"' ";
}
}

if(!suiEdit1->Text.IsEmpty()&suiEdit1->Text.Length()==9){
str=str+" and sellweek.item_code='"+suiEdit1->Text.Trim()+"'";
tempstr=str;

 if(flag==2){
  if ( suiRadioButton2->Checked)
str=str+" group by  store,article_code,itmaster.dept_code,itmaster.section_code,sellweek.item_code,itmaster.vendor_code,itmaster.item_desc,price,stock_onhand order by SUM(SELL) desc " ;
else
str=str+" group by store,article_code,itmaster.dept_code,itmaster.section_code,sellweek.item_code,itmaster.vendor_code,itmaster.item_desc,price,stock_onhand order by SUM(quantity) desc ";
}


try{
dm->dayseq->Active=false;
dm->dayseq->SQL->Clear();
dm->dayseq->SQL->Add(str);
 dm->dayseq->Active=true;
 }
 catch(...){
 dm->dayseq->Active=false;
 }


suiDBComboBox1->Text=dm->dayseq->FieldByName("dept_code")->AsString;
suiDBComboBox2->Text=dm->dayseq->FieldByName("section_code")->AsString;
suiDBComboBox3->Text=dm->dayseq->FieldByName("article_code")->AsString;
}



// suiStatusBar1->SimpleText="全店鋪   總金額:"+FloatToStrF(ctotal,ffCurrency,12,2)+";  總數量:"+IntToStr(qtotal)+"  查詢時間從"+DateTimePicker1->Date.DateString()+"至"+DateTimePicker2->Date.DateString();

suiStatusBar1->SimpleText="  查詢時間從"+DateTimePicker1->Date.DateString()+"至"+DateTimePicker2->Date.DateString()+"  庫存為本店庫存";;



       
}
//---------------------------------------------------------------------------

void __fastcall Tsumm::suiButton4Click(TObject *Sender)
{
 suiButton2->Enabled=false;

 AnsiString str="select store,itmaster.dept_code,itmaster.section_code,itmaster.article_code,itmaster.vendor_code,sellweek.item_code,itmaster.item_desc,stock_onhand ,SUM(quantity) AS quantities ,SUM(customs) AS allcustoms ,itmaster.price ,SUM(SELL) as total  FROM sellweek left join itmaster on sellweek.item_code=itmaster.item_code" ;
str=str+" where weeklastd >=# "+StrToDate(DateTimePicker1->Date.DateString())+"# and weeklastd <=#"+StrToDate(DateTimePicker2->Date.DateString())+"#  ";


str=str+" group by store,article_code,itmaster.dept_code,itmaster.section_code,sellweek.item_code,itmaster.vendor_code,itmaster.item_desc,price,stock_onhand  ";
if ( suiRadioButton2->Checked)
str=str+" order by SUM(SELL) desc " ;
else
str=str+" order by SUM(quantity) desc ";
//ShowMessage(str);
 try{
dm->dayseq->Active=false;
dm->dayseq->SQL->Clear();
dm->dayseq->SQL->Add(str);
dm->dayseq->Active=true;

}
catch(...){
}
suiEdit1->Text="";
suiStatusBar1->SimpleText="查詢時間從"+DateTimePicker1->Date.DateString()+"至"+DateTimePicker2->Date.DateString()+"  庫存為本店庫存";
 flag=2;
}
//---------------------------------------------------------------------------



void __fastcall Tsumm::suiListBox1DblClick(TObject *Sender)
{
 AnsiString tstr;
 float ctotal=0.0;
 int qtotal=0;
 int stotal=0;
  if(!dm->dayseq->Active||flag!=1||!suiCheckBox1->Checked){
  return;
  }
 if (Trim(tempstr).IsEmpty()){

 tempstr=AnsiString(dm->dayseq->SQL->Text);
  tstr=dm->dayseq->SQL->Text+" and month(weeklastd)="+(suiListBox1->TopIndex+1)+" order by weeklastd";//+suiListBox1->TopIndex;

     } else{
  tstr=Trim(tempstr)+" and month(weeklastd)="+(suiListBox1->TopIndex+1)+" order by weeklastd";

 }

 ShowMessage(tstr);
 try{
dm->dayseq->Active=false;
dm->dayseq->SQL->Clear();
dm->dayseq->SQL->Add(tstr);
 dm->dayseq->Active=true;
 }
 catch(...){
 dm->dayseq->Active=false;
 }

   if (!suiEdit1->Text.IsEmpty()){
  dm->dayseq->DisableControls();
  dm->dayseq->First();
 while( !dm->dayseq->Eof){
  ctotal=ctotal+ dm->dayseq->FieldByName("sell")->AsFloat;
 qtotal=qtotal+dm->dayseq->FieldByName("quantity")->AsInteger;
  stotal=stotal+dm->dayseq->FieldByName("Customs")->AsInteger;
dm->dayseq->Next();
  }
dm->dayseq->EnableControls();

 suiStatusBar1->SimpleText="該項目匯總結果 "+suiListBox1->Items->operator [](suiListBox1->TopIndex)+"銷售數量:"+IntToStr(qtotal)+" 銷售客數為"+IntToStr(stotal)+" 銷售金額:"+FormatFloat("0.0",ctotal);
}
}
//---------------------------------------------------------------------------





?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品少妇一区二区三区日产乱码 | 337p亚洲精品色噜噜噜| 不卡一区二区三区四区| 激情六月婷婷综合| 国产精品一二三区| 成人综合婷婷国产精品久久| 国产成人在线视频播放| 成人在线视频一区二区| av在线不卡网| 一本到不卡免费一区二区| 91麻豆国产香蕉久久精品| 久热成人在线视频| 91丝袜高跟美女视频| 亚洲成人一区二区在线观看| 久久欧美一区二区| 欧美日韩一区高清| 亚洲综合久久久久| 麻豆国产精品777777在线| 91免费看视频| 亚洲欧美在线视频| 欧美亚洲一区二区三区四区| 亚洲人吸女人奶水| 99热国产精品| 国产精品国产自产拍在线| 国产综合久久久久久鬼色| 日韩美女一区二区三区四区| 免费的成人av| wwwwxxxxx欧美| 久99久精品视频免费观看| 日韩女优毛片在线| 老色鬼精品视频在线观看播放| 欧美日韩一区二区三区视频 | 亚洲成人www| 在线观看不卡视频| 亚洲v日本v欧美v久久精品| 欧美唯美清纯偷拍| 亚洲国产日韩在线一区模特| 在线影院国内精品| 日韩精品电影在线| 日韩久久免费av| 韩国毛片一区二区三区| 中文字幕第一区第二区| 成人综合在线视频| 亚洲欧美一区二区三区久本道91 | 国产精品538一区二区在线| 久久久久久久久久电影| 成人高清视频免费观看| 亚洲免费资源在线播放| 欧美在线视频你懂得| 日本不卡视频在线观看| 久久蜜桃一区二区| 99视频一区二区三区| 亚洲午夜视频在线| 日韩欧美精品在线| 国产精品亚洲人在线观看| 亚洲欧洲成人自拍| 欧美区在线观看| 韩国女主播成人在线观看| 亚洲丝袜美腿综合| 538在线一区二区精品国产| 国产精品一区二区不卡| 一区二区三区四区五区视频在线观看 | 免费国产亚洲视频| 中文字幕一区二区三区乱码在线| 欧美综合亚洲图片综合区| 久久99深爱久久99精品| 亚洲同性同志一二三专区| 色爱区综合激月婷婷| 久久精品99国产精品| 亚洲免费在线视频一区 二区| 欧美一区在线视频| 成人高清在线视频| 精品一区二区三区蜜桃| 亚洲一区欧美一区| 久久精品男人天堂av| 在线免费观看一区| 国产精品一区二区三区99| 午夜久久久久久久久久一区二区| 久久综合色播五月| 欧美疯狂做受xxxx富婆| 94-欧美-setu| 国产成人av福利| 日本不卡视频一二三区| 亚洲一区二区成人在线观看| 久久精品一区二区三区四区| 欧美日韩卡一卡二| 99久久er热在这里只有精品66| 国内外精品视频| 日韩成人av影视| 亚洲成人免费看| 亚洲欧美一区二区不卡| 欧美激情一区三区| 久久先锋影音av鲁色资源| 91精品婷婷国产综合久久性色| 99这里只有久久精品视频| 国产一区二区三区电影在线观看| 日日嗨av一区二区三区四区| 亚洲最色的网站| 亚洲美女免费视频| 亚洲品质自拍视频| 最新成人av在线| 国产精品久久精品日日| 久久久国产精品午夜一区ai换脸| 精品欧美黑人一区二区三区| 91精品综合久久久久久| 欧美日韩一区二区三区高清| 91传媒视频在线播放| 色综合久久88色综合天天免费| 国产91对白在线观看九色| 国产一区二区精品在线观看| 开心九九激情九九欧美日韩精美视频电影 | 1024亚洲合集| 亚洲人精品午夜| 亚洲精品欧美综合四区| 亚洲精品乱码久久久久久日本蜜臀| 国产精品乱码妇女bbbb| 国产精品久久一级| 中文字幕在线不卡| 依依成人精品视频| 有坂深雪av一区二区精品| 亚洲综合色视频| 日韩制服丝袜av| 久久精品99久久久| 国产精品91xxx| av一区二区三区在线| 色狠狠av一区二区三区| 欧美日韩不卡在线| 欧美精品一区二区三区四区| 久久日一线二线三线suv| 国产欧美一区二区在线观看| 亚洲少妇屁股交4| 亚洲国产人成综合网站| 久久精品国产77777蜜臀| 国产在线一区观看| 成年人国产精品| 色成年激情久久综合| 欧美一区二区三区在线观看视频 | 亚洲日本中文字幕区| 亚洲一区二区精品久久av| 日本欧美韩国一区三区| 国产一区二区三区不卡在线观看 | 一区二区三区不卡视频| 日本在线观看不卡视频| 丁香婷婷深情五月亚洲| 在线观看亚洲精品| 精品成a人在线观看| 亚洲日本在线观看| 丝袜美腿一区二区三区| 国产高清一区日本| 欧美中文字幕亚洲一区二区va在线| 91精品欧美综合在线观看最新| 国产三区在线成人av| 亚洲国产精品精华液网站| 国产乱国产乱300精品| 欧美日韩一级片网站| 国产欧美日韩亚州综合| 日本一区中文字幕| 99精品一区二区| 欧美va亚洲va在线观看蝴蝶网| 亚洲欧美日韩在线播放| 激情丁香综合五月| 欧美在线观看18| 国产精品美女久久久久久久| 日韩精品久久理论片| 99久久久久免费精品国产| 久久亚洲免费视频| 无码av免费一区二区三区试看 | 欧美一级黄色片| 日韩理论在线观看| 国产精品99久| 日韩欧美国产高清| 亚洲国产另类av| 色网站国产精品| 久久精品视频一区| 久久国产精品72免费观看| 欧美日韩激情一区二区三区| 最新国产の精品合集bt伙计| 国产麻豆精品在线| 欧美一级午夜免费电影| 亚洲动漫第一页| 日本大香伊一区二区三区| 国产精品你懂的| 国产不卡一区视频| 久久精品免视看| 国产乱理伦片在线观看夜一区 | 美女久久久精品| 欧美亚洲精品一区| 一区二区三区四区国产精品| av不卡免费电影| 国产精品免费视频网站| 高清国产午夜精品久久久久久| 亚洲精品一区二区三区影院 | 免费高清在线一区| 69p69国产精品| 亚洲成人黄色小说| 欧美日本在线观看| 天天av天天翘天天综合网色鬼国产| 色狠狠av一区二区三区| 一区二区三区丝袜| 精品视频1区2区|