« first day (842 days earlier)      last day (4027 days later) » 

2:52 AM
@AaronBertrand awesome writeup on the filtered indexes
5
 
3:20 AM
Can some one please help me out with the answer which i posted here stackoverflow.com/questions/16205229/… .I don't have a sql editor to test it :(
Need some time befr i reach office to get hold of SSMS to test the code
 
3:57 AM
@praveen what about sqlfiddle.com? I think your issue is that SQL Server does not allow order by inside of a cte iirc.
 
4:24 AM
@ChrisTravers: I was typing using my phone so couldn't use SQL FIDDLE and thanks for helping me .Now i have rectified the query :)
 
 
2 hours later…
6:02 AM
Just saw this (notice the target of the link): dbareactions.tumblr.com/post/47793906144/…
 
6:31 AM
@ypercube ha ha awesome. It happens with all the dev not just with DBA. Being a BI dev i hate when my manager sits beside me and looks at my monitor :(
 
6:45 AM
good morning
 
7:01 AM
good morning
 
2 exact dupes next to each other on the front page, if there's a mod about
 
gbn
7:27 AM
@Phil where? am I blind or not enough coffee yet?
doh
VtCed
 
 
1 hour later…
8:48 AM
@gbn I don't see them. Are they closed already?
 
gbn
@Marian here
0
Q: How do you correct a corrupted index in Oracle?

user83598I have this ORA error in our logs: Caused by: java.sql.BatchUpdateException: ORA-01578: ORACLE data block corrupted (file # 8, block # 22921) ORA-01110: data file 8: '/data/app/oracle/oradata/MYSRVR/datafile/o1_mf_mysrvr_88m82mdj.dbf' I tried running this in sqlplus: select segment_name,segmen...

0
Q: How do you correct a corrupted index in Oracle?

user83598I have this ORA error in our logs: Caused by: java.sql.BatchUpdateException: ORA-01578: ORACLE data block corrupted (file # 8, block # 22921) ORA-01110: data file 8: '/data/app/oracle/oradata/MYSRVR/datafile/o1_mf_mysrvr_88m82mdj.dbf' I tried running this in sqlplus: select segment_name,segmen...

 
@gbn thanks, voted
 
9:26 AM
4
A: duplicate issue when inserint value to varbinary

RichardTheKiwiThe trailing "zero-bytes" 0x00 in a varbinary column is as insignificant as the trailing spaces " " in a varchar column. Therefore, your values are actually duplicates. In other words, your two values are (in byte order) 1 2 3 4 5 6 7 --- bytes in the binary value 59 42 C8 03 66 4B 59 4...

I was going to demonstrate comparing VARCHARs (one with extra trailing space) using Latin1_General_Bin and expecting the space to count... it didn't.
 
9:52 AM
Wheee... working encryption in my test db for managing root passwords on vms :-D
(with key management functions too)
Not sure if I should be happy or sad that I can't generate public/private key pairs from inside Pgsql....
 
@孔夫子 yeah, funky
@孔夫子, there's a funny behavior with trailing spaces and SQL Server + SSIS
@孔夫子, if you do a SQL join, everything is fine and dandy
@孔夫子, if you use a SSIS lookup, the trailing space makes it not match
@孔夫子, I've been bitten by that quite a few times, now I just TRIM() all the things during imports
3
 
10:31 AM
@Gonsalu same problem in the Conditional Split..too, from what I remember.
 
10:42 AM
@Marian, yup, any SSIS task, really.
 
11:42 AM
0
Q: Partitioning in Oracle 11g

Rizwan SheriffIf I alter the partitioning in oracle and trying to retrieval the data,is necessary to mention the partition name or not?

FFS
 
12:02 PM
haha
 
12:27 PM
@Gonsalu I don't think that is entirely correct .When Lookup is used with no cache mode then u can match columns even with spaces
When you use full cache or partial cache mode then spaces will be considered
 
That's true, "no cache" goes directly to the database
I think that only adds to the confusion, IMHO
 
@Gonsalu: yup tats true
 
gbn
1:28 PM
We want this?
0
Q: Is dateadd() slow in on-conditions compared to where-clauses?

SvipI have a situation in a select, where it gets faster if I move dateadd() from the on-condition to the where-clause. But sometimes it may not be possible to move it from the on-condition and to where-clause. My solution was to move the dateadd() from the on-condition to a temporary table instead...

@Gonsalu me too. Damn dat ANSI_PADDING bollocks
 
2:00 PM
anyone here have much experience with pgcrypto?
 
@ChrisTravers zero
 
@Lamak I am getting a crash course in it
writing test cases for my framework of encrypting root passwords for vm's such that only senior-senior level admins can decrypt them.
the key management is turning out to be.... challenging
I now have everything working except for the function that replaces a user's public and private keys.
I keep wondering if there is a market for a general (perhaps open source) toolkit for in-db key management so others don't have to reinvent what we've had to
whee, and rubber duckies to the rescue. All tests passing :-)
 
maybe add ssh certificates to all vms?
 
JNK
I've done a lot of rubber duckie debugging the past couple of weeks
also some talking-to-myself-in-the-heap debugging
 
@Gonsalu yes, that will be preferred access
the idea of root password access is this is what happens if everything is down and virsh console is the only thing up
@JNK Those both work. In my case it was mixing up public and private keys in encryption code which is not good. :-P
 
2:11 PM
have the private key in the vm host? :)
 
gonsalu: the issue is logging in if something is massively wrong. The access is intended to be extremely limited and as a last resort.
 
I'm just fooling around, seems to be a cool project to do
 
@Gonsalu yeah, this is a small piece of it. We want a lot of vm configuration to be automatically done when we change something in the db....
so we can assign new IP addresses or the like just by changing them in the db, and then queue messages get sent out, acted on, and the like
It's a lot of fun
I get to play with all sorts of areas of PostgreSQL I would never get to play with otherwise :-D
It's a great excuse to really stretch my skills
So today cryptography, yesterday ip4r, gist, and exclusion constraints for IP address ranges, and tomorrow, who knows what
 
is it just me or is all of the LinkedIn "Linked DBA" group's stuff a bunch of noise???
 
@swasheck well you could also just say "LinkedIn is a bunch of noise" so: yes.
 
2:22 PM
probably not just you. I find a lot of LinkedIn groups are mostly noise.
 
@DerekDowney yes but I am a glutton for punishment and somehow keep finding my way back there. I need to remove the shortcut from my toolbar because I click it instinctually multiple times a day.
@jcolebrand thanks!
 
@AaronBertrand i guess i just saw you as very hopeful. hope springs eternal
 
@swasheck no, just a slow learner. If 95% of the stack overflow crowd weren't complete f*cking idiots I'd probably get frustrated far less often.
@swasheck oh awesome. Do you get to often have conversations with him like the one I had? Fun fun!
 
@AaronBertrand f*cking idiots are ok. It's their bosses I worry about.
When I worked at Microsoft you wouldn't believe the tech support calls I got from IT professionals
 
@AaronBertrand yes. i do. he was who, when i expressed concern about the proliferation of SVFs in his code and how the optimizer handled it, retorted, "oh, you mean sql server's magical 'black box?'"
 
2:28 PM
We were allowed to refund money on cases that took 15 min or less to resolve. I however refused to do so if the customer was processionally employed in the field and insufficiently competent.
I figured we shouldn't be the subsidy for hiring incompetent sysadmins, network admins, and dbas....
 
@ChrisTravers it's not hard to turn the tables and make the call last longer than 15 minutes. For example, if the computer was unplugged, you could detail the intricacies of electricity, modern wiring, etc.
 
@AaronBertrand hahah I will remember that.... but cases I got included things like:
 
@ChrisTravers PS I'm not talking about the clueless / less experienced. I'm talking about the people who refuse to take sound advice after having enough wits to come to a site that promises exactly that.
 
"Our NT4 PDC was acting strangely and so we reformatted the hard drive and now nobody can log in"
"Well, have you tried to promote a backup?"
"Yes we tried but it won't work!"
 
LOL Someone on the Internet probably said FORMAT C: as a joke
 
2:30 PM
"What's the error?"
"It says a primary domain controller already exists for this domain!"
 
My favorite is "SQL Server doesn't seem to like it." Like software has emotions.
2
 
the $245 advice was "turn off the primary domain controller first"
 
@AaronBertrand Software does have emotions. MySQL behaves so irrationally that it must have them!
2
 
I used to work with a guy who would just say "it's broke." Took three or four relays either in e-mail or the ticket system to suss out an actual error message. EVERY TIME.
 
@AaronBertrand In this case it took me about 10 min to get that advice through. I had to give it to two jr admins and the sr admin
 
2:32 PM
@AaronBertrand With text windows print-screened as .BMPs into Word documents as 10Mb attachments to the emails?
 
Keep in mind that's a textbook operation. As in every NT4 textbook covered it.
 
@Phil no that was a different guy. We had to pull him out of the nightly Exchange backup because all of his uncompressed BMP full-screen screenshots of error dialogs 1/20th of the screen were in his sent items folder and he would never delete a thing and the backups were taking 25 hours.
 
@Phil If MySQL didn't always keep me guessing, I would have a boring job. Don't hate
 
@Phil we still get that only ... but with uploads to our ticketing system
 
Hi, my name is Aaron, and I'm a stackoholic. It's been over 36 hours since my last answer.
 
JNK
2:34 PM
HI AARON
 
@AaronBertrand get back on the wagon, brother
 
@JNK For a second I thought it was JW
 
Hi Aaron. Welcome, we've been expecting you. :)
 
frickin gravatar is a pile of turds now.
 
JW updated his profile again
> I PROMISE to the community that I will not update useless TAGs in the question ever again because eventually they will be rollbacked.
 
2:37 PM
@FreshPrinceOfSO AAAAAAARRRRRRRRGGGGGGGGGGGHHHHHHHHHHHHHH
ROLLED BACK
 
@swasheck I prefer rollbacking
 
@FreshPrinceOfSO you ain't no hollaback girl
 
I prefer Rickrolling.
 
@AaronBertrand Never gonna give that up?
 
hey guys - hate to break up the party! Anybody have a Nokia Lumia 920? I'm thinking of getting one to replace my Android device...
I like the camera specs, but it appears to not have a SD card slot?
 
2:46 PM
@MaxVernon no, it doesn't.
but has 32 gb of internal storage, could run a SQL Express on it :-)
 
