Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
INSERT INTO from a table named as a property?
Message
From
21/04/1999 15:36:57
 
 
To
21/04/1999 15:29:43
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00210707
Message ID:
00210711
Views:
26
>I am attempting to INSERT data from a table that
>can have a different name. The source table name
>is defined in a form property (thisform.ictablename).
>
>How can insert field1 into a table named XYZ?
>
>For instance:
>
> INSERT INTO xyz (field1) VALUES(thisform.ictablename..field1)
>
>does not work? There must be a way to do it - right?

cFromTable = thisform.ictablename

INSERT INTO xyz (field1) VALUES ( &cFromTable..field1 )

**********
You could probably even do...

select ( thisform.icTableName )

INSERT INTO xyz (field1) VALUES (field1)

The first field1 it knows belongs to xyz, the second field one belongs to the current work area.

BOb
Previous
Reply
Map
View

Click here to load this message in the networking platform