Question

How to Create a Master/Detail Page with Web Form Controls (A normal form link to a gridview + Insert record)

Asked by: bkerson

Hello,

Can you provide some help about linking two ranges of information in two related tables.

First table
Student(Student_ID, FirstName, LastName)

Second Table
Notes(Notes_ID, Student_ID, Grades, TeacherName)

Note: My database is in ms sql and and I'm using visual web developer with code behind c#. Also you can use either a panel, Details view or a form view for Student but necessary a grid view for Notes

They are related ( 1, n) I would like to open the page in read only mode and be able to see 1 student and its grades, navigate and be able to update, insert record in both the Form and the grid view. I have some good ideas but not able to complete it the way i want. Any help will begreatly appreciated. Please send sample with code behind c#

Thank you in advanced.

This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.

Subscribe now for full access to Experts Exchange and get

Instant Access to this Solution

  • Plus...
  • 30 Day FREE access, no risk, no obligation
  • Collaborate with the world's top tech experts
  • Unlimited access to our exclusive solution database
  • Never be left without tech help again

Subscribe Now

Asked On
2009-11-06 at 10:35:48ID24878865
Topics

MS SQL Server

,

WebApplications

,

Programming for ASP.NET

Participating Experts
2
Points
250
Comments
12

Trusted by hundreds of thousands everyday for fast, accurate and reliable tech support.

  • "The time we save is the biggest benefit of Experts Exchange to Warner Bros. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange." Mike Kapnisakis, Warner Bros.
  • "Our team likes having a resource that is more secure than just using Google and most experts using this service really know their stuff. It's nice to look here first versus using Google." Dayna Sellner, Lockheed Martin
  • "Anytime that I've been stumped with a problem, 9 out of 10 times Experts Exchange has either the accepted solution or an open discussion of the potential solution to the problem." Kenny Red, eBay Inc.

See what Experts Exchange can do for you.

Got a question?

We've got the answer.

Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.

Screenshot of Experts Exchange Knowledgebase

Need individual assistance?

Our experts are ready to help.

If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.

Screenshot of Experts Exchange Knowledgebase

Want to learn from the best?

Read articles from industry experts.

Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.

Screenshot of an Article

Working on a long term project?

Store your work and research.

Save solutions to your questions, answers you’ve discovered through searching plus helpful articles in your personal knowledgebase for easy future access.

Screenshot of Experts Exchange Knowledgebase

Access the answers to your technology questions today.

Subscribe Now

30-day free trial. Register in 60 seconds.

What Makes Experts Exchange Unique?

Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Trusted by the world's most respected brands.

image of each brand's logo

Faithfully serving IT professionals since 1996.

Experts Exchange Logo

Try it out and discover for yourself.

Subscribe Now

30-day free trial. Register in 60 seconds.

Related Solutions

  1. Combine lastname and firstname to get fullname with space …
    Hi, I would like to combine lastname, firstname in one column staffname with the space in between lastname firstname. I could not get the space in between the lastname, firstname. How do i do it? Select dbo.members.lastname + dbo.members.firstname as staffname. My ...
  2. One column has (lastname, firstname) -- Need to cov…
    One column has (lastname, firstname) -- Need to covert it to (firstname lastname)
  3. Welcome Firstname Lastname
    I finally got MySite working will FBA and SharePoint today, but now, ever since I created the MySite page, my user appears with AspNetSqlMembershipProvider in the front. I know that is my actual username but is there anyway to customize this, preferably with Firstname Lastna...

Free Tech Articles

  1. WARNING: 5 Reasons why you should NEVER fix a computer for free.
    It is in our nature to love the puzzle. We are obsessed. The lot of us. We love puzzles. We love the challenge. We thrive on finding the answer. We hate disarray. It bothers us deep in our soul. W...
  2. SCCM OSD Basic troubleshooting
    SCCM 2007 OSD is a fantastic way to deploy operating systems, however, like most things SCCM issues can sometimes be difficult to resolve due to the sheer volume of logs to sift through and the dispe...
  3. Migrate Small Business Server 2003 to Exchange 2010 and Windows 2008 R2
    This guide is intended to provide step by step instructions on how to migrate from Small Business Server 2003 to Windows 2008 R2 with Exchange 2010. For this migration to work you will need the fo...
  4. Create a Win7 Gadget
    This article shows you how to create a simple "Gadget" -- a sort of mini-application supported by Windows 7 and Vista. Gadgets can be dropped anywhere on the desktop to provide instant information, ...
  5. Outlook continually prompting for username and password
    There have been a lot of questions recently regarding Outlook prompting for a username and password whilst using Exchange 2007. There are a few reasons why this would happen and I will try to cover t...
  6. Backup Exchange 2010 Information Store using Windows Backup
    There seems to be quite a lot of confusion around the ability to backup Exchange 2010 using the built in Windows Backup feature. This stems from the omission of this feature prior to Exchange 2007 s...

