Viewing 15 posts - 256 through 270 (of 1,396 total)
Here's an alternative. Is it better, idk
with
gap_cte as (
select *, case when UserTier<>lag(UserTier) over (partition by UserID order by StartDate) then 1...
March 8, 2023 at 11:21 pm
Imo it depends on whether or not Approved is exactly equivalent to Taken. Could a user be officially approved and yet not take the day? If there's an exact equivalency...
March 6, 2023 at 12:59 pm
It could be two similar queries. For the first one maybe you could try something like this. It uses OUTER APPLY but LEFT JOIN would probably also work
March 3, 2023 at 1:19 pm
Good lord. 🙁
It's got to have you wondering, no? Where the line is to be drawn? How many doublings do we have remaining? What really changes because I'm still...
February 19, 2023 at 5:19 pm
Thank you.I am looking select statement
Ok thank you. Still have some questions tho
Example 1:
exec spLiceceQty @Productid=1,@LicenceQty= 10
I want the following result set
1, 2023-02-15 14:47:16.927, 25
Why...
February 19, 2023 at 4:23 pm
What determines the hierarchy of 'LicenceQty' row values from which to begin the subtraction? In the case of ProductID=1 the example appears to apply lifo, "last in, first out", and...
February 19, 2023 at 1:21 pm
Well, what does the chatbox have to say about this one? It doesn't look too tricky imo
February 19, 2023 at 12:49 pm
BTW and just to clarify, I'm damned impressed with what they've been able to get ChatGPT to do. The technology behind all of that is mind boggling . My...
February 16, 2023 at 3:59 pm
Presumably there are other employees besides Betty? If so it would be convenient to start with a table containing (unique) employees and the sample size. In the case where you're...
January 28, 2023 at 2:30 am
The question came up based on this forum post. Not sure I'd know the answer otherwise
https://www.sqlservercentral.com/forums/topic/nullif-in-ssis#post-4122037
January 24, 2023 at 4:40 pm
Afaik JSON treats carriage returns as white space. At the bottom of this page it says:
Whitespace can be inserted between any pair of tokens
Then there's this...
January 22, 2023 at 1:47 pm
Afaik this matches the output from the existing query. To add additional columns you could add additional CROSS APPLY operators and then vary the date inequalities in the WHERE clause(s)
January 21, 2023 at 6:49 pm
It seems tricky to wade in on this because maybe it's ok the way you're doing it. Or idk maybe more than one thing is amiss. Why add columns in...
January 17, 2023 at 4:59 pm
Well the flip side of that question is, if you're passing the information on to a system that wants to read JSON do you store the sqlified data in...
January 13, 2023 at 11:02 pm
but do you suppose that they'll actually use your good code to "normalize the data" and store that normalized data in a database or store the JSON and parse...
January 13, 2023 at 8:03 pm
Viewing 15 posts - 256 through 270 (of 1,396 total)