Forum Replies Created

Viewing 4 posts - 1 through 4 (of 4 total)

  • RE: Dealing with ' and " in strings

    Just write two times the character you use as string delimiter if it appears in the string you want to insert.

    INSERT INTO table(column1,column2) VALUES ('this is ''string'' 1','this...

  • RE: Internal Query Processor Error:

    Sometimes i get the same error message in Enterprise Manager when I click with the right button on a table and select "Open table --> Return all rows"...

  • RE: weekly report

    You just need to use GROUP BY with the appropriate aggregate function(s) in the SELECT statement.

    SELECT DatePart(wk, Date_field), DatePart(yyyy, Date_field), put aggregate functions here

    FROM table

    GROUP BY DatePart(wk, Date_field), DatePart(yyyy, Date_field)

    ...

  • RE: How to delete duplicated rows in a table

    You can try to set rowcount to the 'number of row to be deleted -1' like this:

    set rowcount # of duplicates - 1

    delete from table where key_column=key_value

    set rowcount 0

    (0 means...

Viewing 4 posts - 1 through 4 (of 4 total)