Cloud Class Webinars

  1. Avoiding Bugs in Microsoft Access
    Alison Balter takes and in-depth look at avoiding bugs in Access. In this webinar you will learn about using the immediate window to debug your applications, invoking the debugger, using breakpoints to troubleshoot, stepping through code, setting the next statement to execute, ...
  2. Top 10 Best New Features in Visio 2010
    Scott Helmers gives live demonstrations of the top 10 new features in Visio 2010. This webinar will teach you how to create compelling diagrams by adding shapes to the page with a single click, linking the shapes in a diagram to data in Excel (or SQL Server, or SharePoint), ...
  3. IT Consultant Business Secrets Revealed
    Michael Munger, Experts Exchange tech pro and IT consultant, pulls back the curtain on his very successful businesses and answers question on every IT consultant and business owner should know about. He shares secrets on what he did to solve the 5 most common problems in IT, ...
  4. Disaster Recovery and Business Continuity
    Quest CTO, Mike Billon, gives an overview of the steps involved in building a dunamic disaster recovery plan. Through case studies and an examination of software/hardware tooles for monitoring and testing, you'll gain a better understandin of where you are, where you want ...
  5. Organize Your Visio Diagrams with Containers and Lists
    Scott Helmers uses cross functional flowcharts, wireframe diagrams, data graphic legends and seating charts to teach you: how to ustilize all three new structured diagram components in Visio 2010, the best practices for organizeing shapes in previous version of Visio, how to organize ...
  6. How to Us Objects, Properties, Events and Methods in Microsoft Access
    Alison Dalter gives an in-depbth look at objects, properties, events and methods in Microsoft Access. In this webinar you will learn about using the object browser, referring to objects, working with properties and methods, working with object variables, understanding the ...

Join the Community

Give a Little. Get a Lot.

Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.

Join the Community

Answers

 

by: k_murli_krishnaPosted on 2009-11-06 at 11:10:46ID: 25762107

What does Notes represent, Subject? or notes he is taking in the class in which case it cannot relate with Grade and Teacher but can relate to student unlike the way it is related to all 3 like Subject.

You can as many master tables as required and keep only ID's for relation and no other duplication to minimize redundancy due to higher normalization and reduced INSERT/UPDATE/DELETE anomalies.

 

by: bkersonPosted on 2009-11-06 at 12:28:43ID: 25762749

Notes table is going to be where user save all student grades. I called it Notes but in database it calls STU_Grades. There is something i would like to mention teacher name is a dropdown list.

Thanks

 

by: k_murli_krishnaPosted on 2009-11-07 at 03:05:28ID: 25765795

You can just follow the concept of single theme tables which is essentially achieved on normalization to fifth normal form. First start with individual master tables i.e. single theme tables
First table
Student(Student_ID, FirstName, LastName)
Second Table
Notes(Notes_ID, Grades) - Assuming this is purely Grade related table and Notes_ID is basically Grade_ID.
Third Table
Teacher(Teacher_ID, TeacherName)

Now, grades are won by students in subjects, hence:
Fourth Table
Subject(Subject_ID, SubjectName)

Now denormalize/reverse normalize by understanding whether relational mapping is 1:1 or 1:n or n:n i.e. one:one or 1:many or many:many. 4 tables taken 2 at a time combinations are 6 which are:

Student:Subject = n:n
Student:Notes = n:n
Student:Teacher = n:n
Teacher:Subject = 1:n
Teacher:Notes = n:n
Subject:Notes = n:n

