« first day (399 days earlier)      last day (4470 days later) » 
07:00 - 15:0015:00 - 00:00

3:00 PM
- if they mention block storage or a parallel file system, everybody finishes their glass.
 
@MarkStoreySmith Oh, by "wasn't a large file" I should mention "for a video recording", it was a couple gigs
I have (unintentionally) written 10GB videos to it in the same time it took to write this 2GB one so I don't know what was up
 
gbn
@MarkStoreySmith Another convert after previous migrations?
 
@BenBrocka maybe a large scale garbage collection operation to free up some space. Doesn't the TRIM protocol advise the disk that certain blocks are no longer in use, or am I confusing it with something else.
 
@ConcernedOfTunbridgeWells Noted :)
 
gbn
What we want
 
3:03 PM
@gbn We can but hope!
 
@ConcernedOfTunbridgeWells MAybe. It's hovering around 20-10 GB of free space now that I think of it, I need to reomve a bunch of games from it again
 
If the disk had a long free list, it could have been an O(N**2) operation to tidy up the free list and consolidate some space.
Maybe getting interrupted with state save/restore to handle I/O from your file save.
 
JNK
I like alex k a lot
he knows a ton of stuff but readily acknowledges what he doesn't know
shows he doesn't have a big ego and just likes to learn and share knowledge
 
Real-time (i.e. interruptable) garbage collection on RTOS platforms is a long way from being a mature technology; I guess it's possible that the disk could have run into a similar class of problem.
However, this is really no more than idle speculation.
 
It's an old drive to boot, so maybe the garbage collection was doing something weird
 
3:08 PM
- If they mention Hadoop, big data or MapReduce, everybody finishes their glass.
 
JNK
I had a vendor try to tell me to use hadoop
since its "better than SQL"
 
@ConcernedOfTunbridgeWells I wish. SQL server 2005 with PHP on windows, using a PHP framework that only recenlty got proper support for sql server. Getting SS to work for our site has been a nightmare
 
@JNK Did you hit him?
 
JNK
I thought about it
Myself and the DBA gave each other a look
and afterwards agreed he was pretty much clueless on databases
He was from the vendor that supplies our main ETL tool
 
@JNK Grasshopper, I think you have mastered @gbn's 'zen like calm'.
 
JNK
3:10 PM
which was disconcerting
 
@JNK In this case, defenestration is actully legal in most jurisdictions.
 
JNK
Our offices are on the ground floor
and conference rooms have no windows
 
JNK
Is it still defensetration if you throw someone through a Windows server?
4
 
@JNK No, I think that refers to removing Windows from the server and installing Linux.
4
 
JNK
3:12 PM
lol
 
@ConcernedOfTunbridgeWells ha, I like that one
 
JNK
the dba and I just mentally wrote off everything that vendor told us
 
But I do like your idea. Maybe you should get some HP ML110's off ebay specifically for vendor management purposes.
 
JNK
What's the pointiest server?
That's what I need.
 
@JNK Did you get to have any fun playing 'let's be mean to the account manager'?
Probably something 1U. Used ML110s are pretty cheap, though.
 
gbn
3:14 PM
@JNK Can you still not try? "make your own window"
 
@ConcernedOfTunbridgeWells Generally Rackspace are a very slick organisation, would recommend them. This case is a new environment build which includes a SQL cluster, so it may be that the right eyes aren't on the case just yet.
 
Actually, a DL360 isn't much smaller than a folded deckchair. Maybe you could do something like that bit on pro wrestling matches where they scone each other with deck chairs, only use a 1U box instead.
 
JNK
@ConcernedOfTunbridgeWells he was actually a technical liason
not an acct manager
 
@ConcernedOfTunbridgeWells With a brick?
 
JNK
he did coding and such
 
3:16 PM
@JNK Mmmmm.... beatings.
There is a significant risk that people will get the ear of someone in your organisation who doesn't know enough to see through the bullshit. That's how a certain vendor of network attached storage equipment managed to sell Oracle over NFS as a data warehouse platform to my current gig.
 
