« first day (1893 days earlier)      last day (3270 days later) » 

00:38
I flagged the question yesterday (if I recalll correctly):
0
Q: student rubric for my sql 5.7

Battlac40create database ruberic; use ruberic; create table student(ID varchar(5) primary key, name varchar(20)not null); insert into student values(1,'James', 'M'); insert into student values(2,'Cezar', 'T'); insert into student values(3,'Mario', 'V'); insert into student values(4,'Tom', 'G'); insert i...

It seems unclear what the OP is asking, isn't it?
@MDCCL The close review process was cut short by an edit.
An unfortunate side-effect, since all the edit did was format the code.
@MDCCL Fixed. Thanks.
01:01
@PaulWhite My pleasure. I dind't know that side-effects could happen.
6
A: Why does an Edit action kick a post out of the Close Votes queue?

Shog9 In the end, should a single user be able to dequeue a post like that when it normally takes three (previously five) Leave Open votes to dequeue it? Yes, assuming that they're actually doing something useful to it. The intent of the close queue is to find posts that aren't closed but should...

@MDCCL I don't think it is widely appreciated.
@PaulWhite Thanks for the link, very informative, as usual. As you know, I am not familiar with the close queues and votes processes, maybe some day, ha ha. :D
@MDCCL You're not that far away from 3000.
01:16
@PaulWhite Almost there...
@PaulWhite Do you the New Zealanders have a non-rhotic accent? If I recall correctly you actually have it, right?
Maybe people from certain regions...
@MDCCL Non-rhotic? I'll need to look that up.
@PaulWhite From Wikipedia:
Rhoticity in English refers to the situations in which English speakers pronounce the historical rhotic consonant /r/, and is one of the most prominent distinctions by which English varieties can be classified. In rhotic varieties of English, speakers pronounce /r/ in all instances, while in non-rhotic varieties, speakers no longer pronounce /r/ in postvocalic environments – that is, when it is not followed by a vowel. For example, a rhotic English speaker pronounces the words hard and butter approximately as /ˈhɑːrd/ and /ˈbʌtər/, whereas a non-rhotic speaker "drops" or "deletes" the /r/ sound...
@MDCCL Yes I was just reading that. I'd never thought of it before, but I guess we are non-rhotic here, yes.
How interesting!
@PaulWhite Yes, that topic came to my mind when writing the word "there". A few years ago, I met this quite nice and classy New Zealander lady, and her accent was actually very elegant.
@MDCCL In the deep south of NZ (e.g. Invercargill) the accent becomes quite Scottish, with rolling r's.
01:37
@PaulWhite It's cool to know that. Those charateristics that are very distinctive of certaing groups of people are indeed very interesting.
 
3 hours later…
04:29
@MaxVernon I saw your post on twitter today about the Data Driven event and Nokia, to be honest when he pulled out the iPhone I thought exactly the same :)
 
3 hours later…
07:14
Not saying that I can suggest a solution to this "unclear" question, but the problem the OP is trying to solve seems pretty clear to me, even if it's explicitly summarised in the title only rather than in the body as well (where it is mentioned anyway):
0
Q: How do I get the checksum of every table