well that's a negative for sure. And no Firefox support!
@Marian Love it!
 
@MaxVernon Nokia still makes things?
 
( looked here: gsmarena.com/nokia_lumia_920-4967.php , I've got a friend with it, but he's not online to ask about it)
@FreshPrinceOfSO partnered with MS for Windows 8 devices
kind of like Google - Samsung
@MaxVernon isn't there a FF for W8?
 
The Register seems to like it overall, scored an 85%
 
@Marian Yeah but Nokia is so 2005
 
2:49 PM
@FreshPrinceOfSO :) not anymore, really. their w8 lineup is pretty sexy
a bit late to the party, but still, not that bad.
 
@FreshPrinceOfSO You're an Apple Fanbois, aren't you!
 
@MaxVernon I don't speak of Apple.
 
@FreshPrinceOfSO the shark was a hit!
 
@Marian Maybe down under. Never heard of it up in 'murika
 
2:54 PM
@FreshPrinceOfSO wasn't a nokia, though, it was made by ericsson, but came in the same period
 
@Marian another dead brand
 
@FreshPrinceOfSO It's part of Sony now, IIRC..
 
@FreshPrinceOfSO and Nokia makes maps, too
 
@swasheck nice, didn't know their site.
 
@swasheck i prefer Bi..err Google
 
