Register Register Member Login Member Login Member Login Forgot Password ??
PHP , ASP , ASP.NET, VB.NET, C#, Java , jQuery , Android , iOS , Windows Phone
 

Registered : 109,038

HOME > .NET Framework > Forum > insert ข้อมูล แล้วข้อมูลที่เพิ่มไม่ขึ้นอย่างที่พิมพ์ไป


 

[.NET] insert ข้อมูล แล้วข้อมูลที่เพิ่มไม่ขึ้นอย่างที่พิมพ์ไป

 
Topic : 123197



โพสกระทู้ ( 7 )
บทความ ( 0 )



สถานะออฟไลน์
Facebook


คือ ทำการinsert ข้อมูลการลงทะเบียน ไปยังฐานข้อมูลsql run ได้คะแต่ข้อมูลที่เพิ่มไม่ใช่ข้อมูลที่ เราพิมพ์ไป ใครช่วยได้รบกวนด้วยนะคะ
*เป็นมือใหม่คะ ทำโปรเจคจบ แต่อาจารย์ สอนไม่ลงลึกต้องมาศึกษาเอง รบกวนช่วยด้วยนะคะ

อันนี้โค้ดคะ

ที่แสดงในฐานข้อมูล



Tag : .NET, Ms SQL Server 2008, VB.NET

Move To Hilight (Stock) 
Send To Friend.Bookmark.
Date : 2016-06-04 15:24:08 By : nittaya28 View : 1202 Reply : 11
 

 

No. 1



โพสกระทู้ ( 4,440 )
บทความ ( 23 )



สถานะออฟไลน์
Facebook

ข้อมูลที่เพิ่มไม่ใช่ข้อมูลที่ เราพิมพ์ไป

ยกตัวอย่างได้ไม๊ครับ

แล้ว password หายไปไหนรึ มันน่าจะไม่ตรงเพราะเจ้า password ไม่ไม่อยู่ใน database นี่แหละ 55555
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-04 16:09:07 By : lamaka.tor
 

 

No. 2



โพสกระทู้ ( 7 )
บทความ ( 0 )



สถานะออฟไลน์
Facebook

ตอบความคิดเห็นที่ : 1 เขียนโดย : lamaka.tor เมื่อวันที่ 2016-06-04 16:09:07
รายละเอียดของการตอบ ::
ข้อความที่กรอก กรอกแบบนี้คะ

แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-04 16:44:21 By : nittaya28
 

 

No. 3



โพสกระทู้ ( 7 )
บทความ ( 0 )



สถานะออฟไลน์
Facebook

ตอบความคิดเห็นที่ : 1 เขียนโดย : lamaka.tor เมื่อวันที่ 2016-06-04 16:09:07
รายละเอียดของการตอบ ::
.sql_insret ขึ้นในฐานข้อมูลเป็นแบบนี้คะ เหมือนที่พิมพ์ในโค้ดเลยคะ TT

แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-04 16:46:23 By : nittaya28
 

 

No. 4



โพสกระทู้ ( 4,440 )
บทความ ( 23 )



สถานะออฟไลน์
Facebook

ถ้ามี password แล้ว ต่อไปก็เรื่องของ parameters ครับ
รูปแบบการใช้งาน parameters ลองดูดีๆ

https://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqlcommand.parameters%28v=vs.110%29.aspx
http://stackoverflow.com/questions/9999751/difference-between-parameters-add-and-parameters-addwithvalue
http://stackoverflow.com/questions/293311/whats-the-best-method-to-pass-parameters-to-sqlcommand
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-04 17:31:25 By : lamaka.tor
 

 

No. 5



โพสกระทู้ ( 4,440 )
บทความ ( 23 )



สถานะออฟไลน์
Facebook

โค๊ด บ้านๆ ครับ ลองแกะดู

