I have a preparation table with 4 fields. Once the records are ready I use the sql script below to insert them into an existing table. It works great however I would like to watch this process in SSIS. Is this possible?
All the fields below exist in the destination table, but only the 4 in brackets are in my source table. Using TSQL, this is super easy. But the closest I have gotten in SSIS is by using derived columns and adding columns but it won't let me create a GUID. There are also some date fields that I have formatted in TSQL that is not possible in this dialog.
use MyDatabase
insert into dbo.DestinationTable (FILEID,
FILENAME,
STATUS,
LIBRARY,
FILESIZE,
MAJREV,
MINREV,
IMPORTDATE,
IMPORTTIME,
[CATNUM],
[MATDESC],
[CATCLASS],
[DOCVER])
select NEWID()
[PartNumber],
'In',
'Projects',
0,
0.0,
0.0,
DATEPART(YYYY, GETDATE()),
DATEPART(HH, GETDATE()),
[Catalog #],
[Material Description],
[Catalog Class],
[Document Version]
from dbo.SourceTable;