3:04 PM
Does sony still make phones?
 
@Zane Yes..
 
@Zane yep, with Android
 
haha
 
:)) you have to be a power lifter, though..to pick it up
 
Anyone going to the Chicago SQL Server May Meeting Thursday, May 9th, 2013 @ 5:30 PM?
 
3:11 PM
Nope
It's close enough that I could go there for a weekend thing but not on a weekday.
 
So I assume I need a linked server?
> Ad hoc access to OLE DB provider 'Microsoft.ACE.OLEDB.12.0' has been denied. You must access this provider through a linked server.
 
3:48 PM
@FreshPrinceOfSO maybe. Did you try:
EXEC sp_configure 'show advanced', 1;
GO
RECONFIGURE;
GO
EXEC sp_configure 'Ad Hoc Distributed Queries', 1;
GO
RECONFIGURE
 
@AaronBertrand User does not have permission to perform this action.
You do not have permission to run the RECONFIGURE statement.
 
@FreshPrinceOfSO then you're probably not going to have permissions to create a linked server, either. shrug
 
Sounds like it's time to put in a request and then wait a month.
 
Just for kicks did you try RECONFIGURE WITH OVERRIDE;
 
@AaronBertrand What @Zane Said
@AaronBertrand Same result.
@AaronBertrand I asked for sysadmin privileges they laughed at me from India
 
3:53 PM
@FreshPrinceOfSO well then I'm not sure what to tell you. If people want you to get this done, they need to help you get it done. I can't mop the floor if you've locked the mop away.
 
