Showing posts with label clean. Show all posts
Showing posts with label clean. Show all posts

Friday, March 23, 2012

Merge 2 columns from the same table

Hi *,

I have a table with 2 columns A1 and Firm. A1 holds "dirty data" and there are no NULL values. Firm holds "clean data" for some of the rows in A1 but not for all. So there are quite a few NULL values in this column. I want to replace the value in A1 if there is any data in Firm (value <> NULL).

Rigth now, I solve this issue with a simple VB.NET script:

Public Class ScriptMain
Inherits UserComponent

Public Overrides Sub Input0_ProcessInputRow(ByVal Row As Input0Buffer)
'
If Row.Firm_IsNull Then
Row.Standard = Row.A1
Else
Row.Standard = Row.Firm

End If
'
End Sub

End Class

Any ideas how to solve this issue without custome code?

Thanks!

It sounds to me like you can use Derived Column transformation:

Repalce A1:

With an expression like

ISNULL(Firm) ? A1 : Firm

Rafael Salas

Friday, February 24, 2012

Memory Orphan Connections

Does SQL Server 2000 clean up broken or orphan connections
and lease their corresponding memory?
Is there a Microsoft Article that goes into this topic.
Thanks,
Mark P.
Basically yes. When a connection is broken SQL Server will rollback any
open transactions for that connection and any memory used as such will be
available for use by other connections.
Andrew J. Kelly SQL MVP
"Mark P." <anonymous@.discussions.microsoft.com> wrote in message
news:34f501c49cfc$55623e50$a601280a@.phx.gbl...
> Does SQL Server 2000 clean up broken or orphan connections
> and lease their corresponding memory?
> Is there a Microsoft Article that goes into this topic.
> Thanks,
> Mark P.

Memory Orphan Connections

Does SQL Server 2000 clean up broken or orphan connections
and lease their corresponding memory?
Is there a Microsoft Article that goes into this topic.
Thanks,
Mark P.Basically yes. When a connection is broken SQL Server will rollback any
open transactions for that connection and any memory used as such will be
available for use by other connections.
--
Andrew J. Kelly SQL MVP
"Mark P." <anonymous@.discussions.microsoft.com> wrote in message
news:34f501c49cfc$55623e50$a601280a@.phx.gbl...
> Does SQL Server 2000 clean up broken or orphan connections
> and lease their corresponding memory?
> Is there a Microsoft Article that goes into this topic.
> Thanks,
> Mark P.