user2113670How do I solve the syntax of this query? SELECT distinct T.NAME AS 'TABLE NAME', P.[ROWS] AS 'NO OF ROWS', (SELECT BINARY_CHECKSUM(*) FROM T.NAME) FROM SYS.TABLES T INNER JOIN SYS.PARTITIONS P ON T.OBJECT_ID=P.OBJECT_ID order by p.rows desc I tried to add (SELECT BINARY_CHECKSUM...

What am I missing about this question that makes it qualify as unclear?
08:01
Morning all
Morning
@PaulWhite Essex vs. West Country
@Phil Mmmm mmmm. Love me some troubleshooting code generators. ProTip: write an example of some working code by hand, test that and then turn it into the template for the generator.
TGIF, looking forward to next week
@PaulWhite My ex's family moved down there about 10 years ago; towards the end she was even starting to pick it up, despite still living in the UK.
08:49
@ConcernedOfTunbridgeWells Yeah, that's what I've been doing. Mocking it up with static stuff first
09:14
@Phil yeah, trying to pot those f*cking balls helps to leave frustration behind
@swasheck excellent question, I don't understand a word of it
09:53
'A role cannot be removed if it is still referenced in any database of the cluster; an error will be raised if so. Before dropping the role, you must drop all the objects it owns (or reassign their ownership) and revoke any privileges the role has been granted on other objects. ' - postgresql.org/docs/current/static/sql-droprole.htmldezso 33 secs ago
@PaulWhite are you around?
@dezso Maybe the latest version at the time didn't have that issue. Is that possible?
checked it, and it was not the case - in the end, I see the solution proposed is working, but not for the reason they gave. Now filed an edit request on it.
10:59
Teamviewer, then hop onto RDP. FML this is horrid. I wish I could get cut and paste sorted :(
Any SQL server people want to give me tips on how to tune a crap query? I've got the plan for it in SSMS and the query text, but i'm a bit overwhelmed, it's huge. If it was Oracle I'd be ok ;/
0
A: Postgresql: how to remove a GRANT on multiple tables?

dezsoThe privileges are not automatically removed. Let's consult the documentation, as always: dropping a role is often not just a matter of a quick DROP ROLE. Any objects owned by the role must first be dropped or reassigned to other owners; and any permissions granted to the role must be revoke...

Am I repeating myself here ? anyone likes database designing here ?
@Phil One nice feature of the query plan visualiser is that it gives you the proportion of total resources used by an operator. As a starting point look for the 99%'s (or two 49%s) etc. This will let you find major bottlenecks fairly quickly.
Yeah, there's a few 25% ones and it's suggested an index
11:31
Another SQL Server-ism not present in Oracle is to see whether to refactor intermediate join results into temporary tables and see if indexing the temp tables helps.
@Phil Have you got SQL Sentry Plan Explorer?
Far better for tuning query plans than SSMS
Downloads
@Phil And try the suggested indexes.
@Mathematics absolutely, why?
If you have the actual plan, Plan Explorer is much better at telling you where there is a problem, especially with the Estimated vs Actual Rows comparisons
11:40
@dezso Your edit has been approved ;) stackoverflow.com/review/suggested-edits/11591005
@ypercubeᵀᴹ thanks, just noticed it myself
today's 'someone's wrong on the internet' issue is solved
@MDCCL Much prefer rotisseries myself.
With the new temporal tables in SQL Server 2016, is there any new magic happening in the query optimiser, or are the validity-defining columns simply more predicates to be fed into the current algorithms?
12:11
When I am doing a transaction, I must lock the accessed data. When transaction is distributed, I should lock all replicas of the same data item. Right?
@Phil If you view the plan xml by right clicking on the plan there may be more than one suggestion, not shown in the GUI (I learned recently)
I don't want to invalidate all replicas besides master because this will reduce the fault tolerance, which is held in place by the replication copies.
@ValentinTihomirov Are you writing a distributed DBMS?
@TomV @Phil All are shown in Plan Explorer though
12:28
@MarkSinkinson In the free version too?
@AndriyM Yep
Nice
@TomV lol, me too
12:54
@Phil Run it through database engine tuning advisor
/ducks
13:48
@TomV [+ 1 assists]
Anyone going to SQL Saturday Exeter?
@JamesAnderson Unfortunately not
14:10
@ypercubeᵀᴹ Wait. Do you want to say that this community is dedicated to administration and DB principles, which means internal mechanics, are outside the scope?
@ValentinTihomirov there is a very nice Hungarian phrase that comes to mind: he?
you forgot add context to your question
I was trying to figure out the context that @ypercubeᵀᴹ is alluding to.
@ValentinTihomirov I guess the answer is very different if you are talking about doing something in Cassandra, DBaseIV or a planned DBMS
and I also guess @ypercubeᵀᴹ was half joking about exactly this
I decided to clarify because I am planning to ask the DB principles question at the official site.
@ValentinTihomirov but without stating which scope we are in it won't be a good question either
14:23
I do not know what you mean by scope of questions but it is definitely not DB administration. Should I lock all replicas and does A imply C in ACID defenitely not administration question.
@ValentinTihomirov No, I'm asking what you are trying to do.
Are you trying to solve a problem in a specific, existing DBMS?
Or are you writing a DBMS of your own?
14:41
And with "no", I mean I was not trying to imply anything. Internal mechanics of DBMS's and db principles and ACID properties are very much on topic on the site.
2
@ypercubeᵀᴹ and to see this, it's enough to scroll up a bit
or check some highly voted answers from the regulars
15:07
Hmm, the reportserver executionlog3 table is empty ;/ It's running from Sharepoint, could that be why? I think I've found the correct dataserver with a ReportServer database in it. There wasn't one in the database that the report data is actually being pulled from
@Phil If you set up Reporting Services Configuration manager (install it if not present on your PC) you can connect to the SSRS instance and see/frig its configuration, including the connection to its repository DB.
@Phil Yes, I believe that the execution logs are now swallowed into the beast of share point
Aha, found it. ReportServerSharepoint. But there's no executionlog3. I guess it has its own sharepoint name or something. Googles
I am an idiot
:-)
15:29
user image
4
It is written
@billinkc I herd it on the intarweb, it must be true!!1
I just realized my trip to Denmark next week would be cheaper if I booked a flight back and forth every day instead of staying in a hotel. I guess comfort has a price
15:45
@TomV that's amazing
250€ a night vs a 130€ roundtrip
@TomV must be some nice hotel
What if you contract with a prostitute, do they have a lower rate?
@Lamak not at all
@TomV ah, is it "Oracle Hotel"?
2
15:47
Haha, the problem query that's part of a SSRS report takes 2:39 to execute, and returns 0 rows
@Lamak I wish, but I don't sleep on a mattress full of money
Actual rows vs estimated rows is way out. How does stats collection work in SQL Server?
16:03
@Phil You update them on a schedule or wait for them to be updated automatically (if that option is on for the database which is the default)
@PaulWhite - a couple of days ago, someone was asking you about a traceflag that you don't like to talk about... what number was it?
@Phil - was it you asking about that flag?
Time of update kinda sucks on large tables without a trace flag (and I believe that is now default in 2016à
Hello guys, quick question. My google fu failed me.
Can I pass an array as positional param in postgresql?
essentially I have a where column in ($1) somewhere in my query, and no matter what I pass as the positional param, if I have more than one item the query returns bad results.
Tried all variations I could think of.
@Phil we have queries like that
@TomV yes. it is default ... also ... trace flags are becoming database options
@Lamak you can check out any time you like, but you can never leave
@Phil i have a query that you can use to look at your stats
@mmarie congrats!
16:24
Do any of you have an opinion on alation?
nvm, found it.
@Mahesh sry. postgres expertise is currently asleep
@swasheck ta
@Mahesh What was it?
TIL: SQL Server 2016 is introducing support for DROP TABLE IF EXISTS
2
16:41
Does SQL server do IO and CPU calibration for use by the optimiser, like Oracle does? Would it need recalibrating if it moved hosts?
16:57
@Phil I've never heard of that before.
if SQL Server did do that, it would very likely automatically re-calibrate.
@Phil could you be more specific
17:15
@MichaelGreen You the Australians have a non-rothic accent (according to Wikipedia), right? I am not a native English speaker myself, but I find those particulars about spoken language very interesting.
@TomV Have you checked airbnb? You could find much cheaper, starting from 25 per night, if you don't mind skipping the luxuries of a hotel: airbnb.co.uk/s/Copenhagen?source=hdr
17:54
The equivalent of dbms_stats.gather_system_stats();
@Phil so it's a way for oracle to take an introspective look at how it sees the hardware performing?
Yup
And the cost based optimiser uses it to cost plans
i would assume that such a thing, if it exists, is handled internally. however, someone like @PaulWhite would probably know better
Just upgraded to SQL Sentry X
Can't wait for Plan Explorer Ultimate Edition with Paul White Theme
5
18:34
@JamesLupolt It's really not that exciting. I'm a beta tester
user image
5
18:44
@billinkc artwork's too good to be your own original work. i say that you've plagiarized this
@swasheck Straight from SQL Sentry Plan Explorer Performant Edition with the exclusive Paul White DLC
You have one long transaction making a lot of reads and many short update transactions which are likely to wait if you use the locks and proposes MVCC instead. But, as I understand, MVCC will just fail the long transaction because it did read the updated location and it will no longer be valid at the time of completion. Is it really a solution or MVCC does some magic?
19:03
Are you saying that it is mentioned on postgresql.org/docs/current/static/indexes-expressional.html that I can use the "+" operator while creating an index. OMG, why can't I see it... — user3202272 39 mins ago
facepalm. They should have mentioned each and evry one of the hundreds opeartors and functions ...
@ValentinTihomirov It does some magic ;)
@ValentinTihomirov In short, the long runing transaction (that only reads) will not be blocked.
It will start reading at say, point in time 7, and complete at say, point in time 378. The results that the user will see will be as if the transaction had finished instantaneously, at point 7.
Whatever other transactions wil be doing in the meantime, will just not be visible to that transaction.
I think SQL Server calls this "Snapshot Isolation". It works like if every transaction takes a snapshot of the data, the time it starts.
@billinkc that's great. What's the symbol for hash/sort spill warning?
@ypercubeᵀᴹ If you say that we read 100 records, every with value 1 in the beginning and one of the values is updated in the middle then our long-running transaction will receive some value 2 in the result. "Taking snapshot " of the data when transaction starts would return all ones.
I mean second transaction updated one value 1=>2 in the middle while long read transaction was executing.
@ValentinTihomirov No, it will read all 1s. Because the db will take a snapshot. What the 2nd transaction does wil be done in the 2nd snapshot, which is not visible by the 1st transaction.
The change will be visible to transactions that start after the 2nd commits.
I understand what snapshot means. I understand how to achieve it with locking. I am asking how does MVCC achieves the same.
19:19
It takes snaphots, i.e keeps versions of each row, usually not by copying everything but my marking the timestamps of changes.
Ok. you are saying that my assumption that "latest wirte takes precedence" is not true. MVCC can figure the old snapshot from the below of the new data.
But wait. The when we commit a new transaction, it must be valid (consistency) with respect to the latest commited one, not just some snapshot from below.
yes, something like that.
@ValentinTihomirov Not sure what you mean there.
Ah, you mean what happens at commit time. Yes, that's complicated.
tran-1 starts at point 7.
        tran-2 starts at point 8.
