Use database1
declare @date varchar(100) = (select Convert(VarChar, GetDate(), 112))
Declare @fullpath varchar(100) = 'c:\templogs\'+(@date)+'-server1.csv'
bulk INSERT server1 FROM '+@fullpath+'
WITH
(
FIELDTERMINATOR = ',',
ROWTERMINATOR = ''
)
How do I say from 'c:\templogs\20100323-server1.csv' using the declared @fullpath?
The file name changes everyday because of the date change and I'd like to automate it.
Help!