Forum Replies Created

Viewing 15 posts - 1 through 15 (of 17 total)

  • RE: Getting Min and Max Date from a Text field

    Got this worked out. New query is:

    Select Min(CONVERT(DATE,PatientDischargeDate)) AS MinDate,

    Max(CONVERT(DATE,PatientDischargeDate)) AS MaxDate

    FROM tblParticipants

  • RE: SQL Filter question

    I don't think I am going to get this to work at all with my current aggregate table structure. The aggregate table has no way of associating the other...

  • RE: SQL Filter question

    Sean,

    Your query basically gave me back what I was already getting. I am only getting back the four keys for that one question. I need to get back...

  • RE: Can't compile stored procedure

    OMG!!!! Luv it when you look at code for over 30 minutes and miss something so small. The @Corp5 was declared in the first part of the sp...

  • RE: LEFT OUTER JOIN Count Question

    Sorry, I forgot to add that tblCSSDataN is also a static table that has over 3,000,000 records in it now and more records are added to it nightly from many...

  • RE: LEFT OUTER JOIN Count Question

    The two tables that I am working with are not temporary tables being created and dropped

    in SQL code. tblStmtChar holds all characteristics for all of our surveys and...

  • RE: Help with a SELECT UPDATE query!!

    This has now been resolved. I looked on another forum and picked up an idea and gave it a try and it worked. Here is the statement that...

  • RE: Multiple COUNT(*) in SELECT

    Thanks Ken, it worked like a charm!!!

  • RE: ISNULL, CASE WHEN Problem

    Mr. Williams,

    Thank you for your response. I am not sure that I follow you though, I apologize.

    In the first query there actually is no data in tblData where the...

  • RE: Updating a field

    Thank you, that was the ticket. I had to change the varchar(MAX) to varchar(10) though. I got an error when I tried it with MAX.

    I took this database...

  • RE: Updating a field

    Okay, the field name is [1] and the datatype is text. Here is the query that I wrote:

    UPDATE tbl1847

    SET ...

  • RE: What is wrong with this IF statement

    Sorry for the post!! Something so simple to overlook.

    The reason I am deleting this table and recreating it is that the background data that is aggregated into this table...

  • RE: Updated Can't figure out how to write the query!!

    I added a couple more columns that I needed and now here is my working query to the first problem:

    select distinct ci.ReportNum, ci.StmtNum, ci.SchemeNum,

    s.Stmt, s.Count_Range, sc.CharNum, c.Characteristic

    from tblClientImport ci

    inner...

  • RE: Can't figure out how to write the query!!

    This topic is no longer valid!! I started another one yesterday with the heading: Updated Can't figure out how to write the query!! and I received some good replies.

    I...

  • RE: Updated Can't figure out how to write the query!!

    GSquared: Your solution worked also and will be easier to comprehend in the stored procedure as I will only have to put the survey number variable in the code...

Viewing 15 posts - 1 through 15 (of 17 total)