output one row

Can I read an entire file and output just one row?

I have a file that contains information about several databases. I need to read in the file and then insert into a new table the appropriate values. Example:

The file:

database1 10 GB used

database2 20 GB used

database3 30 GB used

Insert into table

Date database1 used database2 used database3 used

I can't seem to figure out how to insert only one row. Can someone help me? Does this make sense?

Thanks

[518 byte] By [ChrisHelt] at [2007-12-25]
# 1

Yeah it makes sense. Use the PIVOT component. This is exactly the functionality that it provides.

The only limitation (if you can call it that) is that the list of pvioted columns (and hence the list of columns) needs to be finite.

-Jamie

JamieThomson at 2007-9-3 > top of Msdn Tech,SQL Server,SQL Server Integration Services...
# 2
Thanks! It's just what I needed.
ChrisHelt at 2007-9-3 > top of Msdn Tech,SQL Server,SQL Server Integration Services...

SQL Server

Site Classified