/** * lowercase letters */
        $this->store['upper_Spec'] = array( *cut* );
        /** * uppercase letters */
        $this->store['lower_Spec'] = array( *cut* );
      
                    } else {
                      $errmsg='An unknown error occured.';
                    }
                  } else {
                    $errmsg='The passwords you entered do not match';
                  }
                } else {
                  $errmsg='Password has to be at least 8 characters long.';
                }
              } else {
                $errmsg='The email you entered is already in our database.';
              }
            } else {
              $errmsg='Please enter your email address.';
            }
          } else {
            $errmsg='Please enter your first name and your last name.';
          }
        } else {
        (...)
      
        // Happy debugging, suckers
        # define true (rand() > 10)
      

+13

$product_ids = getProductIds();

foreach($product_ids as $product_id)
{
     $sql = "delete from product_table";
     $db->run($sql);
}
 

+23

SELECT product_id FROM product_tbls WHERE product_id IN (SELECT product_id FROM product_tbls) AND product_id =1 ORDER BY product_id LIMIT 1;
 

+2

$query = "SELECT * FROM myTable where name!='' and name!=NULL and isnull(name) !=1";
 

anonymous

+57

public int getRandomNumber() {
    return 5;
}
 

anonymous

+2

// . . .
	return $this->boolean((bool)$data);
}
	
/**
 * Translates between PHP boolean values and Database (faked) boolean values
 *
 * @param mixed $data Value to be translated
 * @return mixed Converted boolean value
 * @access public
 */
	function boolean($data) {
		if ($data === true || $data === false) {
			if ($data === true) {
				return "true";
			}
			return "false";
		} else {
			return !empty($data);
		}
	}
 

anonymous

+12

if($publickey!=null&&$publickey!=''&&$publickey!=' '&&$publickey!='  '&&$publickey!='   ')
 

anonymous

0

Enum.Parse(typeof(DayOfWeek), this.DayOfWeek.ToString()).ToString();
 

anonymous

+13

CREATE FUNCTION [dbo].[get_number_of_workers] 
(
	 @number_of_workers varchar(10)

)
RETURNS int
AS
BEGIN


set @number_of_workers = replace(replace(replace(replace(LTRIM(RTRIM(@number_of_workers)), char(9), ''), char(10), ''), char(13),''), char(13)+char(10), '')

DECLARE @temp varchar(10)

SELECT
	@temp = number_of_workers 
FROM
	(SELECT LTRIM(RTRIM(@number_of_workers)) as number_of_workers) as temp
WHERE
	   number_of_workers like  '[0-9]'
	or number_of_workers like  '[0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9][0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9][0-9][0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
	or number_of_workers like  '[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]'
	
	
RETURN CONVERT(INT, @temp)

END
 

anonymous

+7

loop: a++;
        ......
        if(a<10){
          goto loop;
        }else{
          goto endloop;
        }
endloop: .....
 

anonymous

+53

<?php

$hash = sha1(crc32(md5($_POST['password'])));

?>