JNK
yikes. Thankfully my manager makes a lot of the decisions on this stuff and he worked with datbaases for a long time before mgt
and my CIO who would make the final decision knows his shit too
he has multiple private sql servers for testing things and writes code still in his spare time
one of the things i like about where I work - most of the folks here have some technical knowledge, and not just enough to be dangerous
 
Unfortunately, management by reading magazines (MBRM) is pretty endemic in uk corporate culture. This is the 5th outfit I've worked for on the trot that's had this type of problem with inappropriately specified MI platforms.
 
JNK
I think its not uncommon here too
just not in my company
 
The only people who seriously advocate this sort of shit for data warehouse systems are high-end storage vendors. Unfortunatley it's next to impossible to get hold of modern SAN kit and do a quantitative benchmark to debunk the bullshit.
 
JNK
i don't know a lot about the hardware end unfortunately
 
3:20 PM
MBRM - I like that acronym
 
@JNK Ebay is your friend. You can buy older server kit - including disk arrays - for peanuts, and do your own experimentation. SANs are a bit of a minefield, though. Often the licenses for the admin software are not transferrarble.
 
My boss thinks he knows stuff, but he really doesn't. The curse of the conversion masters degree :/
 
Plus, a SAN is way, way too big, noisy and puts out too much heat to run up in a private residence.
 
gbn
@ConcernedOfTunbridgeWells just what you need right now, I'd wager
Dropped to 6 degrees last night. Shocking
 
@ConcernedOfTunbridgeWells I had a mini panic when I walked behind an EMC array a few weeks ago. Thought the darned thing was on fire!
 
3:23 PM
@gbn Actually, the place I'm staying in has central heating. However, the disk arrays used to do a good job of heating my office during winter at one point.
@MarkStoreySmith Well, at one point I had the option of buying a DMX2000 for about 5,000 EUR. Unfortunatley it was two rack cabinets with 192 disks, and I was living in a three-bedroom terrace.
 
JNK
take a look at this and tell me if it makes sense. I can't figure out what this guy is trying to do:
-1
Q: Merge with same target and source table

user570715I have one table where I want to check if record exists leave it alone, if not insert new row and update previous row. I am wondering if I can use merge here like below ? CREATE TABLE a (keycol INT PRIMARY KEY, col1 INT NOT NULL, col2 INT NOT NULL, col3 INT NOT NULL); INSERT INTO a VA...

 
@ConcernedOfTunbridgeWells Spot of ducting and you could of offered heating to the rest of the terrace
 
On the plus side, DMX's actually come with a built-in management console, so they don't put you in the business of trying to scrounge a dodgy copy of Navisphere.
@MarkStoreySmith After running 3-phase power into the house :)
 
gbn
@ConcernedOfTunbridgeWells 5 grand would get me a big fuck off gaming rig
 
@MarkStoreySmith Well, I've just stored my F/C kit in a garage at home now - I did think of running up the disk arrays to keep the shed warm :)
 
3:26 PM
@gbn On that note, I had a quick thrash around QuakeLive. I'm decidedly rusty and liable to duel my way to a negative score!
 
@gbn Yes. For 5 grand I could buy a high-end laptop and a couple of big SLC SSDs.
 
gbn
@MarkStoreySmith I need that. My ping on Malta is rubbish, compared to Zurich
I'd only spend 2.5k. The other 2.5k would be for shoes and handbags for SWMBO
2
 
@gbn I wasted a lot more than 5 grand on the F/C kit. Quite the learning experience, though.
i.e. Never buy secondhand F/C kit off ebay unless you know what you're doing.
 
@ConcernedOfTunbridgeWells Did the missus enjoy the compensatory handbags and shoes? :)
 
@MarkStoreySmith No, but she got 3 month holidays to New Zealand, and HMRC did quite well out of me between 2006-2010.
However, I do know that 'Seagate Generic', Netapp and Clariion firmware all play nicely with Mylex DAC-FFX series RAID controllers.
Whereas Hitachi and LSI firmware have slightly wierd, proprietary LIP reset protocols and bollox up pretty much everything they come in contact with.
And software RAID on windows is poo, so fibre channel JBOD hardware is useless on Windows for all intents and purposes.
It does work quite nicely on Linux, though.
 