tran-1 updates name to 'John'
        tran-2 updates name to 'George'
tran-1 commits
        tran-2 commits
what happens?
What is the point? I started to feel that I do not understand snapshoting with locks either.
Simply read-locking any values that I did read during the transaction won't provide me snapshot at the moment when I started it.
19:34
Why do you keep thinking with locks? Locks are not necessarily used.
I believed that this algorithm will ensure the consistent views, the snapshots.
"This" algorithm? Which algorithm?
When you lock everything that you access during transaction.
But probably you do not need the snapshot for the transactions? Say you read these 100 rows and they all are 1 in the beginning. It is allowed to increment the values, which is done by concurrent transaction. At the end, the read(100) transaction may have some high-order rows != 1 but that is fine. It will build up on a newer snapshot than it started with. It will be a problem with MVCC, which comes up with obsolete snapshot.
If you lock things, why are snapshots needed?
it depends on which Snapshot Isolation model you're using in SQL Server
@ValentinTihomirov do you have a specific question, or are you working through theory? also, it might be helpful if you had an RDBMS in mind (postgres, Oracle, SQL Server) as they may have various methods.
19:51
@swasheck I started to learn how do Actors improve reliability and lost somewhere in the distributed transactions theory.
@ypercubeᵀᴹ Company arranges travel, I don't pay for it myself and they have an agency they work with
Whatever I guess
I'm not managing or in charge of that
20:05
my message seems to get through, but this contains some other nonsense, right?
> However, my saying was, DEADLOCK occur if you are trying to take for two EXCLUSIVE LOCKs, in case of SELECT FOR UPDATE the transaction allows others to READ those rows and it completes with full ownership. As a mater of fact, SELECT FOR UPDATE in two session in any RDBMS is complete lock.
@billinkc I had to explain to my wife why I was laughing so loud
20:24
I may have to give up SQL Server and become a photoshop artist
@billinkc your first task would be to fix that avatar to look like an actual head
@Lamak Ugh, you just don't understand my art
I think I'm getting the hang of this
@billinkc sorry kid
20:48
@dezso doesn't parse in my mind. It could be the beers from lunch that affect my processing but I doubt it.

« first day (1893 days earlier)      last day (3270 days later) »