Viewing 15 posts - 11,716 through 11,730 (of 26,486 total)
Just a slight mod to my code. I added an ORDER BY.
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_PADDING ON
GO
CREATE TABLE [dbo].[claim_report](
[claim_stat] [char](1) NOT NULL,
[status_note_code] [varchar](10) NULL,
[biller_cd] [varchar](20) NOT NULL,
[form_id] [varchar](10)...
May 23, 2012 at 1:51 pm
Here is my first shot at your request.
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
SET ANSI_PADDING ON
GO
CREATE TABLE [dbo].[claim_report](
[claim_stat] [char](1) NOT NULL,
[status_note_code] [varchar](10) NULL,
[biller_cd] [varchar](20) NOT NULL,
[form_id] [varchar](10) NOT NULL,
[patient_nbr] [varchar](24) NOT NULL,
[patient_name]...
May 23, 2012 at 1:44 pm
There is no status column. There is a column called claim_stat. Is this column you mean when you say status?
May 23, 2012 at 1:39 pm
The problem with the WHERE clause is that it is forcing a table scan. SQL Server has to comput the difference betwen the two dates for every row in...
May 23, 2012 at 1:01 pm
The Dixie Flatline (5/23/2012)
Hi Lynn.
I am not talking about he-who-is-without-clues.
I am talking about someone else.
May 23, 2012 at 12:46 pm
Because you are using the diag_1 alias for the column DIAGNOSIS_CODE and for the computed column with the CASE functions.
SELECT
RECIP AS recipno
,DIAGNOSIS_CODE AS diag_1 --...
May 23, 2012 at 12:42 pm
This is what I came up with, but I think there are some other issues with the query.
SELECT
Locality,
Region,
ADOPTION,
...
May 23, 2012 at 12:36 pm
chalbert (5/23/2012)
What is OP? Be kind guys
OP == Original Poster
May 23, 2012 at 12:29 pm
chalbert (5/23/2012)
Doesn't that give you the age as of the day it is run?
No, try running the following:
SELECT DATEDIFF(YY,'20111231','20120101') as age
May 23, 2012 at 12:29 pm
My problem is I haven't created or used Maintenance Plans in so long, I have to look things up regarding them. I have been rolling my own processes for...
May 23, 2012 at 12:27 pm
preetid2 (5/23/2012)
May 23, 2012 at 12:23 pm
quillis131 (5/23/2012)
I was wondering and cannot think straight on this, So I came with an idea of getting ideas/views from different people..
HARD RULE : When a Primary Key is defined...
May 23, 2012 at 12:22 pm
derekr 43208 (5/23/2012)
Yes. As I explained earlier, the first query has a correlated subquery in the EXISTS predicate. This query is run for each row in the outer...
May 23, 2012 at 12:10 pm
Check the setting in SSMS. Tools -> Options -> Query Results -> SQL Server -> Results to Grid and Results to Text.
May 23, 2012 at 12:08 pm
Hope this helps, couldn't test it as you didn't provide and DDL for the table or sample data in a readily usable format.
/****** Object: UserDefinedFunction [dbo].[DelimitedSplit8K] ...
May 23, 2012 at 11:42 am
Viewing 15 posts - 11,716 through 11,730 (of 26,486 total)