Esempio n. 1
0
        public List <FamilyAffectedLandUsedInformation> GetAllFamilyAffectedLandUsedInformation(int qid)
        {
            List <FamilyAffectedLandUsedInformation> aList = new List <FamilyAffectedLandUsedInformation>();

            Query = @"SELECT * FROM FamilyAffectedLandUsedInformation WHERE BasicInformationOfAffectedPersonNid='" + qid + "'";


            Connection.Open();
            Command.CommandText = Query;
            Reader = Command.ExecuteReader();

            while (Reader.Read())
            {
                long   id                        = Convert.ToInt64(Reader["BasicInformationOfAffectedPersonNid"]);
                string jlNo                      = Reader["JlNo"].ToString();
                string plotNo                    = Reader["PlotNo"].ToString();
                string totalAcquiedLand          = Reader["LandElevation"].ToString();
                string ownershipPattern          = Reader["LandUse"].ToString();
                string marketPriceOfAcquiredLand = Reader["PriceOfOthersAssets"].ToString();


                FamilyAffectedLandUsedInformation aData = new FamilyAffectedLandUsedInformation();

                aData.BasicInformationOfAffectedPersonNid = id;
                aData.JlNo                = jlNo;
                aData.PlotNo              = plotNo;
                aData.LandElevation       = totalAcquiedLand;
                aData.LandUse             = ownershipPattern;
                aData.PriceOfOthersAssets = marketPriceOfAcquiredLand;

                aList.Add(aData);
            }
            Connection.Close();
            return(aList);
        }
Esempio n. 2
0
        public int SaveFamilyAffectedLandUsedInformation(FamilyAffectedLandUsedInformation aData)
        {
            Query = @"INSERT INTO FamilyAffectedLandUsedInformation(BasicInformationOfAffectedPersonNid,JlNo,PlotNo,LandElevation,LandUse,PriceOfOthersAssets) 
            VALUES('" + aData.BasicInformationOfAffectedPersonNid + "','" + aData.JlNo + "','" + aData.PlotNo + "','" + aData.LandElevation + "','" + aData.LandUse + "','" + aData.PriceOfOthersAssets + "')";
            Connection.Open();
            Command.CommandText = Query;
            int isRowAffected = Command.ExecuteNonQuery();

            Connection.Close();
            return(isRowAffected);
        }
Esempio n. 3
0
 public int SaveFamilyAffectedLandUsedInformation(FamilyAffectedLandUsedInformation aData)
 {
     return(aFamilyGateway.SaveFamilyAffectedLandUsedInformation(aData));
 }