@AaronBertrand Just read me a story in a nice relaxing tone to reassure me that the world isn't this cruel
 
@FreshPrinceOfSO dude, they just laughed at you from India. The world is way more cruel
 
:9146885 no, that is a delicious donut
Though pronounced "kruller" or "creulah" depending on where you are
 
JNK
Kruller
 
@AaronBertrand over here would sound ridiculous
I deleted my comment, but google says that "crueler" does exists....didn't know
 
4:00 PM
@Lamak Google would also tell you performant is a word depending on how critical you are of the results. Doesn't mean you wouldn't get laughed at when using it. :-)
 
@AaronBertrand true. I'll erase it from my limited english vocabulary then
 
@FreshPrinceOfSO: well u may find some people in India like that. They ll sit on top of ur head and ll ask u to do some stuff which they themselves wont be sure how to do it
 
JNK
holy cow unemployment in spain is at over 27%
 
@JNK Same here, maybe more.
 
@praveen They've been generally good to me :)
 
4:16 PM
@FreshPrinceOfSO: Well I said some :-) majority of them are generous :-)
 
@praveen And very friendly
 
JNK
@ypercube latest numbers I see are actually identical
27.2% for both countries
 
@praveen we have an external consultant for our ERP who are based in India. super nice folks
 
@JNK Yeah. And it's awfully higher in ages 18-25
 
@swascheck oh .Feels proud to be an Indian :-)
 
4:23 PM
@praveen it's hard to get a "yes" or "no" answer from them, but overall ... super nice and very helpful.
 
4:53 PM
Can I down-vote the front page of SO instead of each individual question? Wow.
 
@AaronBertrand don't get on around 1 am then ...
 
27% unemployment is brutal.
 
JNK
argh stupid string or binary data would be truncated bullshit
@swasheck is that us1r guy actually your dev?
 
5:08 PM
@JNK yes. but please dont let on that i know it
 
@swasheck how did you come to know this then?
 
JNK
@AaronBertrand can I get a sanity check from you real quick
on a very basic error I've never had an issue figuring out before...
 
@JNK vote! vote! vote! comment! comment! comment! connect.microsoft.com/SQLServer/feedback/details/339410
 
JNK
I'm getting that error
 
@JNK might take me a few minutes to circle around to it, but sure
 
5:10 PM
@AaronBertrand he asked me for driver support help. i did what i could (but i'm in the middle of moving from 2000->2008R2) but then said "take it to SO" :)
 
JNK
in a straight insert with an explicit column list from a select
basically i am populating a staging table
my normal procedure for figuring this error out is to compare the columns
select
c1.name,
c1.max_length as 'WhseLength',
st1.name,
c2.max_length as 'StageLength',
st2.name
from
    WHSE.sys.columns c1
inner join
    Staging.sys.columns c2
	   ON c1.name = c2.name
inner join
    sys.types st1
	   ON st1.system_type_id = c1.system_type_id
inner join
    sys.types st2
	   on st2.system_type_id = c2.system_type_id
where c1.object_id = object_id('MyWhseTable')
and c2.object_id = object_id('MyStagingTable)
AND (c2.max_length < c1.max_length
OR c2.system_type_id<> c1.system_type_id)
 
@AaronBertrand and then lo and behold ... the question came up with the same error ... then he came over and told me that he had and that someone was giving him a hard time about select * and somesuch
(and that user was our very own @FreshPrinceOfSO)
 
JNK
lol
is he a dbag?
we can delete the history here FYI
 
@JNK so you can't do that because the select isn't from a specific table?
 
JNK
no I AM doing that
it's from a specific table
 
5:12 PM
ok
 
2008 - Gotta love it:
Posted by Microsoft on 4/28/2008 at 6:36 PM
Hello

Thanks for your feedback. We're tracking your request to improve this error message for a future release of SQL Server.

-- SQL Server Engine Team
 
@JNK he's actually gotten better. when he first got here he was a real JO ... but i've beaten him into submission
 
How hard can it be?
 
JNK
and the only fields I get back are a bunch of columns where the target is nvarchar256 and the source is varchar255
and some date columns
none of those strings are even in the select though
the dates are, but im inserting from a smalldatetime into a datetime2
 
> Posted by aaronbertrand on 8/11/2009 at 4:35 AM
In Connect #125347, Microsoft said, "too late for 2005, we will fix for 2008!" Now, "too late for 2008, we'll fix in vNext!" Please consider fixing this in the next release for real.
 
JNK
5:14 PM
Here's what I get back
 
@AaronBertrand it's already at 460 UP and was opened in 2008
 
JNK
dupes are from joins I think
OHHH
SONOFA
Does a -1 length mean "max"?
 
@ConcernedOfTunbridgeWells I think the major pushback (and I didn't hear this from anyone specifically, and you didn't hear it from me): if you identify a specific value that failed (presumably the "first"), then folks might go fix that value, then wash, rinse, repeat, ad nauseum.
@ConcernedOfTunbridgeWells I'm not saying that's a worse scenario, at least it gives you a place to start, especially if there's really only one value causing the problem.
@JNK yes, -1 means max
 
JNK
that's my issue
tada
it worked
 
@swasheck I give back when I can. :-)
 
JNK
5:17 PM
When I checked for max_length with a less than, the (max) data type didn't show up
 
@AaronBertrand it's a great comment, though
 
@AaronBertrand haven't uses 2012 yet is the issue resolved?
 
also ... Robert Heinig II ... is he important? right now my mt olympus is bertrand, white, kehey..., randal, smith, rusanu
 
@Zane no, error message is still the same. Vote! Comment!
@swasheck what the heck is a Robert Heinig II - did I miss something?
 
@AaronBertrand Voted before I even saw this conversation. I entered to vote, but was already done that in the past :).
 
