SQL Pseudo code :
insert into SecondTableName
select Column1,Column2
from FirstTableName
where YourConditionHere
C# Code:
try
{
con.open();
cmd=new sqlcommand("insert into SecondTableName select Column1,Column2
from FirstTableName where YourConditionHere",conn);
cmd.executenonquery();
con.close();
}
catch(exception ex)
{
}
finally
{
con.close();
}
Replace the Pseudo code Query with your real time query
It is better to do conversions and calculations with in the query