I use Delphi 2006 to connect MS SQL Express 2005. When I save record, it shows the following error message:
Database Server Error : Cannot create new transaction because capacity was exceeded.
Does anyone know what happen and how to solve?
Thanks!
A quick MSN Search finds http://bdn.borland.com/article/0,1410,32020,00.html with the following solution:
When using dbExpress MSSQL and TClientDataSet.ApplyUpdates,
you may encounter either of the following errors while
applying updates, due to a SQLOLEDB.DLL limitation:
"Cannot create new transaction because capacity was exceeded."
"Cannot create new connection because in manual or
distributed transaction mode."
To resolve the errors, use one of the following workarounds:
- On the DataSetProvider Options property, make sure
poFetchBlobsOnDemand and poFetchDetailsOnDemand are False.
- Use a BeforeApplyUpdates event to either call CloseDataSets
or Close the connection:
procedure TForm1.DataSetProvider1BeforeApplyUpdates(Sender: TObject;
var OwnerData: OleVariant);
begin
SQLConnection1.CloseDataSets;
// SQLConnection1.Close;
end;
Regards,
Mike Wachal
SQL Express team
-
Check out my tips for getting your answer faster and how to ask a good question: http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=307712&SiteID=1
No comments:
Post a Comment