JNK
5:24 PM
@swasheck Ozar
 
@AaronBertrand he commented against Aaron Kempf (on the connect item)
 
@swasheck oh the guy who gave Aaron Kempf crap?
 
@AaronBertrand yeah
 
@swasheck don't know, haven't ever heard of him before
 
@JNK sack ... mach ... larock ...
and apologies to jonathan ... Kehayias ... that's a tough one for me to remember how to spell
but i only learned to spell my last name a few years back
 
5:27 PM
@swasheck LaRock has a list of star bloggers (very good list)
 
JNK
ah pinal dave
he's a character
 
Wow
-1
Q: How to add columns to a SQL result set?

mdobrininI am trying to create a sql statement that returns a single record from data over multiple records. In a way, I am trying to concatenate arbitrary selects on the same table as columns to the result set. The table looks like this, with PK: A, B, C: A B C D E ----------------------...

Please return me one row of spaghetti - al dente!
 
@AaronBertrand "arbitrary selects" is my favorite part of that question.
 
5:42 PM
Burninate it! It is a stupid question and if he cleans it up enough to suss out some syntax, it will probably require CASE / PIVOT etc. and therefore won't be applicable to mysql, SQL Server and Oracle all at the same time.
 
@AaronBertrand I'm very curios to find out exactly what the fuck he's talking about.
 
@Zane I'm not.
 
@swasheck Happy to slap him around
 
@AaronBertrand understandable as it is 100% likely to be stupid.
 
How the hell is there still only one VtC?
It's a terrible question based on a terrible premise and isn't even solvable. He's stated that he doesn't want it solved, he wants a general "how do I approach this kind of problem that I can't even accurately describe" answer. Not useful for the site.
 
5:51 PM
@AaronBertrand what question
 
-6
Q: How to add columns to a SQL result set?

mdobrininI am trying to create a sql statement that returns a single record from data over multiple records. In a way, I am trying to concatenate arbitrary selects on the same table as columns to the result set. The table looks like this, with PK: A, B, C: A B C D E ----------------------...

 
@Zane Voted
 
@AaronBertrand ok yeah it has to be VTC'd
 
@AaronBertrand Voted. Question and OP's comments are nonsense. It's like. "Give me solution. I will tell you the problem later."
 
@AaronBertrand @FreshPrinceOfSO after reading his edits I wanted to shake my monitor and scream make sense god dammit.
 
5:53 PM
@Zane For some reason, the picture I get in my head still has an old CRT..
 
Way mor satisfying to shake those.
 
Those are only more satisfying to shake when you can let go and hear them smash things. Otherwise it's just hernia/disc problems for no gain.
(CRTs are f*ing heavy)
 
@AaronBertrand you should upgrade to one of these.. everymac.com/monitors/apple/studio_cinema/specs/…
Only 77 lbs (32.93 kg)
 
That was when apple was trying it's hardest to get me to not take them seriously.
 
@AaronBertrand Definitely a feature-request.
 
5:58 PM
@FreshPrinceOfSO I have two 30" cinema displays.
According to this they're only 27.5 lbs each
 
@AaronBertrand I have two Dell 22" .. take that
 

« first day (842 days earlier)      last day (4027 days later) »