Based on this, have following tables as well without considering unused mapping:
Fifth Table
Student_Notes_Subject(Student_ID, Notes_ID, Subject_ID)
Sixth Table
Student_Teacher(Student_ID, Teacher_ID)
Fourth Table modified
Subject(Subject_ID, SubjectName, Teacher_ID)
Now simply analyze/relate referential integrity or foreign keys between PK and FK and see whether all above 6 combinational relations are intact. As per me, they are. But still it is better to populate data relationally and check the mapping to be correct.

You have not mentioned your primary keys and foreign keys.
If you are implying that:
Second Table
Notes(Notes_ID, Student_ID, Grades, TeacherName) is mixed i.e. Notes_ID is pointing to subject and Grades is what is obtained in them by students against teacher name, you are keeping only Student as the pure single theme master table. Now let us analyze the six mappings in this context:
For this mapping to work i.e.
Teacher:Subject = 1:n, you need to keep Notes_ID as unique in which case you cannot achieve the following:
Notes_ID(which is subject now):Student_ID = n:n
Notes_ID(which is subject now):Grades = n:n

But you still satisfy:
Student_ID:TeacherName = n:n
Grades:TeacherName = n:n
Student_ID:Grades = n:n

I have laid out the concepts with detailed examples. The more one normalizes or goes towards achieving single theme tables the less the redundancy and more the consistency and less the INSERT/UPDATE/DELETE anomalies. But even there is a scope for inconsistency to arise due to redundancy or incomplete normalization OR anomalies, one can avoid these by taking care in application and from back end SQL/programming level. But if your entities and relationships are wrong i.e. conceptual design is wrong, your logical and physical design unless corrected will also stand to err.




 

by: bkersonPosted on 2009-11-07 at 08:44:07ID: 25766942

Hi,

The database is already in third form normal there is no need to foucus on normalization. The samples I'm currently looking for is little  solution in asp.net that creates a form to insert or update record into two related tables in a database. I use Student and Notes as an exemple but it could be any two related tables

I'm using visual web developer and ms sql. That's all i need .... Or what to put in the button save and update to update the form and the grid view.

 

by: k_murli_krishnaPosted on 2009-11-07 at 11:00:07ID: 25767581

Sorry, I cannot help you knowing now clearly what you want.

 

by: carlnorrbomPosted on 2009-11-15 at 10:52:58ID: 25825877

Hi,

Please review the attached sample page and see if this is in line with what you need. I have used two grids with Edit/Delete functionality and Insert functionality through the footer row. Please look at the attached pics on the data tables I set up as part of this test project. Normally I would keep most of the logic in code behind but in this sample most of it (apart from assigning the parameter values for inserting) is done declaratively.



### MasterDetailPage.aspx ###
 
