Click here to Skip to main content
15,929,253 members
Home / Discussions / Database
   

Database

 
AnswerRe: Simple E-mail functionality Pin
Sunset Towers2-Aug-07 7:21
Sunset Towers2-Aug-07 7:21 
QuestionCounting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 3:25
Sunset Towers2-Aug-07 3:25 
AnswerRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 3:29
kubben2-Aug-07 3:29 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 3:37
Sunset Towers2-Aug-07 3:37 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 5:10
Sunset Towers2-Aug-07 5:10 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 5:22
kubben2-Aug-07 5:22 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 5:43
kubben2-Aug-07 5:43 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 6:01
Sunset Towers2-Aug-07 6:01 
Ok I maybe calling the

DECLARE @cnt int
Select @cnt = count(*) from PlaceInReferralLine

from more than one place so I'm assuming the best thing to do would be put just this code in
the stored procedure.

I'll give that a try, because the orginal code and the stuff I modified kept coming up with a SYNTAX ERROR near @cnt. Of course they couldn't atleast tell me which one was causing the problem from the debugger. Hehe.

Ok. While I am used to getting and retrieving data from different databases I'm still what I consider to be an extreme novice as I only know how to do the basic select, insert, etc.. stuff

So now for a few more questions

1. How do I get it to return the count from the store procedure.

CREATE PROCEDURE dbo.StoredProcedure1
DECLARE @cnt int
Select @cnt = count(*) from TABLE
RETURN @cnt <-I'm assuming

or maybe more simply

CREATE PROCEDURE dbo.StoredProcedure1
RETURN Select count(*) from TABLE

All this is being done in Visual Web Developer from MS.

2. Then I assume to get the data from the stored procedure

INSERT INTO TABLE
(col1, col2)
VALUES ('value1', dpo.StoredProcedure1)
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 6:29
kubben2-Aug-07 6:29 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 7:18
Sunset Towers2-Aug-07 7:18 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 7:20
kubben2-Aug-07 7:20 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 7:22
Sunset Towers2-Aug-07 7:22 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 7:25
kubben2-Aug-07 7:25 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 7:37
Sunset Towers2-Aug-07 7:37 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 7:51
kubben2-Aug-07 7:51 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 8:24
Sunset Towers2-Aug-07 8:24 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 8:28
kubben2-Aug-07 8:28 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
Sunset Towers2-Aug-07 9:35
Sunset Towers2-Aug-07 9:35 
GeneralRe: Counting the Records in a Database for a Insert Statement Pin
kubben2-Aug-07 13:15
kubben2-Aug-07 13:15 
QuestionTransaction in dotNET and SqlServer Pin
Developer6112-Aug-07 1:28
Developer6112-Aug-07 1:28 
AnswerRe: Transaction in dotNET and SqlServer Pin
Colin Angus Mackay2-Aug-07 1:38
Colin Angus Mackay2-Aug-07 1:38 
QuestionRe: Transaction in dotNET and SqlServer Pin
Developer6112-Aug-07 1:56
Developer6112-Aug-07 1:56 
AnswerRe: Transaction in dotNET and SqlServer Pin
Colin Angus Mackay2-Aug-07 7:50
Colin Angus Mackay2-Aug-07 7:50 
QuestionRe: Transaction in dotNET and SqlServer Pin
SalarSoft3-Aug-07 21:50
SalarSoft3-Aug-07 21:50 
AnswerRe: Transaction in dotNET and SqlServer Pin
Colin Angus Mackay3-Aug-07 22:10
Colin Angus Mackay3-Aug-07 22:10 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.