« first day (2166 days earlier)      last day (2695 days later) » 
06:00 - 19:0019:00 - 00:00

6:49 AM
I'm voting to close this question as off-topic because it is a cross-post. The other instance of the question already has an answer at the time of writing this. Please do not cross-post. — Andriy M 2 mins ago
 
7:32 AM
The other instance has been deleted, vote withdrawn.
 
8:09 AM
Good morning, and in case I don't see you, good afternoon, good evening, and good night
 
Good morning
 
8:27 AM
Does anyone here have any views on Entity Framework? Struggling to see the benefits.
 
8:44 AM
@JamesAnderson No views. Never used it, but I'm not THE programmer/developer guy these days
 
Easy class/table coupling in an application. Easier data layer handling when you are not very good at SQL. All the benefits I can see are mainly (client-side) development-related. But I've never used it either, my conclusions are based on encounters in SE.
 
@JamesAnderson depends on the size of database in my opinion
A group in our company uses it for a piece of software, it seems to work fine for smaller installs, but it's a bit hard to keep performance under control on larger setups
But that might just be the way they are using it and not inherent to EF, I don't know
I don't have extensive experience on the database side, and none on the development side
They also keep talking about code first and database first, I have no idea what the implications are, but you might want to look into that
 
@TomV Yes I've heard these terms
I think they are saying that you define a class in the 'model' and then the SQL to create the table is generated.
 
One thing to make sure is to watch out for inheritance, it looks nice at first, but you can't create a composite index across tables of course
 
I thought that sounded quite nice because any conflicts when merging code branches would highlight schema change conflicts but seeing the work required to add 1 column I'm not sure it's worth it
@TomV interesting
 
9:17 AM
@JamesAnderson We use sqlalchemy like that. It's sometimes a pain.
As I have to make sure after each change in the model that the SQL generated is what I wanted
The schema changes are handled by alembic actually (another python module)
It's not too bad when you get used to it.
And I have no idea how EF handles all these (same or differently)
 
9:33 AM
Yesterday I was asked to look at why an EF generated query was slow.
After running a trace I could see that the query was joining two tables and then doing a SELECT TOP 1 * FROM ... WHERE a = 'xxx' from a third table for each row
 
begin;
create schema stack;
set search_path=stack;
--
create table foo as
select *
from (values (1,'X','D','G','P')
, (2,'F','D','L','M')
, (3,'X','N','R','S')
, (4,'Y','I','W','Q')
, (5,'U','Z','E','H') ) AS f(id,a,b,c,d);
--
with recursive t(id,a,b,c,d,start,path,cycle) as (
select *, id, array[id], false from foo
union all
select f.*, start, path||f.id, f.id=any(path) from foo f join t on f.id<>t.id and (f.a=t.a or f.b=t.b or f.c=t.c or f.d=t.d) where not cycle )
select array_agg(f.id order by f.id) ids
 
@JackDouglas Nice.
 
it scales extremely badly :)
 
After playing about a bit we found that it does this because there is no FK releationship between either of the first 2 tables and the 3rd. There is a way to force a join without a FK but it got very messy
 
@ypercubeᵀᴹ did you go to the dba drinks last night?
 
9:38 AM
@JackDouglas yes. but arrived more than fashionably late ;)
 
what, like just before chucking out time?
 
about an hour, or a bit more
 
@JackDouglas why does the reference arrow not work? Or is it only me?
 
@dezso are you ignoring anyone who frequents the room?
it takes me here:
11 hours ago, by Evan Carroll
I really don't want it answered there, but here is the teaser. http://stackoverflow.com/questions/41045859/group-by-any-of-multiple-columns
 
@JackDouglas but of course
I see, that's the explanation then
 
9:45 AM
interesting, I'll have to file that in my brain somewhere
 
@Philᵀᴹ thanks
 
But the SO question is where it started. Evan is probably researching options for a potential answer.
 
