Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

close a single table stored in a variable

Status
Not open for further replies.

thegame8311

Technical User
Jan 6, 2012
133
US
I have done the methods found on here but they don't seem to work:

Code:
select (Team_name)

use

Code:
use in (Team_name)

not sure where to go next because Team_name is variable that contains the name of a table, which I know is unorthodox but it is what I am doing.

each time is know the name of the table but thinks that I am using it as an alias, but all i am trying to do is close the previously used table because upon re-entering the form it will not be the same table selected
 
A good part of this whole issue would have been resolved if the over-all Data Architecture had been better - better table Normalization.

Instead of having separate data tables for each Team, it would have been MUCH BETTER to have had a single Team data table containing ALL teams and then have one or more secondary tables containing the other pertinent records associated with the individual teams.

Regardless, Tamar's advice is the way I would go.

Code:
cTeamTable = ADDBS(<SomePath>) + "Team 1.dbf"
USE (cTeamTable) IN 0 ALIAS TeamTable
SELECT TeamTable
<do whatever>

Good Luck,
JRB-Bldr

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top