Thursday, March 29, 2012
DTS Fixed Field length File Limitations
I am trying to upload a fixed field text file to a sqlserver table using the DTS wizard. The txt file has 111 columns and the total length of a single row is 5897. The problem is when I use the wizard to specify the starting and ending of each column, its not allowing me to specify the columns beyond the position 4095.
Is there a limitation on this? if so is there a work around ? to solve this.
Any help on this is truly appreciated.
Thanks much. :)I've never encountered this problem but then I have never had a file quite that wide....
Personally what I would do is write a quick wee app or ActiveX Script to slice the file in half and then do the import in two stages... probably doesn't help much but it's the best suggestion I can give you.
Tuesday, March 27, 2012
DTS Export Data Pump appending file
I've a "little" problem...
I must generate a txt file with this structure:
- one header
- n details
Header and details have different structure and i must write header before details.. I've already a table with details.. i could create table for header, but this table design it's too different than details design.. and i can't use the union statement in the output query..
Can i write the header line and write details in append on a txt file??
with data pump i can create and replace file.. but not append??
I know that i could use the filesystem object to modify the file, but i would bypass it with tasks of SQL server..
it's possible?
Thanks!!!
PS: I hope that you understand my problems..
I know poor english.. ;-)Why not post your DDL and DML...
Check out
SELECT Data_Row FROM (
SELECT '"Owner","Job"' As Data_Row, 1 AS Row_Group
UNION ALL
SELECT '"' + l.Name+ '","' + j.Name + '"', 2 AS Row_Group
FROM msdb..sysjobs j
INNER JOIN master..syslogins l
ON l.sid = j.owner_sid
) AS XXX
ORDER BY Row_Group|||thanks..
i've already done in that mode... ;-)sql
Wednesday, March 21, 2012
dts copy text to table only
from a text.txt source?
thanks,
trintYour question has been answered in
microsoft.public.sqlserver.programming.
--
Hope this helps.
Dan Guzman
SQL Server MVP
--------
SQL FAQ links (courtesy Neil Pike):
http://www.ntfaq.com/Articles/Index...epartmentID=800
http://www.sqlserverfaq.com
http://www.mssqlserver.com/faq
--------
"trint smith" <trintsmith@.hotmail.com> wrote in message
news:e7081ac9.0307260802.4c8acc5a@.posting.google.c om...
> how do i specify the table destination only not the whole database
> from a text.txt source?
> thanks,
> trint|||Your question has been answered in
microsoft.public.sqlserver.programming.
--
Hope this helps.
Dan Guzman
SQL Server MVP
--------
SQL FAQ links (courtesy Neil Pike):
http://www.ntfaq.com/Articles/Index...epartmentID=800
http://www.sqlserverfaq.com
http://www.mssqlserver.com/faq
--------
"trint smith" <trintsmith@.hotmail.com> wrote in message
news:e7081ac9.0307260802.4c8acc5a@.posting.google.c om...
> how do i specify the table destination only not the whole database
> from a text.txt source?
> thanks,
> trint
Sunday, March 11, 2012
dts and bit fields
If I dts data from a table to a .txt file all of the data
in the bit field gets turned into a "true" or "false"
value. Is there a way to turn this setting off?
TIA, ChrisDid not test, but
turn the column to allow null, then when dts, do not load the column.
"chris" <anonymous@.discussions.microsoft.com> wrote in message
news:014401c3c995$94930900$a501280a@.phx.gbl...
> sql2k sp2
> If I dts data from a table to a .txt file all of the data
> in the bit field gets turned into a "true" or "false"
> value. Is there a way to turn this setting off?
> TIA, Chris|||DTS a query or view rather than the base table.
In the query or view, use CONVERT or CAST to cast the bit column to integer
(or what you want).
James Hokes
"chris" <anonymous@.discussions.microsoft.com> wrote in message
news:014401c3c995$94930900$a501280a@.phx.gbl...
> sql2k sp2
> If I dts data from a table to a .txt file all of the data
> in the bit field gets turned into a "true" or "false"
> value. Is there a way to turn this setting off?
> TIA, Chris
Wednesday, March 7, 2012
DTS "general error" when trying to export/transform to txt file
When I finish up, I try to save the export for later use, in the source server's Meta Data Services. It starts to save and then craps out with the following very useless error:
Error Source: Microsoft Data Transformation Services (DTS) Package
Error Description: General error -2147217355 (80041035)
Google turns up nothing on those number strings... anyone have any ideas, or failing that, a pointer to a tutorial page on how to create a data export script that includes the flexibility to change column names? Maybe I'm doing something wrong and don't realize it.www.sqldts.com is a good site to take a look. There might be something there.