Create a table according the fieldlist


i need to create a table in a database according a fieldlist (received from a flat file). fieldlists and datatypes are read in depending on which db should be created. i already define the parameters (ID, tablename, schema, database and filetype). how can i do this in a procedure?

thanks in advance

more ▼

asked Jun 07, 2012 at 09:40 AM in Default

avatar image

10 1 1 1

Can you please specify the structure of the file? Would there be one file for each table? The more information you give, the more better help you get :-)

Jun 07, 2012 at 11:03 AM Usman Butt

Hi Usman,

it's one file for each table. i already created the procedure that reads the file and stores the information on the right database (CreateStructureDropObject). Now i need to create the table in the right database. The structure of the database is described by the parameters.

thanks in advance.

Jun 07, 2012 at 12:35 PM Alexmarvel

Can you please share the information of those parameters and how they are stored in the database? Based upon that we could hint you how it could be done.

Jun 07, 2012 at 12:54 PM Usman Butt
(comments are locked)
10|1200 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

SQL Server Central

Need long-form SQL discussion? SQLserverCentral.com is the place.



asked: Jun 07, 2012 at 09:40 AM

Seen: 868 times

Last Updated: Jun 07, 2012 at 01:06 PM

Copyright 2018 Redgate Software. Privacy Policy