Author |
Topic |
Exir
Posting Yak Master
151 Posts |
Posted - 2009-01-01 : 15:09:53
|
I have an almost large csv file and want to import it into the sql server 2005 but it is not possible!I tell you what i do for importing step by step and please guide me if i do wrongly in each step:1-I right clicked on a database, chose task/import data...2-in the import/export wizard, in the data source part, i chose flat file source as data source _ browsed and chose the csv file for the filr name and didnt change the format and clicked on the next button3- in the destination part, chose SQL Native client as destination,and cliked on new... button to create a new data base for destination and named it as new. then clicked next button4- finishit started to convert, the status of options before validating were success and after it(prepare for execute, pre execute,copying [new].[dbo].[amlak], post execte and clean up) were stopped and status of Execute was errorthe Error was:TITLE: SQL Server Import and Export Wizard------------------------------Error 0xc002f210: Preparation SQL Task: Executing the query "CREATE TABLE [new].[dbo].[amlak] ([C__REG] string [DT_STR],[REGION_NO] string [DT_STR],[BLOCK_NO] string [DT_STR],[LAND_NO] string [DT_STR],[APARTMENT_NO] string [DT_STR],[OLD_REG_NO] string [DT_STR],[FIRST_NAME] string [DT_STR],[LAST_NAME] string [DT_STR],[PATH_ADDRESS] string [DT_STR],[PLATE_NO] string [DT_STR],[PHONE_NO] string [DT_STR])" failed with the following error: "Incorrect syntax near 'DT_STR'.". Possible failure reasons: Problems with the query, "ResultSet" property not set correctly, parameters not set correctly, or connection not established correctly. please help me. |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-01-02 : 01:29:31
|
did you check the query it produced when you clicked new?what was query it generated? |
 |
|
Exir
Posting Yak Master
151 Posts |
Posted - 2009-01-02 : 01:43:27
|
the qury is this:CREATE TABLE [new].[dbo].[amlak] ([C__REG] NVARCHAR(50),[REGION_NO] NVARCHAR(50),[BLOCK_NO] NVARCHAR(50),[LAND_NO] NVARCHAR(50),[APARTMENT_NO] NVARCHAR(50),[OLD_REG_NO] NVARCHAR(50),[FIRST_NAME] NVARCHAR(50),[LAST_NAME] NVARCHAR(50),[PATH_ADDRESS] NVARCHAR(50),[PLATE_NO] NVARCHAR(50),[PHONE_NO] NVARCHAR(50))it seems ok. isnt it? |
 |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-01-02 : 02:03:26
|
i think the probelm is because DT_STR is missing values for codepage and length parameters. try giving 50,1252 as values |
 |
|
Exir
Posting Yak Master
151 Posts |
Posted - 2009-01-02 : 02:57:02
|
where should i give 50,1252?i made a database by my own and didnt click on new button to made it. this time validating had error and executing status was success.the error is:- Validating (Error)MessagesError 0xc00470fe: Data Flow Task: The product level is insufficient for component "Source - amlaktehran_csv" (1). (SQL Server Import and Export Wizard) Error 0xc00470fe: Data Flow Task: The product level is insufficient for component "Data Conversion 1" (71). (SQL Server Import and Export Wizard) |
 |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-01-02 : 03:16:08
|
what's your source file version? |
 |
|
Exir
Posting Yak Master
151 Posts |
Posted - 2009-01-02 : 03:30:26
|
I think it is excel2003 but i am not sure. some body gave the file on a cd to me. how can i find the version? sorry if my question is so primary |
 |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-01-02 : 03:49:25
|
quote: Originally posted by Exir I think it is excel2003 but i am not sure. some body gave the file on a cd to me. how can i find the version? sorry if my question is so primary
http://blogs.msdn.com/michen/archive/2006/11/11/ssis-product-level-is-insufficient.aspx |
 |
|
Exir
Posting Yak Master
151 Posts |
Posted - 2009-01-02 : 08:32:14
|
when i looked at computer management the sql integration service was not there, does it mean i should install my sql server again? and not having sql server ingeration service is the reason of these errors? :( |
 |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-01-02 : 08:46:43
|
quote: Originally posted by Exir when i looked at computer management the sql integration service was not there, does it mean i should install my sql server again? and not having sql server ingeration service is the reason of these errors? :(
what does that link say? |
 |
|
Exir
Posting Yak Master
151 Posts |
Posted - 2009-01-02 : 15:29:32
|
sorry, my english is not that much good. what i got from the link was that if during instalation, i didnt check SSIS part, the importation dosent work. is it correct? if yes, should i install all of sql again or i can add this part separately? |
 |
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2009-01-03 : 06:59:37
|
quote: Originally posted by Exir sorry, my english is not that much good. what i got from the link was that if during instalation, i didnt check SSIS part, the importation dosent work. is it correct? if yes, should i install all of sql again or i can add this part separately?
Yup thats correctif you havent installed ssis, you can run setup cd again and choose only integration services from menu, you dont need to install everything again. |
 |
|
|