Wrox Programmer Forums
Go Back   Wrox Programmer Forums > SQL Server > SQL Server 2000 > SQL Server 2000
|
SQL Server 2000 General discussion of Microsoft SQL Server -- for topics that don't fit in one of the more specific SQL Server forums. version 2000 only. There's a new forum for SQL Server 2005.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server 2000 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old November 30th, 2006, 06:28 AM
Authorized User
 
Join Date: Nov 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default Splitting columns and inserting to a Table

Hi all,
       here i have a requirement to insert CSVs to a table which has 4 Parameters.
The values are as given below
Parameter1
'06276100011,06276100012,06276100013'
Parameter2
'20061003,20061004,20061005'
Parameter3
'CSUCH,CSUCH,CSUCH'
Parameter4
'373944015,395468826,397600221'

But i want this columns should be inserted in to a single table, say Table1 and the output should look like this(Select * from Table1),

DocID RecDate Verifier MemID
--------------------------------------------------------------
06276100011 20061003 CSUCH 373944015
06276100012 20061004 CSUCH 395468826
06276100013 20061005 CSUCH 397600221

Thanks in advance...



praveen KN
__________________
praveen KN
 
Old November 30th, 2006, 02:58 PM
Friend of Wrox
 
Join Date: Oct 2006
Posts: 475
Thanks: 0
Thanked 9 Times in 9 Posts
Default

You say "Paremater"... is this data being passed in from a GUI in the form of 4 separate parameter blocks as your post seems to indicate? If so, what is the maximum/minimum number of CSV's per parameter? Will it always be 3 as in your example? Or, is this data coming in from a file? If it's coming from a file, please post a dozen lines of data from the file

--Jeff Moden
 
Old December 1st, 2006, 02:59 AM
Authorized User
 
Join Date: Nov 2006
Posts: 10
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi,
   Yes, Data is coming in from a file. Actually i have only this much data as of now in the file. But all columns are of fixed length.

praveen KN
 
Old December 1st, 2006, 08:16 AM
Friend of Wrox
 
Join Date: Oct 2006
Posts: 475
Thanks: 0
Thanked 9 Times in 9 Posts
Default

Like I said, please post a dozen rows of the file as they are in the file so we can help... thanks.

--Jeff Moden





Similar Threads
Thread Thread Starter Forum Replies Last Post
Fixed table columns darkhalf HTML Code Clinic 1 August 27th, 2008 02:05 AM
Sort Table Columns by Table Header Attribute omrieliav XSLT 4 June 7th, 2006 01:05 AM
Splitting table data patingsadagat SQL Server 2000 7 June 2nd, 2006 03:09 AM
Splitting Table into more efficient structure MauiSpud Access 7 May 12th, 2006 07:35 AM
copying from table 1 inserting in table 2 gilgalbiblewheel Java GUI 0 September 15th, 2004 03:40 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.