Page 2 of 2

Re: Multi User Database Issue

Posted: Tue Feb 26, 2019 1:41 pm
by dbroder@nycourts.gov
Auge_Ohr wrote:
dbroder@nycourts.gov wrote:
skiman wrote:Hi,
Are you using indexes? It looks as you don't? You really need indexes!
Thanks for your response. We are using indexes.
did you use NTX or CDX :?:
Hi. We are using CDX

Re: Multi User Database Issue

Posted: Tue Feb 26, 2019 2:45 pm
by Auge_Ohr
dbroder@nycourts.gov wrote:
Auge_Ohr wrote:
dbroder@nycourts.gov wrote: Hi. We are using CDX
so you must have a own DBESYS ... please show it

Re: Multi User Database Issue

Posted: Wed Feb 27, 2019 1:50 pm
by dbroder@nycourts.gov
[quote="Auge_Ohr"][quote="dbroder@nycourts.gov"][quote="Auge_Ohr"][quote="dbroder@nycourts.gov"]
Hi. We are using CDX[/quote][/quote][/quote]so you must have a own DBESYS ... please show it[/quote]

[code]
PROCEDURE dbeSys()
SET COLLATION TO // Use strict ASCII sorting
SET DATE TO AMERICAN // mm/dd/yy

DbeLoad("DBFDBE",.T.)
DbeLoad("FOXDBE",.T.)
DbeLoad("NTXDBE",.T.)
DbeLoad("CDXDBE",.T.)
DbeLoad("DELDBE",.T.)

IF !DbeBuild( "DELCDX", "DELDBE", "CDXDBE" )
ALERT("DELCDX Database Engine is not created", {"OK"} )
ENDIF

IF !DbeBuild( "FOXCDX", "FOXDBE", "CDXDBE" )
ALERT("FOXCDX Database-Engine is not created", {"OK"} )
ENDIF

IF !DbeBuild( "DBFNTX", "DBFDBE", "NTXDBE" )
ALERT("DBFNTX Database-Engine is not created", {"OK"} )
ENDIF

IF !DbeBuild( "DBFCDX", "DBFDBE", "CDXDBE" )
ALERT("DBFCDX Database-Engine is not created", {"OK"} )
ENDIF

DbeSetDefault("FOXCDX")
DbeInfo( COMPONENT_DATA, FOXDBE_LOCKRETRY, 100000)
DbeInfo( COMPONENT_DATA, FOXDBE_LOCKDELAY, 10)
DbeInfo( COMPONENT_DATA, FOXDBE_LIFETIME, 0)
DbeInfo( COMPONENT_DATA, FOXDBE_CREATE_2X, .F. )
DbeInfo( COMPONENT_DATA, FOXDBE_LOCKMODE , FOXDBE_LOCKMODE_VISUAL )

DbeSetDefault( "DBFCDX" )
DbeInfo( COMPONENT_DATA, DBFDBE_LOCKRETRY, 100000 )
DbeInfo( COMPONENT_DATA, DBFDBE_LOCKDELAY, 10 )
DbeInfo( COMPONENT_DATA, DBFDBE_LIFETIME, 0 )
DbeInfo( COMPONENT_DATA, DBFDBE_LOCKOFFSET, 1000000000 )

DbeInfo( COMPONENT_ORDER, CDXDBE_LOCKRETRY, 100000)
DbeInfo( COMPONENT_ORDER, CDXDBE_LOCKDELAY, 1 )
DbeInfo( COMPONENT_ORDER, CDXDBE_LIFETIME, 0 )
DbeInfo( COMPONENT_ORDER, DBE_LOCKMODE, LOCKING_STANDARD )
RETURN
[/code]

Re: Multi User Database Issue

Posted: Wed Feb 27, 2019 6:46 pm
by Auge_Ohr
hi,

i wonder that you are using FOXCDX and (!) DBFCDX :?:
your last DbeSetDefault() is using "DBFCDX". did you switch it in you App :?:

CDXDBE_LIFETIME does not exist. look at CDXDBE (ORDER Komponente)

Re: Multi User Database Issue

Posted: Thu Feb 28, 2019 6:15 am
by dbroder@nycourts.gov
Auge_Ohr wrote:hi,

i wonder that you are using FOXCDX and (!) DBFCDX :?:
your last DbeSetDefault() is using "DBFCDX". did you switch it in you App :?:

CDXDBE_LIFETIME does not exist. look at CDXDBE (ORDER Komponente)
We inherited this code so I'm not sure why the dbesys has a reference to FOXCDE.

We have the xbase help for 2.0 (we are using 1.9) wasn't sure if the CDXDBE_LIFETIME was removed in 2.0 so we left it in place in the dbesys. I can remove it. Thanks/

Re: Multi User Database Issue

Posted: Thu Feb 28, 2019 9:53 am
by Auge_Ohr
hi,

more Comment
*_LIFETIME are for DATA-Component not for ORDER-Component
i recommend to remove hole "DBFCDX" DATA-Component, just use "FOXCDX" DATA-Component

Code: Select all

DbeInfo( COMPONENT_ORDER, CDXDBE_LOCKDELAY, 1 )
that is less than default ... :snooty:
*_LOCKRETRY and *_LOCKDELAY default value most working well (since v1.5x)
FOXDBE (DATA-Komponente) have FOXDBE_LOCKMODE
CDXDBE (ORDER Komponente) have CDXDBE_MODE and DBE_LOCKMODE
CDXDBE_MODE must be same Type like FOXDBE_LOCKMODE :!:
DBE_LOCKMODE i recommend default LOCKING_STANDARD until all run stable.

Re: Multi User Database Issue

Posted: Thu Feb 28, 2019 1:40 pm
by dbroder@nycourts.gov
Auge_Ohr wrote:hi,

more Comment
*_LIFETIME are for DATA-Component not for ORDER-Component
i recommend to remove hole "DBFCDX" DATA-Component, just use "FOXCDX" DATA-Component

Code: Select all

DbeInfo( COMPONENT_ORDER, CDXDBE_LOCKDELAY, 1 )
that is less than default ... :snooty:
*_LOCKRETRY and *_LOCKDELAY default value most working well (since v1.5x)
FOXDBE (DATA-Komponente) have FOXDBE_LOCKMODE
CDXDBE (ORDER Komponente) have CDXDBE_MODE and DBE_LOCKMODE
CDXDBE_MODE must be same Type like FOXDBE_LOCKMODE :!:
DBE_LOCKMODE i recommend default LOCKING_STANDARD until all run stable.
Thank you. We will try your recommendations

Re: Multi User Database Issue

Posted: Thu Feb 28, 2019 2:47 pm
by Auge_Ohr
dbroder@nycourts.gov wrote:Thank you. We will try your recommendations
don't forget to create Index NEW (not REINDEX)

Re: Multi User Database Issue

Posted: Fri Mar 08, 2019 9:22 pm
by alepap
I had this problem 2 years ago, and at that time, Kaspersky anti-virus was causing this.
I remove the Kaspersky and used only Defender and my problem was solved.

A few months ago, the very slow situation came back, around october 2018. I realize that it comes when a file is open in shared mode and another user is trying in exclusive mode.

If I use all files access, always in EXCLUSIVE MODE, I don t get the slow situation.
If I use SHARED and EXCLUSIVE, I get the slow situation.

The solution for me was to make sure that the file is always OPEN in SHARED mode at the beginning of the program, and no function would try to open the file in EXCLUSIVE mode.

I also installed the SMB2 patch from Alaska on all computers, Windows 7, Windows 8, Windows 10.