Click here to Skip to main content
15,891,136 members
Home / Discussions / Database
   

Database

 
GeneralRe: Mapping SqlParamters to Computed Columns Pin
Anonymous19-Mar-04 7:43
Anonymous19-Mar-04 7:43 
GeneralOpen access-file without install Pin
cr9717-Mar-04 23:41
cr9717-Mar-04 23:41 
GeneralRe: Open access-file without install Pin
Rob Graham18-Mar-04 5:47
Rob Graham18-Mar-04 5:47 
GeneralRe: Open access-file without install Pin
eXplodus6-Apr-04 21:23
eXplodus6-Apr-04 21:23 
GeneralSQL Server Access Work Flow 2000 Pin
vikramlinux17-Mar-04 21:18
vikramlinux17-Mar-04 21:18 
GeneralRe: SQL Server Access Work Flow 2000 Pin
JackDotNet24-Mar-04 22:38
JackDotNet24-Mar-04 22:38 
GeneralRe: SQL Server Access Work Flow 2000 Pin
vikramlinux25-Mar-04 0:25
vikramlinux25-Mar-04 0:25 
GeneralAdapter.Update from Two Tables Pin
Anonymous17-Mar-04 19:39
Anonymous17-Mar-04 19:39 
Hello...
I have the following situation :
One data set that contains two data tables, tblHeader and tblDetails. The two tables have a column in common (like a relation).

Dim con as New SqlCOnnection()
Dim da as New SqlDataAdapter()
Dim cmd as New SqlCommand("sp_insertrecord", con)
da.InsertCommand = cmd
da.InsertCommand.CommandType = CommandType.StoredProcedure

da.InsertCommand.Parameters.Add(New SqlParameter("@Param1", SqlDbType.VarChar, 40, strCol1))
da.InsertCommand.Parameters.Add(New SqlParameter("@Param2", SqlDbType.VarChar, 3, strCol2))
da.InsertCommand.Parameters.Add(New SqlParameter("@Param3", SqlDbType.VarChar, 10, strCol3))

as U can see strCol1,strCol2 and strCol3 are source columns that map to the columns that i want to update. The problem is that I have col1 in tblHeader and Col2 and Col3 in tblDetails....
when I execute
da.Update(ds,tblDetails.TableName)
I get an error stating the sp_InsertRecords expects paramter @Param1 that was not supplied.
I guess that the situation is happening because I have one row in the header table and 3 rows in the details table...
How can I map the paramter to the correct column name in the second table??..how should i modify my da.update statement???
what I need is a sort of an INNER JOIN in ADO.NET..is there such a thing??
Please Help Me
Thanks In Advance
GeneralSelecting some range of a table rows Pin
Meysam Mahfouzi17-Mar-04 18:24
Meysam Mahfouzi17-Mar-04 18:24 
GeneralRe: Selecting some range of a table rows Pin
Mazdak17-Mar-04 20:12
Mazdak17-Mar-04 20:12 
GeneralRe: Selecting some range of a table rows Pin
Meysam Mahfouzi18-Mar-04 4:07
Meysam Mahfouzi18-Mar-04 4:07 
GeneralRe: Selecting some range of a table rows Pin
l a u r e n18-Mar-04 18:40
l a u r e n18-Mar-04 18:40 
GeneralRe: Selecting some range of a table rows Pin
Mazdak18-Mar-04 22:24
Mazdak18-Mar-04 22:24 
GeneralRe: Selecting some range of a table rows Pin
JackDotNet24-Mar-04 22:42
JackDotNet24-Mar-04 22:42 
GeneralDatagrid not showing up Pin
cavall17-Mar-04 8:49
cavall17-Mar-04 8:49 
GeneralRe: Datagrid not showing up Pin
Mazdak17-Mar-04 10:15
Mazdak17-Mar-04 10:15 
Generalnvarchar parameter of sql stored proc. Pin
Matthieu.C17-Mar-04 6:33
Matthieu.C17-Mar-04 6:33 
GeneralRe: nvarchar parameter of sql stored proc. Pin
Not Active17-Mar-04 7:15
mentorNot Active17-Mar-04 7:15 
GeneralRe: nvarchar parameter of sql stored proc. Pin
Matthieu.C17-Mar-04 22:11
Matthieu.C17-Mar-04 22:11 
Generalcant pull data into datagrid from MS access file Pin
cavall17-Mar-04 6:13
cavall17-Mar-04 6:13 
GeneralRe: cant pull data into datagrid from MS access file Pin
Marcie Jones17-Mar-04 6:52
Marcie Jones17-Mar-04 6:52 
GeneralRe: cant pull data into datagrid from MS access file Pin
cavall19-Mar-04 6:11
cavall19-Mar-04 6:11 
GeneralRe: cant pull data into datagrid from MS access file Pin
cavall19-Mar-04 6:31
cavall19-Mar-04 6:31 
GeneralDispose and Connection Pooling Pin
Mauricio Ritter17-Mar-04 5:28
Mauricio Ritter17-Mar-04 5:28 
GeneralRe: Dispose and Connection Pooling Pin
Marcie Jones17-Mar-04 5:56
Marcie Jones17-Mar-04 5:56 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.