Results 1 to 4 of 4

Thread: trying to insert records into SQL database

Hybrid View

  1. #1
    Super Moderator FunkyDexter's Avatar
    Join Date
    Apr 2005
    Location
    An obscure body in the SK system. The inhabitants call it Earth
    Posts
    7,957

    Re: trying to insert records into SQL database

    I had a similar problem and Si pointed me at a post of JMcIlhinney's. That might be your problem


    edit> also, as an aside, you don't need to open and close your connection each time you run the insert. It would be more efficient to open it before the loop and close it afterwards.
    The best argument against democracy is a five minute conversation with the average voter - Winston Churchill

    Hadoop actually sounds more like the way they greet each other in Yorkshire - Inferrd

  2. #2

    Thread Starter
    New Member
    Join Date
    Jul 2007
    Posts
    2

    Re: trying to insert records into SQL database

    Thanks for the suggestion. I found that setting & changed it as described, but still no luck. I don't think this could be the problem anyway, as I was able to manually add a record into the table & that one persisted. Since this is my first time around, perhaps it is something more basic, like perhaps I'm not connected to the correct table or some such thing.

    Here's an example of what one of the cmd.CommandText looks like:

    "INSERT INTO StampStaticInfo (ScottNo,Denomination,Description) VALUES ('2',0.10,'Washington - black')"

    Any suggestions?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width