Recent content by CharlieWh

  1. C

    SQL Script | ROW_Number & CASE WHEN

    Got it! CASE WHEN ROW_NUMBER() OVER(PARTITION BY d.c1alias ORDER BY d.c1alias) = 1 THEN concat(''PROP.'', d.c1alias) ELSE concat(''PROP.'', d.c1alias, ''_'', ROW_NUMBER() OVER(PARTITION BY d.c1alias ORDER BY d.c1alias)) END As Wsid,
  2. C

    SQL Script | ROW_Number & CASE WHEN

    A bit like this, but this is no where near d.c1alias ROW_NUMBER() OVER(PARTITION BY d.c1alias ORDER BY d.c1alias) CASE WHEN d.c1alias = 1 THEN 'Original' WHEN d.c1alias = >1 THEN 'Not Original' END AS Wsid,
  3. C

    SQL Script | ROW_Number & CASE WHEN

    I have a Select & Insert Into statement that I am trying to build and due to duplicates (that must not be removed) I am attempting to use row_number within a case statement, so that when the result of row_number = 1 then I specify the vault of As WsID as one thing and case row_number is grater...
  4. C

    Parsing strings of text between xml tag identifiers

    I have a Db with a table imported from sql server. One of the fields contains data wrapped between xml tags. The xml tag identifiers when looked at as columns are not consistently the same tag identifiers but effectively I am parsing the string to provide columns of data from between the tag...
Back
Top Bottom