Code (C#)
0001.//------------------------------------------------------------------------------
0002.// <auto-generated>
0003.//     This code was generated by a tool.
0004.//     Runtime Version:4.0.30319.17929
0005.//
0006.//     Changes to this file may cause incorrect behavior and will be lost if
0007.//     the code is regenerated.
0008.// </auto-generated>
0009.//------------------------------------------------------------------------------
0010. 
0011.#pragma warning disable 1591
0012. 
0013.namespace WindowsFormsApplication1 {
0014.     
0015.     
0016.    /// <summary>
0017.    ///Represents a strongly typed in-memory cache of data.
0018.    ///</summary>
0019.    [global::System.Serializable()]
0020.    [global::System.ComponentModel.DesignerCategoryAttribute("code")]
0021.    [global::System.ComponentModel.ToolboxItem(true)]
0022.    [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedDataSetSchema")]
0023.    [global::System.Xml.Serialization.XmlRootAttribute("Database2DataSet")]
0024.    [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.DataSet")]
0025.    public partial class Database2DataSet : global::System.Data.DataSet {
0026.         
0027.        private ZipCodeTDataTable tableZipCodeT;
0028.         
0029.        private global::System.Data.SchemaSerializationMode _schemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
0030.         
0031.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0032.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0033.        public Database2DataSet() {
0034.            this.BeginInit();
0035.            this.InitClass();
0036.            global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
0037.            base.Tables.CollectionChanged += schemaChangedHandler;
0038.            base.Relations.CollectionChanged += schemaChangedHandler;
0039.            this.EndInit();
0040.        }
0041.         
0042.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0043.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0044.        protected Database2DataSet(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
0045.                base(info, context, false) {
0046.            if ((this.IsBinarySerialized(info, context) == true)) {
0047.                this.InitVars(false);
0048.                global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler1 = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
0049.                this.Tables.CollectionChanged += schemaChangedHandler1;
0050.                this.Relations.CollectionChanged += schemaChangedHandler1;
0051.                return;
0052.            }
0053.            string strSchema = ((string)(info.GetValue("XmlSchema", typeof(string))));
0054.            if ((this.DetermineSchemaSerializationMode(info, context) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
0055.                global::System.Data.DataSet ds = new global::System.Data.DataSet();
0056.                ds.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
0057.                if ((ds.Tables["ZipCodeT"] != null)) {
0058.                    base.Tables.Add(new ZipCodeTDataTable(ds.Tables["ZipCodeT"]));
0059.                }
0060.                this.DataSetName = ds.DataSetName;
0061.                this.Prefix = ds.Prefix;
0062.                this.Namespace = ds.Namespace;
0063.                this.Locale = ds.Locale;
0064.                this.CaseSensitive = ds.CaseSensitive;
0065.                this.EnforceConstraints = ds.EnforceConstraints;
0066.                this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
0067.                this.InitVars();
0068.            }
0069.            else {
0070.                this.ReadXmlSchema(new global::System.Xml.XmlTextReader(new global::System.IO.StringReader(strSchema)));
0071.            }
0072.            this.GetSerializationData(info, context);
0073.            global::System.ComponentModel.CollectionChangeEventHandler schemaChangedHandler = new global::System.ComponentModel.CollectionChangeEventHandler(this.SchemaChanged);
0074.            base.Tables.CollectionChanged += schemaChangedHandler;
0075.            this.Relations.CollectionChanged += schemaChangedHandler;
0076.        }
0077.         
0078.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0079.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0080.        [global::System.ComponentModel.Browsable(false)]
0081.        [global::System.ComponentModel.DesignerSerializationVisibility(global::System.ComponentModel.DesignerSerializationVisibility.Content)]
0082.        public ZipCodeTDataTable ZipCodeT {
0083.            get {
0084.                return this.tableZipCodeT;
0085.            }
0086.        }
0087.         
0088.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0089.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0090.        [global::System.ComponentModel.BrowsableAttribute(true)]
0091.        [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Visible)]
0092.        public override global::System.Data.SchemaSerializationMode SchemaSerializationMode {
0093.            get {
0094.                return this._schemaSerializationMode;
0095.            }
0096.            set {
0097.                this._schemaSerializationMode = value;
0098.            }
0099.        }
0100.         
0101.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0102.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0103.        [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
0104.        public new global::System.Data.DataTableCollection Tables {
0105.            get {
0106.                return base.Tables;
0107.            }
0108.        }
0109.         
0110.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0111.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0112.        [global::System.ComponentModel.DesignerSerializationVisibilityAttribute(global::System.ComponentModel.DesignerSerializationVisibility.Hidden)]
0113.        public new global::System.Data.DataRelationCollection Relations {
0114.            get {
0115.                return base.Relations;
0116.            }
0117.        }
0118.         
0119.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0120.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0121.        protected override void InitializeDerivedDataSet() {
0122.            this.BeginInit();
0123.            this.InitClass();
0124.            this.EndInit();
0125.        }
0126.         
0127.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0128.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0129.        public override global::System.Data.DataSet Clone() {
0130.            Database2DataSet cln = ((Database2DataSet)(base.Clone()));
0131.            cln.InitVars();
0132.            cln.SchemaSerializationMode = this.SchemaSerializationMode;
0133.            return cln;
0134.        }
0135.         
0136.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0137.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0138.        protected override bool ShouldSerializeTables() {
0139.            return false;
0140.        }
0141.         
0142.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0143.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0144.        protected override bool ShouldSerializeRelations() {
0145.            return false;
0146.        }
0147.         
0148.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0149.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0150.        protected override void ReadXmlSerializable(global::System.Xml.XmlReader reader) {
0151.            if ((this.DetermineSchemaSerializationMode(reader) == global::System.Data.SchemaSerializationMode.IncludeSchema)) {
0152.                this.Reset();
0153.                global::System.Data.DataSet ds = new global::System.Data.DataSet();
0154.                ds.ReadXml(reader);
0155.                if ((ds.Tables["ZipCodeT"] != null)) {
0156.                    base.Tables.Add(new ZipCodeTDataTable(ds.Tables["ZipCodeT"]));
0157.                }
0158.                this.DataSetName = ds.DataSetName;
0159.                this.Prefix = ds.Prefix;
0160.                this.Namespace = ds.Namespace;
0161.                this.Locale = ds.Locale;
0162.                this.CaseSensitive = ds.CaseSensitive;
0163.                this.EnforceConstraints = ds.EnforceConstraints;
0164.                this.Merge(ds, false, global::System.Data.MissingSchemaAction.Add);
0165.                this.InitVars();
0166.            }
0167.            else {
0168.                this.ReadXml(reader);
0169.                this.InitVars();
0170.            }
0171.        }
0172.         
0173.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0174.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0175.        protected override global::System.Xml.Schema.XmlSchema GetSchemaSerializable() {
0176.            global::System.IO.MemoryStream stream = new global::System.IO.MemoryStream();
0177.            this.WriteXmlSchema(new global::System.Xml.XmlTextWriter(stream, null));
0178.            stream.Position = 0;
0179.            return global::System.Xml.Schema.XmlSchema.Read(new global::System.Xml.XmlTextReader(stream), null);
0180.        }
0181.         
0182.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0183.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0184.        internal void InitVars() {
0185.            this.InitVars(true);
0186.        }
0187.         
0188.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0189.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0190.        internal void InitVars(bool initTable) {
0191.            this.tableZipCodeT = ((ZipCodeTDataTable)(base.Tables["ZipCodeT"]));
0192.            if ((initTable == true)) {
0193.                if ((this.tableZipCodeT != null)) {
0194.                    this.tableZipCodeT.InitVars();
0195.                }
0196.            }
0197.        }
0198.         
0199.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0200.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0201.        private void InitClass() {
0202.            this.DataSetName = "Database2DataSet";
0203.            this.Prefix = "";
0204.            this.Namespace = "http://tempuri.org/Database2DataSet.xsd";
0205.            this.EnforceConstraints = true;
0206.            this.SchemaSerializationMode = global::System.Data.SchemaSerializationMode.IncludeSchema;
0207.            this.tableZipCodeT = new ZipCodeTDataTable();
0208.            base.Tables.Add(this.tableZipCodeT);
0209.        }
0210.         
0211.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0212.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0213.        private bool ShouldSerializeZipCodeT() {
0214.            return false;
0215.        }
0216.         
0217.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0218.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0219.        private void SchemaChanged(object sender, global::System.ComponentModel.CollectionChangeEventArgs e) {
0220.            if ((e.Action == global::System.ComponentModel.CollectionChangeAction.Remove)) {
0221.                this.InitVars();
0222.            }
0223.        }
0224.         
0225.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0226.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0227.        public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedDataSetSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
0228.            Database2DataSet ds = new Database2DataSet();
0229.            global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
0230.            global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
0231.            global::System.Xml.Schema.XmlSchemaAny any = new global::System.Xml.Schema.XmlSchemaAny();
0232.            any.Namespace = ds.Namespace;
0233.            sequence.Items.Add(any);
0234.            type.Particle = sequence;
0235.            global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
0236.            if (xs.Contains(dsSchema.TargetNamespace)) {
0237.                global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
0238.                global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
0239.                try {
0240.                    global::System.Xml.Schema.XmlSchema schema = null;
0241.                    dsSchema.Write(s1);
0242.                    for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
0243.                        schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
0244.                        s2.SetLength(0);
0245.                        schema.Write(s2);
0246.                        if ((s1.Length == s2.Length)) {
0247.                            s1.Position = 0;
0248.                            s2.Position = 0;
0249.                            for (; ((s1.Position != s1.Length)
0250.                                        && (s1.ReadByte() == s2.ReadByte())); ) {
0251.                                ;
0252.                            }
0253.                            if ((s1.Position == s1.Length)) {
0254.                                return type;
0255.                            }
0256.                        }
0257.                    }
0258.                }
0259.                finally {
0260.                    if ((s1 != null)) {
0261.                        s1.Close();
0262.                    }
0263.                    if ((s2 != null)) {
0264.                        s2.Close();
0265.                    }
0266.                }
0267.            }
0268.            xs.Add(dsSchema);
0269.            return type;
0270.        }
0271.         
0272.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0273.        public delegate void ZipCodeTRowChangeEventHandler(object sender, ZipCodeTRowChangeEvent e);
0274.         
0275.        /// <summary>
0276.        ///Represents the strongly named DataTable class.
0277.        ///</summary>
0278.        [global::System.Serializable()]
0279.        [global::System.Xml.Serialization.XmlSchemaProviderAttribute("GetTypedTableSchema")]
0280.        public partial class ZipCodeTDataTable : global::System.Data.TypedTableBase<ZipCodeTRow> {
0281.             
0282.            private global::System.Data.DataColumn columnID;
0283.             
0284.            private global::System.Data.DataColumn columnZipCode;
0285.             
0286.            private global::System.Data.DataColumn columnCity;
0287.             
0288.            private global::System.Data.DataColumn columnState;
0289.             
0290.            private global::System.Data.DataColumn columnRegion;
0291.             
0292.            private global::System.Data.DataColumn columnemployee_id;
0293.             
0294.            private global::System.Data.DataColumn columnTransactionDate;
0295.             
0296.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0297.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0298.            public ZipCodeTDataTable() {
0299.                this.TableName = "ZipCodeT";
0300.                this.BeginInit();
0301.                this.InitClass();
0302.                this.EndInit();
0303.            }
0304.             
0305.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0306.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0307.            internal ZipCodeTDataTable(global::System.Data.DataTable table) {
0308.                this.TableName = table.TableName;
0309.                if ((table.CaseSensitive != table.DataSet.CaseSensitive)) {
0310.                    this.CaseSensitive = table.CaseSensitive;
0311.                }
0312.                if ((table.Locale.ToString() != table.DataSet.Locale.ToString())) {
0313.                    this.Locale = table.Locale;
0314.                }
0315.                if ((table.Namespace != table.DataSet.Namespace)) {
0316.                    this.Namespace = table.Namespace;
0317.                }
0318.                this.Prefix = table.Prefix;
0319.                this.MinimumCapacity = table.MinimumCapacity;
0320.            }
0321.             
0322.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0323.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0324.            protected ZipCodeTDataTable(global::System.Runtime.Serialization.SerializationInfo info, global::System.Runtime.Serialization.StreamingContext context) :
0325.                    base(info, context) {
0326.                this.InitVars();
0327.            }
0328.             
0329.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0330.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0331.            public global::System.Data.DataColumn IDColumn {
0332.                get {
0333.                    return this.columnID;
0334.                }
0335.            }
0336.             
0337.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0338.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0339.            public global::System.Data.DataColumn ZipCodeColumn {
0340.                get {
0341.                    return this.columnZipCode;
0342.                }
0343.            }
0344.             
0345.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0346.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0347.            public global::System.Data.DataColumn CityColumn {
0348.                get {
0349.                    return this.columnCity;
0350.                }
0351.            }
0352.             
0353.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0354.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0355.            public global::System.Data.DataColumn StateColumn {
0356.                get {
0357.                    return this.columnState;
0358.                }
0359.            }
0360.             
0361.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0362.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0363.            public global::System.Data.DataColumn RegionColumn {
0364.                get {
0365.                    return this.columnRegion;
0366.                }
0367.            }
0368.             
0369.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0370.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0371.            public global::System.Data.DataColumn employee_idColumn {
0372.                get {
0373.                    return this.columnemployee_id;
0374.                }
0375.            }
0376.             
0377.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0378.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0379.            public global::System.Data.DataColumn TransactionDateColumn {
0380.                get {
0381.                    return this.columnTransactionDate;
0382.                }
0383.            }
0384.             
0385.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0386.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0387.            [global::System.ComponentModel.Browsable(false)]
0388.            public int Count {
0389.                get {
0390.                    return this.Rows.Count;
0391.                }
0392.            }
0393.             
0394.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0395.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0396.            public ZipCodeTRow this[int index] {
0397.                get {
0398.                    return ((ZipCodeTRow)(this.Rows[index]));
0399.                }
0400.            }
0401.             
0402.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0403.            public event ZipCodeTRowChangeEventHandler ZipCodeTRowChanging;
0404.             
0405.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0406.            public event ZipCodeTRowChangeEventHandler ZipCodeTRowChanged;
0407.             
0408.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0409.            public event ZipCodeTRowChangeEventHandler ZipCodeTRowDeleting;
0410.             
0411.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0412.            public event ZipCodeTRowChangeEventHandler ZipCodeTRowDeleted;
0413.             
0414.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0415.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0416.            public void AddZipCodeTRow(ZipCodeTRow row) {
0417.                this.Rows.Add(row);
0418.            }
0419.             
0420.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0421.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0422.            public ZipCodeTRow AddZipCodeTRow(string ZipCode, string City, string State, string Region, string employee_id, System.DateTime TransactionDate) {
0423.                ZipCodeTRow rowZipCodeTRow = ((ZipCodeTRow)(this.NewRow()));
0424.                object[] columnValuesArray = new object[] {
0425.                        null,
0426.                        ZipCode,
0427.                        City,
0428.                        State,
0429.                        Region,
0430.                        employee_id,
0431.                        TransactionDate};
0432.                rowZipCodeTRow.ItemArray = columnValuesArray;
0433.                this.Rows.Add(rowZipCodeTRow);
0434.                return rowZipCodeTRow;
0435.            }
0436.             
0437.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0438.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0439.            public ZipCodeTRow FindByID(int ID) {
0440.                return ((ZipCodeTRow)(this.Rows.Find(new object[] {
0441.                            ID})));
0442.            }
0443.             
0444.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0445.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0446.            public override global::System.Data.DataTable Clone() {
0447.                ZipCodeTDataTable cln = ((ZipCodeTDataTable)(base.Clone()));
0448.                cln.InitVars();
0449.                return cln;
0450.            }
0451.             
0452.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0453.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0454.            protected override global::System.Data.DataTable CreateInstance() {
0455.                return new ZipCodeTDataTable();
0456.            }
0457.             
0458.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0459.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0460.            internal void InitVars() {
0461.                this.columnID = base.Columns["ID"];
0462.                this.columnZipCode = base.Columns["ZipCode"];
0463.                this.columnCity = base.Columns["City"];
0464.                this.columnState = base.Columns["State"];
0465.                this.columnRegion = base.Columns["Region"];
0466.                this.columnemployee_id = base.Columns["employee_id"];
0467.                this.columnTransactionDate = base.Columns["TransactionDate"];
0468.            }
0469.             
0470.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0471.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0472.            private void InitClass() {
0473.                this.columnID = new global::System.Data.DataColumn("ID", typeof(int), null, global::System.Data.MappingType.Element);
0474.                base.Columns.Add(this.columnID);
0475.                this.columnZipCode = new global::System.Data.DataColumn("ZipCode", typeof(string), null, global::System.Data.MappingType.Element);
0476.                base.Columns.Add(this.columnZipCode);
0477.                this.columnCity = new global::System.Data.DataColumn("City", typeof(string), null, global::System.Data.MappingType.Element);
0478.                base.Columns.Add(this.columnCity);
0479.                this.columnState = new global::System.Data.DataColumn("State", typeof(string), null, global::System.Data.MappingType.Element);
0480.                base.Columns.Add(this.columnState);
0481.                this.columnRegion = new global::System.Data.DataColumn("Region", typeof(string), null, global::System.Data.MappingType.Element);
0482.                base.Columns.Add(this.columnRegion);
0483.                this.columnemployee_id = new global::System.Data.DataColumn("employee_id", typeof(string), null, global::System.Data.MappingType.Element);
0484.                base.Columns.Add(this.columnemployee_id);
0485.                this.columnTransactionDate = new global::System.Data.DataColumn("TransactionDate", typeof(global::System.DateTime), null, global::System.Data.MappingType.Element);
0486.                base.Columns.Add(this.columnTransactionDate);
0487.                this.Constraints.Add(new global::System.Data.UniqueConstraint("Constraint1", new global::System.Data.DataColumn[] {
0488.                                this.columnID}, true));
0489.                this.columnID.AutoIncrement = true;
0490.                this.columnID.AutoIncrementSeed = -1;
0491.                this.columnID.AutoIncrementStep = -1;
0492.                this.columnID.AllowDBNull = false;
0493.                this.columnID.Unique = true;
0494.                this.columnZipCode.MaxLength = 10;
0495.                this.columnCity.MaxLength = 20;
0496.                this.columnState.MaxLength = 30;
0497.                this.columnRegion.MaxLength = 15;
0498.                this.columnemployee_id.MaxLength = 6;
0499.            }
0500.             
0501.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0502.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0503.            public ZipCodeTRow NewZipCodeTRow() {
0504.                return ((ZipCodeTRow)(this.NewRow()));
0505.            }
0506.             
0507.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0508.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0509.            protected override global::System.Data.DataRow NewRowFromBuilder(global::System.Data.DataRowBuilder builder) {
0510.                return new ZipCodeTRow(builder);
0511.            }
0512.             
0513.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0514.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0515.            protected override global::System.Type GetRowType() {
0516.                return typeof(ZipCodeTRow);
0517.            }
0518.             
0519.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0520.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0521.            protected override void OnRowChanged(global::System.Data.DataRowChangeEventArgs e) {
0522.                base.OnRowChanged(e);
0523.                if ((this.ZipCodeTRowChanged != null)) {
0524.                    this.ZipCodeTRowChanged(this, new ZipCodeTRowChangeEvent(((ZipCodeTRow)(e.Row)), e.Action));
0525.                }
0526.            }
0527.             
0528.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0529.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0530.            protected override void OnRowChanging(global::System.Data.DataRowChangeEventArgs e) {
0531.                base.OnRowChanging(e);
0532.                if ((this.ZipCodeTRowChanging != null)) {
0533.                    this.ZipCodeTRowChanging(this, new ZipCodeTRowChangeEvent(((ZipCodeTRow)(e.Row)), e.Action));
0534.                }
0535.            }
0536.             
0537.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0538.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0539.            protected override void OnRowDeleted(global::System.Data.DataRowChangeEventArgs e) {
0540.                base.OnRowDeleted(e);
0541.                if ((this.ZipCodeTRowDeleted != null)) {
0542.                    this.ZipCodeTRowDeleted(this, new ZipCodeTRowChangeEvent(((ZipCodeTRow)(e.Row)), e.Action));
0543.                }
0544.            }
0545.             
0546.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0547.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0548.            protected override void OnRowDeleting(global::System.Data.DataRowChangeEventArgs e) {
0549.                base.OnRowDeleting(e);
0550.                if ((this.ZipCodeTRowDeleting != null)) {
0551.                    this.ZipCodeTRowDeleting(this, new ZipCodeTRowChangeEvent(((ZipCodeTRow)(e.Row)), e.Action));
0552.                }
0553.            }
0554.             
0555.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0556.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0557.            public void RemoveZipCodeTRow(ZipCodeTRow row) {
0558.                this.Rows.Remove(row);
0559.            }
0560.             
0561.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0562.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0563.            public static global::System.Xml.Schema.XmlSchemaComplexType GetTypedTableSchema(global::System.Xml.Schema.XmlSchemaSet xs) {
0564.                global::System.Xml.Schema.XmlSchemaComplexType type = new global::System.Xml.Schema.XmlSchemaComplexType();
0565.                global::System.Xml.Schema.XmlSchemaSequence sequence = new global::System.Xml.Schema.XmlSchemaSequence();
0566.                Database2DataSet ds = new Database2DataSet();
0567.                global::System.Xml.Schema.XmlSchemaAny any1 = new global::System.Xml.Schema.XmlSchemaAny();
0568.                any1.Namespace = "http://www.w3.org/2001/XMLSchema";
0569.                any1.MinOccurs = new decimal(0);
0570.                any1.MaxOccurs = decimal.MaxValue;
0571.                any1.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
0572.                sequence.Items.Add(any1);
0573.                global::System.Xml.Schema.XmlSchemaAny any2 = new global::System.Xml.Schema.XmlSchemaAny();
0574.                any2.Namespace = "urn:schemas-microsoft-com:xml-diffgram-v1";
0575.                any2.MinOccurs = new decimal(1);
0576.                any2.ProcessContents = global::System.Xml.Schema.XmlSchemaContentProcessing.Lax;
0577.                sequence.Items.Add(any2);
0578.                global::System.Xml.Schema.XmlSchemaAttribute attribute1 = new global::System.Xml.Schema.XmlSchemaAttribute();
0579.                attribute1.Name = "namespace";
0580.                attribute1.FixedValue = ds.Namespace;
0581.                type.Attributes.Add(attribute1);
0582.                global::System.Xml.Schema.XmlSchemaAttribute attribute2 = new global::System.Xml.Schema.XmlSchemaAttribute();
0583.                attribute2.Name = "tableTypeName";
0584.                attribute2.FixedValue = "ZipCodeTDataTable";
0585.                type.Attributes.Add(attribute2);
0586.                type.Particle = sequence;
0587.                global::System.Xml.Schema.XmlSchema dsSchema = ds.GetSchemaSerializable();
0588.                if (xs.Contains(dsSchema.TargetNamespace)) {
0589.                    global::System.IO.MemoryStream s1 = new global::System.IO.MemoryStream();
0590.                    global::System.IO.MemoryStream s2 = new global::System.IO.MemoryStream();
0591.                    try {
0592.                        global::System.Xml.Schema.XmlSchema schema = null;
0593.                        dsSchema.Write(s1);
0594.                        for (global::System.Collections.IEnumerator schemas = xs.Schemas(dsSchema.TargetNamespace).GetEnumerator(); schemas.MoveNext(); ) {
0595.                            schema = ((global::System.Xml.Schema.XmlSchema)(schemas.Current));
0596.                            s2.SetLength(0);
0597.                            schema.Write(s2);
0598.                            if ((s1.Length == s2.Length)) {
0599.                                s1.Position = 0;
0600.                                s2.Position = 0;
0601.                                for (; ((s1.Position != s1.Length)
0602.                                            && (s1.ReadByte() == s2.ReadByte())); ) {
0603.                                    ;
0604.                                }
0605.                                if ((s1.Position == s1.Length)) {
0606.                                    return type;
0607.                                }
0608.                            }
0609.                        }
0610.                    }
0611.                    finally {
0612.                        if ((s1 != null)) {
0613.                            s1.Close();
0614.                        }
0615.                        if ((s2 != null)) {
0616.                            s2.Close();
0617.                        }
0618.                    }
0619.                }
0620.                xs.Add(dsSchema);
0621.                return type;
0622.            }
0623.        }
0624.         
0625.        /// <summary>
0626.        ///Represents strongly named DataRow class.
0627.        ///</summary>
0628.        public partial class ZipCodeTRow : global::System.Data.DataRow {
0629.             
0630.            private ZipCodeTDataTable tableZipCodeT;
0631.             
0632.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0633.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0634.            internal ZipCodeTRow(global::System.Data.DataRowBuilder rb) :
0635.                    base(rb) {
0636.                this.tableZipCodeT = ((ZipCodeTDataTable)(this.Table));
0637.            }
0638.             
0639.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0640.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0641.            public int ID {
0642.                get {
0643.                    return ((int)(this[this.tableZipCodeT.IDColumn]));
0644.                }
0645.                set {
0646.                    this[this.tableZipCodeT.IDColumn] = value;
0647.                }
0648.            }
0649.             
0650.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0651.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0652.            public string ZipCode {
0653.                get {
0654.                    try {
0655.                        return ((string)(this[this.tableZipCodeT.ZipCodeColumn]));
0656.                    }
0657.                    catch (global::System.InvalidCastException e) {
0658.                        throw new global::System.Data.StrongTypingException("The value for column \'ZipCode\' in table \'ZipCodeT\' is DBNull.", e);
0659.                    }
0660.                }
0661.                set {
0662.                    this[this.tableZipCodeT.ZipCodeColumn] = value;
0663.                }
0664.            }
0665.             
0666.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0667.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0668.            public string City {
0669.                get {
0670.                    try {
0671.                        return ((string)(this[this.tableZipCodeT.CityColumn]));
0672.                    }
0673.                    catch (global::System.InvalidCastException e) {
0674.                        throw new global::System.Data.StrongTypingException("The value for column \'City\' in table \'ZipCodeT\' is DBNull.", e);
0675.                    }
0676.                }
0677.                set {
0678.                    this[this.tableZipCodeT.CityColumn] = value;
0679.                }
0680.            }
0681.             
0682.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0683.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0684.            public string State {
0685.                get {
0686.                    try {
0687.                        return ((string)(this[this.tableZipCodeT.StateColumn]));
0688.                    }
0689.                    catch (global::System.InvalidCastException e) {
0690.                        throw new global::System.Data.StrongTypingException("The value for column \'State\' in table \'ZipCodeT\' is DBNull.", e);
0691.                    }
0692.                }
0693.                set {
0694.                    this[this.tableZipCodeT.StateColumn] = value;
0695.                }
0696.            }
0697.             
0698.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0699.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0700.            public string Region {
0701.                get {
0702.                    try {
0703.                        return ((string)(this[this.tableZipCodeT.RegionColumn]));
0704.                    }
0705.                    catch (global::System.InvalidCastException e) {
0706.                        throw new global::System.Data.StrongTypingException("The value for column \'Region\' in table \'ZipCodeT\' is DBNull.", e);
0707.                    }
0708.                }
0709.                set {
0710.                    this[this.tableZipCodeT.RegionColumn] = value;
0711.                }
0712.            }
0713.             
0714.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0715.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0716.            public string employee_id {
0717.                get {
0718.                    try {
0719.                        return ((string)(this[this.tableZipCodeT.employee_idColumn]));
0720.                    }
0721.                    catch (global::System.InvalidCastException e) {
0722.                        throw new global::System.Data.StrongTypingException("The value for column \'employee_id\' in table \'ZipCodeT\' is DBNull.", e);
0723.                    }
0724.                }
0725.                set {
0726.                    this[this.tableZipCodeT.employee_idColumn] = value;
0727.                }
0728.            }
0729.             
0730.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0731.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0732.            public System.DateTime TransactionDate {
0733.                get {
0734.                    try {
0735.                        return ((global::System.DateTime)(this[this.tableZipCodeT.TransactionDateColumn]));
0736.                    }
0737.                    catch (global::System.InvalidCastException e) {
0738.                        throw new global::System.Data.StrongTypingException("The value for column \'TransactionDate\' in table \'ZipCodeT\' is DBNull.", e);
0739.                    }
0740.                }
0741.                set {
0742.                    this[this.tableZipCodeT.TransactionDateColumn] = value;
0743.                }
0744.            }
0745.             
0746.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0747.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0748.            public bool IsZipCodeNull() {
0749.                return this.IsNull(this.tableZipCodeT.ZipCodeColumn);
0750.            }
0751.             
0752.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0753.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0754.            public void SetZipCodeNull() {
0755.                this[this.tableZipCodeT.ZipCodeColumn] = global::System.Convert.DBNull;
0756.            }
0757.             
0758.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0759.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0760.            public bool IsCityNull() {
0761.                return this.IsNull(this.tableZipCodeT.CityColumn);
0762.            }
0763.             
0764.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0765.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0766.            public void SetCityNull() {
0767.                this[this.tableZipCodeT.CityColumn] = global::System.Convert.DBNull;
0768.            }
0769.             
0770.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0771.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0772.            public bool IsStateNull() {
0773.                return this.IsNull(this.tableZipCodeT.StateColumn);
0774.            }
0775.             
0776.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0777.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0778.            public void SetStateNull() {
0779.                this[this.tableZipCodeT.StateColumn] = global::System.Convert.DBNull;
0780.            }
0781.             
0782.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0783.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0784.            public bool IsRegionNull() {
0785.                return this.IsNull(this.tableZipCodeT.RegionColumn);
0786.            }
0787.             
0788.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0789.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0790.            public void SetRegionNull() {
0791.                this[this.tableZipCodeT.RegionColumn] = global::System.Convert.DBNull;
0792.            }
0793.             
0794.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0795.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0796.            public bool Isemployee_idNull() {
0797.                return this.IsNull(this.tableZipCodeT.employee_idColumn);
0798.            }
0799.             
0800.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0801.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0802.            public void Setemployee_idNull() {
0803.                this[this.tableZipCodeT.employee_idColumn] = global::System.Convert.DBNull;
0804.            }
0805.             
0806.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0807.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0808.            public bool IsTransactionDateNull() {
0809.                return this.IsNull(this.tableZipCodeT.TransactionDateColumn);
0810.            }
0811.             
0812.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0813.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0814.            public void SetTransactionDateNull() {
0815.                this[this.tableZipCodeT.TransactionDateColumn] = global::System.Convert.DBNull;
0816.            }
0817.        }
0818.         
0819.        /// <summary>
0820.        ///Row event argument class
0821.        ///</summary>
0822.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0823.        public class ZipCodeTRowChangeEvent : global::System.EventArgs {
0824.             
0825.            private ZipCodeTRow eventRow;
0826.             
0827.            private global::System.Data.DataRowAction eventAction;
0828.             
0829.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0830.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0831.            public ZipCodeTRowChangeEvent(ZipCodeTRow row, global::System.Data.DataRowAction action) {
0832.                this.eventRow = row;
0833.                this.eventAction = action;
0834.            }
0835.             
0836.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0837.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0838.            public ZipCodeTRow Row {
0839.                get {
0840.                    return this.eventRow;
0841.                }
0842.            }
0843.             
0844.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0845.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0846.            public global::System.Data.DataRowAction Action {
0847.                get {
0848.                    return this.eventAction;
0849.                }
0850.            }
0851.        }
0852.    }
0853.}
0854.namespace WindowsFormsApplication1.Database2DataSetTableAdapters {
0855.     
0856.     
0857.    /// <summary>
0858.    ///Represents the connection and commands used to retrieve and save data.
0859.    ///</summary>
0860.    [global::System.ComponentModel.DesignerCategoryAttribute("code")]
0861.    [global::System.ComponentModel.ToolboxItem(true)]
0862.    [global::System.ComponentModel.DataObjectAttribute(true)]
0863.    [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterDesigner, Microsoft.VSDesigner" +
0864.        ", Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
0865.    [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
0866.    public partial class ZipCodeTTableAdapter : global::System.ComponentModel.Component {
0867.         
0868.        private global::System.Data.OleDb.OleDbDataAdapter _adapter;
0869.         
0870.        private global::System.Data.OleDb.OleDbConnection _connection;
0871.         
0872.        private global::System.Data.OleDb.OleDbTransaction _transaction;
0873.         
0874.        private global::System.Data.OleDb.OleDbCommand[] _commandCollection;
0875.         
0876.        private bool _clearBeforeFill;
0877.         
0878.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0879.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0880.        public ZipCodeTTableAdapter() {
0881.            this.ClearBeforeFill = true;
0882.        }
0883.         
0884.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0885.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0886.        protected internal global::System.Data.OleDb.OleDbDataAdapter Adapter {
0887.            get {
0888.                if ((this._adapter == null)) {
0889.                    this.InitAdapter();
0890.                }
0891.                return this._adapter;
0892.            }
0893.        }
0894.         
0895.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0896.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0897.        internal global::System.Data.OleDb.OleDbConnection Connection {
0898.            get {
0899.                if ((this._connection == null)) {
0900.                    this.InitConnection();
0901.                }
0902.                return this._connection;
0903.            }
0904.            set {
0905.                this._connection = value;
0906.                if ((this.Adapter.InsertCommand != null)) {
0907.                    this.Adapter.InsertCommand.Connection = value;
0908.                }
0909.                if ((this.Adapter.DeleteCommand != null)) {
0910.                    this.Adapter.DeleteCommand.Connection = value;
0911.                }
0912.                if ((this.Adapter.UpdateCommand != null)) {
0913.                    this.Adapter.UpdateCommand.Connection = value;
0914.                }
0915.                for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
0916.                    if ((this.CommandCollection[i] != null)) {
0917.                        ((global::System.Data.OleDb.OleDbCommand)(this.CommandCollection[i])).Connection = value;
0918.                    }
0919.                }
0920.            }
0921.        }
0922.         
0923.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0924.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0925.        internal global::System.Data.OleDb.OleDbTransaction Transaction {
0926.            get {
0927.                return this._transaction;
0928.            }
0929.            set {
0930.                this._transaction = value;
0931.                for (int i = 0; (i < this.CommandCollection.Length); i = (i + 1)) {
0932.                    this.CommandCollection[i].Transaction = this._transaction;
0933.                }
0934.                if (((this.Adapter != null)
0935.                            && (this.Adapter.DeleteCommand != null))) {
0936.                    this.Adapter.DeleteCommand.Transaction = this._transaction;
0937.                }
0938.                if (((this.Adapter != null)
0939.                            && (this.Adapter.InsertCommand != null))) {
0940.                    this.Adapter.InsertCommand.Transaction = this._transaction;
0941.                }
0942.                if (((this.Adapter != null)
0943.                            && (this.Adapter.UpdateCommand != null))) {
0944.                    this.Adapter.UpdateCommand.Transaction = this._transaction;
0945.                }
0946.            }
0947.        }
0948.         
0949.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0950.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0951.        protected global::System.Data.OleDb.OleDbCommand[] CommandCollection {
0952.            get {
0953.                if ((this._commandCollection == null)) {
0954.                    this.InitCommandCollection();
0955.                }
0956.                return this._commandCollection;
0957.            }
0958.        }
0959.         
0960.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0961.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0962.        public bool ClearBeforeFill {
0963.            get {
0964.                return this._clearBeforeFill;
0965.            }
0966.            set {
0967.                this._clearBeforeFill = value;
0968.            }
0969.        }
0970.         
0971.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
0972.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
0973.        private void InitAdapter() {
0974.            this._adapter = new global::System.Data.OleDb.OleDbDataAdapter();
0975.            global::System.Data.Common.DataTableMapping tableMapping = new global::System.Data.Common.DataTableMapping();
0976.            tableMapping.SourceTable = "Table";
0977.            tableMapping.DataSetTable = "ZipCodeT";
0978.            tableMapping.ColumnMappings.Add("ID", "ID");
0979.            tableMapping.ColumnMappings.Add("ZipCode", "ZipCode");
0980.            tableMapping.ColumnMappings.Add("City", "City");
0981.            tableMapping.ColumnMappings.Add("State", "State");
0982.            tableMapping.ColumnMappings.Add("Region", "Region");
0983.            tableMapping.ColumnMappings.Add("employee_id", "employee_id");
0984.            tableMapping.ColumnMappings.Add("TransactionDate", "TransactionDate");
0985.            this._adapter.TableMappings.Add(tableMapping);
0986.            this._adapter.DeleteCommand = new global::System.Data.OleDb.OleDbCommand();
0987.            this._adapter.DeleteCommand.Connection = this.Connection;
0988.            this._adapter.DeleteCommand.CommandText = @"DELETE FROM `ZipCodeT` WHERE ((`ID` = ?) AND ((? = 1 AND `ZipCode` IS NULL) OR (`ZipCode` = ?)) AND ((? = 1 AND `City` IS NULL) OR (`City` = ?)) AND ((? = 1 AND `State` IS NULL) OR (`State` = ?)) AND ((? = 1 AND `Region` IS NULL) OR (`Region` = ?)) AND ((? = 1 AND `employee_id` IS NULL) OR (`employee_id` = ?)) AND ((? = 1 AND `TransactionDate` IS NULL) OR (`TransactionDate` = ?)))";
0989.            this._adapter.DeleteCommand.CommandType = global::System.Data.CommandType.Text;
0990.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ID", global::System.Data.DataRowVersion.Original, false, null));
0991.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ZipCode", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ZipCode", global::System.Data.DataRowVersion.Original, true, null));
0992.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ZipCode", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ZipCode", global::System.Data.DataRowVersion.Original, false, null));
0993.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_City", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Original, true, null));
0994.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_City", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Original, false, null));
0995.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_State", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "State", global::System.Data.DataRowVersion.Original, true, null));
0996.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_State", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "State", global::System.Data.DataRowVersion.Original, false, null));
0997.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Region", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Original, true, null));
0998.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Region", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Original, false, null));
0999.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_employee_id", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "employee_id", global::System.Data.DataRowVersion.Original, true, null));
1000.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_employee_id", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "employee_id", global::System.Data.DataRowVersion.Original, false, null));
1001.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_TransactionDate", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "TransactionDate", global::System.Data.DataRowVersion.Original, true, null));
1002.            this._adapter.DeleteCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_TransactionDate", global::System.Data.OleDb.OleDbType.Date, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "TransactionDate", global::System.Data.DataRowVersion.Original, false, null));
1003.            this._adapter.InsertCommand = new global::System.Data.OleDb.OleDbCommand();
1004.            this._adapter.InsertCommand.Connection = this.Connection;
1005.            this._adapter.InsertCommand.CommandText = "INSERT INTO `ZipCodeT` (`ZipCode`, `City`, `State`, `Region`, `employee_id`, `Tra" +
1006.                "nsactionDate`) VALUES (?, ?, ?, ?, ?, ?)";
1007.            this._adapter.InsertCommand.CommandType = global::System.Data.CommandType.Text;
1008.            this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ZipCode", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ZipCode", global::System.Data.DataRowVersion.Current, false, null));
1009.            this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("City", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Current, false, null));
1010.            this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("State", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "State", global::System.Data.DataRowVersion.Current, false, null));
1011.            this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Region", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Current, false, null));
1012.            this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("employee_id", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "employee_id", global::System.Data.DataRowVersion.Current, false, null));
1013.            this._adapter.InsertCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("TransactionDate", global::System.Data.OleDb.OleDbType.Date, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "TransactionDate", global::System.Data.DataRowVersion.Current, false, null));
1014.            this._adapter.UpdateCommand = new global::System.Data.OleDb.OleDbCommand();
1015.            this._adapter.UpdateCommand.Connection = this.Connection;
1016.            this._adapter.UpdateCommand.CommandText = @"UPDATE `ZipCodeT` SET `ZipCode` = ?, `City` = ?, `State` = ?, `Region` = ?, `employee_id` = ?, `TransactionDate` = ? WHERE ((`ID` = ?) AND ((? = 1 AND `ZipCode` IS NULL) OR (`ZipCode` = ?)) AND ((? = 1 AND `City` IS NULL) OR (`City` = ?)) AND ((? = 1 AND `State` IS NULL) OR (`State` = ?)) AND ((? = 1 AND `Region` IS NULL) OR (`Region` = ?)) AND ((? = 1 AND `employee_id` IS NULL) OR (`employee_id` = ?)) AND ((? = 1 AND `TransactionDate` IS NULL) OR (`TransactionDate` = ?)))";
1017.            this._adapter.UpdateCommand.CommandType = global::System.Data.CommandType.Text;
1018.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ZipCode", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ZipCode", global::System.Data.DataRowVersion.Current, false, null));
1019.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("City", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Current, false, null));
1020.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("State", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "State", global::System.Data.DataRowVersion.Current, false, null));
1021.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Region", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Current, false, null));
1022.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("employee_id", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "employee_id", global::System.Data.DataRowVersion.Current, false, null));
1023.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("TransactionDate", global::System.Data.OleDb.OleDbType.Date, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "TransactionDate", global::System.Data.DataRowVersion.Current, false, null));
1024.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ID", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ID", global::System.Data.DataRowVersion.Original, false, null));
1025.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_ZipCode", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ZipCode", global::System.Data.DataRowVersion.Original, true, null));
1026.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_ZipCode", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ZipCode", global::System.Data.DataRowVersion.Original, false, null));
1027.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_City", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Original, true, null));
1028.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_City", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "City", global::System.Data.DataRowVersion.Original, false, null));
1029.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_State", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "State", global::System.Data.DataRowVersion.Original, true, null));
1030.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_State", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "State", global::System.Data.DataRowVersion.Original, false, null));
1031.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_Region", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Original, true, null));
1032.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_Region", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "Region", global::System.Data.DataRowVersion.Original, false, null));
1033.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_employee_id", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "employee_id", global::System.Data.DataRowVersion.Original, true, null));
1034.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_employee_id", global::System.Data.OleDb.OleDbType.VarWChar, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "employee_id", global::System.Data.DataRowVersion.Original, false, null));
1035.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("IsNull_TransactionDate", global::System.Data.OleDb.OleDbType.Integer, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "TransactionDate", global::System.Data.DataRowVersion.Original, true, null));
1036.            this._adapter.UpdateCommand.Parameters.Add(new global::System.Data.OleDb.OleDbParameter("Original_TransactionDate", global::System.Data.OleDb.OleDbType.Date, 0, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "TransactionDate", global::System.Data.DataRowVersion.Original, false, null));
1037.        }
1038.         
1039.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1040.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1041.        private void InitConnection() {
1042.            this._connection = new global::System.Data.OleDb.OleDbConnection();
1043.            this._connection.ConnectionString = global::WindowsFormsApplication1.Properties.Settings.Default.Database2ConnectionString;
1044.        }
1045.         
1046.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1047.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1048.        private void InitCommandCollection() {
1049.            this._commandCollection = new global::System.Data.OleDb.OleDbCommand[2];
1050.            this._commandCollection[0] = new global::System.Data.OleDb.OleDbCommand();
1051.            this._commandCollection[0].Connection = this.Connection;
1052.            this._commandCollection[0].CommandText = "SELECT ID, ZipCode, City, State, Region, employee_id, TransactionDate FROM ZipCod" +
1053.                "eT";
1054.            this._commandCollection[0].CommandType = global::System.Data.CommandType.Text;
1055.            this._commandCollection[1] = new global::System.Data.OleDb.OleDbCommand();
1056.            this._commandCollection[1].Connection = this.Connection;
1057.            this._commandCollection[1].CommandText = "SELECT        ID, ZipCode, City, State, Region, employee_id, TransactionDate\r\nFRO" +
1058.                "M            ZipCodeT\r\nWHERE        (ZipCode = ?)";
1059.            this._commandCollection[1].CommandType = global::System.Data.CommandType.Text;
1060.            this._commandCollection[1].Parameters.Add(new global::System.Data.OleDb.OleDbParameter("ZipCode", global::System.Data.OleDb.OleDbType.WChar, 10, global::System.Data.ParameterDirection.Input, ((byte)(0)), ((byte)(0)), "ZipCode", global::System.Data.DataRowVersion.Current, false, null));
1061.        }
1062.         
1063.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1064.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1065.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1066.        [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, true)]
1067.        public virtual int Fill(Database2DataSet.ZipCodeTDataTable dataTable) {
1068.            this.Adapter.SelectCommand = this.CommandCollection[0];
1069.            if ((this.ClearBeforeFill == true)) {
1070.                dataTable.Clear();
1071.            }
1072.            int returnValue = this.Adapter.Fill(dataTable);
1073.            return returnValue;
1074.        }
1075.         
1076.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1077.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1078.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1079.        [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, true)]
1080.        public virtual Database2DataSet.ZipCodeTDataTable GetData() {
1081.            this.Adapter.SelectCommand = this.CommandCollection[0];
1082.            Database2DataSet.ZipCodeTDataTable dataTable = new Database2DataSet.ZipCodeTDataTable();
1083.            this.Adapter.Fill(dataTable);
1084.            return dataTable;
1085.        }
1086.         
1087.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1088.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1089.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1090.        [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Fill, false)]
1091.        public virtual int FillBy(Database2DataSet.ZipCodeTDataTable dataTable, string ZipCode) {
1092.            this.Adapter.SelectCommand = this.CommandCollection[1];
1093.            if ((ZipCode == null)) {
1094.                this.Adapter.SelectCommand.Parameters[0].Value = global::System.DBNull.Value;
1095.            }
1096.            else {
1097.                this.Adapter.SelectCommand.Parameters[0].Value = ((string)(ZipCode));
1098.            }
1099.            if ((this.ClearBeforeFill == true)) {
1100.                dataTable.Clear();
1101.            }
1102.            int returnValue = this.Adapter.Fill(dataTable);
1103.            return returnValue;
1104.        }
1105.         
1106.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1107.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1108.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1109.        [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Select, false)]
1110.        public virtual Database2DataSet.ZipCodeTDataTable GetDataBy(string ZipCode) {
1111.            this.Adapter.SelectCommand = this.CommandCollection[1];
1112.            if ((ZipCode == null)) {
1113.                this.Adapter.SelectCommand.Parameters[0].Value = global::System.DBNull.Value;
1114.            }
1115.            else {
1116.                this.Adapter.SelectCommand.Parameters[0].Value = ((string)(ZipCode));
1117.            }
1118.            Database2DataSet.ZipCodeTDataTable dataTable = new Database2DataSet.ZipCodeTDataTable();
1119.            this.Adapter.Fill(dataTable);
1120.            return dataTable;
1121.        }
1122.         
1123.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1124.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1125.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1126.        public virtual int Update(Database2DataSet.ZipCodeTDataTable dataTable) {
1127.            return this.Adapter.Update(dataTable);
1128.        }
1129.         
1130.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1131.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1132.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1133.        public virtual int Update(Database2DataSet dataSet) {
1134.            return this.Adapter.Update(dataSet, "ZipCodeT");
1135.        }
1136.         
1137.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1138.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1139.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1140.        public virtual int Update(global::System.Data.DataRow dataRow) {
1141.            return this.Adapter.Update(new global::System.Data.DataRow[] {
1142.                        dataRow});
1143.        }
1144.         
1145.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1146.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1147.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1148.        public virtual int Update(global::System.Data.DataRow[] dataRows) {
1149.            return this.Adapter.Update(dataRows);
1150.        }
1151.         
1152.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1153.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1154.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1155.        [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Delete, true)]
1156.        public virtual int Delete(int Original_ID, string Original_ZipCode, string Original_City, string Original_State, string Original_Region, string Original_employee_id, global::System.Nullable<global::System.DateTime> Original_TransactionDate) {
1157.            this.Adapter.DeleteCommand.Parameters[0].Value = ((int)(Original_ID));
1158.            if ((Original_ZipCode == null)) {
1159.                this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(1));
1160.                this.Adapter.DeleteCommand.Parameters[2].Value = global::System.DBNull.Value;
1161.            }
1162.            else {
1163.                this.Adapter.DeleteCommand.Parameters[1].Value = ((object)(0));
1164.                this.Adapter.DeleteCommand.Parameters[2].Value = ((string)(Original_ZipCode));
1165.            }
1166.            if ((Original_City == null)) {
1167.                this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(1));
1168.                this.Adapter.DeleteCommand.Parameters[4].Value = global::System.DBNull.Value;
1169.            }
1170.            else {
1171.                this.Adapter.DeleteCommand.Parameters[3].Value = ((object)(0));
1172.                this.Adapter.DeleteCommand.Parameters[4].Value = ((string)(Original_City));
1173.            }
1174.            if ((Original_State == null)) {
1175.                this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(1));
1176.                this.Adapter.DeleteCommand.Parameters[6].Value = global::System.DBNull.Value;
1177.            }
1178.            else {
1179.                this.Adapter.DeleteCommand.Parameters[5].Value = ((object)(0));
1180.                this.Adapter.DeleteCommand.Parameters[6].Value = ((string)(Original_State));
1181.            }
1182.            if ((Original_Region == null)) {
1183.                this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(1));
1184.                this.Adapter.DeleteCommand.Parameters[8].Value = global::System.DBNull.Value;
1185.            }
1186.            else {
1187.                this.Adapter.DeleteCommand.Parameters[7].Value = ((object)(0));
1188.                this.Adapter.DeleteCommand.Parameters[8].Value = ((string)(Original_Region));
1189.            }
1190.            if ((Original_employee_id == null)) {
1191.                this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(1));
1192.                this.Adapter.DeleteCommand.Parameters[10].Value = global::System.DBNull.Value;
1193.            }
1194.            else {
1195.                this.Adapter.DeleteCommand.Parameters[9].Value = ((object)(0));
1196.                this.Adapter.DeleteCommand.Parameters[10].Value = ((string)(Original_employee_id));
1197.            }
1198.            if ((Original_TransactionDate.HasValue == true)) {
1199.                this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(0));
1200.                this.Adapter.DeleteCommand.Parameters[12].Value = ((System.DateTime)(Original_TransactionDate.Value));
1201.            }
1202.            else {
1203.                this.Adapter.DeleteCommand.Parameters[11].Value = ((object)(1));
1204.                this.Adapter.DeleteCommand.Parameters[12].Value = global::System.DBNull.Value;
1205.            }
1206.            global::System.Data.ConnectionState previousConnectionState = this.Adapter.DeleteCommand.Connection.State;
1207.            if (((this.Adapter.DeleteCommand.Connection.State & global::System.Data.ConnectionState.Open)
1208.                        != global::System.Data.ConnectionState.Open)) {
1209.                this.Adapter.DeleteCommand.Connection.Open();
1210.            }
1211.            try {
1212.                int returnValue = this.Adapter.DeleteCommand.ExecuteNonQuery();
1213.                return returnValue;
1214.            }
1215.            finally {
1216.                if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
1217.                    this.Adapter.DeleteCommand.Connection.Close();
1218.                }
1219.            }
1220.        }
1221.         
1222.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1223.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1224.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1225.        [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Insert, true)]
1226.        public virtual int Insert(string ZipCode, string City, string State, string Region, string employee_id, global::System.Nullable<global::System.DateTime> TransactionDate) {
1227.            if ((ZipCode == null)) {
1228.                this.Adapter.InsertCommand.Parameters[0].Value = global::System.DBNull.Value;
1229.            }
1230.            else {
1231.                this.Adapter.InsertCommand.Parameters[0].Value = ((string)(ZipCode));
1232.            }
1233.            if ((City == null)) {
1234.                this.Adapter.InsertCommand.Parameters[1].Value = global::System.DBNull.Value;
1235.            }
1236.            else {
1237.                this.Adapter.InsertCommand.Parameters[1].Value = ((string)(City));
1238.            }
1239.            if ((State == null)) {
1240.                this.Adapter.InsertCommand.Parameters[2].Value = global::System.DBNull.Value;
1241.            }
1242.            else {
1243.                this.Adapter.InsertCommand.Parameters[2].Value = ((string)(State));
1244.            }
1245.            if ((Region == null)) {
1246.                this.Adapter.InsertCommand.Parameters[3].Value = global::System.DBNull.Value;
1247.            }
1248.            else {
1249.                this.Adapter.InsertCommand.Parameters[3].Value = ((string)(Region));
1250.            }
1251.            if ((employee_id == null)) {
1252.                this.Adapter.InsertCommand.Parameters[4].Value = global::System.DBNull.Value;
1253.            }
1254.            else {
1255.                this.Adapter.InsertCommand.Parameters[4].Value = ((string)(employee_id));
1256.            }
1257.            if ((TransactionDate.HasValue == true)) {
1258.                this.Adapter.InsertCommand.Parameters[5].Value = ((System.DateTime)(TransactionDate.Value));
1259.            }
1260.            else {
1261.                this.Adapter.InsertCommand.Parameters[5].Value = global::System.DBNull.Value;
1262.            }
1263.            global::System.Data.ConnectionState previousConnectionState = this.Adapter.InsertCommand.Connection.State;
1264.            if (((this.Adapter.InsertCommand.Connection.State & global::System.Data.ConnectionState.Open)
1265.                        != global::System.Data.ConnectionState.Open)) {
1266.                this.Adapter.InsertCommand.Connection.Open();
1267.            }
1268.            try {
1269.                int returnValue = this.Adapter.InsertCommand.ExecuteNonQuery();
1270.                return returnValue;
1271.            }
1272.            finally {
1273.                if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
1274.                    this.Adapter.InsertCommand.Connection.Close();
1275.                }
1276.            }
1277.        }
1278.         
1279.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1280.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1281.        [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapter")]
1282.        [global::System.ComponentModel.DataObjectMethodAttribute(global::System.ComponentModel.DataObjectMethodType.Update, true)]
1283.        public virtual int Update(string ZipCode, string City, string State, string Region, string employee_id, global::System.Nullable<global::System.DateTime> TransactionDate, int Original_ID, string Original_ZipCode, string Original_City, string Original_State, string Original_Region, string Original_employee_id, global::System.Nullable<global::System.DateTime> Original_TransactionDate) {
1284.            if ((ZipCode == null)) {
1285.                this.Adapter.UpdateCommand.Parameters[0].Value = global::System.DBNull.Value;
1286.            }
1287.            else {
1288.                this.Adapter.UpdateCommand.Parameters[0].Value = ((string)(ZipCode));
1289.            }
1290.            if ((City == null)) {
1291.                this.Adapter.UpdateCommand.Parameters[1].Value = global::System.DBNull.Value;
1292.            }
1293.            else {
1294.                this.Adapter.UpdateCommand.Parameters[1].Value = ((string)(City));
1295.            }
1296.            if ((State == null)) {
1297.                this.Adapter.UpdateCommand.Parameters[2].Value = global::System.DBNull.Value;
1298.            }
1299.            else {
1300.                this.Adapter.UpdateCommand.Parameters[2].Value = ((string)(State));
1301.            }
1302.            if ((Region == null)) {
1303.                this.Adapter.UpdateCommand.Parameters[3].Value = global::System.DBNull.Value;
1304.            }
1305.            else {
1306.                this.Adapter.UpdateCommand.Parameters[3].Value = ((string)(Region));
1307.            }
1308.            if ((employee_id == null)) {
1309.                this.Adapter.UpdateCommand.Parameters[4].Value = global::System.DBNull.Value;
1310.            }
1311.            else {
1312.                this.Adapter.UpdateCommand.Parameters[4].Value = ((string)(employee_id));
1313.            }
1314.            if ((TransactionDate.HasValue == true)) {
1315.                this.Adapter.UpdateCommand.Parameters[5].Value = ((System.DateTime)(TransactionDate.Value));
1316.            }
1317.            else {
1318.                this.Adapter.UpdateCommand.Parameters[5].Value = global::System.DBNull.Value;
1319.            }
1320.            this.Adapter.UpdateCommand.Parameters[6].Value = ((int)(Original_ID));
1321.            if ((Original_ZipCode == null)) {
1322.                this.Adapter.UpdateCommand.Parameters[7].Value = ((object)(1));
1323.                this.Adapter.UpdateCommand.Parameters[8].Value = global::System.DBNull.Value;
1324.            }
1325.            else {
1326.                this.Adapter.UpdateCommand.Parameters[7].Value = ((object)(0));
1327.                this.Adapter.UpdateCommand.Parameters[8].Value = ((string)(Original_ZipCode));
1328.            }
1329.            if ((Original_City == null)) {
1330.                this.Adapter.UpdateCommand.Parameters[9].Value = ((object)(1));
1331.                this.Adapter.UpdateCommand.Parameters[10].Value = global::System.DBNull.Value;
1332.            }
1333.            else {
1334.                this.Adapter.UpdateCommand.Parameters[9].Value = ((object)(0));
1335.                this.Adapter.UpdateCommand.Parameters[10].Value = ((string)(Original_City));
1336.            }
1337.            if ((Original_State == null)) {
1338.                this.Adapter.UpdateCommand.Parameters[11].Value = ((object)(1));
1339.                this.Adapter.UpdateCommand.Parameters[12].Value = global::System.DBNull.Value;
1340.            }
1341.            else {
1342.                this.Adapter.UpdateCommand.Parameters[11].Value = ((object)(0));
1343.                this.Adapter.UpdateCommand.Parameters[12].Value = ((string)(Original_State));
1344.            }
1345.            if ((Original_Region == null)) {
1346.                this.Adapter.UpdateCommand.Parameters[13].Value = ((object)(1));
1347.                this.Adapter.UpdateCommand.Parameters[14].Value = global::System.DBNull.Value;
1348.            }
1349.            else {
1350.                this.Adapter.UpdateCommand.Parameters[13].Value = ((object)(0));
1351.                this.Adapter.UpdateCommand.Parameters[14].Value = ((string)(Original_Region));
1352.            }
1353.            if ((Original_employee_id == null)) {
1354.                this.Adapter.UpdateCommand.Parameters[15].Value = ((object)(1));
1355.                this.Adapter.UpdateCommand.Parameters[16].Value = global::System.DBNull.Value;
1356.            }
1357.            else {
1358.                this.Adapter.UpdateCommand.Parameters[15].Value = ((object)(0));
1359.                this.Adapter.UpdateCommand.Parameters[16].Value = ((string)(Original_employee_id));
1360.            }
1361.            if ((Original_TransactionDate.HasValue == true)) {
1362.                this.Adapter.UpdateCommand.Parameters[17].Value = ((object)(0));
1363.                this.Adapter.UpdateCommand.Parameters[18].Value = ((System.DateTime)(Original_TransactionDate.Value));
1364.            }
1365.            else {
1366.                this.Adapter.UpdateCommand.Parameters[17].Value = ((object)(1));
1367.                this.Adapter.UpdateCommand.Parameters[18].Value = global::System.DBNull.Value;
1368.            }
1369.            global::System.Data.ConnectionState previousConnectionState = this.Adapter.UpdateCommand.Connection.State;
1370.            if (((this.Adapter.UpdateCommand.Connection.State & global::System.Data.ConnectionState.Open)
1371.                        != global::System.Data.ConnectionState.Open)) {
1372.                this.Adapter.UpdateCommand.Connection.Open();
1373.            }
1374.            try {
1375.                int returnValue = this.Adapter.UpdateCommand.ExecuteNonQuery();
1376.                return returnValue;
1377.            }
1378.            finally {
1379.                if ((previousConnectionState == global::System.Data.ConnectionState.Closed)) {
1380.                    this.Adapter.UpdateCommand.Connection.Close();
1381.                }
1382.            }
1383.        }
1384.    }
1385.     
1386.    /// <summary>
1387.    ///TableAdapterManager is used to coordinate TableAdapters in the dataset to enable Hierarchical Update scenarios
1388.    ///</summary>
1389.    [global::System.ComponentModel.DesignerCategoryAttribute("code")]
1390.    [global::System.ComponentModel.ToolboxItem(true)]
1391.    [global::System.ComponentModel.DesignerAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerDesigner, Microsoft.VSD" +
1392.        "esigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a")]
1393.    [global::System.ComponentModel.Design.HelpKeywordAttribute("vs.data.TableAdapterManager")]
1394.    public partial class TableAdapterManager : global::System.ComponentModel.Component {
1395.         
1396.        private UpdateOrderOption _updateOrder;
1397.         
1398.        private ZipCodeTTableAdapter _zipCodeTTableAdapter;
1399.         
1400.        private bool _backupDataSetBeforeUpdate;
1401.         
1402.        private global::System.Data.IDbConnection _connection;
1403.         
1404.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1405.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1406.        public UpdateOrderOption UpdateOrder {
1407.            get {
1408.                return this._updateOrder;
1409.            }
1410.            set {
1411.                this._updateOrder = value;
1412.            }
1413.        }
1414.         
1415.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1416.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1417.        [global::System.ComponentModel.EditorAttribute("Microsoft.VSDesigner.DataSource.Design.TableAdapterManagerPropertyEditor, Microso" +
1418.            "ft.VSDesigner, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3" +
1419.            "a", "System.Drawing.Design.UITypeEditor")]
1420.        public ZipCodeTTableAdapter ZipCodeTTableAdapter {
1421.            get {
1422.                return this._zipCodeTTableAdapter;
1423.            }
1424.            set {
1425.                this._zipCodeTTableAdapter = value;
1426.            }
1427.        }
1428.         
1429.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1430.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1431.        public bool BackupDataSetBeforeUpdate {
1432.            get {
1433.                return this._backupDataSetBeforeUpdate;
1434.            }
1435.            set {
1436.                this._backupDataSetBeforeUpdate = value;
1437.            }
1438.        }
1439.         
1440.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1441.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1442.        [global::System.ComponentModel.Browsable(false)]
1443.        public global::System.Data.IDbConnection Connection {
1444.            get {
1445.                if ((this._connection != null)) {
1446.                    return this._connection;
1447.                }
1448.                if (((this._zipCodeTTableAdapter != null)
1449.                            && (this._zipCodeTTableAdapter.Connection != null))) {
1450.                    return this._zipCodeTTableAdapter.Connection;
1451.                }
1452.                return null;
1453.            }
1454.            set {
1455.                this._connection = value;
1456.            }
1457.        }
1458.         
1459.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1460.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1461.        [global::System.ComponentModel.Browsable(false)]
1462.        public int TableAdapterInstanceCount {
1463.            get {
1464.                int count = 0;
1465.                if ((this._zipCodeTTableAdapter != null)) {
1466.                    count = (count + 1);
1467.                }
1468.                return count;
1469.            }
1470.        }
1471.         
1472.        /// <summary>
1473.        ///Update rows in top-down order.
1474.        ///</summary>
1475.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1476.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1477.        private int UpdateUpdatedRows(Database2DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
1478.            int result = 0;
1479.            if ((this._zipCodeTTableAdapter != null)) {
1480.                global::System.Data.DataRow[] updatedRows = dataSet.ZipCodeT.Select(null, null, global::System.Data.DataViewRowState.ModifiedCurrent);
1481.                updatedRows = this.GetRealUpdatedRows(updatedRows, allAddedRows);
1482.                if (((updatedRows != null)
1483.                            && (0 < updatedRows.Length))) {
1484.                    result = (result + this._zipCodeTTableAdapter.Update(updatedRows));
1485.                    allChangedRows.AddRange(updatedRows);
1486.                }
1487.            }
1488.            return result;
1489.        }
1490.         
1491.        /// <summary>
1492.        ///Insert rows in top-down order.
1493.        ///</summary>
1494.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1495.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1496.        private int UpdateInsertedRows(Database2DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
1497.            int result = 0;
1498.            if ((this._zipCodeTTableAdapter != null)) {
1499.                global::System.Data.DataRow[] addedRows = dataSet.ZipCodeT.Select(null, null, global::System.Data.DataViewRowState.Added);
1500.                if (((addedRows != null)
1501.                            && (0 < addedRows.Length))) {
1502.                    result = (result + this._zipCodeTTableAdapter.Update(addedRows));
1503.                    allAddedRows.AddRange(addedRows);
1504.                }
1505.            }
1506.            return result;
1507.        }
1508.         
1509.        /// <summary>
1510.        ///Delete rows in bottom-up order.
1511.        ///</summary>
1512.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1513.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1514.        private int UpdateDeletedRows(Database2DataSet dataSet, global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows) {
1515.            int result = 0;
1516.            if ((this._zipCodeTTableAdapter != null)) {
1517.                global::System.Data.DataRow[] deletedRows = dataSet.ZipCodeT.Select(null, null, global::System.Data.DataViewRowState.Deleted);
1518.                if (((deletedRows != null)
1519.                            && (0 < deletedRows.Length))) {
1520.                    result = (result + this._zipCodeTTableAdapter.Update(deletedRows));
1521.                    allChangedRows.AddRange(deletedRows);
1522.                }
1523.            }
1524.            return result;
1525.        }
1526.         
1527.        /// <summary>
1528.        ///Remove inserted rows that become updated rows after calling TableAdapter.Update(inserted rows) first
1529.        ///</summary>
1530.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1531.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1532.        private global::System.Data.DataRow[] GetRealUpdatedRows(global::System.Data.DataRow[] updatedRows, global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows) {
1533.            if (((updatedRows == null)
1534.                        || (updatedRows.Length < 1))) {
1535.                return updatedRows;
1536.            }
1537.            if (((allAddedRows == null)
1538.                        || (allAddedRows.Count < 1))) {
1539.                return updatedRows;
1540.            }
1541.            global::System.Collections.Generic.List<global::System.Data.DataRow> realUpdatedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
1542.            for (int i = 0; (i < updatedRows.Length); i = (i + 1)) {
1543.                global::System.Data.DataRow row = updatedRows[i];
1544.                if ((allAddedRows.Contains(row) == false)) {
1545.                    realUpdatedRows.Add(row);
1546.                }
1547.            }
1548.            return realUpdatedRows.ToArray();
1549.        }
1550.         
1551.        /// <summary>
1552.        ///Update all changes to the dataset.
1553.        ///</summary>
1554.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1555.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1556.        public virtual int UpdateAll(Database2DataSet dataSet) {
1557.            if ((dataSet == null)) {
1558.                throw new global::System.ArgumentNullException("dataSet");
1559.            }
1560.            if ((dataSet.HasChanges() == false)) {
1561.                return 0;
1562.            }
1563.            if (((this._zipCodeTTableAdapter != null)
1564.                        && (this.MatchTableAdapterConnection(this._zipCodeTTableAdapter.Connection) == false))) {
1565.                throw new global::System.ArgumentException("All TableAdapters managed by a TableAdapterManager must use the same connection s" +
1566.                        "tring.");
1567.            }
1568.            global::System.Data.IDbConnection workConnection = this.Connection;
1569.            if ((workConnection == null)) {
1570.                throw new global::System.ApplicationException("TableAdapterManager contains no connection information. Set each TableAdapterMana" +
1571.                        "ger TableAdapter property to a valid TableAdapter instance.");
1572.            }
1573.            bool workConnOpened = false;
1574.            if (((workConnection.State & global::System.Data.ConnectionState.Broken)
1575.                        == global::System.Data.ConnectionState.Broken)) {
1576.                workConnection.Close();
1577.            }
1578.            if ((workConnection.State == global::System.Data.ConnectionState.Closed)) {
1579.                workConnection.Open();
1580.                workConnOpened = true;
1581.            }
1582.            global::System.Data.IDbTransaction workTransaction = workConnection.BeginTransaction();
1583.            if ((workTransaction == null)) {
1584.                throw new global::System.ApplicationException("The transaction cannot begin. The current data connection does not support transa" +
1585.                        "ctions or the current state is not allowing the transaction to begin.");
1586.            }
1587.            global::System.Collections.Generic.List<global::System.Data.DataRow> allChangedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
1588.            global::System.Collections.Generic.List<global::System.Data.DataRow> allAddedRows = new global::System.Collections.Generic.List<global::System.Data.DataRow>();
1589.            global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter> adaptersWithAcceptChangesDuringUpdate = new global::System.Collections.Generic.List<global::System.Data.Common.DataAdapter>();
1590.            global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection> revertConnections = new global::System.Collections.Generic.Dictionary<object, global::System.Data.IDbConnection>();
1591.            int result = 0;
1592.            global::System.Data.DataSet backupDataSet = null;
1593.            if (this.BackupDataSetBeforeUpdate) {
1594.                backupDataSet = new global::System.Data.DataSet();
1595.                backupDataSet.Merge(dataSet);
1596.            }
1597.            try {
1598.                // ---- Prepare for update -----------
1599.                //
1600.                if ((this._zipCodeTTableAdapter != null)) {
1601.                    revertConnections.Add(this._zipCodeTTableAdapter, this._zipCodeTTableAdapter.Connection);
1602.                    this._zipCodeTTableAdapter.Connection = ((global::System.Data.OleDb.OleDbConnection)(workConnection));
1603.                    this._zipCodeTTableAdapter.Transaction = ((global::System.Data.OleDb.OleDbTransaction)(workTransaction));
1604.                    if (this._zipCodeTTableAdapter.Adapter.AcceptChangesDuringUpdate) {
1605.                        this._zipCodeTTableAdapter.Adapter.AcceptChangesDuringUpdate = false;
1606.                        adaptersWithAcceptChangesDuringUpdate.Add(this._zipCodeTTableAdapter.Adapter);
1607.                    }
1608.                }
1609.                //
1610.                //---- Perform updates -----------
1611.                //
1612.                if ((this.UpdateOrder == UpdateOrderOption.UpdateInsertDelete)) {
1613.                    result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
1614.                    result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
1615.                }
1616.                else {
1617.                    result = (result + this.UpdateInsertedRows(dataSet, allAddedRows));
1618.                    result = (result + this.UpdateUpdatedRows(dataSet, allChangedRows, allAddedRows));
1619.                }
1620.                result = (result + this.UpdateDeletedRows(dataSet, allChangedRows));
1621.                //
1622.                //---- Commit updates -----------
1623.                //
1624.                workTransaction.Commit();
1625.                if ((0 < allAddedRows.Count)) {
1626.                    global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
1627.                    allAddedRows.CopyTo(rows);
1628.                    for (int i = 0; (i < rows.Length); i = (i + 1)) {
1629.                        global::System.Data.DataRow row = rows[i];
1630.                        row.AcceptChanges();
1631.                    }
1632.                }
1633.                if ((0 < allChangedRows.Count)) {
1634.                    global::System.Data.DataRow[] rows = new System.Data.DataRow[allChangedRows.Count];
1635.                    allChangedRows.CopyTo(rows);
1636.                    for (int i = 0; (i < rows.Length); i = (i + 1)) {
1637.                        global::System.Data.DataRow row = rows[i];
1638.                        row.AcceptChanges();
1639.                    }
1640.                }
1641.            }
1642.            catch (global::System.Exception ex) {
1643.                workTransaction.Rollback();
1644.                // ---- Restore the dataset -----------
1645.                if (this.BackupDataSetBeforeUpdate) {
1646.                    global::System.Diagnostics.Debug.Assert((backupDataSet != null));
1647.                    dataSet.Clear();
1648.                    dataSet.Merge(backupDataSet);
1649.                }
1650.                else {
1651.                    if ((0 < allAddedRows.Count)) {
1652.                        global::System.Data.DataRow[] rows = new System.Data.DataRow[allAddedRows.Count];
1653.                        allAddedRows.CopyTo(rows);
1654.                        for (int i = 0; (i < rows.Length); i = (i + 1)) {
1655.                            global::System.Data.DataRow row = rows[i];
1656.                            row.AcceptChanges();
1657.                            row.SetAdded();
1658.                        }
1659.                    }
1660.                }
1661.                throw ex;
1662.            }
1663.            finally {
1664.                if (workConnOpened) {
1665.                    workConnection.Close();
1666.                }
1667.                if ((this._zipCodeTTableAdapter != null)) {
1668.                    this._zipCodeTTableAdapter.Connection = ((global::System.Data.OleDb.OleDbConnection)(revertConnections[this._zipCodeTTableAdapter]));
1669.                    this._zipCodeTTableAdapter.Transaction = null;
1670.                }
1671.                if ((0 < adaptersWithAcceptChangesDuringUpdate.Count)) {
1672.                    global::System.Data.Common.DataAdapter[] adapters = new System.Data.Common.DataAdapter[adaptersWithAcceptChangesDuringUpdate.Count];
1673.                    adaptersWithAcceptChangesDuringUpdate.CopyTo(adapters);
1674.                    for (int i = 0; (i < adapters.Length); i = (i + 1)) {
1675.                        global::System.Data.Common.DataAdapter adapter = adapters[i];
1676.                        adapter.AcceptChangesDuringUpdate = true;
1677.                    }
1678.                }
1679.            }
1680.            return result;
1681.        }
1682.         
1683.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1684.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1685.        protected virtual void SortSelfReferenceRows(global::System.Data.DataRow[] rows, global::System.Data.DataRelation relation, bool childFirst) {
1686.            global::System.Array.Sort<global::System.Data.DataRow>(rows, new SelfReferenceComparer(relation, childFirst));
1687.        }
1688.         
1689.        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1690.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1691.        protected virtual bool MatchTableAdapterConnection(global::System.Data.IDbConnection inputConnection) {
1692.            if ((this._connection != null)) {
1693.                return true;
1694.            }
1695.            if (((this.Connection == null)
1696.                        || (inputConnection == null))) {
1697.                return true;
1698.            }
1699.            if (string.Equals(this.Connection.ConnectionString, inputConnection.ConnectionString, global::System.StringComparison.Ordinal)) {
1700.                return true;
1701.            }
1702.            return false;
1703.        }
1704.         
1705.        /// <summary>
1706.        ///Update Order Option
1707.        ///</summary>
1708.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1709.        public enum UpdateOrderOption {
1710.             
1711.            InsertUpdateDelete = 0,
1712.             
1713.            UpdateInsertDelete = 1,
1714.        }
1715.         
1716.        /// <summary>
1717.        ///Used to sort self-referenced table's rows
1718.        ///</summary>
1719.        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1720.        private class SelfReferenceComparer : object, global::System.Collections.Generic.IComparer<global::System.Data.DataRow> {
1721.             
1722.            private global::System.Data.DataRelation _relation;
1723.             
1724.            private int _childFirst;
1725.             
1726.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1727.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1728.            internal SelfReferenceComparer(global::System.Data.DataRelation relation, bool childFirst) {
1729.                this._relation = relation;
1730.                if (childFirst) {
1731.                    this._childFirst = -1;
1732.                }
1733.                else {
1734.                    this._childFirst = 1;
1735.                }
1736.            }
1737.             
1738.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1739.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1740.            private global::System.Data.DataRow GetRoot(global::System.Data.DataRow row, out int distance) {
1741.                global::System.Diagnostics.Debug.Assert((row != null));
1742.                global::System.Data.DataRow root = row;
1743.                distance = 0;
1744. 
1745.                global::System.Collections.Generic.IDictionary<global::System.Data.DataRow, global::System.Data.DataRow> traversedRows = new global::System.Collections.Generic.Dictionary<global::System.Data.DataRow, global::System.Data.DataRow>();
1746.                traversedRows[row] = row;
1747. 
1748.                global::System.Data.DataRow parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
1749.                for (
1750.                ; ((parent != null)
1751.                            && (traversedRows.ContainsKey(parent) == false));
1752.                ) {
1753.                    distance = (distance + 1);
1754.                    root = parent;
1755.                    traversedRows[parent] = parent;
1756.                    parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Default);
1757.                }
1758. 
1759.                if ((distance == 0)) {
1760.                    traversedRows.Clear();
1761.                    traversedRows[row] = row;
1762.                    parent = row.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
1763.                    for (
1764.                    ; ((parent != null)
1765.                                && (traversedRows.ContainsKey(parent) == false));
1766.                    ) {
1767.                        distance = (distance + 1);
1768.                        root = parent;
1769.                        traversedRows[parent] = parent;
1770.                        parent = parent.GetParentRow(this._relation, global::System.Data.DataRowVersion.Original);
1771.                    }
1772.                }
1773. 
1774.                return root;
1775.            }
1776.             
1777.            [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
1778.            [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Data.Design.TypedDataSetGenerator", "4.0.0.0")]
1779.            public int Compare(global::System.Data.DataRow row1, global::System.Data.DataRow row2) {
1780.                if (object.ReferenceEquals(row1, row2)) {
1781.                    return 0;
1782.                }
1783.                if ((row1 == null)) {
1784.                    return -1;
1785.                }
1786.                if ((row2 == null)) {
1787.                    return 1;
1788.                }
1789. 
1790.                int distance1 = 0;
1791.                global::System.Data.DataRow root1 = this.GetRoot(row1, out distance1);
1792. 
1793.                int distance2 = 0;
1794.                global::System.Data.DataRow root2 = this.GetRoot(row2, out distance2);
1795. 
1796.                if (object.ReferenceEquals(root1, root2)) {
1797.                    return (this._childFirst * distance1.CompareTo(distance2));
1798.                }
1799.                else {
1800.                    global::System.Diagnostics.Debug.Assert(((root1.Table != null)
1801.                                    && (root2.Table != null)));
1802.                    if ((root1.Table.Rows.IndexOf(root1) < root2.Table.Rows.IndexOf(root2))) {
1803.                        return -1;
1804.                    }
1805.                    else {
1806.                        return 1;
1807.                    }
1808.                }
1809.            }
1810.        }
1811.    }
1812.}
1813. 
1814.#pragma warning restore 1591

แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-04 17:41:40 By : lamaka.tor
 

 

No. 6



โพสกระทู้ ( 7 )
บทความ ( 0 )



สถานะออฟไลน์
Facebook

ตอบความคิดเห็นที่ : 5 เขียนโดย : lamaka.tor เมื่อวันที่ 2016-06-04 17:41:40
รายละเอียดของการตอบ ::
@user

แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-04 19:20:12 By : nittaya28
 

 

No. 7



โพสกระทู้ ( 4,440 )
บทความ ( 23 )



สถานะออฟไลน์
Facebook

ไม่เอาโค้ด มาด้วยละครับ
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-06 08:23:08 By : lamaka.tor
 

 

No. 8



โพสกระทู้ ( 4,440 )
บทความ ( 23 )



สถานะออฟไลน์
Facebook

ลองเอา โค๊ดจาก DataSource Wizard แบบบ้าน ๆ ไปแกะดูครับ
ตัวนี้ผมใช้ OleDb เผื่องงภายหลัง

Code (VB.NET)
001.Private Sub InitAdapter()
002.            Me._adapter = New OleDbDataAdapter()
003.            Dim tableMapping As Global.System.Data.Common.DataTableMapping = New Global.System.Data.Common.DataTableMapping()
004.            tableMapping.SourceTable = "Table"
005.            tableMapping.DataSetTable = "tblBrand"
006.            tableMapping.ColumnMappings.Add("bndID", "bndID")
007.            tableMapping.ColumnMappings.Add("Brand_1", "Brand_1")
008.            tableMapping.ColumnMappings.Add("Brand_2", "Brand_2")
009.            tableMapping.ColumnMappings.Add("Brand_3", "Brand_3")
010.            Me._adapter.TableMappings.Add(tableMapping)
011.            Me._adapter.DeleteCommand = New OleDbCommand()
012.            Me._adapter.DeleteCommand.Connection = Me.Connection
013.            Me._adapter.DeleteCommand.CommandText = "DELETE FROM `tblBrand` WHERE ((`bndID` = ?) AND ((? = 1 AND `Brand_1` IS NULL) OR" & _
014.                " (`Brand_1` = ?)) AND ((? = 1 AND `Brand_2` IS NULL) OR (`Brand_2` = ?)) AND ((?" & _
015.                " = 1 AND `Brand_3` IS NULL) OR (`Brand_3` = ?)))"
016.            Me._adapter.DeleteCommand.CommandType = Global.System.Data.CommandType.Text
017.            Me._adapter.DeleteCommand.Parameters.Add(New OleDbParameter("Original_bndID", OleDbType.[Integer], 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "bndID", Global.System.Data.DataRowVersion.Original, False, Nothing))
018.            Me._adapter.DeleteCommand.Parameters.Add(New OleDbParameter("IsNull_Brand_1", OleDbType.[Integer], 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_1", Global.System.Data.DataRowVersion.Original, True, Nothing))
019.            Me._adapter.DeleteCommand.Parameters.Add(New OleDbParameter("Original_Brand_1", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_1", Global.System.Data.DataRowVersion.Original, False, Nothing))
020.            Me._adapter.DeleteCommand.Parameters.Add(New OleDbParameter("IsNull_Brand_2", OleDbType.[Integer], 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_2", Global.System.Data.DataRowVersion.Original, True, Nothing))
021.            Me._adapter.DeleteCommand.Parameters.Add(New OleDbParameter("Original_Brand_2", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_2", Global.System.Data.DataRowVersion.Original, False, Nothing))
022.            Me._adapter.DeleteCommand.Parameters.Add(New OleDbParameter("IsNull_Brand_3", OleDbType.[Integer], 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_3", Global.System.Data.DataRowVersion.Original, True, Nothing))
023.            Me._adapter.DeleteCommand.Parameters.Add(New OleDbParameter("Original_Brand_3", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_3", Global.System.Data.DataRowVersion.Original, False, Nothing))
024.            Me._adapter.InsertCommand = New OleDbCommand()
025.            Me._adapter.InsertCommand.Connection = Me.Connection
026.            Me._adapter.InsertCommand.CommandText = "INSERT INTO `tblBrand` (`Brand_1`, `Brand_2`, `Brand_3`) VALUES (?, ?, ?)"
027.            Me._adapter.InsertCommand.CommandType = Global.System.Data.CommandType.Text
028.            Me._adapter.InsertCommand.Parameters.Add(New OleDbParameter("Brand_1", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_1", Global.System.Data.DataRowVersion.Current, False, Nothing))
029.            Me._adapter.InsertCommand.Parameters.Add(New OleDbParameter("Brand_2", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_2", Global.System.Data.DataRowVersion.Current, False, Nothing))
030.            Me._adapter.InsertCommand.Parameters.Add(New OleDbParameter("Brand_3", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_3", Global.System.Data.DataRowVersion.Current, False, Nothing))
031.            Me._adapter.UpdateCommand = New OleDbCommand()
032.            Me._adapter.UpdateCommand.Connection = Me.Connection
033.            Me._adapter.UpdateCommand.CommandText = "UPDATE `tblBrand` SET `Brand_1` = ?, `Brand_2` = ?, `Brand_3` = ? WHERE ((`bndID`" & _
034.                " = ?) AND ((? = 1 AND `Brand_1` IS NULL) OR (`Brand_1` = ?)) AND ((? = 1 AND `Br" & _
035.                "and_2` IS NULL) OR (`Brand_2` = ?)) AND ((? = 1 AND `Brand_3` IS NULL) OR (`Bran" & _
036.                "d_3` = ?)))"
037.            Me._adapter.UpdateCommand.CommandType = Global.System.Data.CommandType.Text
038.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("Brand_1", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_1", Global.System.Data.DataRowVersion.Current, False, Nothing))
039.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("Brand_2", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_2", Global.System.Data.DataRowVersion.Current, False, Nothing))
040.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("Brand_3", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_3", Global.System.Data.DataRowVersion.Current, False, Nothing))
041.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("Original_bndID", OleDbType.[Integer], 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "bndID", Global.System.Data.DataRowVersion.Original, False, Nothing))
042.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("IsNull_Brand_1", OleDbType.[Integer], 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_1", Global.System.Data.DataRowVersion.Original, True, Nothing))
043.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("Original_Brand_1", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_1", Global.System.Data.DataRowVersion.Original, False, Nothing))
044.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("IsNull_Brand_2", OleDbType.[Integer], 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_2", Global.System.Data.DataRowVersion.Original, True, Nothing))
045.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("Original_Brand_2", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_2", Global.System.Data.DataRowVersion.Original, False, Nothing))
046.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("IsNull_Brand_3", OleDbType.[Integer], 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_3", Global.System.Data.DataRowVersion.Original, True, Nothing))
047.            Me._adapter.UpdateCommand.Parameters.Add(New OleDbParameter("Original_Brand_3", OleDbType.VarWChar, 0, Global.System.Data.ParameterDirection.Input, CType(0, Byte), CType(0, Byte), "Brand_3", Global.System.Data.DataRowVersion.Original, False, Nothing))
048.        End Sub
049. 
050. 
051. 
052.Public Overridable Overloads Function Delete(ByVal Original_bndID As Integer, ByVal Original_Brand_1 As String, ByVal Original_Brand_2 As String, ByVal Original_Brand_3 As String) As Integer
053.            Me.Adapter.DeleteCommand.Parameters(0).Value = CType(Original_bndID, Integer)
054.            If (Original_Brand_1 Is Nothing) Then
055.                Me.Adapter.DeleteCommand.Parameters(1).Value = CType(1, Object)
056.                Me.Adapter.DeleteCommand.Parameters(2).Value = Global.System.DBNull.Value
057.            Else
058.                Me.Adapter.DeleteCommand.Parameters(1).Value = CType(0, Object)
059.                Me.Adapter.DeleteCommand.Parameters(2).Value = CType(Original_Brand_1, String)
060.            End If
061.            If (Original_Brand_2 Is Nothing) Then
062.                Me.Adapter.DeleteCommand.Parameters(3).Value = CType(1, Object)
063.                Me.Adapter.DeleteCommand.Parameters(4).Value = Global.System.DBNull.Value
064.            Else
065.                Me.Adapter.DeleteCommand.Parameters(3).Value = CType(0, Object)
066.                Me.Adapter.DeleteCommand.Parameters(4).Value = CType(Original_Brand_2, String)
067.            End If
068.            If (Original_Brand_3 Is Nothing) Then
069.                Me.Adapter.DeleteCommand.Parameters(5).Value = CType(1, Object)
070.                Me.Adapter.DeleteCommand.Parameters(6).Value = Global.System.DBNull.Value
071.            Else
072.                Me.Adapter.DeleteCommand.Parameters(5).Value = CType(0, Object)
073.                Me.Adapter.DeleteCommand.Parameters(6).Value = CType(Original_Brand_3, String)
074.            End If
075.            Dim previousConnectionState As Global.System.Data.ConnectionState = Me.Adapter.DeleteCommand.Connection.State
076.            If ((Me.Adapter.DeleteCommand.Connection.State And Global.System.Data.ConnectionState.Open) _
077.                        <> Global.System.Data.ConnectionState.Open) Then
078.                Me.Adapter.DeleteCommand.Connection.Open()
079.            End If
080.            Try
081.                Dim returnValue As Integer = Me.Adapter.DeleteCommand.ExecuteNonQuery
082.                Return returnValue
083.            Finally
084.                If (previousConnectionState = Global.System.Data.ConnectionState.Closed) Then
085.                    Me.Adapter.DeleteCommand.Connection.Close()
086.                End If
087.            End Try
088.        End Function
089.        Public Overridable Overloads Function Insert(ByVal Brand_1 As String, ByVal Brand_2 As String, ByVal Brand_3 As String) As Integer
090.            If (Brand_1 Is Nothing) Then
091.                Me.Adapter.InsertCommand.Parameters(0).Value = Global.System.DBNull.Value
092.            Else
093.                Me.Adapter.InsertCommand.Parameters(0).Value = CType(Brand_1, String)
094.            End If
095.            If (Brand_2 Is Nothing) Then
096.                Me.Adapter.InsertCommand.Parameters(1).Value = Global.System.DBNull.Value
097.            Else
098.                Me.Adapter.InsertCommand.Parameters(1).Value = CType(Brand_2, String)
099.            End If
100.            If (Brand_3 Is Nothing) Then
101.                Me.Adapter.InsertCommand.Parameters(2).Value = Global.System.DBNull.Value
102.            Else
103.                Me.Adapter.InsertCommand.Parameters(2).Value = CType(Brand_3, String)
104.            End If
105.            Dim previousConnectionState As Global.System.Data.ConnectionState = Me.Adapter.InsertCommand.Connection.State
106.            If ((Me.Adapter.InsertCommand.Connection.State And Global.System.Data.ConnectionState.Open) _
107.                        <> Global.System.Data.ConnectionState.Open) Then
108.                Me.Adapter.InsertCommand.Connection.Open()
109.            End If
110.            Try
111.                Dim returnValue As Integer = Me.Adapter.InsertCommand.ExecuteNonQuery
112.                Return returnValue
113.            Finally
114.                If (previousConnectionState = Global.System.Data.ConnectionState.Closed) Then
115.                    Me.Adapter.InsertCommand.Connection.Close()
116.                End If
117.            End Try
118.        End Function
119.        Public Overridable Overloads Function Update(ByVal Brand_1 As String, ByVal Brand_2 As String, ByVal Brand_3 As String, ByVal Original_bndID As Integer, ByVal Original_Brand_1 As String, ByVal Original_Brand_2 As String, ByVal Original_Brand_3 As String) As Integer
120.            If (Brand_1 Is Nothing) Then
121.                Me.Adapter.UpdateCommand.Parameters(0).Value = Global.System.DBNull.Value
122.            Else
123.                Me.Adapter.UpdateCommand.Parameters(0).Value = CType(Brand_1, String)
124.            End If
125.            If (Brand_2 Is Nothing) Then
126.                Me.Adapter.UpdateCommand.Parameters(1).Value = Global.System.DBNull.Value
127.            Else
128.                Me.Adapter.UpdateCommand.Parameters(1).Value = CType(Brand_2, String)
129.            End If
130.            If (Brand_3 Is Nothing) Then
131.                Me.Adapter.UpdateCommand.Parameters(2).Value = Global.System.DBNull.Value
132.            Else
133.                Me.Adapter.UpdateCommand.Parameters(2).Value = CType(Brand_3, String)
134.            End If
135.            Me.Adapter.UpdateCommand.Parameters(3).Value = CType(Original_bndID, Integer)
136.            If (Original_Brand_1 Is Nothing) Then
137.                Me.Adapter.UpdateCommand.Parameters(4).Value = CType(1, Object)
138.                Me.Adapter.UpdateCommand.Parameters(5).Value = Global.System.DBNull.Value
139.            Else
140.                Me.Adapter.UpdateCommand.Parameters(4).Value = CType(0, Object)
141.                Me.Adapter.UpdateCommand.Parameters(5).Value = CType(Original_Brand_1, String)
142.            End If
143.            If (Original_Brand_2 Is Nothing) Then
144.                Me.Adapter.UpdateCommand.Parameters(6).Value = CType(1, Object)
145.                Me.Adapter.UpdateCommand.Parameters(7).Value = Global.System.DBNull.Value
146.            Else
147.                Me.Adapter.UpdateCommand.Parameters(6).Value = CType(0, Object)
148.                Me.Adapter.UpdateCommand.Parameters(7).Value = CType(Original_Brand_2, String)
149.            End If
150.            If (Original_Brand_3 Is Nothing) Then
151.                Me.Adapter.UpdateCommand.Parameters(8).Value = CType(1, Object)
152.                Me.Adapter.UpdateCommand.Parameters(9).Value = Global.System.DBNull.Value
153.            Else
154.                Me.Adapter.UpdateCommand.Parameters(8).Value = CType(0, Object)
155.                Me.Adapter.UpdateCommand.Parameters(9).Value = CType(Original_Brand_3, String)
156.            End If
157.            Dim previousConnectionState As Global.System.Data.ConnectionState = Me.Adapter.UpdateCommand.Connection.State
158.            If ((Me.Adapter.UpdateCommand.Connection.State And Global.System.Data.ConnectionState.Open) _
159.                        <> Global.System.Data.ConnectionState.Open) Then
160.                Me.Adapter.UpdateCommand.Connection.Open()
161.            End If
162.            Try
163.                Dim returnValue As Integer = Me.Adapter.UpdateCommand.ExecuteNonQuery
164.                Return returnValue
165.            Finally
166.                If (previousConnectionState = Global.System.Data.ConnectionState.Closed) Then
167.                    Me.Adapter.UpdateCommand.Connection.Close()
168.                End If
169.            End Try
170.        End Function

แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-06 08:46:07 By : lamaka.tor
 

 

No. 9

Guest


Code (VB.NET)
01.sql = "inset into [Users] ([Username], [Password], [name], [lastname], [nickname], [e-mail], [phone]) values (@Username, @Password, @name, @lastname, @nickname, @email, @phone);"
02. 
03.cmd.Parameters.AddWithValue("@Username", TextBoxUsername.Text)
04.cmd.Parameters.AddWithValue("@Password", TextBoxPassword.Text)
05.cmd.Parameters.AddWithValue("@name", TextBoxName.Textl)
06.cmd.Parameters.AddWithValue("@lastname", TextBoxUsername.Text)
07.cmd.Parameters.AddWithValue("@nickname", TextBoxNickname.Text)
08.cmd.Parameters.AddWithValue("@email", TextBoxEmail.Text)
09.cmd.Parameters.AddWithValue("@phone", TextBoxPhone.Text)


Quote:
*เป็นมือใหม่คะ ทำโปรเจคจบ แต่อาจารย์ สอนไม่ลงลึกต้องมาศึกษาเอง รบกวนช่วยด้วยนะคะ


- อ.ทำถูกต้องแล้ว เรียนระดับนี้ไม่สอนจับมือเขียนแล้ว ปี 4 ทำโปรเจ็คจบแล้วยังเขียนไม่เป็นนี่แย่นะ
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-06 10:31:39 By : ห้ามตอบเกินวันละ 2 กระทู้
 

 

No. 10



โพสกระทู้ ( 242 )
บทความ ( 0 )



สถานะออฟไลน์


เอ็งก็เปลี่ยนจาก cmd_ เป็น cmd. สิ คริๆ
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-11 23:49:35 By : bigsuntat
 

 

No. 11



โพสกระทู้ ( 281 )
บทความ ( 0 )



สถานะออฟไลน์


เปลี่ยนไปใช้ TableAdapter แทนได้มั้ย
แสดงความคิดเห็นโดยอ้างถึง ความคิดเห็นนี้
Date : 2016-06-12 16:09:17 By : deksoke
 

   

ค้นหาข้อมูล


   
 

แสดงความคิดเห็น
Re : insert ข้อมูล แล้วข้อมูลที่เพิ่มไม่ขึ้นอย่างที่พิมพ์ไป
 
 
รายละเอียด
 
ตัวหนา ตัวเอียง ตัวขีดเส้นใต้ ตัวมีขีดกลาง| ตัวเรืองแสง ตัวมีเงา ตัวอักษรวิ่ง| จัดย่อหน้าอิสระ จัดย่อหน้าชิดซ้าย จัดย่อหน้ากึ่งกลาง จัดย่อหน้าชิดขวา| เส้นขวาง| ขนาดตัวอักษร แบบตัวอักษร
ใส่แฟลช ใส่รูป ใส่ไฮเปอร์ลิ้งค์ ใส่อีเมล์ ใส่ลิ้งค์ FTP| ใส่แถวของตาราง ใส่คอลัมน์ตาราง| ตัวยก ตัวห้อย ตัวพิมพ์ดีด| ใส่โค้ด ใส่การอ้างถึงคำพูด| ใส่ลีสต์
smiley for :lol: smiley for :ken: smiley for :D smiley for :) smiley for ;) smiley for :eek: smiley for :geek: smiley for :roll: smiley for :erm: smiley for :cool: smiley for :blank: smiley for :idea: smiley for :ehh: smiley for :aargh: smiley for :evil:
Insert PHP Code
Insert ASP Code
Insert VB.NET Code Insert C#.NET Code Insert JavaScript Code Insert C#.NET Code
Insert Java Code
Insert Android Code
Insert Objective-C Code
Insert XML Code
Insert SQL Code
Insert Code
เพื่อความเรียบร้อยของข้อความ ควรจัดรูปแบบให้พอดีกับขนาดของหน้าจอ เพื่อง่ายต่อการอ่านและสบายตา และตรวจสอบภาษาไทยให้ถูกต้อง

อัพโหลดแทรกรูปภาพ

Notice

เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ
อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง

   
  เพื่อความปลอดภัยและการตรวจสอบ กระทู้ที่แทรกไฟล์อัพโหลดไฟล์จากที่อื่น อาจจะถูกลบทิ้ง
 
โดย
อีเมล์
บวกค่าให้ถูก
<= ตัวเลขฮินดูอารบิก เช่น 123 (หรือล็อกอินเข้าระบบสมาชิกเพื่อไม่ต้องกรอก)





Load balance : Server 05
ThaiCreate.Com Logo
© www.ThaiCreate.Com. 2003-2025 All Rights Reserved.
ไทยครีเอทบริการ จัดทำดูแลแก้ไข Web Application ทุกรูปแบบ (PHP, .Net Application, VB.Net, C#)
[Conditions Privacy Statement] ติดต่อโฆษณา 081-987-6107 อัตราราคา คลิกที่นี่