Viewing 15 posts - 3,391 through 3,405 (of 3,543 total)
Interesting Tim, my code worked OK for me in QA. I'm running SQL7 SP4.
nb Your code runs OK in QA with or without the GLOBAL option.
March 7, 2003 at 8:47 am
Better still combine both into one single proc with selection param (eg Boys, Girls or Both).
March 7, 2003 at 6:30 am
If you embed the query you need to add more quotes as in
@query ='DECLARE @A1 CHAR (20)
DECLARE @A2 CHAR (2)
SET @A1 = ''Yvette Palomo''
SET @A2 = ''N''...
March 7, 2003 at 4:54 am
Create the database/tables etc on SQL7 and use DTS.
March 7, 2003 at 4:40 am
Andy, I think formatting is an issue and it depends on what you are using to do the transfer. DTS for example will use select to get data and the...
March 7, 2003 at 4:29 am
The advantage of using a command object is being able to pass any text inc single quotes without undue processing or conversion and you can specify the CommandType (StoredProcedure or...
March 7, 2003 at 4:13 am
declare @sql nvarchar(200)
set @sql = 'declare Update_IndexID cursor for Select '+@IndexColumn+' from ##CopyCaseIDtbl'
exec sp_executesql @sql
OPEN Update_IndexID
FETCH NEXT FROM Update_IndexID
WHILE @@FETCH_STATUS = 0
BEGIN
FETCH NEXT FROM Update_IndexID
END
CLOSE Update_IndexID
DEALLOCATE Update_IndexID
March 7, 2003 at 2:29 am
Could try using temp table
create #tmp ([Name] varchar(10),C int)
insert into #tmp exec SP1
insert into #tmp exec SP2
select * from #tmp
March 7, 2003 at 2:19 am
You are returning two recordsets. QA displays each recordset in a separate result window in grid mode or both together in text mode. If you are using ADO with ASP...
March 4, 2003 at 3:26 am
Bit stumped really.
I'm using SQL7 so don't know if that is the problem!!.
In the first sample you posted is all the data in one text field or is it split?
Can...
February 28, 2003 at 7:07 am
When I use the code with your sample data and Greg's it works for me!
Is there something different about the data?
Can u post small sample?
February 28, 2003 at 6:09 am
My answer depends on each row of text having both 'User Name:' and 'Domain:', also if there is no name will give you the error.
Try
select LTRIM(RTRIM(SUBSTRING(test_text,CHARINDEX('User Name:', test_text)+10,CHARINDEX('Domain:', test_text)-CHARINDEX('User Name:...
February 28, 2003 at 4:13 am
Depends on whether you want the avg to be of 17 weeks or the number of weeks worked!
This code uses the data available and will calc the average of the...
February 28, 2003 at 4:07 am
I always script my procs in text files and use ISQL to load/update them in one or more DB's. This way I never have to copy procs and also...
February 28, 2003 at 3:17 am
How about
select SUBSTRING(test_text,CHARINDEX('User Name: ', test_text)+11,CHARINDEX(' Domain:', test_text)-CHARINDEX('User Name: ', test_text)-11)
from x
February 28, 2003 at 3:03 am
Viewing 15 posts - 3,391 through 3,405 (of 3,543 total)