Hello,
I am trying to import data from a csv file to sql server table. I am importing based off a ssis package with data conversion. Here is ddl for the table:
CREATE TABLE [dbo].[Email](
[ID] [int] IDENTITY(1,1) NOT NULL,
[IP] [varchar](30) NULL,
[Response] [varchar](900) NULL,
[CreatedAt] [datetime] NULL,
[FirstName] [nvarchar](60) NULL,
[LastName] [nvarchar](60) NULL,
[Title] [nvarchar](60) NULL,
[ComapnyName] [nvarchar](60) NULL,
[TypeOfBusiness] [nvarchar](60) NULL,
[Address] [nvarchar](60) NULL,
[City] [nvarchar](60) NULL,
[State] [nvarchar](60) NULL,
[ZipCode] [nvarchar](20) NULL,
[EmailAddress] [nvarchar](60) NULL,
[VerifyEmailAddress] [nvarchar](60) NULL,
[PhoneNumber] [nvarchar](24) NULL,
[PhoneExtension] [nvarchar](20) NULL,
[PromotialCode] [nvarchar](60) NULL,
[HowDidHear] [nvarchar](60) NULL,
[NatureOfInquiry] [nvarchar](60) NULL,
[AdditionalComments] [nvarchar](4000) NULL,
[SCRM] [text] NULL,
[Prefix] [nvarchar](30) NULL,
CONSTRAINT [Email] PRIMARY KEY CLUSTERED
(
[ID] ASC
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
SET ANSI_PADDING OFF
GO
ALTER TABLE [dbo].[Email] ADD CONSTRAINT [DF_Email_GetdateValue] DEFAULT (getdate()) FOR [CreatedAt]
GO
In the conversion I used String[DT_STR] for IP column and used Unicode String[DT_WSTR] for the rest of the columns. The mapping was good and the insert was also successful but it shows values in double quotes for the following fields
ComapnyName, Address,City,State and additionalcomments
but showing correctly for the remaining fields.
Am I doing something wrong in the conversion?
Thanks a lot for the help in advance