Run Time Error 2486

  • Thread starter Hiten Kothari via AdminLife
  • Start date
H

Hiten Kothari via AdminLife

Hi All,
I have migrated an application from MS Access 97 to Access 2000.I have a process which uploads data from various tables to asingle table which is used for Report Generation.

During upload large no of queries are executed. After theapplication has executed abt 10-12 queries it puts up an Runtime Error '2486': You can't carry out this action at presenttime. When i debug the error generated, it gets me to thefollowing command:

DoCmd.OpenQuery "Journals - Withdrawals", acNormal, acEdit
also the application hangs up. The query has the following code:

INSERT INTO Journals ( Type, [From Code], [From Name], [To Name],[To Code], Pool, [Date], Principal, [Currency], SubPool, Ref )
SELECT "Injections" AS Type, [Bank Accounts].[Gateway Code],[Bank Accounts].[Account Name], [Action Panel - Unique].Bank,IIf([Bank Accounts].[currency]="EUR" And [instruction eur] IsNot Null,[instruction eur],[Instruction]) AS Inst, [Action Panel- Unique].Pool, [forms]![control panel]![date] AS [Date],Sum([Withdraw]*-1) AS Amount, [Sub Pool Accounts -MASTER].Currency, [Sub Pool Accounts - MASTER].SubPool,IIf([existingref]>0,[existingref],[latestref]+1) AS ChapsRef
FROM (((([Action Panel - Unique] INNER JOIN [Sub Pool Accounts -MASTER] ON [Action Panel - Unique].HeaderAccount = [Sub PoolAccounts - MASTER].SubAccount) INNER JOIN [Bank Accounts] ON[Sub Pool Accounts - MASTER].OverallHeader = [BankAccounts].[Account No]) INNER JOIN [Bank Ratings] ON [ActionPanel - Unique].Bank = [Bank Ratings].Bank) LEFT JOIN [Journals- Existing Ref] ON [Action Panel - Unique].Pool = [Journals -Existing Ref].Pool) LEFT JOIN [Journals - Latest Ref] ON [ActionPanel - Unique].Pool = [Journals - Latest Ref].Pool
WHERE ((([Action Panel - Unique].Withdraw)>0))
GROUP BY [Bank Accounts].[Gateway Code], [Bank Accounts].[AccountName], [Action Panel - Unique].Bank, IIf([BankAccounts].[currency]="EUR" And [instruction eur] Is NotNull,[instruction eur],[Instruction]), [Action Panel -Unique].Pool, [forms]![control panel]![date], [Sub Pool Accounts- MASTER].Currency, [Sub Pool Accounts - MASTER].SubPool,IIf([existingref]>0,[existingref],[latestref]+1)
HAVING ((([Action Panel - Unique].Pool)="Euro"));


I restarted the application and then tried runninng this querydirectly from the database but it does not respond to the runcommand. Also if I try to open up the table that it is insertingthe records into the table opens but it does not allow me toclose that table..

How do i remove this error. Also i don't have an idea what theproblem is..

Please reply if someone can help.

Thanks and Regards
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top