Viewing 15 posts - 31 through 45 (of 231 total)
I'm still having a hard time following. Not sure why it's so challenging.
I'm going to try to replicate this with a couple of test sprocs and see if I can...
October 20, 2020 at 3:21 am
I just got a chance to try this out and it ...kinda worked. Proc B calling Proc A returned the dataset from Proc A with the "EXEC ProcA", but I...
October 17, 2020 at 12:50 am
So how do I actually do this? Here's my example sprocs:
----THIS IS AN EXAMPLE OF PROC 1:
CREATE PROC dbo.Service_Data
AS
DECLARE @SQL NVARCHAR(MAX);
BEGIN
DECLARE @DATA TABLE
(COLUMN1 INT
,COLUMN2 INT
)
SET @SQL =...
October 15, 2020 at 4:47 pm
I'm sorry guys, I'm just not seeing it for whatever reason.
So proc 1, let's call it dbo.Service_Data. Uses OpenQuery to get a bunch of data and eventually, ends in a...
October 15, 2020 at 3:57 pm
Not sure I understand.
To be clear, the proc I'm calling is being used in other reports so I can't necessarily modify it to insert the resultset into a table inside...
October 14, 2020 at 9:25 pm
Thanks Scott.
Actually I transformed the field (called COS) using your code first, then used a CTE to split the values and comma delimit them for the final product:
October 2, 2020 at 3:02 pm
Wow, guys, thank you so much.
The REPLACE actually worked well in my existing query.
Thank you both for your help with this!
October 2, 2020 at 1:56 pm
Nice! This also does the trick, with the additional DupeGrp and GrpCnt columns. I like it. And so simple, like you said, just a Dense Rank.
Thank you, Jeff! And thank...
August 7, 2020 at 2:14 pm
Yes that's correct. In the new dataset I renamed RIN# to Cl_ID and License# to VEH. But yes, you would be correct.
August 7, 2020 at 1:48 am
There are definitely rows without dupes. And in the full dataset that's the vast majority. Any records that have a 1 rownum, (which are not followed by a 2 or...
August 7, 2020 at 1:35 am
Hi Jeff,
Below is a slightly bigger example dataset, 30 rows, more columns.
CREATE TABLE #duplicatetrips2(
[ID] [int] IDENTITY(1,1) NOT NULL,
[RowNum] [bigint] NULL,
[TRIP_DATE] [varchar](10) NULL,
[LDATE] [varchar](10) NULL,
[CL_ID] [nvarchar](255) NULL,
[PROVIDER_NAME] [nvarchar](255)...
August 7, 2020 at 1:00 am
Scott, I'm looking through the query, running against my full dataset and it looks pretty close. I'll need to add more columns to my final dataset as there are a...
August 7, 2020 at 12:04 am
Actually, I used all of the values listed in the table as the values which identify duplicates (those are what the Row_Number used to create the RowNum column). Does that...
August 6, 2020 at 6:06 pm
Not quite. The RIN# is not a unique number here, that number will exist multiple times on a day and provider so this will not return the expected results across...
August 6, 2020 at 5:57 pm
Hello Kate,
You're right, we were trying to eliminate the duplicates as that was not correct. Sample data was posted at the beginning of the post, but I was unable to...
April 28, 2020 at 10:06 pm
Viewing 15 posts - 31 through 45 (of 231 total)