Results 1 to 5 of 5

Thread: [RESOLVED] SQL Return Value

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Sep 2008
    Posts
    162

    Resolved [RESOLVED] SQL Return Value

    how can i return the number of records processed from an sql procedure wether it is a select or update/insert query and how can i receive it in the calling method in vb .net.

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: SQL Return Value

    If you call Fill or Update on a DataAdapter or ExecuteNonQuery on a Command, they will return the number of records affected.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Addicted Member
    Join Date
    Sep 2008
    Posts
    162

    Re: SQL Return Value

    please help me with the syntax.

  4. #4
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: SQL Return Value

    Follow the Database FAQ link in my signature and you'll find various ADO.NET resources that can show you what to do.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  5. #5

    Thread Starter
    Addicted Member
    Join Date
    Sep 2008
    Posts
    162

    Re: SQL Return Value

    thanks

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