dbTalk Databases Forums  

DTS Export to CSV

microsoft.public.sqlserver.programming microsoft.public.sqlserver.programming


Discuss DTS Export to CSV in the microsoft.public.sqlserver.programming forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Adam Stewart
 
Posts: n/a

Default DTS Export to CSV - 06-02-2004 , 04:31 AM






Hi all

i am having a very strange issue when trying to create a very simple dts package. I have a table (see sql below) and i have created a new sql dts package. In my package i have a sql connection to the db (this is fine) and a text file (source)(this is also fine). I then define a data pump task and use select * from table as the query. Preview returns the correct results. Now go to destination columns and click populate from source, execute and the list of available columns is blank. If i click on define columns, EM closes itself

Now if i list the columns explicitly in the sql statement i get the same issue, so i started removing the columns one by one. There is no one column that causes this issue, any large combination of columns will cause this behaviour. I have even tried ommiting the 'bit' columns in order to avoid having a 'calculated value' in my select statement, this does not sove the problem on its own (other columns must be ommited). The only conclusion i can draw is that i a being limited by the total width of the record that i am trying to write to the file. However this is no more than 2700, and i would be surprised to find out this is a boundary

Does anyone have any ideas, or has anyone experienced this themselves - and got around the issue

The recordset is small at the moment (less than 20 records)
Environment
Production SQL Server - multi Zeon processor, 8GB ram, scsii 160 drive
SQL server 2000 ent ed. result of select @@version