10:37 AM
@AndriyM He is going up a blind alley with CUBE though — I don't think any solution is possible that doesn't use recursion.
because two rows can end up in the same group even though they have no data in common
 
 
2 hours later…
1:05 PM
I'm glad it's Friday :-)
 
 
1 hour later…
2:22 PM
@ThomasWard you around?
 
@ypercubeᵀᴹ what's up?
 
odd question: Possible reasons for apt-get install upgrade to need 30+ minutes to run?
 
@ypercubeᵀᴹ slow network connection for downloading the upgrades, slow to compile kernel modules, grub taking a long time to search for kernels to add to the boot options list, any of a number of other things
possible DNS issues too
 
The dev had never run it before? Slow network? Low-spec hardware? All of the above?
Ah, thnx!
 
slow network, low-spec hardware will slow down some things, never been run, without a lot more info I couldn't say specifically
 
2:25 PM
No worries. It's not too important, to spend time investigating.
 
@ypercubeᵀᴹ yeah, that sounds about right. In this case, I'd say that it could be any of a number of different reasons from a slow mirror to never being run before, to slow system, to ...
(the list goes on)
 
It's nice that we have mods from SuperUser, AskUbuntu and SE employees. We don't have to wander the sites to get our questions answered.
The Heap™ knows. Everything. ;)
5
 
@ypercubeᵀᴹ heh
 
 
2 hours later…
4:46 PM
@AndriyM He was keen to have the question migrated here.
@ypercubeᵀᴹ Installing SQL Server on Ubuntu?
 
@PaulWhite Oh no. Unrelated to SQL Server
But it could be a valid explanation ;)
 
@ypercubeᵀᴹ how dare you?
 
@ypercubeᵀᴹ Yeah I should have put a simley of some sort there.
 
@Lamak dare what?
@PaulWhite It will take long time for MS to manage get SQL Server update with apt-get.
 
@ypercubeᵀᴹ not trying to install SQL Server in Ubuntu
 
4:49 PM
They still haven't got it right with Skype
 
@ypercubeᵀᴹ The only reason I ever start Skype is so I can marvel at the shut down sequence.
 
@Lamak Oh, I will try. But in a VM, not in my working pc
@Lamak Have you?
 
The great thing about having so many different native languages in this room is that so many things end up being explained at great length.
 
@ypercubeᵀᴹ nope, sorry
 
@JackDouglas I think I could see a non-recursive solution working quite well, possibly very well, so long as rows that link (i.e. that have any common elements) appear sequentially in the input data. As so often with these questions, it's not clear whether that is the case or not.
@ypercubeᵀᴹ Am I misreading the instructions?
> sudo apt-get update
sudo apt-get install -y mssql-server
 
5:04 PM
@PaulWhite No, you probably aren't. I hadn't read them.
And my point was mainly for Skype, the SQL Server team may have got it right.
 
@ypercubeᵀᴹ I think you may owe Microsoft the SQL Server team a sorry card and a box of chocolates then :)
 
For Skype they have only a 32bit version and recently added a 64bit alpha!
Which I had it working and then suddenly stopped, giving me a link to some forum page, to go find the new update
 
Same with SSMS and VS (32 bit), though I understand there are actually good technical reasons for that (not just because it's hard)
@ypercubeᵀᴹ Smooth.
Well Windows 10 just rebooted itself to install an update I hadn't noticed or approved. SQL Prompt and SSMS also now want to update, as does my graphics card driver. Should be able to get heaps done today :-/
 
5:25 PM
HALLO EVERYONE
IT IS I, EVAN
 
Hi I, Evan
 
5:44 PM
Some of you guys are kind of funny :p
So @EvanCarroll what drags you around these parts all of a sudden lately?
I feel like we've only just recently been seeing you around, and I know you've been on the network for a while.
Did you get a new job or something fun?
 
Lol, what is this an AMA?
I'm working on a new project for myself, and I'm preparing for my new role as Admin/Moderator/Dungeon Master of dba.stackexchange.com -- I'm going to run in the next elections. So I need to be in good standing.
 
What's the new project?
And come on Evan, you know you like a little attention ;-)
 