3:41 PM
You've got "proper hacker" written all over you my good fellow :)
 
Well, I did manage to sweet-talk a complete set of up-to-date disk firmware images off Netapp's support staff.
You didn't see that.
:D
Actually, tinkering with the F/C stuff was quite fun.
I think its principal benefit was knowing enough about SANs to engage with infrastructure types and see through their bullshit.
 
I've had years of meeting with EMC & HDS numpties, so I'm well versed in their bullshit :)
 
@ConcernedOfTunbridgeWells For anything "non-core" to my skillset, that tends to be my approach. I don't need to be expert but I need to be able to spot someone pretending to be one.
Doesn't take much most of the time :)
 
Most of my bullshit-wrangling has been through infrastructure architects who have already drunk the vendor cool-aid. Unfortunately in the contracting racket, most of the design decisions have already been cocked up long before I get anywhere near the project.
 
Confidence in Rackspace restored... "I am glad to inform you that our Segment Support Infrastructure team is already aware of this and they have confirmed the "DATA" folder and any .MDF / .NDF / .LDF files are excluded by default for being scanned."
 
3:48 PM
@MarkStoreySmith It's a useful skill to have.
 
@gbn he's even got positive feedback from the OP after over a year - maarvelous. It would be great to see him settled here
 
I know enough about .Net and Java to do development work in them as the need comes up, and to spot architects who are full of shit.
 
@ConcernedOfTunbridgeWells You'd love my boss :D
 
I know enough about infrastructure to make cogent recommendations and spot BS from infrastructure types.
Is that love or 'love'?
A bit of a jack of all trades and master of none really. I can write SQL OK.
But the 'jack of all trades' approach is pretty useful. I.T. departments are so overspecialised.
And the look on an empire-builder's face when they realise you know what you're talking about is priceless.
 
@Nick you around?
 
3:52 PM
@JackDouglas just walked in
wassup
 
10
Q: Passing array parameters to a stored procedure

Mongus PongI frequently come across the situation where I want to pass an array of Ids as a parameter to a stored procedure. For example with GetCustomerAccounts stored procedure, the client chooses say 20 customers from a list. I want to then pass these 20 customer Ids to the procedure for it to return th...

13
Q: Technique for sending lots of data into stored proc

D. LambertI've got a process that grabs a bunch of records (1000's) and operates on them, and when I'm done, I need to mark a large number of them as processed. I can indicate this with a big list of IDs. I'm trying to avoid the "updates in a loop" pattern, so I'd like to find a more efficient way to sen...

 
yep, RE: my flags?
 
you sure you think these should be merged?
.
 
nickcraver.com/blog/2012/02/07/stack-overflow-short-on-space Blog post on stack overflows growing pains
3
 
gbn
@ConcernedOfTunbridgeWells Many IT depts lack some form of Db specilaisation though
 
3:55 PM
@JackDouglas judging from just the title they look like related but independent questions; however the bodies and answers show these questions are basically the same. any answer on one is a valid answer on the other. don't you agree?
but I don't think it's a big deal; they are already linked to each other so if you want to leave them open then that should be fine
 
I'm not sure - what do others think. My hesitation is there seems to be a difference in scale in the Qs intent
 
@atxdba Some pragmatic common sense thinking in there
 
@gbn Yes, Sadly, I think databases are a big enough topic that they really need to be a primary speciality to do well. However, there's nothing stopping a database specialist from knowing a bunch of other stuff as well.
 
Do you mind having a look @gbn and saying what you think?
 
@gbn Because its all so easy. Until it stops being easy.
 
gbn
3:58 PM
@JackDouglas you mean merging?
 
Yes - to merge or not to merge :-)
 
gbn
@atxdba A few comments mentioning "NoSQL", Postgres, Hadoop, "use this search" or "use that search", Apache etc
 
