Tài liệu Practical Database Programming With Visual C#.NET- P1 doc

50 520 2
Tài liệu Practical Database Programming With Visual C#.NET- P1 doc

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

Thông tin tài liệu

Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. babout.indd 904babout.indd 904 2/11/2010 11:47:38 AM2/11/2010 11:47:38 AM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Practical Database Programming With Visual C#.NET ffirs01.indd iffirs01.indd i 2/11/2010 12:02:41 PM2/11/2010 12:02:41 PM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. IEEE Press 445 Hoes Lane Piscataway, NJ 08854 IEEE Press Editorial Board Lajos Hanzo, Editor in Chief R. Abari T. Chen B. M. Hammerli J. Anderson T. G. Croda O. Malik S. Basu M. El - Hawary S. Nahavandi A. Chatterjee S. Farshchi W. Reeve Kenneth Moore, Director of IEEE Book and Information Services (BIS) ffirs01.indd iiffirs01.indd ii 2/11/2010 12:02:41 PM2/11/2010 12:02:41 PM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Practical Database Programming With Visual C#.NET Ying Bai Department of Computer Science and Engineering Johnson C. Smith University Charlotte, North Carolina IEEE PRESS A John Wiley & Sons, Inc., Publication ffirs01.indd iiiffirs01.indd iii 2/11/2010 12:02:41 PM2/11/2010 12:02:41 PM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Copyright © 2010 by the Institute of Electrical and Electronics Engineers, Inc. Published by John Wiley & Sons, Inc., Hoboken, New Jersey. All rights reserved. Published simultaneously in Canada No part of this publication may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, electronic, mechanical, photocopying, recording, scanning, or otherwise, except as permitted under Section 107 or 108 of the 1976 United States Copyright Act, without either the prior written permission of the Publisher, or authorization through payment of the appropriate per-copy fee to the Copyright Clearance Center, Inc., 222 Rosewood Drive, Danvers, MA 01923, (978) 750-8400, fax (978) 750-4470, or on the web at www.copyright.com. Requests to the Publisher for permission should be addressed to the Permissions Department, John Wiley & Sons, Inc., 111 River Street, Hoboken, NJ 07030, (201) 748-6011, fax (201) 748-6008, or online at http://www.wiley.com/go/permission. Limit of Liability/Disclaimer of Warranty: While the publisher and author have used their best efforts in preparing this book, they make no representations or warranties with respect to the accuracy or complete- ness of the contents of this book and specifi cally disclaim any implied warranties of merchantability or fi tness for a particular purpose. No warranty may be created or extended by sales representatives or written sales materials. The advice and strategies contained herein may not be suitable for your situation. You should consult with a professional where appropriate. Neither the publisher nor author shall be liable for any loss of profi t or any other commercial damages, including but not limited to special, incidental, consequential, or other damages. For general information on our other products and services or for technical support, please contact our Customer Care Department within the United States at (800) 762-2974, outside the United States at (317) 572-3993 or fax (317) 572-4002. Wiley also publishes its books in a variety of electronic formats. Some content that appears in print may not be available in electronic formats. For more information about Wiley products, visit our web site at www. wiley.com. Library of Congress Cataloging-in-Publication Data: Bai, Ying, 1956– Practical database programming with Visual C#.NET / Ying Bai. p. cm. Includes index. ISBN 978-0-470-46727-5 (cloth) 1. Microsoft Visual C# .NET. 2. C# (Computer program language) 3. Database design. 4. Microsoft .NET. I. Title. QA76.73.C154B347 2009 006.7'882–dc22 2009025977 Printed in the United States of America 10 9 8 7 6 5 4 3 2 1 ffirs01.indd ivffirs01.indd iv 2/11/2010 12:02:43 PM2/11/2010 12:02:43 PM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. To my wife, Yan Wang, and my daughter, Xue Bai ffirs02.indd vffirs02.indd v 2/11/2010 12:02:47 PM2/11/2010 12:02:47 PM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. ffirs02.indd viffirs02.indd vi 2/11/2010 12:02:47 PM2/11/2010 12:02:47 PM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. Contents Preface xxiii Acknowledgment xxv 1 Introduction 1 Outstanding Features of the Book 2 Target Audience 2 Topics Covered 3 Organization of the Book and How to Use It 5 How to Use the Source Code and Sample Databases 6 Instructor and Customer Support 7 Homework Solutions 8 2 Introduction to Databases 11 2.1 What Are Databases and Database Programs? 12 2.1.1 File Processing System 12 2.1.2 Integrated Databases 13 2.2 Develop a Database 14 2.3 Sample Database 15 2.3.1 Relational Data Model 18 2.3.2 Entity-Relationship Model (ER) 18 2.4 Identifying Keys 19 2.4.1 Primary Key and Entity Integrity 19 2.4.2 Candidate Key 19 2.4.3 Foreign Keys and Referential Integrity 19 2.5 Defi ne Relationships 20 2.5.1 Connectivity 20 2.6 ER Notation 23 2.7 Data Normalization 24 2.7.1 First Normal Form (1NF) 25 2.7.2 Second Normal Form (2NF) 25 2.7.3 Third Normal Form (3NF) 26 2.8 Database Components in Some Popular Databases 28 2.8.1 Microsoft Access Databases 28 vii ftoc.indd viiftoc.indd vii 2/11/2010 2:43:34 PM2/11/2010 2:43:34 PM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. viii Contents 2.8.1.1 Database File 29 2.8.1.2 Tables 29 2.8.1.3 Queries 29 2.8.2 SQL Server Databases 29 2.8.2.1 Data Files 30 2.8.2.2 Tables 30 2.8.2.3 Views 31 2.8.2.4 Stored Procedures 31 2.8.2.5 Keys and Relationships 31 2.8.2.6 Indexes 32 2.8.2.7 Transaction Log Files 32 2.8.3 Oracle Databases 32 2.8.3.1 Data Files 33 2.8.3.2 Tables 33 2.8.3.3 Views 33 2.8.3.4 Stored Procedures 33 2.8.3.5 Indexes 34 2.8.3.6 Initialization Parameter Files 35 2.8.3.7 Control Files 35 2.8.3.8 Redo Log Files 35 2.8.3.9 Password Files 35 2.9 Create Microsoft Access Sample Database 36 2.9.1 Create LogIn Table 36 2.9.2 Create Faculty Table 38 2.9.3 Create Other Tables 40 2.9.4 Create Relationships Among Tables 42 2.10 Create Microsoft SQL Server 2005 Sample Database 46 2.10.1 Create LogIn Table 48 2.10.2 Create Faculty Table 50 2.10.3 Create Other Tables 51 2.10.4 Create Relationships Among Tables 56 2.10.4.1 Create Relationship Between LogIn and Faculty Tables 56 2.10.4.2 Create Relationship Between LogIn and Student Tables 59 2.10.4.3 Create Relationship Between Faculty and Course Tables 59 2.10.4.4 Create Relationship Between Student and StudentCourse Tables 60 2.10.4.5 Create Relationship Between Course and StudentCourse Tables 62 2.11 Create Oracle 10g XE Sample Database 63 2.11.1 Create Oracle User Database 64 2.11.2 Add New Data Tables into Oracle User Database 65 2.11.2.1 Create LogIn Table 66 2.11.2.2 Create Faculty Table 72 2.11.2.3 Create Other Tables 75 2.11.3 Create Constraints Between Tables 78 2.11.3.1 Create Constraints Between LogIn and Faculty Tables 80 2.11.3.2 Create Constraints Between LogIn and Student Tables 81 ftoc.indd viiiftoc.indd viii 2/11/2010 2:43:34 PM2/11/2010 2:43:34 PM Please purchase PDF Split-Merge on www.verypdf.com to remove this watermark. [...]... students and software programmers who want to develop practical and commercial database programming with Visual C#.NET 2008 and relational databases such as Microsoft Access, SQL Server 2005, and Oracle Database 10 g XE The book provides a detailed description about practical considerations and applications in database programming with Visual C# 2008 with authentic examples and detailed explanations More... contains two programming Practical Database Programming With Visual C#.NET, by Ying Bai Copyright © 2010 the Institute of Electrical and Electronics Engineers, Inc 1 2 Chapter 1 Introduction methods: the fundamental database programming method Visual Studio.NET 2008 Design Tools and Wizards—and an advanced database programming method— the runtime objects method In the second method, all database- related... learning and developing practical database programs, and to avoid the headaches caused by using huge blocks of code in the traditional database programming books 2 Covers both fundamental and advanced database programming techniques for both beginning and experienced students as well as programmers 3 Three types of popular databases are covered and discussed in detail with practical examples: Microsoft... This book is designed for college students and software programmers who want to develop practical and commercial database programming with Visual C#.NET 2008 and relational databases such as Microsoft Access, SQL Server 2005, and Oracle Database 10 g XE Fundamental knowledge and understanding of Visual C#.NET and Visual Studio.NET IDE is assumed Topics Covered 3 TOPICS COVERED Nine chapters are included... structure and components about relational databases Some key technologies in developing and designing databases are also discussed The procedures and components used to develop a practical relational database with three database versions such as Microsoft Access, SQL Server 2005, and Oracle Database 10 g XE are analyzed in detail with some real data tables in the sample database CSE_DEPT • Chapter 3 provides... Homework 434 xiv Contents 6 Data Inserting with Visual C#.NET PART I 6.1 Data Inserting with Visual Studio.NET Design Tools and Wizards 439 440 Insert New Data into a Database 440 6.1.1 Insert New Records into a Database Using TableAdapter.Insert Method 441 6.1.2 Insert New Records into a Database Using TableAdapter.Update Method 442 6.2 Insert Data into Microsoft Access Database Using Sample Project InsertWizard... programming books on the current market, which discuss and present database programming techniques with huge blocks of programming codes from the first page to the last page, this book uses a new writing style to show readers, especially college students, how to develop professional and practical database programs in Visual C# 2008 by using Visual Studio.NET 2008 Design Tools and Wizards related to ADO... implemented in this book, combined with real examples, to provide readers with a clear picture as how to handle the database programming issues in Visual C#.NET 2008 environment The outstanding features of this book include, but are not limited to: 1 A novel writing style is adopted to try to attract students’ or beginning programmers’ interested in learning and developing practical database programs, and to... of codes in the traditional database programming books xxiii xxiv Preface 2 A real completed sample database CSE_DEPT with three versions (Microsoft Access 2007, SQL Server 2005 SP2, and Oracle Database 10 g XE Release 2) is provided and used throughout the entire book Step by step, detailed illustrations and descriptions about how to design and build a practical relational database are provided 3 Both... beginning programmers who are new to Visual Studio.NET and database programming I have had to prepare class presentations and develop homework problems and exercises for my students I used to dream that one day I would find a good textbook that would be suitable for college students or beginning programmers and help them to learn and master database programming with Visual C#.NET easily and conveniently . 1956– Practical database programming with Visual C#. NET / Ying Bai. p. cm. Includes index. ISBN 978-0-470-46727-5 (cloth) 1. Microsoft Visual C# .NET Query with Visual C#. NET 235 PART I Data Query with Visual Studio Design Tools and Wizards 236 5.1 Completed Sample Database Application Example 236 5.2 Visual

Ngày đăng: 26/01/2014, 08:20

Từ khóa liên quan

Mục lục

  • Practical Database Programming With Visual C#.NET

    • Contents

    • Preface

    • Acknowledgment

    • 1 Introduction

      • Outstanding Features of the Book

      • Target Audience

      • Topics Covered

      • Organization of the Book and How to Use It

      • How to Use the Source Code and Sample Databases

      • Instructor and Customer Support

      • Homework Solutions

      • 2 Introduction to Databases

        • 2.1 What Are Databases and Database Programs?

          • 2.1.1 File Processing System

          • 2.1.2 Integrated Databases

          • 2.2 Develop a Database

          • 2.3 Sample Database

            • 2.3.1 Relational Data Model

            • 2.3.2 Entity-Relationship Model (ER)

            • 2.4 Identifying Keys

              • 2.4.1 Primary Key and Entity Integrity

              • 2.4.2 Candidate Key

              • 2.4.3 Foreign Keys and Referential Integrity

              • 2.5 Define Relationships

                • 2.5.1 Connectivity

                • 2.6 ER Notation

Tài liệu cùng người dùng

  • Đang cập nhật ...

Tài liệu liên quan