It's top secret.
 
I'm actually interested
So I thought I would ask
 
I may post about on all of the stack exchange sites so all of my fans know about it.
I'm not competing with Stack Exchange though, the market for Yahoo Answers! clones is saturated.
 
5:52 PM
I'm not sure how you would do that last thing you said. How would you post on all the sites?
 
@jcolebrand I mean, he is "I, Evan", of course he can
 
Copy and paste a boiler plate and cater each and every post with sufficient love to make it a welcomed addition to the community and defensible to subjective claims of cross-posting.
you know how i roll
That's not funny, and it's not true. I never troll.
Keep in mind I'm like in the top 2% of users on dba.stackexchange.com, because I'm so damn smart, good looking, and clever.
 
I wish I had time to re-read my Calvin & Hobbes books.
 
@PaulWhite are you the mom there?
 
@Lamak Posted without comment.
 
5:56 PM
@PaulWhite spend less time here and you would
 
@Lamak Actually it was "Admin/Moderator/Dungeon Master" that made me think of the Dictator-for-Life thing.
 
@EvanCarroll this quarter, right?
 
I've only been active this quater
 
@Lamak December so far AFAIR
 
I'm like GOD of December.
 
5:58 PM
@bluefeet That might be true.
 
If Jesus were alive, he'd skip his birthday and celebrate me.
 
I wonder why my comment got deleted....seems to me like it was truthful at least....
 
@EvanCarroll Well, #8 god for the first week, anyway.
@Lamak Failed the Be Nice test.
 
I've failed that test too a few times. That test can suck.
I think it's rigged.
 
I demand a recount!!!1!
 
6:00 PM
Someone start a gofundme for Paul Stein
we can raise millionz.
 
Who's Paul Stein?
 
dba.se's jill stein
 
@PaulWhite but I was niiiiice....
 
ie., you.
 
@EvanCarroll I might have to Google it. I normally do for all popular culture references.
 
6:01 PM
@PaulWhite I think he's name calling you now....
 
You from murica?
 
@EvanCarroll No. New Zealand.
 
he from new zealand
 
Ahh. I'll explain.
 
no need, thanks :-)
 
6:03 PM
Oh hang on so (without Googling) Jill Stein might be the person (Green?) that petitioned for the US election recounts?
 
@PaulWhite correct
 
\o/
Test fails++
 
@Lamak now we're tied.
Next points wins.
 
But anyway, to explain my small joke at some length, the "rigged" I took as a reference to something Donald Trump said during the US election. The recount petition afterward has a certain ironic juxtaposition there, for people of a certain political persuasion. My small joke connected those things. But I didn't know Jill Stein's name at that point, so the follow up joke also required explanation, which is all good in here.
 
@PaulWhite why ASL instead of AGL?
 
6:11 PM
@Lamak Well I could and perhaps should do better, but I'm on thin ice knowledge-wise here, so I'm hoping to hand wave some of the aspects. Naturally can be a team sport.
There being no I in team.
So, having successfully killed the conversation once again, I will go find a question to answer.
 
@PaulWhite you are good
 
6:27 PM
@TomV I think I owe you an apology for pulling the wrong person in yesterday. I blame @PaulWhite of course.
Because why would I own that :p
 
Always happy to be the Default Blame Acceptor.
 
Thanks @PaulWhite ... now how do we get you the default bounty acceptor status too so you get all the reps lol
 
Rep is pointless for me.
2
pointless ha ha ha
 
don't you mean hat hat hat?
 
lol
Oy, what a kidder
I think @bluefeet is so happy about the hats :D:D:D
 
6:33 PM
@bluefeet I so suck at remembering memes!
 
@jcolebrand I'll be extra happy once it launches and is over
 
@bluefeet you mean after it launches and there's the flood of meta posts about it aaaaaaaaand then it's over
 
hi. If I have a table Exam, which have a reference to Course, where course has a reference of Class is it bad if I include both 'Class_ID` and Course_ID in exam table?
 
