Please give me the SP for the below scenario. I have two
tables named Table1 and Table2...I need to fetch record by
record from Table1 and insert the record in to table2 where
the value in the sno column of the table1 is even number.

Answer Posted / meenaprasanna

insert into table2(Column1,Column2) select Column1,Column2
from Table1 where Column1 %2 ='0'

Is This Answer Correct ?    14 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

what is the difference between openrowset and openquery?

585


Tell me what are cursors and when they are useful?

500


Can you move the resources after pausing the node? : sql server database administration

586


What is a non-clustered index?

552


What is the datatype of rowid?

500






why would you use sql agent? : Sql server database administration

518


optimization techinques

2187


What is difference between oltp and olap?

565


Suppose i have a table that contains 5 columns like col1,col2...colm5.I want to import only two column through BCP utility.How to do same through BCP in sybase.

1955


How does a profiler work?

507


Describe in brief sql server monitoring ways.

581


What is data file in computer?

534


Do you know what is similarity and difference between truncate and delete in sql?

567


How would we use distinct statement? What is its use?

596


What is the syntax for encrypting a column in SQL Server?

546