<%@ Page Language="C#" AutoEventWireup="false" CodeFile="MasterDetailPage.aspx.cs" Inherits="MasterDetailPage" %>
 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
 
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <h1><u>Students</u></h1>
        <asp:GridView ID="gvStudents" runat="server" AllowPaging="True" 
            AllowSorting="True" AutoGenerateColumns="False" CellPadding="4" 
            DataKeyNames="Student_ID" DataSourceID="dsStudents" ForeColor="#333333" 
            GridLines="None" ShowFooter="True">
            <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
            <Columns>
                <asp:TemplateField ShowHeader="False">
                    <EditItemTemplate>
                        <asp:Button ID="Button1" runat="server" CausesValidation="True" 
                            CommandName="Update" Text="Update" />
                        &nbsp;<asp:Button ID="Button2" runat="server" CausesValidation="False" 
                            CommandName="Cancel" Text="Cancel" />
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Button ID="Button1" runat="server" CausesValidation="False" 
                            CommandName="Edit" Text="Edit" />
                        &nbsp;<asp:Button ID="Button2" runat="server" CausesValidation="False" 
                            CommandName="Delete" Text="Delete" OnClientClick="return confirm('Are You sure You want to delete?');"/>
                    </ItemTemplate>
                    <FooterTemplate>
                        <asp:Button ID="btnInsertStudent" runat="server" Text="Insert" OnClick="btnInsertStudent_Click" />
                    </FooterTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Student_ID" InsertVisible="False" 
                    SortExpression="Student_ID" Visible="False">
                    <EditItemTemplate>
                        <asp:Label ID="Label1" runat="server" Text='<%# Eval("Student_ID") %>'></asp:Label>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label1" runat="server" Text='<%# Bind("Student_ID") %>'></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="FirstName" SortExpression="FirstName">
                    <EditItemTemplate>
                        <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("FirstName") %>'></asp:TextBox>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label2" runat="server" Text='<%# Bind("FirstName") %>'></asp:Label>
                    </ItemTemplate>
                    <FooterTemplate>
                        <asp:TextBox ID="txtFirstName" runat="server" Text='<%# Bind("FirstName") %>' />
                    </FooterTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="LastName" SortExpression="LastName">
                    <EditItemTemplate>
                        <asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("LastName") %>'></asp:TextBox>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label3" runat="server" Text='<%# Bind("LastName") %>'></asp:Label>
                    </ItemTemplate>
                    <FooterTemplate>
                        <asp:TextBox ID="txtLastName" runat="server" Text='<%# Bind("LastName") %>' />
                    </FooterTemplate>
                </asp:TemplateField>
            </Columns>
            <EditRowStyle BackColor="#999999" />
            <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <PagerSettings Position="Top" />
            <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
            <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
            <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
        </asp:GridView>
        <asp:SqlDataSource ID="dsStudents" runat="server" 
            ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
            DeleteCommand="DELETE FROM [Student] WHERE [Student_ID] = @Student_ID" 
            InsertCommand="INSERT INTO [Student] ([FirstName], [LastName]) VALUES (@FirstName, @LastName)" 
            SelectCommand="SELECT * FROM [Student]" 
            UpdateCommand="UPDATE [Student] SET [FirstName] = @FirstName, [LastName] = @LastName WHERE [Student_ID] = @Student_ID">
            <DeleteParameters>
                <asp:Parameter Name="Student_ID" Type="Int32" />
            </DeleteParameters>
            <InsertParameters>
                <asp:Parameter Name="FirstName" Type="String" />
                <asp:Parameter Name="LastName" Type="String" />
            </InsertParameters>
            <UpdateParameters>
                <asp:Parameter Name="FirstName" Type="String" />
                <asp:Parameter Name="LastName" Type="String" />
                <asp:Parameter Name="Student_ID" Type="Int32" />
            </UpdateParameters>
        </asp:SqlDataSource>
        <h1><u>Notes</u></h1>
        <asp:GridView ID="gvNotes" runat="server" AllowPaging="True" 
            AllowSorting="True" AutoGenerateColumns="False" DataKeyNames="Notes_ID" 
            DataSourceID="dsNotes" CellPadding="4" ForeColor="#333333" 
            GridLines="None" ShowFooter="True">
            <AlternatingRowStyle BackColor="White" ForeColor="#284775" />
            <Columns>
                <asp:TemplateField ShowHeader="False">
                    <EditItemTemplate>
                        <asp:Button ID="Button1" runat="server" CausesValidation="True" 
                            CommandName="Update" Text="Update" />
                        &nbsp;<asp:Button ID="Button2" runat="server" CausesValidation="False" 
                            CommandName="Cancel" Text="Cancel" />
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Button ID="Button1" runat="server" CausesValidation="False" 
                            CommandName="Edit" Text="Edit" />
                        &nbsp;<asp:Button ID="Button2" runat="server" CausesValidation="False" 
                            CommandName="Delete" Text="Delete" />
                    </ItemTemplate>
                    <FooterTemplate>
                        <asp:Button ID="btnAddNotes" runat="server" Text="Add Notes" OnClick="btnAddNotes_Click" />
                    </FooterTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Notes_ID" InsertVisible="False" 
                    SortExpression="Notes_ID" Visible="False">
                    <EditItemTemplate>
                        <asp:Label ID="Label1" runat="server" Text='<%# Eval("Notes_ID") %>'></asp:Label>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label1" runat="server" Text='<%# Bind("Notes_ID") %>'></asp:Label>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Student_ID" SortExpression="Student_ID">
                    <EditItemTemplate>
                        <asp:DropDownList id="ddlStudentID" runat="server" DataSourceID="dsStudents" DataTextField="LastName" DataValueField="Student_ID" SelectedValue='<%# Bind("Student_ID") %>' />
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label2" runat="server" Text='<%# Bind("Student_ID") %>'></asp:Label>
                    </ItemTemplate>
                    <FooterTemplate>
                        <asp:DropDownList id="ddlStudentID" runat="server" DataSourceID="dsStudents" DataTextField="LastName" DataValueField="Student_ID" />
                    </FooterTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Grades" SortExpression="Grades">
                    <EditItemTemplate>
                        <asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("Grades") %>'></asp:TextBox>
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label3" runat="server" Text='<%# Bind("Grades") %>'></asp:Label>
                    </ItemTemplate>
                    <FooterTemplate>
                        <asp:TextBox ID="txtGrades" runat="server" Text='<%# Bind("Grades") %>' />
                    </FooterTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="TeacherName" SortExpression="TeacherName">
                    <EditItemTemplate>
                        <asp:DropDownList ID="ddlTeacherName" runat="server" DataSourceID="dsTeachers" DataTextField="TeacherName" DataValueField="TeacherName" SelectedValue='<%# Bind("TeacherName") %>' />
                    </EditItemTemplate>
                    <ItemTemplate>
                        <asp:Label ID="Label4" runat="server" Text='<%# Bind("TeacherName") %>'></asp:Label>
                    </ItemTemplate>
                    <FooterTemplate>
                        <EditItemTemplate>
                            <asp:DropDownList ID="ddlTeacherName" runat="server" DataSourceID="dsTeachers" DataTextField="TeacherName" DataValueField="TeacherName" />
                        </EditItemTemplate>
                    </FooterTemplate>
                </asp:TemplateField>
            </Columns>
            <EditRowStyle BackColor="#999999" />
            <FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
            <PagerSettings Position="Top" />
            <PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
            <RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
            <SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
        </asp:GridView>
        <asp:SqlDataSource ID="dsNotes" runat="server" 
            ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
            DeleteCommand="DELETE FROM [Notes] WHERE [Notes_ID] = @Notes_ID" 
            InsertCommand="INSERT INTO [Notes] ([Student_ID], [Grades], [TeacherName]) VALUES (@Student_ID, @Grades, @TeacherName)" 
            SelectCommand="SELECT * FROM [Notes]" 
            UpdateCommand="UPDATE [Notes] SET [Student_ID] = @Student_ID, [Grades] = @Grades, [TeacherName] = @TeacherName WHERE [Notes_ID] = @Notes_ID">
            <DeleteParameters>
                <asp:Parameter Name="Notes_ID" Type="Int32" />
            </DeleteParameters>
            <InsertParameters>
                <asp:Parameter Name="Student_ID" Type="Int32" />
                <asp:Parameter Name="Grades" Type="String" />
                <asp:Parameter Name="TeacherName" Type="String" />
            </InsertParameters>
            <UpdateParameters>
                <asp:Parameter Name="Student_ID" Type="Int32" />
                <asp:Parameter Name="Grades" Type="String" />
                <asp:Parameter Name="TeacherName" Type="String" />
                <asp:Parameter Name="Notes_ID" Type="Int32" />
            </UpdateParameters>
        </asp:SqlDataSource>
        <asp:SqlDataSource ID="dsTeachers" runat="server" ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
            SelectCommand="SELECT * FROM Teacher">
        </asp:SqlDataSource>
    </div>
    </form>
