Report NULL pointer exception

Source: Internet
Author: User

  

|| When the left is true, the expression on the right is not run | When the left is true, the expression on the right is calculated && the expression on the right is not calculated when the left side is false & the left side is false, or the expression on the right is calculated//add by Zengzhiwei December 26, 2015 23:56:19 beginpublic Boolean CHECKPK (String billpk) throws Businessexception {string Sql=new string (""); sql= "Select GUID from Mid_payinfo where billpk= '" +billpk+ ""; Map map = (map) Getbasedao (). ExecuteQuery (SQL, New Mapprocessor ()); if (map! = NULL | | MAP.SIZE>0)//The correct wording should be  (map! =null&&map.size>0) {return true;} Elsereturn false;} Add by Zengzhiwei December 26, 2015 23:56:29 end

  

Report NULL pointer exception

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.