示例#1
0
        public static List <RSH_log> Get_rshList_dvdIndex(int dvdIndex)
        {
            List <RSH_log> RSH_list = new List <RSH_log>();

            DB_select    selt = new DB_select(RSH_log.Get_cmdTP());
            SQL_relation rela = new SQL_relation("DividendIndex", RelationalOperator.Equals, dvdIndex);

            selt.SetCondition(rela);

            DB_reader reader = new DB_reader(selt, Utility.Get_DRWIN_hDB());

            while (reader.Read())
            {
                RSH_log rsh = new RSH_log();
                rsh.Init_from_reader(reader);
                RSH_list.Add(rsh);
            }
            reader.Close();

            return(RSH_list);
        }
示例#2
0
        public RSH_log GetCopy()
        {
            RSH_log newEntity = new RSH_log();

            if (!this.DividendIndex.IsNull_flag)
            {
                newEntity.DividendIndex.Value = this.DividendIndex.Value;
            }
            if (!this.DTC.IsNull_flag)
            {
                newEntity.DTC.Value = this.DTC.Value;
            }
            if (!this.Depositary.IsNull_flag)
            {
                newEntity.Depositary.Value = this.Depositary.Value;
            }
            if (!this.AccountNumber.IsNull_flag)
            {
                newEntity.AccountNumber.Value = this.AccountNumber.Value;
            }
            if (!this.TIN.IsNull_flag)
            {
                newEntity.TIN.Value = this.TIN.Value;
            }
            if (!this.Shares.IsNull_flag)
            {
                newEntity.Shares.Value = this.Shares.Value;
            }
            if (!this.RegisteredName.IsNull_flag)
            {
                newEntity.RegisteredName.Value = this.RegisteredName.Value;
            }
            if (!this.Address.IsNull_flag)
            {
                newEntity.Address.Value = this.Address.Value;
            }
            if (!this.CountryCode.IsNull_flag)
            {
                newEntity.CountryCode.Value = this.CountryCode.Value;
            }
            if (!this.TaxStatus.IsNull_flag)
            {
                newEntity.TaxStatus.Value = this.TaxStatus.Value;
            }
            if (!this.ForeignTaxWH.IsNull_flag)
            {
                newEntity.ForeignTaxWH.Value = this.ForeignTaxWH.Value;
            }
            if (!this.CUSIP.IsNull_flag)
            {
                newEntity.CUSIP.Value = this.CUSIP.Value;
            }
            if (!this.IssueNumber.IsNull_flag)
            {
                newEntity.IssueNumber.Value = this.IssueNumber.Value;
            }
            if (!this.CitizenshipCode.IsNull_flag)
            {
                newEntity.CitizenshipCode.Value = this.CitizenshipCode.Value;
            }
            if (!this.OwnerCode.IsNull_flag)
            {
                newEntity.OwnerCode.Value = this.OwnerCode.Value;
            }
            if (!this.ZipCode.IsNull_flag)
            {
                newEntity.ZipCode.Value = this.ZipCode.Value;
            }
            if (!this.State.IsNull_flag)
            {
                newEntity.State.Value = this.State.Value;
            }
            if (!this.CityName.IsNull_flag)
            {
                newEntity.CityName.Value = this.CityName.Value;
            }
            if (!this.Agent.IsNull_flag)
            {
                newEntity.Agent.Value = this.Agent.Value;
            }
            if (!this.LOC.IsNull_flag)
            {
                newEntity.LOC.Value = this.LOC.Value;
            }
            if (!this.RecordDate.IsNull_flag)
            {
                newEntity.RecordDate.Value = this.RecordDate.Value;
            }
            if (!this.Comp_Num.IsNull_flag)
            {
                newEntity.Comp_Num.Value = this.Comp_Num.Value;
            }
            if (!this.Class_CD.IsNull_flag)
            {
                newEntity.Class_CD.Value = this.Class_CD.Value;
            }
            if (!this.Tax_CD.IsNull_flag)
            {
                newEntity.Tax_CD.Value = this.Tax_CD.Value;
            }
            if (!this.Shares2.IsNull_flag)
            {
                newEntity.Shares2.Value = this.Shares2.Value;
            }
            if (!this.GlobeTax.IsNull_flag)
            {
                newEntity.GlobeTax.Value = this.GlobeTax.Value;
            }
            if (!this.Dividend_Intention.IsNull_flag)
            {
                newEntity.Dividend_Intention.Value = this.Dividend_Intention.Value;
            }
            if (!this.Holder_On_Date.IsNull_flag)
            {
                newEntity.Holder_On_Date.Value = this.Holder_On_Date.Value;
            }
            if (!this.Tin_Status_1.IsNull_flag)
            {
                newEntity.Tin_Status_1.Value = this.Tin_Status_1.Value;
            }
            if (!this.Tin_Status_Source.IsNull_flag)
            {
                newEntity.Tin_Status_Source.Value = this.Tin_Status_Source.Value;
            }
            if (!this.Tin_Exp_Date_1.IsNull_flag)
            {
                newEntity.Tin_Exp_Date_1.Value = this.Tin_Exp_Date_1.Value;
            }
            if (!this.Tin_B_Count.IsNull_flag)
            {
                newEntity.Tin_B_Count.Value = this.Tin_B_Count.Value;
            }
            if (!this.Holder_Type_Code.IsNull_flag)
            {
                newEntity.Holder_Type_Code.Value = this.Holder_Type_Code.Value;
            }
            if (!this.Last_Contact_Date.IsNull_flag)
            {
                newEntity.Last_Contact_Date.Value = this.Last_Contact_Date.Value;
            }
            if (!this.Last_Contact_Type.IsNull_flag)
            {
                newEntity.Last_Contact_Type.Value = this.Last_Contact_Type.Value;
            }
            if (!this.GlobeTax_Findings.IsNull_flag)
            {
                newEntity.GlobeTax_Findings.Value = this.GlobeTax_Findings.Value;
            }
            return(newEntity);
        }
