Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 Separating data into columns - DTS

Author  Topic 

IC
Starting Member

1 Post

Posted - 2007-07-05 : 06:10:50
I have temp table that contains one column. The data from the temp table must be exported to another table and then the data must be separated into 3 columns in another table.

The data looks like this in the temp table that has one column:

TEST01 - TEST SMS: Control Dates Failure on Jul 3 2007 8:10AM

The columns names are supposed to be separated like this:
ServerName - TEST01,
Alert - TEST SMS: Control Dates Failure,
Alert Date - Jul 3 2007 8:10AM

there should be now hyphens in the data.

Can anyone perhaps help me with this?

madhivanan
Premature Yak Congratulator

22864 Posts

Posted - 2007-07-05 : 10:27:15
You need to know what basis data should be sperated

If you have data like this


TEST01 - TEST SMS: Control Dates Failure on - Jul 3 2007 8:10AM
(hyphen before jul)

then you can make use of parsename function to split and store them in different columns
Read about it in sql server help file

Madhivanan

Failing to plan is Planning to fail
Go to Top of Page
   

- Advertisement -