To import a comma separated file or CSV file using the database, you should first create a table on the SQL server. Tables that are created is useful for importing CSV file.
Open the SQL studio and sign in using the right credentials and do a right click on the desired target database. You can right click on the whole DB, instead of the table in the DB.
The wizard with introduction page will be opened. So, when the page is opened simply proceed to click on next. This screen is shown for the selection of DS(data source) from the list that is shown. From this data source click on the flat file which is shown as a drop down and click browse.
You will see an explorer that is opened out choose the CSV file from the given list, to ensure that you are selecting the file type to choose the file type as CSV
After selecting the designated file, please take few mins to configure on importing the data inside DB by selecting the list of columns displayed before choosing next
After this is done, kindly review the columns you could see advanced options. This evaluation is needed before you import a CSV file.
If you find some character that is larger than fifty, request SQL for inspecting the columns in that file. This final assessment can be done by clicking on the Suggest type button on the SQL server. SQL servers are instructed only to examine the first hundred Rows. An error will be pointed during these examine process.
You could be redirected to one of the preview section in the DS (data source).
After you did the final evaluation on the preview section and if it is fine you can select the destination DB
In the step, you can select the destination DB. SQL will normally select the desired tables. Else if you are not satisfied, then you are required to create your own table or you would like to choose an alternate table that is shown in the DB then if you are fine click on the desired column in the DB
You must save it as an SSIS package. You can even leave by not choosing that option and proceed to next
You will see a verification screen. If it's fine, then you can import by clicking on the finish button