</body>
</html>
 
### MasterDetailPage.aspx.cs ###
 
partial class MasterDetailPage : System.Web.UI.Page
{
   
    protected void btnInsertStudent_Click(object sender, EventArgs e)
    {
        dsStudents.InsertParameters.Clear();
        dsStudents.InsertParameters.Add(new Parameter("FirstName", Data.DbType.String, ((TextBox)gvStudents.FooterRow.FindControl("txtFirstName")).Text));
        dsStudents.InsertParameters.Add(new Parameter("LastName", Data.DbType.String, ((TextBox)gvStudents.FooterRow.FindControl("txtLastName")).Text));
        dsStudents.Insert();
    }
   
    protected void btnAddNotes_Click(object sender, EventArgs e)
    {
        dsNotes.InsertParameters.Clear();
        dsNotes.InsertParameters.Add(new Parameter("Student_ID", Data.DbType.String, ((DropDownList)gvNotes.FooterRow.FindControl("ddlStudentID")).SelectedValue));
        dsNotes.InsertParameters.Add(new Parameter("Grades", Data.DbType.String, ((TextBox)gvNotes.FooterRow.FindControl("txtGrades")).Text));
        dsNotes.InsertParameters.Add(new Parameter("TeacherName", Data.DbType.String, ((DropDownList)gvNotes.FooterRow.FindControl("ddlTeacherName")).SelectedValue));
        dsNotes.Insert();
    }
}

                                              
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
26:
27:
28:
29:
30:
31:
32:
33:
34:
35:
36:
37:
38:
39:
40:
41:
42:
43:
44:
45:
46:
47:
48:
49:
50:
51:
52:
53:
54:
55:
56:
57:
58:
59:
60:
61:
62:
63:
64:
65:
66:
67:
68:
69:
70:
71:
72:
73:
74:
75:
76:
77:
78:
79:
80:
81:
82:
83:
84:
85:
86:
87:
88:
89:
90:
91:
92:
93:
94:
95:
96:
97:
98:
99:
100:
101:
102:
103:
104:
105:
106:
107:
108:
109:
110:
111:
112:
113:
114:
115:
116:
117:
118:
119:
120:
121:
122:
123:
124:
125:
126:
127:
128:
129:
130:
131:
132:
133:
134:
135:
136:
137:
138:
139:
140:
141:
142:
143:
144:
145:
146:
147:
148:
149:
150:
151:
152:
153:
154:
155:
156:
157:
158:
159:
160:
161:
162:
163:
164:
165:
166:
167:
168:
169:
170:
171:
172:
173:
174:
175:
176:
177:
178:
179:
180:
181:
182:
183:
184:
185:
186:
187:
188:
189:
190:
191:
192:
193:
194:
195:
196:
197:
198:
199:
200:
201:
202:
203:
204:
205:
206:
207:
208:
209:
210:
211:
212:
213:
214:
215:
216:
217:
218:
219:
220:
221:
222:
223:
224:

