812 reputation
110
bio website
location Ukraine
age
visits member for 1 year, 2 months
seen May 10 at 18:52
stats profile views 39

Sep
10
comment MySQL: selecting arbitrarily ordered rows after a specific id
Why not use an offset (especially if it solves the very problem you are asking about)?
Sep
8
revised Should I use left join to do my job in this scenario?
corrected spelling in the title
Sep
8
suggested suggested edit on Should I use left join to do my job in this scenario?
Sep
5
answered Total of orders open on a given date for each date in a date range
Sep
5
comment Total of orders open on a given date for each date in a date range
@EmmadKareem: The OP may be referring to a running total question simply because they could see a connection between the two problems, but I think this one isn't fundamentally a running total problem. (Although it can be turned into one, as AlexKuznetsov has demonstrated.)
Aug
31
answered CROSS JOIN with temp table and CASE statement
Aug
30
revised CROSS JOIN with temp table and CASE statement
CROSS JOIN doesn't expect an ON clause; the WHEN values were incorrect
Aug
30
suggested suggested edit on CROSS JOIN with temp table and CASE statement
Aug
30
comment Why should a CTE start with a semi-colon?
I think you cannot put a semicolon before BEGIN CATCH simply because it is part of a single compound statement introduced with BEGIN TRY. It's same as putting a semicolon before an IF statement's ELSE.
Aug
28
comment Are there any way to stop typing 'go' in sqlcmd?
(Just a guess.) The semicolon is a statement delimiter in T-SQL. Previously it was completely optional because it was impossible to write an ambiguously interpreted batch (aka multi-statement query) that had no statement delimiters. Based on that, the semicolon was probably chosen as a batch delimiter in sqlcmd. However, since SQL Server 2005, new features have begun to appear in T-SQL that enable you to write an ambiguous batch if you don't delimit the statements. So, to avoid the ambiguity interpreting the function of ;, the need for a distinct batch delimiter must have arisen.
Aug
27
comment Convert datetime to europe default without time
Strictly, speaking, the 6 format specifier gives a closer result to what you are asking about than the 106 one does, but keeping the century may be a good idea.
Aug
22
comment How do I perform a UNION query on a dynamic list of tables?
I think it should be possible to avoid a cursor with something like GROUP_CONCAT(CONCAT('SELECT * FROM ', table_name) SEPARATOR ' UNION ALL ').
Aug
22
comment Reason to not use nullable number in Oracle?
Related question on SO: Standard use of 'Z' instead of NULL to represent missing data?
Aug
19
comment SQL Server Decimal(9, 0) vs INT
Another difference between decimal(x,0) and an integer type shows itself in arithmetical division. If you divide an int by an int, you get an int. If you divide a decimal(x,0) by an int, you get a decimal(x+6,6).
Aug
16
comment query generate the information one column in two columns in one query
Note also that having two columns with identical names (id) doesn't really make much sense.
Aug
16
comment Commonly Used Acronyms by Database Administrators
Added DBMS & RBAR. Perhaps terms that are not acronyms should be described in a separate answer.
Aug
16
revised Commonly Used Acronyms by Database Administrators
added DBMS and RBAR, replaced hyphens and double hyphens with n-dashes
Aug
11
comment Query for data that is not there
@RolandoCruz: I see. Please have a look at my update then.
Aug
11
revised Query for data that is not there
added an alternative suggestion
Aug
11
comment Query for data that is not there
@EmmadKareem: I did see your comment about registration_date. My assumption regarding that attribute at the time was along the lines of what Rolando would eventually tell you, i.e. that the date was related to the person's registration as a member, not as an event participant.