{"id":14070879,"url":"https://github.com/cavo789/vbs_sql_extract_stored_proc","last_synced_at":"2026-04-21T22:03:10.135Z","repository":{"id":101354668,"uuid":"130841202","full_name":"cavo789/vbs_sql_extract_stored_proc","owner":"cavo789","description":"VBS script for extracting every stored procedure from SQL Server databases into flat files on disk","archived":false,"fork":false,"pushed_at":"2021-11-01T21:52:06.000Z","size":90,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-31T21:44:26.525Z","etag":null,"topics":["documentation","markdown","marknotes","sql-server","stored-procedures","vbscript"],"latest_commit_sha":null,"homepage":"","language":"VBScript","has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cavo789.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-04-24T11:06:48.000Z","updated_at":"2025-10-06T09:24:16.000Z","dependencies_parsed_at":null,"dependency_job_id":"4ec62697-a7d7-4cb0-bbe7-f7da44917c55","html_url":"https://github.com/cavo789/vbs_sql_extract_stored_proc","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cavo789/vbs_sql_extract_stored_proc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cavo789%2Fvbs_sql_extract_stored_proc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cavo789%2Fvbs_sql_extract_stored_proc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cavo789%2Fvbs_sql_extract_stored_proc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cavo789%2Fvbs_sql_extract_stored_proc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cavo789","download_url":"https://codeload.github.com/cavo789/vbs_sql_extract_stored_proc/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cavo789%2Fvbs_sql_extract_stored_proc/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32112030,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-21T11:25:29.218Z","status":"ssl_error","status_checked_at":"2026-04-21T11:25:28.499Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["documentation","markdown","marknotes","sql-server","stored-procedures","vbscript"],"created_at":"2024-08-13T07:08:09.002Z","updated_at":"2026-04-21T22:03:10.093Z","avatar_url":"https://github.com/cavo789.png","language":"VBScript","funding_links":[],"categories":["VBScript"],"sub_categories":[],"readme":"# sql_extract_stored_proc\n\n![Banner](./banner.svg)\n\n\u003e VBS script for extracting every stored procedures from SQL Server databases into flat files on disk.\n\n## Table of Contents\n\n- [Description](#description)\n- [Install](#install)\n- [Usage](#usage)\n- [Author](#author)\n- [License](#license)\n\n## Description\n\nConnect to a SQL Server database, obtain the list of\nstored procedures (USPs) in that db (process all schemas), get\nthe code in these stored procs and save them as text files (.md)\n\nAt the end, we'll have as many files as there are stored procs\nin the database. One text file by stored proc.\n\nFiles will be saved under the /results folder.\n\nRunning this script against a SQL Server DB will take a local\ncopy of your USPs : you can then take a backup of them easily.\n\nNOTE : The user should have enough permissions on SQL Server side\nfor retrieving the code of the stored procedure. This is never the\ncase of a \"simple\" user and requires advanced permissions. So; if\ngenerated files are empty, first check user's permissions (or directly\nuse an \"admin\" user to check if it's better).\n\nNOTE : files are stored as a .md file to make easier to include them into [marknotes](https://github.com/cavo789/marknotes), a documentation tool.\n\n## Install\n\nJust get a copy of the sql_extract_stored_proc.vbs file and store it onto your computer.\n\n## Usage\n\nYou'll need to provide the script with four variables :\n\n- The SQL Server name (f.i. `myServer`)\n- The name of the database (f.i. `dbOfMine`)\n- The user to use for the connection (f.i. `userAdmin`)\n- The password for this user (f.i. `my$ecret`)\n\nYou can pass these parameters as command line arguments\n\n```\ncscript sql_extract_stored_proc.vbs \"myServer\" \"dbOfMine\" \"userAdmin\" \"my$ecret\"\n```\n\n(so you can reuse this script for other databases)\n\nor by updating, in the source code, the constants that you can find at the top of the file. If you do that, you don't need to specify credentials anymore and you can just fire the script like :\n\n```\ncscript sql_extract_stored_proc.vbs\n```\n\nWhen the script is done, you'll get a folder called `results´ with one .md file by stored procedure. The .md file is a markdown file format with the source code of the stored procedure.\n\n## Author\n\nChristophe Avonture\n\n## Contribute\n\nPRs not accepted.\n\n## License\n\n[MIT](LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcavo789%2Fvbs_sql_extract_stored_proc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcavo789%2Fvbs_sql_extract_stored_proc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcavo789%2Fvbs_sql_extract_stored_proc/lists"}