mcnewsxp
2012-11-13 21:50:39 UTC
i need to pass a single value to a stored proc for a select statement then use a couple of the values in the select statement in an insert statement.
@id as decimal
select a, b, c, d from table1 where id = @id
insert into table2(col1, col2, col3, col4) values (table1.a, table1.b, table1.c, table1.d) where id = @id
i could use help with syntax.
tia,
mcnewsxp
@id as decimal
select a, b, c, d from table1 where id = @id
insert into table2(col1, col2, col3, col4) values (table1.a, table1.b, table1.c, table1.d) where id = @id
i could use help with syntax.
tia,
mcnewsxp