Index errors when using NT-server and 95/98 workstations 
Author Message
 Index errors when using NT-server and 95/98 workstations

We are using a paradox-database on a Windows NT Server and several Windows
98 workstations.

We are retrieving errors in the folowing case:

An application on a workstation opens a table and it inserts a record to
that table. On creation of the record a query is executed which determines
the maximum key-value of the existing records. We add one to the result
value of the query and we use this value as the key-value of the new record.

The same application on an other workstation opens the same table and it
inserts also a record while the state of the table on the first workstation
is still in insert-mode.

So the key-value of the new records on both workstations are the same. When
we post one of the records the record will be posted with the mentioned
key-value. When we post the other record the application adds one to the
key-value before the record is posted.

During this process we don't get any errors but when we examinate the table
we have been used we always have index-errors on that table when we use an
NT-server.

But when we put the database on a windows 98 configuration we do NOT have
this problem.

Configuration:

Application written in delphi 4.0 pro
Paradox database (The problem table has several indexes, Primary Key + 21
Sec. Keys)
Windows 98 as workstations (2 workstations)
Windows NT 4.0 (Build 1381 service pack 3) as server

Does somebody has an explanation for this problem or is there anybody who
has simular problems?



Wed, 18 Jun 1902 08:00:00 GMT  
 Index errors when using NT-server and 95/98 workstations
Kurt,

There's a simple way round this. You need a separate table with a
single field to hold the last key value used. When a user inserts a
new record, in the OnNewRecord event, open this table and try to set
Exclusive to True. If successful, get the current value, increment it
and post it back to the single-field table. Then use that value as the
key for the new record.

I'm not sure I've explained that very clearly, so if it doesn't make
sense mail me and I'll try to explain better.

--
Stephen Brown

Quote:

>An application on a workstation opens a table and it inserts a record
to
>that table. On creation of the record a query is executed which
determines
>the maximum key-value of the existing records. We add one to the
result
>value of the query and we use this value as the key-value of the new
record.

>The same application on an other workstation opens the same table and
it
>inserts also a record while the state of the table on the first
workstation
>is still in insert-mode.

>So the key-value of the new records on both workstations are the
same. When
>we post one of the records the record will be posted with the
mentioned
>key-value. When we post the other record the application adds one to
the
>key-value before the record is posted.

>During this process we don't get any errors but when we examinate the
table
>we have been used we always have index-errors on that table when we
use an
>NT-server.



Wed, 18 Jun 1902 08:00:00 GMT  
 Index errors when using NT-server and 95/98 workstations
Are you using IPX/SPX?

NT has a bug with IPX/SPX prior to Service Pack 4.

HTH,

Paul Motyer
SoftStuff
PO Box 637, Croydon, VIC, Australia, 3136




Wed, 18 Jun 1902 08:00:00 GMT  
 Index errors when using NT-server and 95/98 workstations

Quote:

> We are using a paradox-database on a Windows NT Server and several Windows

                           ^^^^^^^^^

ftAutoInc ???

--
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
...Should we shout ? Should we Scream ?    ...With all the best wishes - Arioch /BDV/
   What happenned to the post-War dream ?     Buroff - the only and unique...



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 4 post ] 

 Relevant Pages 

1. User32.dll Error on 95 Not on 98 or NT

2. Help: MS-DOS Screen Capture (in Full-Screen Mode) Under Win 95/98/NT

3. Migrating from Windows 95 to Windows 98

4. TP6 - Windows 3.x,95,98

5. BP7 + Protected mode apps + Windows 95/98 = slowdown

6. Programmically installing TCP/IP under windows 95/98

7. TD286 Debugger and Win 95/98

8. Windows '95/'98 Shutdown

9. Windows 95/98 Version Information

10. compiler for windows 95 or 98

11. Missing PRNFLTR for Turbo Pascal 7.0 on Windows 95/98

12. Windows 95-98 Source Code

 

 
Powered by phpBB® Forum Software