Paradox Limits

Posted on 1997-11-19
Last Modified: 2008-03-06
I am working on a project that is is sharing Paradox (v. 7) data between two applications.  There is many tables with various physical files.  We are running into memory problems when trying to run both applications at the same time.  We always get a Memory error on a specific table.  My guess is we are hitting one of the internal limits of Paradox, such as open tables per system or open physical files.  Does anyone know of a utility that I can use to tell me how many tables/files are open while running an
application.  If there is not a utility, is there another way for me to obtain this info?

Question by:gjbaker

Accepted Solution

d4jaj1 earned 100 total points
ID: 1025556
Unfortunately, there isn't a utility to display locks of ALL tables at one time, only a single table. You can use the 'Display Lock' command from the Paradox menu. I know this is tedious, but I thought of a better way.

You could loop through your Alias for tables, and once found - use a TCursor to get the current locks, append the lock info to another table (say CurrentLocks.db) and display them in a custom form.  The code below gets the Lock info;

method pushButton(var eventInfo Event)
  tc TCursor
  tv TableView

; Add your code to loop through all the tables in your alias here

if"Orders.db") then  
  tc.enumLocks("OrderLck.db")  ; store Orders.db locks in OrderLck.db"OrderLck.db")       ; open OrderLck.db
  msgStop("Stop!", "Can’t open Orders.db table")

; Once finished appending the records, display the in a tableview or a custom form.

As for Paradox limits, this list outlines the number of bytes each Paradox field type consumes in a record structure.  Note that this is the space taken up in the .DB file itself, not in any ancillary files, such as .MB's.

   Data Type              Bytes
   Alphanumeric         1 byte per character, up to 255
   AutoIncrement        4 bytes
   Binary (BLOB)       10 bytes + 1 per char. in Size (0 - 240) [1]
   Bytes                       1 per character, up to 255 max.
   BCD                       17
   Currency (Money)    8
   Date                        4
   Formatted Memo  10 bytes + 1 per char. in Size (0 - 240)
   Graphic                 10 bytes + 1 per char. in Size (0 - 240)
   Memo                   10 bytes + 1 per char. in Size (1 - 240) [2]
   Logical                   1
   LongInt                   4
   Numeric (Number)  8
   OLE                      10 bytes + 1 per char. in Size (0 - 240)
   SmallInt                 2
   Time                      4
   TimeStamp            8

   Maximum Field Count        :  255 fields
   Maximum Blocks per table :  64K
   Maximum Block Size          :  32K characters
   Max Record Size, unkeyed :  Current block size - 6 bytes [3]
   Max Record Size, keyed     :  (BlockSize - 6) / 3, rounded down to the nearest block size. [4]


 [1]  All blob fields contain a 10-byte pointer to the .MB file, which indicates where the "rest" of the field value can be  found.

 [2]  Unlike other "blob" data types, memos require at least one character of the memo to be stored in the .DB file, for compatibility with Paradox for DOS.

  [3]  The default block size is saved in IDAPI.CFG.  To change the default, run the Configuration Utility and then change the Tables, Paradox, Block Size setting. The default is 2048 and can be increased in increments of 1024 up to 32K.

   6 bytes of this value are reserved for internal pointers.

 [4]  This stems from the way Paradox records key values, which go into a .PX file that is very similar to a table.  The size of the key cannot exceed 1/3 of the table's block size; otherwise, Paradox tries to increase the block size.

 When performing calculations, be sure to take the 6-byte pointers into account.

The only 'memory' resrictions to tables open at a time are determined by the memory you have & the Stack/Block size configuration in the IDAPI.CFG file.

Finally, I doesn't sound like a problem with Paradox internal limits since 1) I have run two copies of P7 over the network from the same machine, aliases, and tables with no problem and 2) you stated it only happenes to this table.  Make sure your PC & network can handle the amount of data you are trying to pass, e.g., it you are running an enifcient query, this could bring your PC and network to a crawl.  Also, make sure the table isn't corrupted itself.  If the table isn't corrupt & your sure the network is good, the example I gave should work (at least well enough to let you know you Do/Don't have too many tables open at a time)

Any questions, just add a comment.

Good Luck!


Author Comment

ID: 1025557
I'm sorry I didn't explain my error correctly, we always get a memory error on a table (but it can be ANY table).  I found in some, Borland technical information regarding internal limits of BDE, that says that Paradox has as limits of:
127 Tables open per system
512 Open Physical files
We have over 100 tables between the two applications.  Some of the tables are shared.  Counting the physical files we have well over 500.  Do you think we shoulld change to a real database such os Oracle?

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains all about SQL Server Piecemeal Restore with examples in step by step manner.
Using SQL Scripts we can save all the SQL queries as files that we use very frequently on our database later point of time. This is one of the feature present under SQL Workshop in Oracle Application Express.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

679 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question