示例#3
0
        internal HssUtility.SQLserver.DB_update Get_DBupdate()
        {
            if (!this.CheckValueChanges())
            {
                return(null);
            }

            HssUtility.SQLserver.DB_update upd = new HssUtility.SQLserver.DB_update(RSH_log.Get_cmdTP());
            if (this.DividendIndex.ValueChanged)
            {
                upd.AddValue("DividendIndex", this.DividendIndex);
            }
            if (this.DTC.ValueChanged)
            {
                upd.AddValue("DTC", this.DTC);
            }
            if (this.Depositary.ValueChanged)
            {
                upd.AddValue("Depositary", this.Depositary);
            }
            if (this.AccountNumber.ValueChanged)
            {
                upd.AddValue("AccountNumber", this.AccountNumber);                                 /*Optional 5*/
            }
            if (this.TIN.ValueChanged)
            {
                upd.AddValue("TIN", this.TIN);                       /*Optional 6*/
            }
            if (this.Shares.ValueChanged)
            {
                upd.AddValue("Shares", this.Shares);                          /*Optional 7*/
            }
            if (this.RegisteredName.ValueChanged)
            {
                upd.AddValue("RegisteredName", this.RegisteredName);                                  /*Optional 8*/
            }
            if (this.Address.ValueChanged)
            {
                upd.AddValue("Address", this.Address);                           /*Optional 9*/
            }
            if (this.CountryCode.ValueChanged)
            {
                upd.AddValue("CountryCode", this.CountryCode);                               /*Optional 10*/
            }
            if (this.TaxStatus.ValueChanged)
            {
                upd.AddValue("TaxStatus", this.TaxStatus);                             /*Optional 11*/
            }
            if (this.ForeignTaxWH.ValueChanged)
            {
                upd.AddValue("ForeignTaxWH", this.ForeignTaxWH);                                /*Optional 12*/
            }
            if (this.CUSIP.ValueChanged)
            {
                upd.AddValue("CUSIP", this.CUSIP);                         /*Optional 13*/
            }
            if (this.IssueNumber.ValueChanged)
            {
                upd.AddValue("IssueNumber", this.IssueNumber);                               /*Optional 14*/
            }
            if (this.CitizenshipCode.ValueChanged)
            {
                upd.AddValue("CitizenshipCode", this.CitizenshipCode);                                   /*Optional 15*/
            }
            if (this.OwnerCode.ValueChanged)
            {
                upd.AddValue("OwnerCode", this.OwnerCode);                             /*Optional 16*/
            }
            if (this.ZipCode.ValueChanged)
            {
                upd.AddValue("ZipCode", this.ZipCode);                           /*Optional 17*/
            }
            if (this.State.ValueChanged)
            {
                upd.AddValue("State", this.State);                         /*Optional 18*/
            }
            if (this.CityName.ValueChanged)
            {
                upd.AddValue("CityName", this.CityName);                            /*Optional 19*/
            }
            if (this.Agent.ValueChanged)
            {
                upd.AddValue("Agent", this.Agent);                         /*Optional 20*/
            }
            if (this.LOC.ValueChanged)
            {
                upd.AddValue("LOC", this.LOC);                       /*Optional 21*/
            }
            if (this.RecordDate.ValueChanged)
            {
                upd.AddValue("RecordDate", this.RecordDate);                              /*Optional 22*/
            }
            if (this.Comp_Num.ValueChanged)
            {
                upd.AddValue("Comp_Num", this.Comp_Num);                            /*Optional 23*/
            }
            if (this.Class_CD.ValueChanged)
            {
                upd.AddValue("Class_CD", this.Class_CD);                            /*Optional 24*/
            }
            if (this.Tax_CD.ValueChanged)
            {
                upd.AddValue("Tax_CD", this.Tax_CD);                          /*Optional 25*/
            }
            if (this.Shares2.ValueChanged)
            {
                upd.AddValue("Shares2", this.Shares2);                           /*Optional 26*/
            }
            if (this.GlobeTax.ValueChanged)
            {
                upd.AddValue("GlobeTax", this.GlobeTax);                            /*Optional 27*/
            }
            if (this.Dividend_Intention.ValueChanged)
            {
                upd.AddValue("Dividend_Intention", this.Dividend_Intention);                                      /*Optional 28*/
            }
            if (this.Holder_On_Date.ValueChanged)
            {
                upd.AddValue("Holder_On_Date", this.Holder_On_Date);                                  /*Optional 29*/
            }
            if (this.Tin_Status_1.ValueChanged)
            {
                upd.AddValue("Tin_Status_1", this.Tin_Status_1);                                /*Optional 30*/
            }
            if (this.Tin_Status_Source.ValueChanged)
            {
                upd.AddValue("Tin_Status_Source", this.Tin_Status_Source);                                     /*Optional 31*/
            }
            if (this.Tin_Exp_Date_1.ValueChanged)
            {
                upd.AddValue("Tin_Exp_Date_1", this.Tin_Exp_Date_1);                                  /*Optional 32*/
            }
            if (this.Tin_B_Count.ValueChanged)
            {
                upd.AddValue("Tin_B_Count", this.Tin_B_Count);                               /*Optional 33*/
            }
            if (this.Holder_Type_Code.ValueChanged)
            {
                upd.AddValue("Holder_Type_Code", this.Holder_Type_Code);                                    /*Optional 34*/
            }
            if (this.Last_Contact_Date.ValueChanged)
            {
                upd.AddValue("Last_Contact_Date", this.Last_Contact_Date);                                     /*Optional 35*/
            }
            if (this.Last_Contact_Type.ValueChanged)
            {
                upd.AddValue("Last_Contact_Type", this.Last_Contact_Type);                                     /*Optional 36*/
            }
            if (this.GlobeTax_Findings.ValueChanged)
            {
                upd.AddValue("GlobeTax_Findings", this.GlobeTax_Findings);                                     /*Optional 37*/
            }
            HssUtility.SQLserver.SQL_relation rela = new HssUtility.SQLserver.SQL_relation("RSHID", HssUtility.General.RelationalOperator.Equals, this.pk_ID);
            upd.SetCondition(rela);

            return(upd);
        }
