Quantcast
Channel: Forum Getting started with SQL Server
Viewing all articles
Browse latest Browse all 7129

SQL: how to loop through data table in store procedure?

$
0
0

We need to create a store procedure which needs to go through a table which include ItemIDs and get each ItemID and run some query base on ItemID.

We know we can use "cursor" to fetch each ItemID.

We wonder are there other ways in SQL store procedure? Thx!


JaneC



Viewing all articles
Browse latest Browse all 7129

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>