Error: JAS Database Failure in HTML

sathyabalu

Active Member
Long time haven't posted here. So pardon if i am missing any usual posting rules.

Came across a strange problem in HTML. We have a custom App that is based on a Union View of F4211/9. We have used custom data selection and sequencing.

We have 2 types of JDE security roles. One (Role A) that doesn't have type 4 security (open to all MCU and CO). The other one (Role B) where there is row level security on MCU and CO.

When the App is run (find button pressed) in Citrix under both the roles, they work fine. But when the app is run in HTML they work fine for Role A, but for Role B it throws an error on hitting the find button saying "JAS_MSG346: JAS database failure". The JAS.log gave a "missing right paranthesis" error. It was puzzling me for couple of days.

Then we decided to turn on all the debug options in JAS.ini and ran the app under both the roles. What i found was rather bizzare. The underlying SQL that is generated by JDE in HTML doesn't append a 'AND' clause after the user/app level data selection is applied.

Basically this is how the query looks under each of the roles.

Role A (without MCU and CO row security): Select .....from F4211 where SDAN8=123456 and SDDOCO=1234 and SDDCTO='SO'

Role B (with MCU and CO row security): Select .....from F4211 where SDAN8=123456 and SDDOCO=1234 and SDDCTO='SO' ( F4211.SDMCU BETWEEN ' ABCD00' AND ' ABCD99' OR F4211.SDMCU BETWEEN ' EFG000' AND ' EFG999')

In the above Role B query notice that there is no 'AND' clause after the Doc Type and before the paranthesis starts for the row security.

Here is how the App is coded on the Find event:
Clear Sequencing(FC Grid)
Clear Selection(FC Grid)
Set Selection Append Flag(FC Grid, <Yes>) (This line was added to see if it makes a difference)
Set Selection(FC Grid, F4211, AN8, <Equal To>, FC Sold To_V, <And>)
Set Selection(FC Grid, F4211, DOCO, <Equal To>, FC SalesOrder_V, <And>)
Set Selection(FC Grid, F4211, DCTO, <Equal To>, FC SalesType_V, <And>)
Set Sequencing(FC Grid, "F4211", "DCTO", <Ascending>)
Set Sequencing(FC Grid, F4211, "DOCO", <Descending>)


I even tried adding the Set Selection Append Flag(FC Grid, <Yes>) to the end of the code - that didn't help as well.

I searchecd this forum for the error - didn't find anything related to the scenario above.

Anyone one willing to chime in to help me out?
 
Back
Top