Commit 5d0bc18c authored by vvengurlekar's avatar vvengurlekar

SiteRegNoIC.java - Added condition for remove validation against 99999


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@183016 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 9f4c17db
......@@ -189,28 +189,33 @@ public class SiteRegNoIC extends ValidatorEJB implements SiteRegNoICLocal,SiteRe
System.out.println("@@@@@ validation site_code executed");
siteCode = genericUtility.getColumnValue("site_code",dom);
if ( siteCode != null && siteCode.trim().length() > 0 && !("99999".equalsIgnoreCase(siteCode)) )
{
sql = " select count(1) from site where site_code = ? ";
pstmt = conn.prepareStatement(sql);
pstmt.setString( 1, siteCode );
rs = pstmt.executeQuery();
if (rs.next())
{
cnt = rs.getInt(1);
}
//Removed condition for 99999 to make entry in siteregno by Varsha V
//if ( siteCode != null && siteCode.trim().length() > 0 && !("99999".equalsIgnoreCase(siteCode)) )
if ( siteCode != null && siteCode.trim().length() > 0 )
{
if(!("99999".equalsIgnoreCase(siteCode)))
{
sql = " select count(1) from site where site_code = ? ";
pstmt = conn.prepareStatement(sql);
pstmt.setString( 1, siteCode );
rs = pstmt.executeQuery();
if (rs.next())
{
cnt = rs.getInt(1);
}
rs.close();
rs = null;
pstmt.close();
pstmt = null;
rs.close();
rs = null;
pstmt.close();
pstmt = null;
if( cnt == 0 )
{
errCode = "VMSITE1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
if( cnt == 0 )
{
errCode = "VMSITE1";
errList.add(errCode);
errFields.add(childNodeName.toLowerCase());
}
}
}
else
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment