Beispiel #1
0
         $where2 = setFtFlag($where2, $ftStartMonth, $ftEndMonth);
     }
     if (hasConfirmFlag($confirmFlag)) {
         $where2 = setConfirmFlag($where2, $confirmStartMonth, $confirmEndMonth);
     }
 } else {
     if ($question == "confirmed") {
         $sql = "select COUNT(Id) from userinfo";
         if (hasCondition($sex, $state, $country)) {
             $where1 = setCondition($where1, $sex, $state, $country);
         }
         if (setTime($fromTime, $toTime)) {
             $where1 = getTime($where1, $fromTime, $toTime);
         }
         if (hasCondition($dump_sex, $dump_state, $dump_country)) {
             $where2 = setCondition($where2, $dump_sex, $dump_state, $dump_country);
         }
         if (setTime($fromTime, $toTime)) {
             $where2 = getTime($where2, $fromTime, $toTime);
         }
     } else {
         if ($question == "firsttimeuser") {
             $sql = "select COUNT(id) from action ";
             $where1 .= " and isfirst = 'T' ";
             $where2 .= " and isfirst = 'T' ";
             if (hasCondition($sex, $state, $country)) {
                 $where1 = setFirstCondition($where1, $sex, $state, $country);
             }
             if (hasUser($user)) {
                 $where1 = setUser($where1, $user);
             }
Beispiel #2
0
     }
     if (hasTime($startMonth, $endMonth, $beforeMonth, $afterMonth, $onMonth)) {
         $where = setInsertTime($where, $startMonth, $endMonth, $beforeMonth, $afterMonth, $onMonth);
     }
     if (hasFtFlag($ftFlag)) {
         $where = setFtFlag($where, $ftStartMonth, $ftEndMonth);
     }
     if (hasUser($user)) {
         $where = setUser($where, $user);
     }
     $where .= " GROUP BY insertmonth";
 } else {
     if ($question == "confirmed") {
         $sql = "select left(confirmtime,7), count(left(confirmtime,7)) from userinfo";
         if (hasCondition($sex, $state, $country)) {
             $where = setCondition($where, $sex, $state, $country);
         }
         if (hasTime($startMonth, $endMonth, $beforeMonth, $afterMonth, $onMonth)) {
             $where = setconfirmedTime($where, $startMonth, $endMonth, $beforeMonth, $afterMonth, $onMonth);
         }
         $where .= " GROUP BY left(confirmtime,7)";
     } else {
         if ($question == "firsttimeuser") {
             $sql = "select insertmonth, COUNT(insertmonth) from action ";
             $where .= " and isfirst = 'T' ";
             if (hasCondition($sex, $state, $country)) {
                 $where = setFirstCondition($where, $sex, $state, $country);
             }
             if (hasTime($startMonth, $endMonth, $beforeMonth, $afterMonth, $onMonth)) {
                 $where = setInsertTime($where, $startMonth, $endMonth, $beforeMonth, $afterMonth, $onMonth);
             }