Viewing 10 posts - 1 through 11 (of 11 total)
Garadin (9/16/2009)
This code works perfectly fine:
--// lets create the source data
CREATE TABLE tblSource
(
...
September 16, 2009 at 11:36 am
the where clause was one problem... what did you find was the other ?
September 16, 2009 at 11:32 am
Garadin (9/16/2009)
Does it? Or did you just forget theWHERE oldv.oldvalue newv.newvalue
😉
hehe yes I did forget the where clause... but... and maybe im being a little dense......
September 16, 2009 at 8:36 am
Wow thanks for the replies... definitely gives me something to think about. Handling the the variable column widths and data types are going to be a challenge... but...
September 11, 2009 at 10:40 am
hey again 🙂
I figured it out
-- original problem
Select Transaction_id,fieldName, oldvalue
from (
Select
Transaction_id
, acmc_id
, company_id
, company_type_id
, activity_company_id
, Addr_1
, Addr_2
, Addr_3
from activity_company_master_copy
Where CharIndex('Original',user_action) > 0
and transaction_id is not null) as aammc_src
unpivot
(oldvalue...
September 11, 2009 at 8:33 am
Garadin (9/10/2009)
September 10, 2009 at 9:21 am
heh I think I was refereing to the
;WITH UnPivotCTE AS (
at the beginning of the code piece.... as I said I am going to need to study this a...
September 10, 2009 at 9:15 am
looks like some code is missing....?
lol im going to have to study this a bit....
September 10, 2009 at 9:04 am
Hi Seth,
Currently there is no way to link the 2(orig and new) rows to a single transaction. However in the ongoing days I will be adding a transaction key...
September 10, 2009 at 8:33 am
Thanks for the reply and yes you misunderstood... i did as you advised and went the link. Here is the script to illustrate my question and problem:
--// create temp...
September 10, 2009 at 7:08 am
Viewing 10 posts - 1 through 11 (of 11 total)