I hadn't read through the comments
 
@JNK had it been a "more normal evening" I would've been here shortly after this pinging ... alas
 
JNK
@jcolebrand no problem, jack showed up
 
4:01 PM
@jcolebrand Hi :-) Is that abnormal good or abnormal bad?
 
abnormal frustrating
 
gbn
Interesting. I don't want to sound critical, but SO database isn't that big and hasn't as much traffic as some that are mentioned here,. I always thought the main issue they had was the web and middle tiers, caching, DNS, SSL et. Not the DB per se.
 
life or SE?
 
gbn
@JackDouglas yes, merge the one with 2 answers into the other, but keep title from thi one?
 
@gbn that's what I thought too
 
4:04 PM
I think they do OK to run it on fairly modest hardware though. The server has a lot or RAM for caching, but otherwise they've not had to bother with a big hardware footprint.
 
gbn
@JackDouglas if they have asked here about RAID; we'd have "closed as dupe" based on previous answers. Or @COTW could offer his garden shed as hosting
 
100GB of 'hot' data is in the realms of "challenging"
 
@JackDouglas life
 
they must have a bunch of read-only slaves knocking about?
 
I think they just cache the buggery out of the DB.
 
4:05 PM
@gbn wait what's the conversation?
 
@JackDouglas Search is done with Lucene + fat cache
 
gbn
@MarkStoreySmith RAM. Chips and RAM. RAM and egss, RAM, RAM, RAM.
 
Also, the SE team has hired BrentOzar to help with stuff, and apparently he's top notch for MS SQL
 
@gbn my favorite comment: "Don't spend too much time and energy rearranging the deck chairs on the Titanic." Oh noes!!11!1 DB IZ GROWING!!!
 
The HW spec is a bit cheap and nasty, though - white box servers and MLC SSDs. It's not like SLC disks are all that expensive.
 
JNK
4:06 PM
This is really not a huge DBV
 
@gbn So attach title "Passing array parameters to a stored procedure" to other quesion? @Nick you happy with that?
 
JNK
its just huge for the activity level they have
however i want to punch everyone mentioning nosql solutions
2
eventual consistency won't work on something like SO
 
gbn
@JNK yep.
 
@JNK No, it isn't. I think most of the hard work is in the full-text searches.
 
@gbn Its a lot to be shuffling even when entirely in RAM
 
4:07 PM
@JNK it's ok for votes etc, no?
 
@Concerned, i had a look of disappointent when they claimed their intel drives were the fasted out there, completely looking over fusion io
 
JNK
its ok for votes, its not ok for answers or delete votes or flags
 
gbn
@ConcernedOfTunbridgeWells Another volumes for the FT indexes then??
 
JNK
and as busy as that site is most of that NEEDS to be real time
 
@gbn Lucene
 
4:08 PM
@gbn Probably - plus more RAM.
 
@MarkStoreySmith what is Lucene btw?
 
JNK
they already use lucene i think
 
gbn
@MarkStoreySmith yes, but with enough RAM, you can minimise IO access. IO write speed is determined by LDF volume.
 
Inverted indexes aren't super efficient though - you still have to stuff your results into a priority queue to get the highest cosine ranking out quickly.
 
+1 for lucene
 
JNK
4:09 PM
it's xml/text based search you can put on top of sql
 
@JackDouglas open source free text search
 
JNK
basically flat file indexing
 
@JackDouglas how exactly does a merge work? one question will disappear?
 
I've done some POC with Solr recently, which is built on Lucene, awesome
 
better than FTS built in to SS?
 
gbn
4:09 PM
On an SE note, I see Jeff A is leaving
 
JNK
yep
yeah I was going to test solr here
as a fun project
 
@JackDouglas Lucene is to SQL FTS as SQL Server is to MySQL
 
JNK
but they are going with Live search or whatever MS offering is
 
@MarkStoreySmith :-)
 
@MarkStoreySmith Reminds me of my third year software engineering project - hacking a full-text search system to change its definition of 'word' to encompass search terms we wanted to support on javadoc collections.
 