示例#4
0
        internal HssUtility.SQLserver.DB_insert Get_DBinsert()
        {
            HssUtility.SQLserver.DB_insert dbIns = new HssUtility.SQLserver.DB_insert(RSH_log.Get_cmdTP());

            dbIns.AddValue("DividendIndex", this.DividendIndex);
            dbIns.AddValue("DTC", this.DTC);
            dbIns.AddValue("Depositary", this.Depositary);
            dbIns.AddValue("AccountNumber", this.AccountNumber);           /*Optional 5*/
            dbIns.AddValue("TIN", this.TIN);                               /*Optional 6*/
            dbIns.AddValue("Shares", this.Shares);                         /*Optional 7*/
            dbIns.AddValue("RegisteredName", this.RegisteredName);         /*Optional 8*/
            dbIns.AddValue("Address", this.Address);                       /*Optional 9*/
            dbIns.AddValue("CountryCode", this.CountryCode);               /*Optional 10*/
            dbIns.AddValue("TaxStatus", this.TaxStatus);                   /*Optional 11*/
            dbIns.AddValue("ForeignTaxWH", this.ForeignTaxWH);             /*Optional 12*/
            dbIns.AddValue("CUSIP", this.CUSIP);                           /*Optional 13*/
            dbIns.AddValue("IssueNumber", this.IssueNumber);               /*Optional 14*/
            dbIns.AddValue("CitizenshipCode", this.CitizenshipCode);       /*Optional 15*/
            dbIns.AddValue("OwnerCode", this.OwnerCode);                   /*Optional 16*/
            dbIns.AddValue("ZipCode", this.ZipCode);                       /*Optional 17*/
            dbIns.AddValue("State", this.State);                           /*Optional 18*/
            dbIns.AddValue("CityName", this.CityName);                     /*Optional 19*/
            dbIns.AddValue("Agent", this.Agent);                           /*Optional 20*/
            dbIns.AddValue("LOC", this.LOC);                               /*Optional 21*/
            dbIns.AddValue("RecordDate", this.RecordDate);                 /*Optional 22*/
            dbIns.AddValue("Comp_Num", this.Comp_Num);                     /*Optional 23*/
            dbIns.AddValue("Class_CD", this.Class_CD);                     /*Optional 24*/
            dbIns.AddValue("Tax_CD", this.Tax_CD);                         /*Optional 25*/
            dbIns.AddValue("Shares2", this.Shares2);                       /*Optional 26*/
            dbIns.AddValue("GlobeTax", this.GlobeTax);                     /*Optional 27*/
            dbIns.AddValue("Dividend_Intention", this.Dividend_Intention); /*Optional 28*/
            dbIns.AddValue("Holder_On_Date", this.Holder_On_Date);         /*Optional 29*/
            dbIns.AddValue("Tin_Status_1", this.Tin_Status_1);             /*Optional 30*/
            dbIns.AddValue("Tin_Status_Source", this.Tin_Status_Source);   /*Optional 31*/
            dbIns.AddValue("Tin_Exp_Date_1", this.Tin_Exp_Date_1);         /*Optional 32*/
            dbIns.AddValue("Tin_B_Count", this.Tin_B_Count);               /*Optional 33*/
            dbIns.AddValue("Holder_Type_Code", this.Holder_Type_Code);     /*Optional 34*/
            dbIns.AddValue("Last_Contact_Date", this.Last_Contact_Date);   /*Optional 35*/
            dbIns.AddValue("Last_Contact_Type", this.Last_Contact_Type);   /*Optional 36*/
            dbIns.AddValue("GlobeTax_Findings", this.GlobeTax_Findings);   /*Optional 37*/

            return(dbIns);
        }
示例#5
0
        /// <summary>
        /// Initialize object from DB
        /// </summary>
        public bool Init_from_DB()
        {
            if (this.RSHID < 0)
            {
                return(false);
            }

            HssUtility.SQLserver.DB_select db_sel = new HssUtility.SQLserver.DB_select(RSH_log.Get_cmdTP());
            db_sel.tableName = "RSHLog";
            HssUtility.SQLserver.SQL_relation rela = new HssUtility.SQLserver.SQL_relation("RSHID", HssUtility.General.RelationalOperator.Equals, this.RSHID);
            db_sel.SetCondition(rela);

            bool res_flag = false;

            HssUtility.SQLserver.DB_reader reader = new HssUtility.SQLserver.DB_reader(db_sel, Utility.Get_DRWIN_hDB());
            if (reader.Read())
            {
                this.Init_from_reader(reader);
                res_flag = true;
            }
            reader.Close();
            return(res_flag);
        }