Microsoft SQL Server 2000 - 8.00.760 (Intel X86)
Dec 17 2002 14:22:05
Copyright (c) 1988-2003 Microsoft Corporatio
Standard Edition on Windows NT 5.0 (Build 2195: Service Pack 4

TIA

Adam Stewar

CREATE TABLE [dbo].[TrialUser]
[id] [int] IDENTITY (1, 1) NOT NULL
[FirstName] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[LastName] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[Address1] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[Address2] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[City] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[State] [char] (2) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[PostalCode] [varchar] (10) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[email] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[AgeRange] [varchar] (25) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[HouseholdIncome] [varchar] (25) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[CoffeeDaysPerWeek] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[CoffeeCupsPerDay] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[CoffeemakersOwned] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[Liked] [bit] NOT NULL
[WhyNotLiked] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[FavoriteBlend] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[MostEnjoyedFlavors] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[DescribeSenseo] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[PerfectCup] [bit] NOT NULL
[WhyNotPerfectCup] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[EveryDay] [bit] NOT NULL
[WhyNotEveryDay] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[RegularBasis] [bit] NOT NULL
[WhyNotRegularBasis] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[Recommend] [bit] NOT NULL
[WhyNotRecommend] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
[DateTimeCreated] [datetime] NULL
[DateTimeExported] [datetime] NULL
) ON [PRIMARY
G

ALTER TABLE [dbo].[TrialUser] ADD
CONSTRAINT [DF_TrialUser_FirstName] DEFAULT ('') FOR [FirstName]
CONSTRAINT [DF_TrialUser_LastName] DEFAULT ('') FOR [LastName]
CONSTRAINT [DF_TrialUser_Address1] DEFAULT ('') FOR [Address1]
CONSTRAINT [DF_TrialUser_Address2] DEFAULT ('') FOR [Address2]
CONSTRAINT [DF_TrialUser_City] DEFAULT ('') FOR [City]
CONSTRAINT [DF_TrialUser_State] DEFAULT ('') FOR [State]
CONSTRAINT [DF_TrialUser_PostalCode] DEFAULT ('') FOR [PostalCode]
CONSTRAINT [DF_TrialUser_Email] DEFAULT ('') FOR [email],
CONSTRAINT [DF_TrialUser_AgeRange] DEFAULT ('') FOR [AgeRange],
CONSTRAINT [DF_TrialUser_HouseholdIncome] DEFAULT ('') FOR [HouseholdIncome],
CONSTRAINT [DF_TrialUser_CoffeeDaysPerWeek] DEFAULT ('') FOR [CoffeeDaysPerWeek],
CONSTRAINT [DF_TrialUser_CoffeeCupsPerDay] DEFAULT ('') FOR [CoffeeCupsPerDay],
CONSTRAINT [DF_TrialUser_CoffeemakersOwned] DEFAULT ('') FOR [CoffeemakersOwned],
CONSTRAINT [DF_TrialUser_Liked] DEFAULT (0) FOR [Liked],
CONSTRAINT [DF_TrialUser_WhyNotLiked] DEFAULT ('') FOR [WhyNotLiked],
CONSTRAINT [DF_TrialUser_FavoriteBlend] DEFAULT ('') FOR [FavoriteBlend],
CONSTRAINT [DF_TrialUser_MostEnjoyedFlavors] DEFAULT ('') FOR [MostEnjoyedFlavors],
CONSTRAINT [DF_TrialUser_DescribeSenseo] DEFAULT ('') FOR [DescribeSenseo],
CONSTRAINT [DF_TrialUser_PerfectCup] DEFAULT (0) FOR [PerfectCup],
CONSTRAINT [DF_TrialUser_WhyNotPerfectCup] DEFAULT ('') FOR [WhyNotPerfectCup],
CONSTRAINT [DF_TrialUser_EveryDay] DEFAULT (0) FOR [EveryDay],
CONSTRAINT [DF_TrialUser_WhyNotEveryDay] DEFAULT ('') FOR [WhyNotEveryDay],
CONSTRAINT [DF_TrialUser_RegularBasis] DEFAULT (0) FOR [RegularBasis],
CONSTRAINT [DF_TrialUser_WhyNotRegularBasis] DEFAULT ('') FOR [WhyNotRegularBasis],
CONSTRAINT [DF_TrialUser_Recommend] DEFAULT (0) FOR [Recommend],
CONSTRAINT [DF_TrialUser_WhyNotRecommend] DEFAULT ('') FOR [WhyNotRecommend],
CONSTRAINT [DF_TrialUser_DateTimeCreated] DEFAULT (getdate()) FOR [DateTimeCreated],
CONSTRAINT [PK_TrialUser] PRIMARY KEY CLUSTERED
(
[id]
) ON [PRIMARY]
GO

Reply With Quote
  #2  
Old   
Narayana Vyas Kondreddi
 
Posts: n/a

Default Re: DTS Export to CSV - 06-02-2004 , 06:18 AM






You are probably running into this issue:
http://support.microsoft.com/default...b;en-us;814113
--
HTH,
Vyas, MVP (SQL Server)
http://vyaskn.tripod.com/
Is .NET important for a database professional?
http://vyaskn.tripod.com/poll.htm


"Adam Stewart" <anonymous (AT) discussions (DOT) microsoft.com> wrote

Hi all,

i am having a very strange issue when trying to create a very simple dts
package. I have a table (see sql below) and i have created a new sql dts
package. In my package i have a sql connection to the db (this is fine) and
a text file (source)(this is also fine). I then define a data pump task and
use select * from table as the query. Preview returns the correct results.
Now go to destination columns and click populate from source, execute and
the list of available columns is blank. If i click on define columns, EM
closes itself!

Now if i list the columns explicitly in the sql statement i get the same
issue, so i started removing the columns one by one. There is no one column
that causes this issue, any large combination of columns will cause this
behaviour. I have even tried ommiting the 'bit' columns in order to avoid
having a 'calculated value' in my select statement, this does not sove the
problem on its own (other columns must be ommited). The only conclusion i
can draw is that i a being limited by the total width of the record that i
am trying to write to the file. However this is no more than 2700, and i
would be surprised to find out this is a boundary.

Does anyone have any ideas, or has anyone experienced this themselves - and
got around the issue?

The recordset is small at the moment (less than 20 records).
Environment:
Production SQL Server - multi Zeon processor, 8GB ram, scsii 160 drives
SQL server 2000 ent ed. result of select @@version:

Microsoft SQL Server 2000 - 8.00.760 (Intel X86)
Dec 17 2002 14:22:05
Copyright (c) 1988-2003 Microsoft Corporation
Standard Edition on Windows NT 5.0 (Build 2195: Service Pack 4)


TIA

Adam Stewart

CREATE TABLE [dbo].[TrialUser] (
[id] [int] IDENTITY (1, 1) NOT NULL ,
[FirstName] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[LastName] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[Address1] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[Address2] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[City] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[State] [char] (2) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[PostalCode] [varchar] (10) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[email] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[AgeRange] [varchar] (25) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL ,
[HouseholdIncome] [varchar] (25) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[CoffeeDaysPerWeek] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[CoffeeCupsPerDay] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[CoffeemakersOwned] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[Liked] [bit] NOT NULL ,
[WhyNotLiked] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
,
[FavoriteBlend] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT NULL
,
[MostEnjoyedFlavors] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS
NOT NULL ,
[DescribeSenseo] [varchar] (50) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[PerfectCup] [bit] NOT NULL ,
[WhyNotPerfectCup] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[EveryDay] [bit] NOT NULL ,
[WhyNotEveryDay] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[RegularBasis] [bit] NOT NULL ,
[WhyNotRegularBasis] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS
NOT NULL ,
[Recommend] [bit] NOT NULL ,
[WhyNotRecommend] [varchar] (255) COLLATE SQL_Latin1_General_CP1_CI_AS NOT
NULL ,
[DateTimeCreated] [datetime] NULL ,
[DateTimeExported] [datetime] NULL
) ON [PRIMARY]
GO

ALTER TABLE [dbo].[TrialUser] ADD
CONSTRAINT [DF_TrialUser_FirstName] DEFAULT ('') FOR [FirstName],
CONSTRAINT [DF_TrialUser_LastName] DEFAULT ('') FOR [LastName],
CONSTRAINT [DF_TrialUser_Address1] DEFAULT ('') FOR [Address1],
CONSTRAINT [DF_TrialUser_Address2] DEFAULT ('') FOR [Address2],
CONSTRAINT [DF_TrialUser_City] DEFAULT ('') FOR [City],
CONSTRAINT [DF_TrialUser_State] DEFAULT ('') FOR [State],
CONSTRAINT [DF_TrialUser_PostalCode] DEFAULT ('') FOR [PostalCode],
CONSTRAINT [DF_TrialUser_Email] DEFAULT ('') FOR [email],
CONSTRAINT [DF_TrialUser_AgeRange] DEFAULT ('') FOR [AgeRange],
CONSTRAINT [DF_TrialUser_HouseholdIncome] DEFAULT ('') FOR
[HouseholdIncome],
CONSTRAINT [DF_TrialUser_CoffeeDaysPerWeek] DEFAULT ('') FOR
[CoffeeDaysPerWeek],
CONSTRAINT [DF_TrialUser_CoffeeCupsPerDay] DEFAULT ('') FOR
[CoffeeCupsPerDay],
CONSTRAINT [DF_TrialUser_CoffeemakersOwned] DEFAULT ('') FOR
[CoffeemakersOwned],
CONSTRAINT [DF_TrialUser_Liked] DEFAULT (0) FOR [Liked],
CONSTRAINT [DF_TrialUser_WhyNotLiked] DEFAULT ('') FOR [WhyNotLiked],
CONSTRAINT [DF_TrialUser_FavoriteBlend] DEFAULT ('') FOR [FavoriteBlend],
CONSTRAINT [DF_TrialUser_MostEnjoyedFlavors] DEFAULT ('') FOR
[MostEnjoyedFlavors],
CONSTRAINT [DF_TrialUser_DescribeSenseo] DEFAULT ('') FOR [DescribeSenseo],
CONSTRAINT [DF_TrialUser_PerfectCup] DEFAULT (0) FOR [PerfectCup],
CONSTRAINT [DF_TrialUser_WhyNotPerfectCup] DEFAULT ('') FOR
[WhyNotPerfectCup],
CONSTRAINT [DF_TrialUser_EveryDay] DEFAULT (0) FOR [EveryDay],
CONSTRAINT [DF_TrialUser_WhyNotEveryDay] DEFAULT ('') FOR [WhyNotEveryDay],
CONSTRAINT [DF_TrialUser_RegularBasis] DEFAULT (0) FOR [RegularBasis],
CONSTRAINT [DF_TrialUser_WhyNotRegularBasis] DEFAULT ('') FOR
[WhyNotRegularBasis],
CONSTRAINT [DF_TrialUser_Recommend] DEFAULT (0) FOR [Recommend],
CONSTRAINT [DF_TrialUser_WhyNotRecommend] DEFAULT ('') FOR
[WhyNotRecommend],
CONSTRAINT [DF_TrialUser_DateTimeCreated] DEFAULT (getdate()) FOR
[DateTimeCreated],
CONSTRAINT [PK_TrialUser] PRIMARY KEY CLUSTERED
(
[id]
) ON [PRIMARY]
GO



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.