TPS TryInsert Access Denied

Using a process template reading an SQLite2 table and writing to TPS (C:\Users\Public\Documents\myApp\data\v3DailyMetrics.tps) fails with Access Denied

The open is successful but the TryInsert throws an error

|*** dbState:|Access:v3DailyMetrics.TryOpen() - 0.
|*** dbError|Access:v3DailyMetrics.TryInsert() - 5.Access Denied

I’ve checked the DCT (which is being used by 3 other apps and they work just fine)

I’ve checked the Individual File controls in the app and it’s the same as the other apps.

Any thoughts?

What do you get if you call STATUS(YourFile) ?

That will tell you your open mode.

1 Like

Further … the Open Mode may be Read Only which an ADD would be denied.

Help on STATUS example code notes IF STATUS(YourFile) % 16 = 0 !Opened Read-Only?

Your have to look in the DCT to see the default Open Mode. I think if you have it set to Deny All and try to open it on more than one thread, then it gets opened Read Only.

1 Like

v3DailyMetrics:Status 64

Tried to force it to OPEN ReadWrite (2) but still shows 64

64 Decimal is Readonly+Deny None.
Try putting OPEN(v3DailyMetrics, ReadWrite+DenyNone) 042h and testing errorcode() and status() afterwards.
Also, trace out v3DailyMetrics{Prop:Name} and make sure the file it is opening is really where you think it is.

1 Like

Thx All!

found the culprit - deep embedded code in global … inherited code :frowning:

**SHARE(refFile, ReadOnly+DenyNone)**
4 Likes