INSERTING TABLE INFORMATION [message #36245] |
Tue, 13 November 2001 05:55  |
Amy
Messages: 29 Registered: September 1999
|
Junior Member |
|
|
I have been trying to insert information from one table to another table. The problem I have is that my insert also has to include some constant fields with each line inserted. Here is an example below:
my constant values: Table2.field1 = True
table2.field4 = 27
Table1
field1 ; field 2
---------------
truck ; blue
car ; red
Table2 (resulting table inserts)
field1 ; field2 ; field3 ; field4
--------------------------------
True ; truck ; Blue ; 27
true ; car ; red ; 27
This is what I have tried to do but I get a fatal error and it exits me out of worksheet:
insert into table2(field1,field2,field3,field4)
values
('True'. table1.field1, table1.field2, '27')
I appreciate any insight you can give me on this. Thank You.
(note: the semicolons were to just to help separate the field values not to be in the table)
----------------------------------------------------------------------
|
|
|
|