4:10 PM
@JNK, don't forget about looking at elsatic search, it seems to be the new hotness for a lucene top layer
 
Had to reverse that with an edit! i.e. Lucene rocks, FTS blows
 
JNK
carrot is cool too
 
A full-text index literally contains a set of words, with a list of documents they occur in, and maybe word counts.
 
JNK
but im not going to mess with it
development is working on it and they are going to FAST i think is the name
 
@MarkStoreySmith glad I spotted that - I took it as read...
 
4:11 PM
@JNK works on reddit doesn't it?
 
JNK
@jcolebrand yep but it's out of my hands anyways
 
@NickChammas only after a period of time. Until then it remains alive with a pointer, much as a closed Q does.
@JNK just mentioning that it's not totally foreign or impossible for eventual consistency to work on such a large site. Would be awkward with SE Q and A, but not impossible
 
reddit doesn't use solr directly, their indexing company (which is about to get shutdown), IndexTank does use lucene though
 
Maybe it would work on a less waterfall site.
 
@jcolebrand what's up?
 
4:12 PM
@JackDouglas wife frustrations
 
gbn
@NickChammas The old box becomes a performance testing box then. Not wasted money, really. Example, spank in more questions and comment to predict growth and load patterns
 
more a conversation for skype than the SE Chats
the long and short of the current frustrations is that she knew she was leaving town with her mother for two weeks and didn't do any laundry till two days ago, and yesterday when we should've left the house at 5pm for her to go to her mothers in preparation for leaving at 1am, we didn't leave till 9:15
 
JNK
I think you would have major issues with BASE on SE....not knowing if an answer was already accepted. Not knowing if something has been flagged. Not seeing if others have VTC a question. Multiple bounties on same Q. Answering a closed question, or deleted question, without knowing it was closed/deleted.
 
So I didn't get home till midnight, woke up late for work, have stuff to do tonight, etc
 
@gbn Yah. The current tech fashion is really against scaling up.
@jcolebrand Okie doke. So yes, @JackDouglas if we're all in agreement we can merge those two questions together and keep the "array parameters title"
 
4:15 PM
@NickChammas fwiw, the merge moves all comments and answers to the target Q, so the merged-in Q is barren
 
@gbn Jeff leaving?
 
JNK
reading those comments also tells you everyone is an "expert" but most are still clueless
 
gbn
@MarkStoreySmith yes, was on SO blog earlier
 
Posted by Joel Spolsky on February 6th, 2012

Stack Exchange co-founder Jeff Atwood announced that he is leaving the company to spend more time with his family, including his twin daughters Maisie Jane (5lb2oz) and June Adeline (5lb 7oz) who celebrated their 0th birthday (and joined Twitter) last Friday, to the great joy of their parents.

It has been a great honor for all of us to have worked with Jeff over the last four years as Stack Exchange grew from absolutely nothing to a world-changing resource with over 30 million monthly visitors.

When I first met Jeff, I told him that when Stack Overflow was built, it would become a standard part  …

 
4:17 PM
Good on him. Cash out and enjoy the success, all over that.
 
gbn
@NickChammas Which is curious for me. Anyone who can scale out can afford racks/power/cooling and custom solutions. But most folk can't or won't afford that. So scale up, easier for most sites
Scaling to 2 or 3 servers? Why?
Silly argument for me
 
@gbn Even fairly modest wintel or lintel hardware is pretty damn powerful these days.
And clustering adds lots of complexity to your architecture.
 
JNK
Your bottleneck won't be the procs anyways
 
network & disk are the bottlenecks these days
 
gbn
@ConcernedOfTunbridgeWells you mean sharding? Cluster in the SQL Server sense is transparent. Cluster in the MySQL sense is shot
 
4:20 PM
@gbn Clustered shared-disk databases, sharding or clustered middle tiers.
 
gbn
yep
Shot = wrong vowel
 
RAC :)
 
