User Profile

Collapse

Profile Sidebar

Collapse
PaullyB
PaullyB
Last Activity: Jun 17 '09, 12:42 PM
Joined: Nov 17 '08
Location: Johannesburg SA
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • PaullyB
    replied to Import CSV file into SQL using C#
    in .NET
    Thanks.
    This has solved my problems...
    See more | Go to post

    Leave a comment:


  • PaullyB
    replied to Import CSV file into SQL using C#
    in .NET
    Thanks, But I'm not sure what you mean by this....
    See more | Go to post

    Leave a comment:


  • PaullyB
    replied to Import CSV file into SQL using C#
    in .NET
    Thanks for your reply

    The CSV file comes from a 3rd party source and at this stage it is not possible to remove the embedded commas. the fields with embedded commas are qualified by " " (double quotes) however the fields are being separated at the commas.
    is there any code i can add to get the streamreader to recognise the qualified fields?...
    See more | Go to post

    Leave a comment:


  • PaullyB
    started a topic Import CSV file into SQL using C#
    in .NET

    Import CSV file into SQL using C#

    Hi There
    I'm trying to insert a CSV file into SQL Database using C#. I can read the csv file and insert it into the table, however any fields with an embebbed comma are not being read correctly. How can I get around this.
    Below is the code that I'm using:

    Code:
    protected void cmdUploadFile_Click(object sender, EventArgs e)
            {
                conStr = "workstation id=" + ServerName + ";packet
    ...
    See more | Go to post
No activity results to display
Show More
Working...