Viewing 15 posts - 76 through 90 (of 168 total)
try this
Create
table ntexttest (sno int, val ntext)
Create
September 13, 2006 at 3:10 pm
try this
Create table #orders(orderid int, quantity int)
insert #orders
select 1,3 union all
select 2,1 union all
select 3,4 union all
select 4,2
GO
Create procedure orderproc as
begin
declare @oid int, @cnt int,@i int
Create table #temp(orderid int, quantity...
September 13, 2006 at 11:58 am
Its very simple logic,
In All the four columns One Column only contains the value and all other's contains 0, Then dont allow any value to be true for two conditions,...
September 11, 2006 at 5:52 pm
Replace the totOpen column def in Query with this, hope it will work
CASE WHEN Payday IS NOT NULL OR WRcurrentStatus = 110 OR WRcurrentStatus = 40 THEN '0' ELSE DEaltKeyValue END...
September 11, 2006 at 1:52 pm
September 11, 2006 at 12:41 pm
same result using CTE's
WITH ACTE ([ID],[Name],[NameCount]) AS
(
SELECT [ID], [Name], COUNT([Name]) NameCount FROM MyTable1 GROUP BY [ID], [Name]
 
SELECT B.[ID],MIN([NAME]) AS [NM]
FROM...
September 11, 2006 at 12:35 pm
try this
select * from employeedetails where edescription='employee name is ''john jackson'' and state is ''ca'''
September 11, 2006 at 11:24 am
This can allow upto 16000
declare @sql1 varchar(8000),
@sql2 varchar(8000),
@ret int
set @sql1=N'Select * from '
set @sql2=N'sysobjects;'
exec( @sql1 + @sql2)
I think you need to capture return code, that is not possible with...
September 8, 2006 at 3:44 pm
But I am able to create a synonym for a SP and successfully executed that SP using synonym in SQL 2005
CREATE
SYNONYM [dbo]
September 8, 2006 at 3:42 pm
Four-part names for function base objects are not supported in Creation of Synonymns
-- BOL
September 8, 2006 at 2:39 pm
September 8, 2006 at 1:51 pm
try this
SET
TRANSACTION ISOLATION LEVEL READ COMMITTED
GO
Begin
Tran T2
September 8, 2006 at 11:41 am
I think this is what you are looking for
select coalesce(nullif(ColumnA,''),nullif(ColumnB,''),nullif(ColumnC,''),nullif(ColumnD,'')) from tab
But performance wise its too bad I guess
September 8, 2006 at 11:16 am
try this
select distinct o.[name],case i.indid when 1 then 'PrimaryKey' else i.[name] end as IndexName
from sysindexes i
inner join sysobjects o on
i.id=o.id
inner join sysindexkeys k on
k.id=o.id and k.indid=i.indid
where o.xtype='U' and i.[name]...
September 8, 2006 at 10:59 am
I think you concluded in a wrong way
It is possible to convert float datatype to nvarchar datatype
September 7, 2006 at 5:11 pm
Viewing 15 posts - 76 through 90 (of 168 total)