
Research
Security News
The Growing Risk of Malicious Browser Extensions
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
< badges will go here >
This is a python utility that allows users to import/export data to/from a database.
This library began as a wrapper around SQL Server's BCP utility. It makes some assumptions about parameters to simplify the interface and allow the user to work natively in python. Though it currently supports MSSQL, there are plans to extend support to other database dialects.
This library purposely requires no python packages outside of the standard library, beyond testing and documentation needs. The intention is to maintain this status. However, you will need to have the appropriate command line utilities installed for the specific database dialects with which you'll interact. For example, if your database is a MS SQL SERVER instance, you'll need BCP installed. Consult the table below for further documentation, including download files and instructions.
RDBMS | Utility | Documentation / Installation |
---|---|---|
MS SQL Server | BCP | https://docs.microsoft.com/en-us/sql/tools/bcp-utility |
This library is still in development. So you'll have to build it from
source in the meantime. I'll soon get around to publishing it on pypi,
in which case you'll be able to install it using pip
pip install bcp
Import data:
import bcp
conn = bcp.Connection(host='HOST', driver='mssql', username='USER', password='PASSWORD')
my_bcp = bcp.BCP(conn)
file = bcp.DataFile(file_path='path/to/file.csv', delimiter=',')
my_bcp.load(input_file=file, table='table_name')
Export data:
import bcp
conn = bcp.Connection(host='HOST', driver='mssql', username='USER', password='PASSWORD')
my_bcp = bcp.BCP(conn)
file = bcp.DataFile(file_path='path/to/file.csv', delimiter=',')
my_bcp.dump(query='select * from sys.tables', output_file=file)
For the full documentation, please visit: https://bcp.readthedocs.io/en/latest/
FAQs
This is a python utility that allows users to import/export data to/from a database.
We found that bcp demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
Research
Security News
An in-depth analysis of credential stealers, crypto drainers, cryptojackers, and clipboard hijackers abusing open source package registries to compromise Web3 development environments.
Security News
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.