Are you really a DBA? Documentation"The server is free to choose any value from each group, so unless they are the same, the values chosen are indeterminate. " — FreshPrinceOfSO1 min ago
I don't think this has anything to do with the non-standard GROUP BY semantics - whether it resulted in an error or indeterminate values, this query can never return the rows the OP wants. — IMSoP1 min ago
@MarkStorey-Smith No, I was taking a week off - slightly short of budget until a committee meeting in September and the PM needed to save a few bob, so lots of people encouraged to take leave.
@MarkStorey-Smith I think the programme manager at the next layer up made a hash of their budgeting.
I also think they don't want to get rid of me - appraently I'm on the risks register as a key man dependency. At one point the CIO was grizzling at them about having a contractor as a KMD but they don't have any perms with a background in insurance and DW design.
How the mighty have fallen - PowerVR just bought MIPS for $100M. I think they're planning to have a go at ARM.
@Cruncher: The WHERE clause in your second query will result in no output for answers that have only upvotes or only downvotes or neither. — Andriy M1 min ago
@ConcernedOfTunbridgeWells I doubt it. Imagination Technologies license their GPUs for use with ARM CPUs - Apple have a big stake in them. A U-turn to MIPS would be bonkers. Maybe they're just helping ARM kill the competition and essentially buying a patent pool
I remember seeing pricing for a SGI 4D/25 ca 1990. Back then you could have bought a house for the price of the machine.
@Phil Oh, dear. That would have been slow. UOC bought all of Sun Australia's trade-ins at one point and converted them to XTerminals. That worked much better, although they also had to buy a few high spec servers.
I am trying to execute a command but I need the spaces removed.
Here's the command I want to execute, but it has two spaces:
DROP TABLE Table_1
What I want to do is to convert it to a form which has no spaces. I thought I could use concatenation and the CHAR string function to produce a strin...
At one point (mid 1990s) they had a couple of labs full of entry level sun workstations. Then they worked out that they could buy PCs with hardware that was actually supported by Intel Solaris for much less and the next lab had really high spec PCs with Matrox video cards and SCSI drives.
@Phil Reminds me of a nice feature of XEmacs - you can open windows on the same buffer from different X servers. Made quite a useful quick-and-dirty groupware app.
@ChrisTravers Maybe I should suggest MikTeX. I had a lecturer that reckoned using LaTeX was worth about half a grade on average if you used it to format an assignment.
@Phil love it: "We also have a lot of experience with eventual consistency systems at Google," they write in the paper. "In all such systems, we find developers spend a significant fraction of their time building extremely complex and error-prone mechanisms to cope with eventual consistency and handle data that may be out of date."
@ChrisTravers It's just funny watching the NoSQL fad run it's course. Of course even NoSQL has it's uses, but is clearly isn't a replacement technology for SQL Server etc
Also the ideas that Martin Fowler advocates for NoSQL, namely a db encapsulated behind an API, are valid designs relating to SQL DB's with stored procedures ;-)
@ConcernedOfTunbridgeWells My thing is I'm a big picture guy and and I feel like I'm playing a game of Starcraft and I have to tell the units exactly where to move to.
Yeah, they've invested too much into him to cut him I think. I made fun last night after a couple of bad drives but he seems overall a decent player. How long he'll want to stay 3rd string, I don't know.
@bluefeet Awesome. Pics please. After getting my first I wanted a second immediately but still haven't figured out what or where (and that's been 8 years now)
@MaxVernon ok. I couldn't understand what had happened exactly on those comments (not yours, the whole thread in the question). And sometimes answers get edited in the 6-min window and no trace is left, except for confusing comments.
@bluefeet Yeah, the permanent aspect definitely slows things down for me (although my friend had a number of hers covered/redone and it looks good). The other thing is I like to look at mine so locations like the back are no good as I don't want to stare in a mirror to see my art
@ypercube hmmm I suppose if it was well known and handled by the compiler in a good way, it might be useful. Although I must say, I'm not really a fan of shortcuts like that.
@billinkc I have two on my back which of course I can never see. I have one on my upper arm, hip, wrist and two on my ankle. The new one will be on my foot. They all had a meaning to me at the time but things change.
I had one reworked because I had a blowout on my upper arm one. Basically I count it as 2 tats because both pieces are still there but joined together now.
Had a girlfriend get a lizard on her top of foot, toe to ankle and she said it was the most painful of her tattoos. No meat down there to cushion the needle
Mine's a 3/4 band around my thigh, just above the knee. Perfect height for still presenting a "wholesome" appearance but shows when I dance/run/ride my bike
One of the BAs I worked with she had a large lotus on the inside of her wrist. Tastefully done but since they were financial services, she always had bangles or somethign on to obscure it
@Zane I think they sort of have to now because they are so popular. I'm in financial and there are plenty of people who have them. I just choose to place mine strategically so I can hide them if I want
@Zane One issue in this particular case is that the original query was suboptimal. It used subqueries to get the counts, and the rewritten version used window aggregation. The former could be used with CROSS APPLY (but would still be suboptimal), and the latter couldn't.
Well, the outliers should be picked and monitored anyway. Maybe they are taking the right time to execute and a recompile won't help at all. If so, they should be ignored the next time
> A sample output is as follows. It shows that on a given database, there are three pending I/Os at this moment. You can use the database_id and file_id to find the physical disk the files are mapped to. The io_pending_ms_ticks represent the total time individual I/Os are waiting in the pending queue.
FWIW it sounds like you're playing it the right way. Keep biting your tongue until you've built some relationships outside IT, then start steam-rolling him
I don't want to steamroll him. Honestly my plan right now is to keep playing nice and keep refactoring/fixing things, then let him handle the DBA stuff and I handle the development stuff
@JNK I know for a fact that's not true because we constantly had people making DML changes at our client sites at wand from the help desk. The most assuredly were not using explicit transactions and we used replaction to pull of that stuff back to our home base.
@JNK that seems odd to me. What does he expect to gain from re-compiling a plan that has been used once?
Has he ever heard of optimize for ad hoc workloads? Maybe what he's trying to do is prevent single-use plans from occupying the cache, or trying to prevent single-use plans from aging out
@AaronBertrand This is kind of what interests me about this chap. He's read (and possibly misunderstood) enough to be fiddling with plan cache, so what on earth did he muddle to end up with this course of action?
@MarkStorey-Smith no idea. I wonder the same things about even simpler decisions by the majority of folks, like storing dates as strings, thinking an indexed view will improve every query on earth, wanting to free disk space or memory temporarily...
These are all things for which there is ample documentation and discussion that has been going on for years, but people refuse to read and instead insist on relying what they think must be right.
@MarkStorey-Smith In fact I bet a lot of these people have read a bit - e.g. they read one post where a person chose string for a specific reason (and maybe even a bad one, e.g. to maintain formatting) and then decide, huh, that's a good idea. And never read about it again.
@AaronBertrand that early stuff just comes from a fundemental lack of knowledge though. Making no effort to learn how to design or even operate a database.
@Zane but it's the same kind of stuff, only relative. Those people are at tier 1, and the stuff at tier 2 is just beyond them enough to make them dangerous. This guy, say tier 2, knows enough about the plan cache to know to fiddle with it, but he doesn't know how (tier 3). At every tier, there is something that is just beyond you, until you reach the highest tier - and even then, while folks like Paul White are way beyond anyone else on earth in certain areas,
the product is vast enough that there are other areas where they're not experts, and for which there is a tier beyond their current inherent capability.
Now, the big difference is, that as you go up the tiers, you make better decisions about how you use something before you use it - you read, you experiment, you consult others, etc. The people at the lower tiers, I feel, just slap sh*t together so they can leave on time.
I've never understood the path of doing it fast vs. the path of ensuring you've done it right. Great, you delivered a steaming pile of wet crap in 20 minutes, but if you spent an hour on it, it would have been a lot better.
@JNK that is just more stupidity. They are probably trying to round to a day, in one of the most moronic ways possible. But since it looks complicated, they probably feel clever by it.
@swasheck I guess they got rid of their network admin as well and replaced him with a guy who used to run a hockey equipment store but is friends with the VP of software development.
I want to dedicate some time to learn more about performance and tuning issues.
I assign for that a clean DB. I want to know how can I load into it some data and performance-problem queries/DML/DDL?
Do you know some scripts that can cause/generate that (purposely or not)?
The idea is to learn th...
I have a query that does the following:
SELECT DATEDIFF(d, DateUsed, DateExpires) AS DaysBetweenExpirationAndUse FROM tbl
How would I get the average of the column that does the DATEDIFF()? I tried wrapping it in the AVG() function, but that obviously doesn't work.
Agreed with the others about how useless "didn't work" is. If your original question had included the actual code you were trying and the error message you were receiving, it would have been a lot more obvious. Garbage in, garbage out. Don't be surprised to be getting feedback when you ask a crap question. — Aaron Bertrand35 secs ago
"Obviously it didn't work because I tried it" <-- GFYS