Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Can't update SQL table
Message
Information générale
Forum:
ASP.NET
Catégorie:
The Mere Mortals .NET Framework
Titre:
Can't update SQL table
Versions des environnements
Environment:
ASP.NET
OS:
Windows 2000 SP4
Network:
Windows 2000 Server
Database:
MS SQL Server
Divers
Thread ID:
00984795
Message ID:
00984795
Vues:
62
Kevin,

I am trying to update a SQL table and receive the following error:

Dynamic SQL generation for the UpdateCommand is not supported against a SelectCommand that does not return any key column information.

This business object for this table, is set up the same as the rest of my business objects. I just added this table this morning. The table name is Aprvl, and the primary key is the identity column. This is the command that it is choking on:

this.oApproval.SaveDataSet(this.dsApproval,"Aprvl","PMR");

public DataSet GetAllApprovals(int PMR_Num)
{
mmDataAccessBase dao = this.GetDataAccessObject();
IDbDataParameter param1 = dao.CreateParameter("@PMR_Num", PMR_Num);
dsApproval = this.GetDataSet("Select * FROM Aprvl WHERE PMR_Num = @PMR_Num", param1);
return dsApproval;
}

I hope you have some insight into this. I'm pulling my hair put.
Bill Benton
Senior Systems Analyst
Nuvell Financial Services
Répondre
Fil
Voir

Click here to load this message in the networking platform