You must Sign In to post a response.
  • Category: .NET

    How to Get all Stored Procedure from C#

    Hi

    I have Mysql Data Base with 50 Stored Procedure .

    1.How to Get all Stored Procedure without data using C# code only. No need design side only c# code .

    2.How to get Last 5 days created Stored procedure stored to one text file

    I need this Mysql Only without Data.
  • #762157
    Hello Kumar,

    I have never work on this type of situation. Still i can suggest you some links for reference :

    http://stackoverflow.com/questions/169330/simple-way-to-programmatically-get-all-stored-procedures

    http://stackoverflow.com/questions/1976248/how-do-i-list-all-non-system-stored-procedures

    http://www.sqlteam.com/article/scripting-database-objects-using-smo-updated


    Hope this will work for you.

    Regards,
    Nirav Lalan
    DNS Gold Member
    "Failure is the path of least persistence"

  • #762165
    Hi DotnetDeveloper,

    Implement the stuff whatever you want in database side like below.


    SELECT obj.Name as SPName,
    obj.create_date as SPCreationDate

    FROM sys.objects obj

    WHERE obj.create_date >= DATEADD(DAY, -5,GETDATE())


    and then you can write all the records in to text file after that.

    Hope this will helpful to you..

    --------------------------------------------------------------------------------
    Give respect to your work, Instead of trying to impress your boss.

    N@veen
    Blog : http://naveens-dotnet.blogspot.in/

  • #762169
    Hi

    Thanks for reply Nirav and navanee

    But My Requirement is Mysql only.

    For ex we can easily generated script in sql server I need same operation in my sql but only raised c# code only.

    Name : Dotnet Developer-2015
    Email Id :kumaraspcode2009@gmail.com

    'Not by might nor by power, but by my Spirit,' says the LORD Almighty.


Sign In to post your comments