There's quite a lot to be said for simplicity in architecture. Less things to break.
5
And a modern wintel or lintel server can scale up to a pretty substantial piece of kit.
HP DL980 can take (IIRC) 11 RAID controllers (=1,100 disks), 1TB of RAM and 80 CPU cores.
How scalable do you want?
Still cheaper than the database license :)
 
so what's the rackspace requirement for 1100 disks?
 
88U.
Two and a bit racks, including the server itself.
 
4:25 PM
@ConcernedOfTunbridgeWells that's for 3.5" right?
 
gbn
@ConcernedOfTunbridgeWells from memory or did you look it up...?
 
2.5" MSA70s (or whatever the current version is).
4 shelves = 100 disks in 8U.
Actually with P812 controllers you might be able to get 2,200 disks on it.
 
problem is with the flood aftermath still in effect good luck getting 2200 disks on demand
 
That's a pretty extreme case, though - 1.3PB of disk storage.
 
think of a site that needs to store cat pictures, seems trivial then
 
4:28 PM
Still, even with a more sane disk fit-out, that's some pretty serious iron. You could get a lot of punters onto that box for most applications.
Chances are, it would be cheaper to hire Brent Ozar to tune your database than to re-write your app to cope with sharded databases.
Plus, HP will now sell you systems with Seagate Pulsar SSDs and FusionIO PCIe units.
 
@NickChammas done :-) please flag any comments if you think we should delete them
 
@JackDouglas will do (looks like my comment is now obsolete). is Marian's link staying an answer btw?
lolz i just got awarded necromancer for the merge
 
JNK
noice
 
4:45 PM
@atxdba According to the quickspecs the P812 supports 108 disks in total, so just 4 shelves in practice.
 
good to know
 
So, just 0.6PB - damn.
 
<3 SSDs
No way I'd ever have a desktop/laptop with a spinny disk again
 
Less than 3 SSDs?
 
well the internet archive is measured in PB to give a real world example
 
4:49 PM
1
A: What are some ways to implement a many-to-many relationship in a data warehouse?

ConcernedOfTunbridgeWellsSome scenarios for M:M relationships in a data warehouse model Most OLAP servers and ROLAP systems have a means to deal with M:M data structures now, but there are some caveats about this that you will need to pay attention to. If you do implement M:M relationships you will need to keep an eye ...

very thorough
 
Well, you know. Bringing intelligence to the business since 2001 ...
@atxdba Better off with SATA disks for that sort of thing. Plus archive.org use their own proprietary software.
Maybe it's open-source now.
 
it is open source, my shop played around w/ it for a bit
 
Really I'm thinking about a big HP server as a RDBMS server box. Big data types can go with NoSQL solutions, and Big data types with money can use Netezza or Teradata.
A DL980 could handle a pretty substantial transaction load on an ordinary transaction processing system workload.
Maybe I should put that on a business card.
Concerned of Tunbridge Wells
Bringing intelligence to the business since 2001.
cotw@fatbastard.com
 
Who's going to step up and give this Q some luvin' dba.stackexchange.com/questions/12337/…
 
JNK
i was hoping someone would
i wanted to see the answer
 
4:59 PM
@JNK I thought it was prime @gbn territory :)
 
JNK
yeah me too
 
I have an opinion i.e. its a pile of old arse, but I suspect gbn can be more thorough on the security implications
 
JNK
i dont have any practical experience with it
so i didn't weigh in
 
5:18 PM
@MarkStoreySmith I'm not seeing why the intermediary makes anything safer than setting up proper perms + those data accessing procs on the web database
That's what I've been doing on our set up, moving all actual views and procs onto our web database. The old set up had it's hands in a vendor DB and a company DB directly which I didn't care for
 
@BenBrocka Exactly, pile of old arse
 
Dunno if I should answer it though, I'll let someone else
@ConcernedOfTunbridgeWells I wish more people realized that...
Our past development cycle was
Week 1: "Hey, let's customize everything!"
Week 3: "Our customizations are done!"
Week 4: "Why is everything broken?!"
 
5:33 PM
@JackDouglas @jcolebrand Mod magic needed on dba.stackexchange.com/questions/12394/…
Looks like answer from OP after migration, rather than edit into original Q
 