6:37 PM
@Lamak most definitely
 
@Anwar why do you want that column (ClassID) there?
 
@bluefeet how're things going, btw?
 
@swasheck Things are going really well. How are you doing?
 
@ypercubeᵀᴹ for quicker queries. otherwise it's becoming more complex.
 
@Anwar there would be no need, unless the key of Course is course_Id and Class_Id
 
6:39 PM
@bluefeet i'm ok. i'm ready to retire
 
@swasheck where did you find that gem?
 
@Anwar well, then it is bad
 
@swasheck I think we all are
 
@bluefeet good point
 
@Lamak primary key of Course is ID and it has a foreign key to Class as Class_ID
 
6:40 PM
@swasheck or how about just win the lottery
 
Skeptics.SE is the oddest animal ever.
 
@Anwar yeah, there's no need of Class_Id in the Exam table then
 
@bluefeet too much pressure to share that other others. winning the lottery is savage on friends and family relationships
(from what i hear)
 
@Lamak But (@Anwar) if you put it, then the FK from Exam to Course should be composite (Class_ID, Course_ID)
 
@swasheck and fellow heapers
 
6:42 PM
@Lamak Thank you. I initially designed that way and later removed the Class_ID. Now wondering if that would be good. You saved some experimentation time. Thanks again :)
 
@swasheck I'd still be willing to give it a crack.
 
@PaulWhite @Lamak enough $$ to disappear? that actually sounds pretty nice right now
 
@swasheck just don't tell anyone!
 
@Anwar it's about what makes sense to have. Not just have the columns because experimentation
 
secrets eat you from the inside
 
6:44 PM
but then you just drink and make it better
 
@Lamak True. But there are cases when having composite keys like that can improve efficiency of some queries
 
@swasheck You want us to disappear? Harsh!
 
(and probably cases of the opposite)
 
@swasheck I might have to find this
 
6:45 PM
@ypercubeᵀᴹ I was planning to use two foreign keys to Class and Course
 
@PaulWhite nah. i'd rather disappear. chris mccandless style :)
(minus the stupid death part)
 
@Anwar That would be a problem. Or more accurately it would model something different. You could end up with an Exam that references Course A and Class 1 but Course A referencing Class 2.
 
@bluefeet i dont like rum. well. i DIDNT like rum. my friend let me try this and told me to sip it. i protested. "i hate rum." i tried this stuff ... amazong
 
I would hope so for that kind of moolah
 
6:47 PM
@swasheck A big enough win (US lottery scale) would enable The Heap to retire en masse
 
@bluefeet this is a bit more accessible ... .Ron Zacapa Centenario
 
We'd still hang out naturally.
 
natch
 
@ypercubeᵀᴹ That's why i removed it later. I can see that it will allow inconsistent Class and Course
Oh! You edited what I was writing
 
Yes, exactly. A composite FK would have taken care of that issue.
But unless you prove test that it really helps in some preformance issue, it's unnecessary complication, as @Lamak already pointed.
 
6:48 PM
@swasheck oh yeah that's a bit more acceptable
 
@Anwar Might make a decent question on Database Administrators if you add the sort of queries you run. Getting answers in chat is super awesome, but doesn't have too much lasting value. Especially here :)
 
@bluefeet it's a really nice guatemalan rum aged in cognac barrels. quite tasty. didnt realize you liked rum that much.
 
Anyway thanks again for clearing the matter. @ypercubeᵀᴹ and @Lamak
 
@swasheck Rum and Run :)
 
I wonder if I could write a query to get the typo% of ypercubeᵀᴹ's posts.
 
6:51 PM
@PaulWhite Thanks for the suggestion. I have got my answer already. You want me to ask the question on the site still?
 
@Anwar No preference. Just pointing out an option.
 
@swasheck I do like it - especially mixed with root beer. It's sorta a running joke with my colleagues
 
@ypercubeᵀᴹ am i missing a reference?
 
@swasheck give me a sec
 
