October 25, 2017 at 12:40 pm
rodjkidd - Wednesday, October 25, 2017 3:48 AMSteve, I feel your pain! Damn shame you can't use the windowing functions in 2008. I seem to use them more and more for simplifying problems.I had the complete opposite situation last year at a company. Most of the dbs were 2008 R2, but one was 2012 or 2014. My fellow Dev had a nasty little task set which using FIRST_VALUE was trivial to do. But he wasn't too familiar with windowing functions. I spotted the server was 2012 (or 2014) gave him the solution the next morning... Worked like a dream.
Except, all the overnight build was run via third party app that had its own t-sql interpreter (yep no SSIS here or sql jobs running T-sql) and it was only up to 2008...
"It doesn't work for the over night build" I was told the day after...
"Oh I reply, why not stick the code in a stored procedure and call that from the build job..."
Result. I had to say I was really glad it did, tricky to solve without FIRST_VALUE ! I would have had to post the problem on the forums 🙂Rodders...
Edit: It was FIRST_VALUE not LEAD that saved the day!
It's actually fairly easy to emulate FIRST_VALUE in SQL 2008. I don't want to go into it here, because I want to keep this thread non-technical.
Drew
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
October 25, 2017 at 2:05 pm
drew.allen - Wednesday, October 25, 2017 12:40 PMIt's actually fairly easy to emulate FIRST_VALUE in SQL 2008. I don't want to go into it here, because I want to keep this thread non-technical.Drew
No doubt, most of them are are. But I'd have to look it up an d/ or think about it.
But I could fire back the answer in minutes to him once I knew FIRST_VALUE was supported.
October 26, 2017 at 6:51 am
The downside to working from home is, if the cats decide it's the season to start throwing up on the carpet, you kind of need to clean it up instead of pretending you don't see it until the wife gets home and notices it...
October 26, 2017 at 8:02 am
jasona.work - Thursday, October 26, 2017 6:51 AMThe downside to working from home is, if the cats decide it's the season to start throwing up on the carpet, you kind of need to clean it up instead of pretending you don't see it until the wife gets home and notices it...
I got to mop up urine yesterday when a dog made a mess between conference calls.
October 26, 2017 at 8:05 am
Steve Jones - SSC Editor - Thursday, October 26, 2017 8:02 AMjasona.work - Thursday, October 26, 2017 6:51 AMThe downside to working from home is, if the cats decide it's the season to start throwing up on the carpet, you kind of need to clean it up instead of pretending you don't see it until the wife gets home and notices it...I got to mop up urine yesterday when a dog made a mess between conference calls.
At least your dogs don't insist on joining in with conference calls...
Thomas Rushton
blog: https://thelonedba.wordpress.com
October 26, 2017 at 8:34 am
jasona.work - Thursday, October 26, 2017 6:51 AMThe downside to working from home is, if the cats decide it's the season to start throwing up on the carpet, you kind of need to clean it up instead of pretending you don't see it until the wife gets home and notices it...
My sweetie used to work in a shelter and she used to bring home just about every really cute but troublesome case. We were up to 15 cats from the shelter and a couple of outdoor strays. I used to like cats but they destroyed the house. We even had cats that would bring us other cats. We're finally down to just 2... 1 exclusively indoor (he's really clean about things so I don't mind" and 1 that's mostly outdoor (ditto on the clean thing there). I told her "No more cats". She asked why. "Because they'll make me fat". "What do you mean by that?", she asked.
"I love cats... but I can't eat a whole one". 😛
--Jeff Moden
Change is inevitable... Change for the better is not.
October 26, 2017 at 9:14 am
ThomasRushton - Thursday, October 26, 2017 8:05 AMAt least your dogs don't insist on joining in with conference calls...
That's not true at all. Had one in my lap during the first call with my boss while urine festered in the other room.
October 26, 2017 at 9:15 am
Steve Jones - SSC Editor - Thursday, October 26, 2017 8:02 AMjasona.work - Thursday, October 26, 2017 6:51 AMThe downside to working from home is, if the cats decide it's the season to start throwing up on the carpet, you kind of need to clean it up instead of pretending you don't see it until the wife gets home and notices it...I got to mop up urine yesterday when a dog made a mess between conference calls.
That isn't so bad. Whenever our dog has an accident or pukes in the house he runs from the hardwood floor to the carpet to ensure it causes a lot more work for us to clean up.
_______________________________________________________________
Need help? Help us help you.
Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.
Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.
Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/
October 26, 2017 at 9:20 am
FWIW, we brought a second web server online today. Let me know here, or in the other thread, if performance is better or worse.
Our IT group was hesitant to do this as these forums store their attachments on local storage. With old WS2003 servers, we don't have a good shared storage location at the moment. The compromise is that we have a sync job that moves stuff back and forth every 5 minutes. If you get inconsistency with attachments, that's probably it. Wait a few as it will resolve before we can respond to a note.
October 26, 2017 at 9:26 am
Steve Jones - SSC Editor - Thursday, October 26, 2017 9:20 AMThe compromise is that we have a sync job that moves stuff back and forth every 5 minutes. If you get inconsistency with attachments, that's probably it.
Why not set up Service Broker to sync these attachments?
(Very lightweight trigger on attachment table, to put message on queue; activated stored procedure checks if the affected row needs to be copied to the other location; message with attachment contents on separate conversation to the other server if that is the case)
(Does it show that I have been working on my PASS presentation on Service Broker applications today???)
October 26, 2017 at 9:42 am
Sean Lange - Thursday, October 26, 2017 9:15 AMSteve Jones - SSC Editor - Thursday, October 26, 2017 8:02 AMjasona.work - Thursday, October 26, 2017 6:51 AMThe downside to working from home is, if the cats decide it's the season to start throwing up on the carpet, you kind of need to clean it up instead of pretending you don't see it until the wife gets home and notices it...I got to mop up urine yesterday when a dog made a mess between conference calls.
That isn't so bad. Whenever our dog has an accident or pukes in the house he runs from the hardwood floor to the carpet to ensure it causes a lot more work for us to clean up.
Cats do the same thing when it comes to puking.
October 26, 2017 at 10:33 am
Sean Lange - Thursday, October 26, 2017 9:15 AMSteve Jones - SSC Editor - Thursday, October 26, 2017 8:02 AMjasona.work - Thursday, October 26, 2017 6:51 AMThe downside to working from home is, if the cats decide it's the season to start throwing up on the carpet, you kind of need to clean it up instead of pretending you don't see it until the wife gets home and notices it...I got to mop up urine yesterday when a dog made a mess between conference calls.
That isn't so bad. Whenever our dog has an accident or pukes in the house he runs from the hardwood floor to the carpet to ensure it causes a lot more work for us to clean up.
And that's why we got a house without carpet.
October 26, 2017 at 10:43 am
Luis Cazares - Thursday, October 26, 2017 10:33 AMSean Lange - Thursday, October 26, 2017 9:15 AMSteve Jones - SSC Editor - Thursday, October 26, 2017 8:02 AMjasona.work - Thursday, October 26, 2017 6:51 AMThe downside to working from home is, if the cats decide it's the season to start throwing up on the carpet, you kind of need to clean it up instead of pretending you don't see it until the wife gets home and notices it...I got to mop up urine yesterday when a dog made a mess between conference calls.
That isn't so bad. Whenever our dog has an accident or pukes in the house he runs from the hardwood floor to the carpet to ensure it causes a lot more work for us to clean up.
And that's why we got a house without carpet.
LOL. My thoughts for a solution seem to run akin to Jeff's. Get a house without pets...but of course I would really hate not having our dog around.
_______________________________________________________________
Need help? Help us help you.
Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.
Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.
Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/
October 26, 2017 at 10:50 am
Sean Lange - Thursday, October 26, 2017 10:43 AMLuis Cazares - Thursday, October 26, 2017 10:33 AMAnd that's why we got a house without carpet.
LOL. My thoughts for a solution seem to run akin to Jeff's. Get a house without pets...but of course I would really hate not having our dog around.
One pet is fine.
Two pets might not be for everyone.
Three or more...Are we running a shelter?
Of course, anything in a fish tank doesn't count as a pet, just as ornaments.
October 26, 2017 at 11:00 am
Luis Cazares - Thursday, October 26, 2017 10:50 AMSean Lange - Thursday, October 26, 2017 10:43 AMLuis Cazares - Thursday, October 26, 2017 10:33 AMAnd that's why we got a house without carpet.
LOL. My thoughts for a solution seem to run akin to Jeff's. Get a house without pets...but of course I would really hate not having our dog around.
One pet is fine.
Two pets might not be for everyone.
Three or more...Are we running a shelter?Of course, anything in a fish tank doesn't count as a pet, just as ornaments.
Agreed. I love having our dog but when the inlaws visit they bring theirs. It is ok for the 2-3 days they stay but not something I would want to deal with all the time. We tried fish and the boys did a good job taking care of them for awhile. But I had no interest in having fish but they became my problem. And they wouldn't clean the tank at all. That was our one and only attempt at fish. Definitely only dogs for us, my wife is very allergic to cats.
_______________________________________________________________
Need help? Help us help you.
Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.
Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.
Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/
Viewing 15 posts - 60,196 through 60,210 (of 66,712 total)
You must be logged in to reply to this topic. Login to reply