At 11:42 AM 6/21/2011, J BLAUSTEIN wrote:

I have two simple question?
how do I get the record count for a table?

J,

There are two techniques to achieve this goal.

01. Use Enhanced DB Navigator to be associated with appropriate table.
    Make sure to enable the option for "Record Count".

How do I make a form with a primary table - when I delete the primary
table all the sub table records are delete?

If I understand your question correctly ...

The best and most eloquent method is to use the "CASCADE" option for
the table with PRIMARY Key.

Using R:BASE eXtreme 9.1, there are two available options while in
Table Designer.

Cascade: [ ] Update [ ] Delete

Cascade - Maintains primary/foreign key relationships automatically.
A CASCADE can be applied to UPDATE, DELETE, or BOTH data set changes
for primary keys. For example, if you either UPDATE or DELETE a
primary key value from a table, the corresponding foreign key values
are updated or deleted automatically. CASCADE can only be added to
tables with primary keys.

· Update - enforces that when a primary key value is updated, the
  corresponding value in the foreign key table(s) will also be updated.

· Delete - enforces that when a primary key value is deleted, the
   corresponding value in the foreign key table(s) will also be deleted.

Separate UPDATE and DELETE data restrictions can allow a CASCADE to be
enforced for values that are updated, but not enforced when records are
deleted, in order to avoid an accidental or undesired record delete.

Hope that helps!

Very Best R:egards,

Razzak.


Reply via email to