Viewing 15 posts - 151 through 165 (of 1,082 total)
mmm that is going to be tricky ...
Could you not just join your other tables to the dynamic query:
--TEST DATA
--**************************************
CREATE TABLE contactinfo
(
person_id INT,
question VARCHAR(1000),
answer VARCHAR(2000)
)
CREATE TABLE personinfo
(
person_id...
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 22, 2009 at 5:38 am
Ok I hope I'm understanding what you saying but sorry if I've misunderstood:-)
This code you will see that if you add extra rows with different questions to the table before...
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 22, 2009 at 5:05 am
could you post the actual execution plan?
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 22, 2009 at 4:55 am
This can be done dynamically without having to change the code.
Could you supply some sample data and what the output should be please 🙂
thanks
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 22, 2009 at 4:46 am
Welcome to SSC 🙂
I hope find all the help you need here.
Please could I ask that you read the link in my sig about how to make the best posts,...
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 22, 2009 at 4:22 am
I'm sorry but I have to back up Gianluca Sartori here.
He has tried to help the OP at the beginning of the thread with some suggestions on changing the order...
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 22, 2009 at 3:29 am
Glad I could help 🙂
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 22, 2009 at 2:12 am
DECLARE @Date DATETIME
SET @Date = '2009-05-01 13:43:15'
SELECT REPLACE(CONVERT(varchar(13),@Date,10),'-','')
Check out the CONVERT function in BOL
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 21, 2009 at 10:42 am
also depends if you have SET ANSI_WARNINGS ON or not
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 21, 2009 at 10:36 am
IS this query only supposed to return the correct phone numbers?
If this is case I think I will work on a short circuit case statement in the where clause...
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 21, 2009 at 9:11 am
I've tried using scalar functions that don't access data and Gail is correct that most of the time they perform poorly.
I've tried to break this query down for the mil...
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 21, 2009 at 9:05 am
could you show us you SQL ?
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 21, 2009 at 6:34 am
I'm sure about why you getting error.
However if there is a certain query or table that you have identified as being a poor perform, throw the code at us and...
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 21, 2009 at 5:13 am
I agree, this was a very useful thread and I think alot things have been cleared up 🙂
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 20, 2009 at 9:49 am
awesome Gail found us he he he
----------------------------------------------
Try to learn something about everything and everything about something. - Thomas Henry Huxley
:w00t:
Posting Best Practices[/url]
Numbers / Tally Tables[/url]
May 20, 2009 at 7:47 am
Viewing 15 posts - 151 through 165 (of 1,082 total)