Solved

Script

Posted on 2008-06-20
1
187 Views
Last Modified: 2013-11-05
Hi All

I'm looking for a script that loops through a table(table1) and for every row in the table it performs an insert in another table(table2).
So If table1.value = "number" then insert  table1.value  into table2

Thanks for any help
0
Comment
Question by:ram_os
1 Comment
 
LVL 75

Accepted Solution

by:
Aneesh Retnakaran earned 150 total points
ID: 21831285
insert into Table2
select Column1, col2....
 from from Table1 where value = 'number'
0

Featured Post

Microsoft Certification Exam 74-409

VeeamĀ® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article explains how to reset the password of the sa account on a Microsoft SQL Server.  The steps in this article work in SQL 2005, 2008, 2008 R2, 2012, 2014 and 2016.
I have a large data set and a SSIS package. How can I load this file in multi threading?
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

821 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question