Viewing 15 posts - 286 through 300 (of 1,346 total)
No,
a second query is in order
alter PROCEDURE TestProc
@SumTotal money OUTPUT,
@AvgTotal money OUTPUT
AS
SET NOCOUNT ON
SELECT @SumTotal = Sum(LineTotal), @AvgTotal = Avg(LineTotal)
FROM Sales.SalesOrderDetail
SELECT SalesOrderID, LineTotal
FROM Sales.SalesOrderDetail
November 30, 2007 at 10:46 am
What control are you using? the Table control?
on each cell on the table control you can select the Cangrow Property and set it to false.
That will maintain the layout...
November 30, 2007 at 10:07 am
Just because he has been given grant permissions does not mean he does not have to specify the table owner.
Its all part of the security chain.
UserA and UserB can both...
November 30, 2007 at 9:57 am
a little odd, but since you declared your variable a datetime, and initialized it by setting it to '' it looks like sql server set it to 0, or the...
November 30, 2007 at 9:44 am
You probly figured this out already,
but when you get that error it usually means your account got locked, but your security token is out of sinc.
Log off your machine,...
November 29, 2007 at 10:25 pm
No, you can alias your columns.
So where you know the column names returned are the same in each table you can us the as to alias the column
I know your...
November 29, 2007 at 10:23 pm
Ravi Patel (11/29/2007)
November 29, 2007 at 9:58 pm
Sure,
But your logic makes no sense, Do you need to return the Number RangeID, or just the next number??
create Proc ReturnNumber @CurrentNumber bigint output
as
-- Get the current number
select @CurrentNumber...
November 29, 2007 at 9:55 pm
That does not make sense.
What do you mean
Table01 all fields having Account index.
Take what I gave you and keep it going you have to use table aliases to keep...
November 29, 2007 at 4:41 pm
Cannot read your code to figure out what your executing
Try printing the @sqql variable to see what is actually being executed.
Print @sqql
EXEC sp_executesql @sqql
take the data that is returned to...
November 29, 2007 at 4:33 pm
-- By first ID
select *
from number_ranges
where id = (select min(id)
from number_ranges
...
November 29, 2007 at 4:30 pm
The following script will kick out a row for each table.
Set your query window to Results to Text, Execute this script
Copy results to clipboard,
then paste them into a new...
November 29, 2007 at 3:20 pm
To link tables together in a query is called a join.
By the table definitions you have provided, it is not clear what field in table01 is the account index as...
November 29, 2007 at 3:03 pm
What is the reason you need to drop the table?
By dropping the table you will be unable to hold any locks against it.
By default sql will lock the table if...
November 29, 2007 at 11:26 am
You can use charindex, or patindex along with substring
declare @Temptable table (pk int identity, Name varchar(50))
insert into @Temptable (Name)
select 'Doe, John' union
select 'Doe, Jane' union
select 'Dirt, Joe' union
select 'Cartoon, Joe'
select...
November 29, 2007 at 11:17 am
Viewing 15 posts - 286 through 300 (of 1,346 total)