Select allOpen in new window

 

by: bkersonPosted on 2009-11-15 at 17:09:41ID: 25827271

Hi Wizard,

Thank you so much. your approach seems to solve my problem. However I don't like the idea the user is going to choose the student ID in a dropdown list which denied the concept related table. In your concept how the notes table can get the the studeant ID value automaticly from the table student. once that question answer i'm gonna accept your solution.

Thanks

 

by: carlnorrbomPosted on 2009-11-16 at 04:33:56ID: 25829592

Hi,

Not sure what you mean by "how the notes table can get the student ID value automatically from the table student"? In the solution presented, you don't choose the ID, you choose the name of the student but the notes table gets populated with the student ID, I thought that's what you were after?

/Carl.

 

by: bkersonPosted on 2009-11-16 at 06:53:18ID: 25830611

Thank you so much Carl.

Your solution give me an bright idea on how to work with related tables. For the student I gonna use form view instead of a grid view. Your solution has been accepted.

Again thanks

 

by: bkersonPosted on 2009-11-16 at 06:54:33ID: 31651165

What more I can say. A million of thanks

20120131-EE-VQP-002

3 Ways to Join

30-Day Free Trial

The Experts

98% positive feedback on 31,087 answers since March 2000. angeliii is a Microsoft Most Valuable Professional for his work with MS SQL Server & Develoment.

He has also proven his knowledge of Visual Basic Programming, PHP Scripting and Oracle Databases.

The Experts

97% positive feedback on 10,752 answers since July 2000. lrmoore has more than 18 years experience in the networking industry.

The six-time Mircosoft MVPs specialties include firewalls, virtual private networking, and network management.

Testimonials

"...and excellent source for support... Kind of like having your very own IT dept." Electriciansnet

Testimonials

"I was apprehensive at signing up at first. However... it has already made my life as an IT administrator much easier." JaCrews

Testimonials

"WOW! You guys have great, active, and knowledgeable people on here." moore50

Business Clients

Business Clients

In the Press

"If you’ve got a question... Experts Exchange can supply an answer.”

In the Press

"...an invaluable aid for both IT professionals and those who require tech support."

In the Press

"where IT professionals provide quick answers on just about any topic"

Business Account Plans

Loading Advertisement...