CAR Entry
User :
Monthly Entry Form :: CAR (Total)
0){ $result7=mysql_query("SELECT * FROM car_details where Thana_code='$Thana_code' and Month_Id='$Date'and NGO_Code='1'"); $num1=mysql_num_rows($result7); $i=0; while ($i<$num1){ $num_id=1; $Month_Id=mysql_result($result7,$i,"Month_Id"); $Thana_code=mysql_result($result7,$i,"Thana_code"); $Total_EC=mysql_result($result7,$i,"Total_EC"); $Pill_Old=mysql_result($result7,$i,"Pill_Old"); $Pill_New=mysql_result($result7,$i,"Pill_New"); $Pill_Drop=mysql_result($result7,$i,"Pill_Drop"); $Pill_Switch=mysql_result($result7,$i,"Pill_Switch"); $Con_Old=mysql_result($result7,$i,"Con_Old"); $Con_New=mysql_result($result7,$i,"Con_New"); $Con_Drop=mysql_result($result7,$i,"Con_Drop"); $Con_Switch=mysql_result($result7,$i,"Con_Switch"); $Inj_Old=mysql_result($result7,$i,"Inj_Old"); $Inj_New=mysql_result($result7,$i,"Inj_New"); $Inj_Drop=mysql_result($result7,$i,"Inj_Drop"); $Inj_Switch=mysql_result($result7,$i,"Inj_Switch"); $IUD_Old=mysql_result($result7,$i,"IUD_Old"); $IUD_New=mysql_result($result7,$i,"IUD_New"); $IUD_Drop=mysql_result($result7,$i,"IUD_Drop"); $IUD_Switch=mysql_result($result7,$i,"IUD_Switch"); $Imp_Old=mysql_result($result7,$i,"Imp_Old"); $Imp_New=mysql_result($result7,$i,"Imp_New"); $Imp_Drop=mysql_result($result7,$i,"Imp_Drop"); $Imp_Switch=mysql_result($result7,$i,"Imp_Switch"); $PerM_Old=mysql_result($result7,$i,"PerM_Old"); $PerM_New=mysql_result($result7,$i,"PerM_New"); $PerF_Old=mysql_result($result7,$i,"PerF_Old"); $PerF_New=mysql_result($result7,$i,"PerF_New"); ++$i; } $T_User=($Pill_Old+$Pill_New+$Con_Old+$Con_New+$Inj_Old+$Inj_New+$IUD_Old+$IUD_New+$Imp_Old+$Imp_New+$PerM_Old+$PerM_New+$PerF_Old+$PerF_New); $T_CA=($T_User/$Total_EC)*100; $T_CAR=number_format($T_CA,2); } else { //$num_id=0; echo 'Data Insert not allowed'; //Current Month Entry $resultdate1=mysql_query("SELECT Date_Add(Max(Month_id),Interval 1 Month) Cdate FROM car_details where Thana_code='$Thana_code'and NGO_Code='1'"); $rowD1=mysql_fetch_array($resultdate1); $C_Date=$rowD1['Cdate']; //echo $C_Date; $RDate=substr($Date,0,7); $ADate=substr($C_Date,0,7); if($RDate==$ADate){ $V_valu=1;} else{ $V_valu=2;} } //End If //Last Month Entry--Date_Add('Max(Month_id)',Interval 1 Month) $resultdate=mysql_query("SELECT Max(Month_id) Maxdate FROM car_details where Thana_code='$Thana_code' and NGO_Code='1'"); $rowD=mysql_fetch_array($resultdate); $M_Date=$rowD['Maxdate']; //Privious Month Couple $resultcouple=mysql_query("SELECT Total_EC PTotal_EC FROM car_details where Thana_code='$Thana_code' and NGO_Code='1'and Month_Id = Date_Add('$Date',Interval -1 Month)"); $rowC=mysql_fetch_array($resultcouple); $P_Couple=$rowC['PTotal_EC']; //District name $resultD=mysql_query("SELECT Dist_Name FROM district where Dist_code='$Dist_Id'"); $rowD=mysql_fetch_array($resultD); $D_Name=$rowD['Dist_Name']; //Thana name $resultT=mysql_query("SELECT Thana_Name FROM thana where Thana_code='$Thana_code'"); $rowT=mysql_fetch_array($resultT); $T_Name=$rowT['Thana_Name']; //Month name $sql=mysql_query("select M_name from month where M_id='$m'"); $rowM=mysql_fetch_array($sql); $M_Name=$rowM['M_name']; ?>
District :
Thana :
Entry Reporting Month :
Year :
 
Eligible Couple Previous Month Couple:: Last Entry Month:: -
Method
Old New Total No Method Switch over
Oral Pill
Condom
Injectable
I U D
Implant
Per.Method(Male)
Per.method(Female)
Total User :: CAR(%) ::
Copyright © 2013 MIS Unit, DGFP All rights reserved