5:48 PM
I'm impressed by SSMS's ability to suggest (and use) indexes that cause a query to perform worse
It's 1/4 for suggesting helpful indexes for this app...which is annoying as they take 20 minutes to build. They seem logical enough but perform like crap
 
DTA can be useful, if used with caution, as it'll create hypothetical indexes (stats only) which avoids the physical build time
 
13
Q: Guide to reading, comparing, and interpretting Execution Plans in SQL Server

Joel CoehoornI'm looking for a good, well-written and explained guide on reading and comparing execution plans in SQL Server. This is for more my own edification as well as for sharing with others. If you want to add your own summary here that would be welcome, though I expect the topic is large enough that...

This looks good for us, no?
canonical and all that?
 
JNK
yes
see if it pisses Joel off though
 
@MarkStoreySmith never used that, how's it work?
@jcolebrand steal it
 
@JNK me? Joel flagged it...
 
JNK
5:54 PM
BRING IT then
 
@jcolebrand seriously? a question from '09?
 
He might have just learned of DBA
 
lmao
 
nvm he has an account here
 
@BenBrocka Give it a database and sample workload (trace or individual queries), hit magic button, enjoy. blogs.msdn.com/b/john_daskalakis/archive/2008/11/20/…
Like SSMS, take the index suggestions with a pinch of salt but it can be useful for tearaway systems that you need to get to grips with fast
 
JNK
6:21 PM
You guys think it's bad form for me to berate askers who just post a list of requirements without any sample code/data or any display of an attempt to resolve on their own?
 
JNK
im talking about Qs like this:
0
Q: Powershell import CSV with multiple delimiters

user1195370I've got a CSV that has multiple delimiters and the following format: groupname;user1,user2;user3 groupname;user1,user2;user3,users4 How can i add the users to the AD groups. All the group names in the CSV ends with an ";" seperator and the users users use the "," seperator.

 
Hopefully @JackDouglas returns before the night is over ;-)
 
@JNK Screw that. Let them "jog on" or leave it for a rep whore to pick up
 
JNK
I normally just tell them in comments to show some effort
and/or berate them
 
6:58 PM
Woohoo, finally an index worked. Giant query from 1m20s to 2s
@MarkStoreySmith interesting, sounds good if I can test an index without locking up the DB for 20 minutes per index
 
@BenBrocka You can do it without DTA also, IIRC undocumented option is WITH STATS_ONLY on the index create statement. Hang on, got a ref somewhere
WITH STATISTICS_ONLY - simple-talk.com/sql/performance/…
 
ahhh that's it. I'll have to try it once I've finished my new queries
working out this hack-job MERGE for SS 2005
 
@BenBrocka Found the one I was after, which includes the DBCC AUTOPILOT command so the optimiser evaluates hypotheticals blogs.solidq.com/fabianosqlserver/…
 
STATISTICS_ONLY was/is undocumented? Jeez
 
@BenBrocka Little use to the average monkey, intended to support DTA only AFAIK
 
7:13 PM
Hadn;t heard of the autopilot either. I'll have to try this stuff out. This app definitely needs indexes. It's still the slowest thing on the site (fortunately only one person will use it)
@MarkStoreySmith Being able to test indexes without building them is pretty useful...
 
@BenBrocka True but its then in the hands of the user to compare the estimated plan costs to see if theres a benefit to be had
 
True...but damn, blindly trusting SSMS's recommendations doesn't seem like a good idea, at least for big tables it seems to give very varied results
Testing a sample query against it's varied suggestions I've gotten query times from 1m20s (base time), 2m+, 50s and as low as 2 seconds
oddly enough the covering index did very poorly and the current non-covering index does way better, even though the base table is huge and the subset is relatively small (200k vs 3m)
shouldn't covering indexes be faster when they're possible?
 
@BenBrocka Yes, it's probably something else in the plan thats bent it out of shape
Post the XML plans on gist at some point and we can take a look.
 
