Viewing 15 posts - 46 through 60 (of 73 total)
If your update takes 11 seconds consistently, but selects instantly then it sounds like the query is having to do a lot of locking before it can commit.
But without knowing...
June 16, 2003 at 4:12 am
Murad
Why not try casting the fields in a lowest common denominator kind of way to compare them.
This kind of idea...
select
t1.key1,
t1.val1 as table1_val1,
t2.val1 as...
June 16, 2003 at 4:03 am
Pranav
XSL is used to change the presentation of XML data, so I can't see how (or why) you would want to do this.
Apply the XSL to transform the data when...
June 12, 2003 at 3:56 am
demos
If the variable really is '1' or '1,2,3' then you will need to build up a sql statement in a string then use sp_executesql to execute the string.
June 11, 2003 at 3:20 am
Fascinating have I fallen into a alt.sports.boer newsgroup by mistake?
You'll need to do
Select * from (tablename) as ROOT for XML Auto, Elements
if you want <ROOT> around your output.
June 9, 2003 at 10:56 am
A standard recursive call would involve a cursor but that is a dirty word on this forum.
Depending on the target application you could use a 'fragment caching' technique. Fragment...
June 9, 2003 at 9:57 am
Not sure if it will work. Also if you don't specify the table name etc. the optimiser will have trouble compiling the function and you may not get many...
June 9, 2003 at 7:58 am
Do you remember where you read that order by might not work?
I realise that you are pointing out that it is in 'insert' or 'select into' but it...
June 9, 2003 at 3:07 am
Crappy
Why don't you add an identity column to your temp table and then select between key values
ie
create table #temp (id_no identity (1,1), val varchar(50))
<insert your data>
for first ten
select val from...
June 6, 2003 at 8:45 am
Well if you want column names you could use sysobjects and syscolumns like
SELECT syscolumns.*
FROM
sysobjects
join syscolumns on sysobjects.[id]=syscolumns.[id]
where sysobjects.[name]=<tablename>
bung the output into a temp table, loop round from 1 to...
June 6, 2003 at 2:52 am
As NPeeters pointed out a correlated subquery is the best way forward. Another option (less good) is to use derived tables.
June 6, 2003 at 2:38 am
Just read Antares reply (amazing that replies can happen while you are writing) and he is right you can use identity fields and temp tables.
June 3, 2003 at 4:32 am
Hi
Using a correlated subquery should do the trick. It works by counting the number of values that are less than or equal to the current value (in this...
June 3, 2003 at 4:05 am
Perhaps the site owners could make a feature of favourite books, when I'm buying from Amazon (or almost anywhere online) I always check out reviews and pick out the most...
June 3, 2003 at 3:35 am
Create your own psuedo-for-xml command and you can do waht you like with the header.
declare @XML nvarchar(4000)
set @XML=(select '<customers><CustomerId>' + customerId + '</CustomerId><CompanyName>' + CompanyName + '</CompanyName></customers>' from customers where...
May 29, 2003 at 8:56 am
Viewing 15 posts - 46 through 60 (of 73 total)