I want to export bulk of records from a table in Sqlserver database to a file and after that i want to import that file to another table in another database .
my project is Asp.net
my Database is Sqlserver 2008
how do i can do this and what kind of file is faster to use?(XML,TXT,...)
thanks so much
You can use bcp utility that comes along with sqlserver. More details at http://msdn.microsoft.com/en-us/library/aa337544.aspx
in sql server management
Right click on DB then select task->generate script
follow wizard....
Related
I am trying to import MS ACCESS Database tables into Teradata 13.0 using automated script. Basically a job which will import all tables from MS-ACCESS to related tables in Teradata. I searched on internet but no luck. So lease let me know if its possible.
Thanks
export each table to csv file .
Import that file to Teradata using any one of its utilities ( ex : fastload or sql assistant ).
Or with TPT you can connect to Ms access via odbc and load to Teradata.
you can check manuals.
i have created my DB in plesk control panel then genarate script from local to run it in query to restore database , all work done , succesfuly connceted to DB , just now it cant find my tables and store procedures as i ran the query. what is the best way to upload my db ?
For MySQL databases Plesk has built-in support of phpMyAdmin. Just open it and choose to import DB in top menu. You may need to have phpMyAdmin installed locally to export local DB in a file. Alternatively I think you can use mysqlbackup tool or read phpMyAdmin documentation for more details about import file format.
How can I convert my Access database (.accdb) to an SQLite database(.sqlite)?
May be you can use several step algoritm:
1. Export (convert) Access table or query to Excel file
2. Save Excel file as CSV file.
3. Use any SQLLite manager (for example, phpLiteAdmin) to import data from CSV file to exist SQLLite table.
Except Android and IOS, that use SQLLite, there are still webhostings, that use no more database engine, except for SQLLite.
1) If you want to convert a structure of db you shoud use any DB-modeling tools:
create new model from existing Access Database
generate sql scripte for creating SQLite database
use this script in SQL helper
2) If you want to import data from Access Database to your android app. I think you can do case #1, migrate all data from Access Database to temporary SQLite database, save it to asset folder and rewrite from asset to internal SQLite database during first app. start
is there any tool that can compare data from ms-access database table with sqlite table and update it if finds it updated and insert if not found?
Thanks in advance
There aren't any good tool that allows one click conversion from one db to antoher, so created a utility in c# for the same.
I'm used to MySQL and PHPMyAdmin - I had to switch over to MSSQL for an ASP.net project, and I'm having tons of trouble. I'm using the express version of SQL 2008, with SQL Server Management Studio. The following are 2 questions I've been struggling with for a while:
1) How do I export the DB schema for the database? The table structure, etc.?
2) How do I export all the data in the database?
Ideally I'd like to have a .sql file that can be run wherever I need the schema or data duplicated, for example a co-worker's computer for a shared project, or online when the project is being hosted.
Thanks!
1) How do I export the DB schema for the database? The table structure, etc.?
INFORMATION_SCHEMA is your friend
SELECT * FROM INFORMATION_SCHEMA.TABLES
http://www.mssqltips.com/tutorial.asp?tutorial=179
http://weblogs.asp.net/jgalloway/archive/2006/07/07/455797.aspx
http://preetul.wordpress.com/2009/06/09/sql-server-information_schema/
Otherwise, if you want something pretty looking, download the 14 day trial of SQL Doc (part of SQL Toolbelt) here:
http://www.red-gate.com/products/SQL_Professional_Toolbelt/index.htm
"2) How do I export all the data in the database?"
In what form? .bak files are typically the most useful. http://www.sqlteam.com/article/backup-and-restore-in-sql-server-full-backups
Or were you looking to move the data into MYSQL or Excel or some other program? If you want to move data to MYSQL check here: http://www.google.com/search?q=mssql+to+mysql