Delete all Rows

jeremey_garcia

VIP Member
I have searched the postings for information on Business Function B8000002. I looked at Zoltan's post 91354 and I had already setup the functions like that. I placed the three functions in the initialize function, after last object printed on the final section and even in the calling application and each place does not clear the records in the file. Is there any other suggestions someone can provide to help me figure out why the records are not being deleted? I turned debugging on and do not see any obvious errors. Here is a snippet of the log:

ar 08 10:49:39.908019 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 jdeSpecOpen() opening spec of release JDESPECRELLVL_B9U.
Mar 08 10:49:39.908020 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 SpecEncapsulation : jdeSpecOpenLocalOpt completed OK.
Mar 08 10:49:39.908021 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 SpecEncapsulation : jdeSpecSelectKeyed completed OK.
Mar 08 10:49:39.908022 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 Unlocking TAM file F:\PeopleSoft\E811\DDP\DV811\spec\gbrlink.ddb
Mar 08 10:49:39.908023 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 JDETAMA:entering INTUnlockTam with pTamLock:[06FE0FA0],pTamLock->hIPCTamLock:[08ADCE20],pTamLock->szLockName:F:\PeopleSoft\E811\DDP\DV811\spec\gbrlink.ddb
Mar 08 10:49:39.908024 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 JDETAMA:entering INTUnlockTam nReaders 1
Mar 08 10:49:39.908025 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 UNLOCK: Total READ locks after operation: 0
Mar 08 10:49:39.908026 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 JDETAMA:exited INTUNLockTam with pTamLock:[06FE0FA0].
Mar 08 10:49:39.908027 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 SpecEncapsulation : Close completed.
Mar 08 10:49:39.908028 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 Exiting JDB_OpenTable(Table = F57PFRA1) with Success
Mar 08 10:49:39.908029 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 Entering JDB_DeleteTable (Table F57PFRA1)
Mar 08 10:49:39.893001 - 5952/4300 WRK:Call Object For BSFN[DeleteAllRowsFromTable] Error count: Received - #Error[0] #Warning[0]
Mar 08 10:49:39.908040 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 Exiting JDB_DeleteTable with Failure (Table F57PFRA1)
Mar 08 10:49:39.908041 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 Entering JDB_GetEnv
Mar 08 10:49:39.908042 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 Exiting JDB_GetEnv with Success
Mar 08 10:49:39.908043 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 Entering JDB_InitUser with (AUTO commit mode)
Mar 08 10:49:39.908044 - 5952/4300 WRK:JGARCIA_04DD7008_R57PFRA1 Entering JDB_BeginTransaction (UserHandle 08EC0EC8)

It says exiting with failure, but I can not see why. Any help you can provide will be greatly apprecaited.
 
Hi Jeremy.
Witch does the envoirement are you running this Business Function?
Was the table generated?
I will reply this process and I will answer you. Ok?
 
Hi Jeremy,

I do not know, how do these BSFNs work on 8.11 and on WEB client.

Just some shot in the dark:

S#1: turn on Include Transaction on the BSFN calls in the UBE
S#2: turn off Transaction Processing on the UBE, if you do not use it

Some additional question:

Q#1: Where and how do you populate the table?
Q#2: Do you "play" with Transaction Processing somewhere in you process?

Please, keep us informed. Thanks.

Good Luck & Reagrds,

Zoltán
 
Hey Zoltan,

Thanks for the reply, I will attempt what you suggested. To answer your questions:

1. File is populated in the report throough the level break sections using insert statements. I am trying to clear the file in either the initialize section before the insert statements or the last thing in the report before it finishes
2. I have not "played" with transaction processing so I do not if it is on or not.
 
It's telling you this command failed (from B8000002). It may be that changes in the middleware no longer delete all rows when the #keys field is zero (just a guess). All the prior steps of opening the table, etc, succeeded, or else you'd have never got to the delete.

/* Delete all the rows in the requested table. 0 in number of Keys deletes all rows. */

idJDBReturn = JDB_DeleteTable(hRequestTable, szTable, (ID)0, (ID)NULL,
(void *)NULL, nNumKeys);

Is SQL appearing elsewhere in the log? If it is then the DeleteTable command doesn't appear to be called correctly, or no longer functions as the comment implies.
 
Hello,

No SQL doesn't appear elsewhere in the log in regard to Delete records from the table. That would make it to0 easy to test, because then I could copy the statement to Query Analyzer and run it to see what happens.
 
New Info:

I added a button to a windows application to test just the function statements. It cleared the file. So whatever is causing the problem is coming from the web application. But that still leaves a question of why it is not being cleared when the report runs, unless it is the same cause of the web app not being able to clear the file.
 
In reviewing the log, I do not see a prior call to "Get Input Output Env Handles (B8000007), where you would obtain the handle to the output environment that is required when using B8000002. A subsequent call to B8000007 is also required, to release that same environment handle. Use GENLNG for the handle(s). I generally map SL for Current environment. This might be the issue.
 
Back
Top