Viewing 12 posts - 16 through 27 (of 27 total)
So, that's why I was trying to see if an "if exists" or "where exists" or is not null, or some such variation would work.
Basically, check for the expected columns...
December 15, 2005 at 2:08 pm
So, when I run this:
DECLARE @strColNames VarChar(500)
SELECT * INTO Project01PreTemp
FROM OpenRowSet('MSDASQL', 'Driver={Microsoft dBASE Driver (*.dbf)};
DriverID=277;
DBQ=C:\ReturnedProjects',
'SELECT * FROM Proj01')
--DECLARE @strColNames VarChar(500)
SELECT @strColNames = isnull(@strColNames +', ', '')
+ name FROM...
December 15, 2005 at 2:01 pm
The dbf file has different columns than the SQL table.
Let's see if I can clarify.
dbf file has the same columns (for example) of
FIRSTNAME, LASTNAME, HOMEPHONE, CELLPHONE, etc.
Sometimes, some non-required...
December 15, 2005 at 1:56 pm
I'll see if I can do that. Meanwhile, I have no trouble importing the file with all it's columns to a temporary table. But how do I do an insert...
December 15, 2005 at 12:46 pm
Sorry, but some times, when I posted in other forum categories that were more relevant to the question, I received ZERO responses, but actually received some responses to the same...
December 15, 2005 at 12:42 pm
So, I can get this code to work:
SELECT *
INTO Project01tmp
FROM OpenRowSet{'MSDASQL', 'Driver=(Microsoft dBASE Driver (*.dbf(};DriverID=277;DBQ=C:\ProjectDir', 'select * from Proj01');
INSERT INTO Project01tmp
(FirstName, LastName, ....)
But again, I'm having to specify the filename....
December 14, 2005 at 5:46 pm
What should I look for in BOL for the Driver details information?
Thanks.
December 14, 2005 at 5:18 pm
I see in the DTS package tool, with the "File Transfer Protocol" I can choose the source to be either Internet or Directory. So I choose Directory. Then it lists...
December 14, 2005 at 5:13 pm
So what is this fso you're referring to? ?File System Object?
I'm NOT an activeX developer at all. In fact, the hope is that eventually they will migrate off this ms...
December 14, 2005 at 5:06 pm
I'll try fiddling around with that then. I was hoping I could do things in a more SQL related way, but if DTS can be made to do it correctly,...
December 14, 2005 at 4:54 pm
I'd PREFER to do it all in sql rather than dts, but I can't seem to get it to correctly handle the file format.
What is the driver information/code/syntax I would...
December 14, 2005 at 4:51 pm
Viewing 12 posts - 16 through 27 (of 27 total)