I will once I figure out my view and secondary table. I just had the plans open in SSMS but closed them when I found the best one
 
7:33 PM
I've probably mentioned it before but... sqlsentry.com/plan-explorer/sql-server-query-view.asp
 
So, I'm supposed to figure out how to deploy SSRS reports and I'm honestly confused. The idea would be to have the reports viewable through sharepoint mainly to make permissions easier to manage. I don't understand if I need to setup something on SQL server and sharepoint would connect to that, or if I'd just install reporting services for sharepoint and deploy straight to there. We have SQL Server 2008 and Sharepoint 2010.
 
Makes sense to deploy to sharepoint if you've got it.
 
7:50 PM
@MarkStoreySmith Yeah, that's the goal. I apologize if this sounds stupid. I'm a bit of an accidental dba, and sharepoint is definitely not my specialty. So this specific project has been a bit overwhelming. I'm guessing that's what I need to be able to deploy directly to sharepoint. I'll read the link you posted, thanks.
 
@EugeneM If you've got any specific questions, there is a stack exchange sharepoint site that looks to be well covered with experts these days sharepoint.stackexchange.com
 
Ah that's a good point.
At the moment, I just needed some direction, so that link should be good. I've been struggling to find a low level article that just says "Here are the options for serving ssrs reports." The stuff I've found is more "Here is the standard report server setup. Here is the setup for a failover cluster for report serving."
Thank you very much
 
@EugeneM pleasure
 
Does anyone know off the cuff if it's a waste to have an external SSD drive piped through USB 2.0? (for personal use of course)
Or can USB 2.0 transfer data as fast as a typical SSD can deliver it?
 
usb2 is 60 MB/s odd iirc, slower than most ssds
slower than a good spindle drive
But, you'd get a consistent 60MB/s random read which most consumer spindles couldn't get close too
 
8:07 PM
they could deliver that if they were in the machine, though, right? (perhaps just for sequential reads)
 
likely only for sequential
 
cool
 
 
1 hour later…
JNK
9:35 PM
why is it half the aggregation questions on SO are about how people don't know how aggregation works?
 
@JNK well if they knew what they were doing wrong...
aggregates can mix you up a bit though, half the time I still try using count(*) in WHERE instead of HAVING because I aggregate so rarely
 
JNK
Half the Qs i see about it now are just invalid
but they are in mysql so they parse
 
Weird, what does mysql do differently?
 
JNK
in every other RDBMS, this would be invalid. It works in MySQL:
SELECT Cola, ColB, COUNT(*) FROM Table GROUP BY ColA
It just returns a random ColB value from the group
then the folks are confused about why their results are funky
 
Er...that's special. That's survived this lnog without being fixed?
 
9:49 PM
It's not a bug it's a feature
 
JNK
its a bug
imo
 
(I was being facetious)
 
JNK
sorry I couldn't hear your tone! :)
I imagine if they "fixed" it half the mysql code out there would break
I can certainly see the value in having something like an ANY() aggregate to ge tthe same effect
 
Also, airlines are sneaky fuckers. They say "no service fee for flight changes", then go to the change booking page and they tag a $50 change fee on. Re-check the conditions and it says in small print at the very bottom "Change fees may apply to some booking classes"
 
JNK
but not silently when it's not requested explicitly
You should list your name as --;DROP TABLE Passengers to get back at them.
 
9:52 PM
shouldn't that be '; drop table passengers?
 
you forgot the trailing -- but yes
 
@JNK I can't imagine why any code would be written to intentionally group incorrectly.
@SimonRigharts right
 
; drop table passengers; -- <- that
 
I was fixing the error I saw not all possible errors :P
 
10:05 PM
Have we ever got the SQL Authority guy on this site? I swear his stuff comes up in every other SQL related google search
 
 
1 hour later…
11:18 PM
@BenBrocka Pinal Dave has uber google-fu!
 
11:33 PM
@MartinSmith Thanks for digging out the reference. I removed a couple of redundant comments.
 
07:00 - 15:0015:00 - 00:00

« first day (399 days earlier)      last day (4470 days later) »