i'm using odac 5.55.1.24 24.10.05 with Oracle9i Release 9.2.0.6.0.
i'm sorry that i can't reproduce the error, but the message is:
Assertion failure (D:\Projects\Delphi\Dac\Source\MemData.pas, Zeile 6354).
Maybe this is useful for you...
if you need more information, please tell me
the last time i saw this message (today) was after inserting a new entry in the DB... the code is:
Code: Select all
new_Art_ID = prv_GetNextTrigger("ARTICLE");
//insert the article
DlgMain->tQryInsertIntoArticle->ParamByName("InternID")->AsInteger = new_Art_ID;
DlgMain->tQryInsertIntoArticle->ParamByName("Text")->AsString = prv_CheckText(Memo1->Lines->GetText());
DlgMain->tQryInsertIntoArticle->ParamByName("Loginname")->AsString = DlgMain->Anmeldenamen();
DlgMain->tQryInsertIntoArticle->ParamByName("ID")->AsInteger = new_Art_ID;
DlgMain->tQryInsertIntoArticle->Execute();
//write the keyword(s) but check if it is in the DB
for(i = 0; i RowCount; i++)
{
if(StringGrid1->Cells[0][i] == "")
continue;
//here is the key_id test
DlgMain->tQryFindKey->ParamByName("Keyword")->AsString = StringGrid1->Cells[0][i];
DlgMain->tQryFindKey->Execute();
tmp_Key = DlgMain->tQryFindKey->FieldByName("ID")->AsInteger;
if(tmp_Key == NULL && StringGrid1->Cells[0][i] != "") //its a new one
{
Key_ID = prv_GetNextTrigger("KEYWORD");
//insert it in the keyword table
DlgMain->tQryInsertKeyword->ParamByName("InternKID")->AsInteger = Key_ID;
DlgMain->tQryInsertKeyword->ParamByName("Keyword")->AsString = StringGrid1->Cells[0][i];
DlgMain->tQryInsertKeyword->ParamByName("Loginname")->AsString = DlgMain->Anmeldenamen();
DlgMain->tQryInsertKeyword->Execute();
//link the new one into the subject field
DlgMain->tQryInsertBothToSubject->ParamByName("InternAID")->AsInteger = new_Art_ID;
DlgMain->tQryInsertBothToSubject->ParamByName("InternKID")->AsInteger = Key_ID;
DlgMain->tQryInsertBothToSubject->Execute();
}
else
{
//insert the old one back into the subject field
Key_ID = tmp_Key;
DlgMain->tQryInsertBothToSubject->ParamByName("InternAID")->AsInteger = new_Art_ID;
DlgMain->tQryInsertBothToSubject->ParamByName("InternKID")->AsInteger = Key_ID;
DlgMain->tQryInsertBothToSubject->Execute();
}
//insert the linkage
for(int y = 0; y RowCount; y++)
{
if(StringGrid4->Cells[0][y] == "")
continue;
Link_ID = prv_GetNextTrigger("LINKAGE");
DlgMain->tQryInsertLinkage->ParamByName("InternLID")->AsInteger = Link_ID;
DlgMain->tQryInsertLinkage->ParamByName("InternAID")->AsInteger = new_Art_ID;
DlgMain->tQryInsertLinkage->ParamByName("Link")->AsString = StringGrid4->Cells[0][y];
DlgMain->tQryInsertLinkage->Execute();
}
DlgMain->OraSession->Commit();
}
...
//maybe this *could* be the reason for the assertion?
DlgMain->OraSession->Commit();
DlgMain->tQryClearKeywords->Execute(); //list all death keywords
for(int i = 0; !DlgMain->tQryClearKeywords->Eof; i++)
{
AnsiString keyword = DlgMain->tQryClearKeywords->FieldByName("Keyword")->AsString; //get the name
DlgMain->tQryFindKey->ParamByName("Keyword")->AsString = keyword; //get the ID from the death keyword
DlgMain->tQryFindKey->Execute();
DlgMain->tQryDelKeyFromSubj->ParamByName("ID")->AsInteger = DlgMain->tQryFindKey->FieldByName("ID")->AsInteger; //kill it from subject
DlgMain->tQryDelKeyFromSubj->Execute();
DlgMain->tQryDelKeyFromSubj->Close();
DlgMain->tQryDeleteKeyword->ParamByName("Keyword")->AsString = keyword; //kill it from keyword
DlgMain->tQryDeleteKeyword->Execute();
DlgMain->tQryDeleteKeyword->Close();
DlgMain->tQryFindKey->Next();
DlgMain->tQryClearKeywords->Next();
}
DlgMain->OraSession->Commit();
DlgMain->tQryFindKey->Close();
DlgMain->prv_getKeyWords();
//display the new edited article and not the old one, so lets start a new search in the tmstringgrid
if(DlgMain->bIsNewEntry == false)
{
AnsiString t_Article;
DlgMain->TMStringGrid->Cells[8][DlgMain->m_iHitRow] = new_Art_ID;
DlgMain->tQryGetAllFromArtByID->ParamByName("InternID")->AsInteger = new_Art_ID;
DlgMain->tQryGetAllFromArtByID->Execute();
DlgMain->TMStringGrid->Cells[1][DlgMain->m_iHitRow] = DlgMain->tQryGetAllFromArtByID->FieldByName("keyword")->AsString;
t_Article = DlgMain->tQryGetAllFromArtByID->FieldByName("article")->AsString;
for(int i = 1; i TMStringGrid->Cells[2][DlgMain->m_iHitRow] = t_Article;
DlgMain->TMStringGrid->Cells[5][DlgMain->m_iHitRow] = DlgMain->tQryGetAllFromArtByID->FieldByName("edited_by")->AsString;
DlgMain->TMStringGrid->Cells[6][DlgMain->m_iHitRow] = DlgMain->tQryGetAllFromArtByID->FieldByName("edited")->AsString;
}
LG
Oliver