6:52 PM
#REF!
 
@bluefeet interesting combo. i've decided to stop drinking anything i have to mix ... and beer. lost 60 lbs with that policy (also .... working out like a fiend)
 
@PaulWhite not everyone here encourages them.
 
@ypercubeᵀᴹ You still settled on TypooCube for Winter (Summer!) Bash?
 
@swasheck congrats, that's awesome
 
Jun 11 '13 at 11:57, by bluefeet
@SimonRigharts wow, that is a lot of stuff. I just run, and go to a gym.
@PaulWhite Yesss.
 
6:53 PM
@EvanCarroll 'We' = policy.
2
 
@PaulWhite Thank you for the suggestion. I knew it :) But I think that would be proved as dupe :)
 
(3 s because 2 would look like a typoo ;)
 
@Anwar You're probably right. I suggest dumb things all the time.
2
 
@ypercubeᵀᴹ the poop jokes were earlier this week
 
@PaulWhite yeah, he even summon @billinkc occasionally
 
6:54 PM
@bluefeet thanks. all it took was an ACL reconstruction to motivate me
 
@PaulWhite ha ha. no problem. Good bye all
 
@PaulWhite keep setting (row) goals for yourself
 
The room's on fire this morning.
 
@swasheck sometimes it takes something to motive it. Mine was my shoulder surgery, changed all my eating habits after and dropped 30
 
BTW, he took the question to DBA.se!
1
Q: Grouping on any one of multiple columns in Postgres

Stephen SmithIs it possible to create some sort of chain of grouping in Postgres? So let's say I have the following chart: CREATE TABLE foo AS SELECT row_number() OVER (), * FROM ( VALUES ( 'X', 'D', 'G', 'P' ), ( 'F', 'D', 'L', 'M' ), ( 'X', 'N', 'R', 'S' ), ( 'Y', 'I', 'W', NULL ), ( 'U', 'Z', 'E...

Best Question of the month.
 
6:56 PM
@EvanCarroll We have had similar I think in the past. Not sure if it was for Postgres.
 
except now it's cross-posted
 
@EvanCarroll That's why I dislike people suggesting alternate sites in comments.
 
@bluefeet nice! i eat less food and have grown to be addicted to plyometrics, rowing machiens, and barbells
 
@bluefeet clearly he's new on both networks, I told him. I flagged the SO one to be closed.
 
@swasheck very very nice. I still run just not as much, I mainly do crossfit and lift weights
 
6:57 PM
If they would just allow flag-migration we wouldn't have this problem.
 
@EvanCarroll why didn't you vote to close instead?
 
deleted by Stephen Smith 6 secs ago
 
@ypercubeᵀᴹ Deleted, sorry about that. — Stephen Smith 14 secs ago
 
@bluefeet i refuse to run unless it's a competition. i hate running. it's the worst. i've not yet decided to do crossfit ... you people are nuts
 
@Lamak I vote to close a lot -> vote to migrate to DBA.se is a "vote to close".
 
6:58 PM
@ypercubeᵀᴹ Thanks Mr Cube.
 
@PaulWhite TypooCube
 
@EvanCarroll yes, but you said that you flagged it
 
@swasheck Not yet.
 
@swasheck yeah, we get that a lot. I absolutely love it though. It kicks my butt everyday
 
I do flag, and VTC for migration.
 
6:59 PM
@bluefeet i have a friend who now lives in pheonix who loves it. i've just not brought myself to that level of insanity because i'd get hooked. my wife and kids would like to see me sometimes
 
It had four votes to close (all to migrate to dba.se I think) at the time it was self-deleted.
 
though it's gotten to the point where if i dont get a workout in, they dont want to be around me because i'm a grump (more than normal)
 
@EvanCarroll Flagging is for off-topic questions not for qs that are one topic on both sites. And in some cases, the OP may know about dba.se but just prefers to post at SO
 
06:00 - 19:0019:00 - 00:00

« first day (2166 days earlier)      last day (2695 days later) »