database

Merging data between databases

Suppose I have two distinct databases with identical schemas but different data. I want to merge the data between the two databases by adding the data from one into the other. Foreign key relationships, etc. need to be maintained when the data is migrated. Are there any tools (or databases that have built-in tools) to make this job fair...

Best way to control shopping carts

Hi I am trying to build a simple shopping cart, i read about controlling them and see there are 3 ways to control them. one is cookies, another one is session based, and last one is database model. I am wondering which one is better choice ? some told that database method is better but its harder too. I am also looking for database model...

Migrating MySQL to a table with different structure

Hi all, My company's currently moving our databases around, shifting one set of tables out from the old MySQL instance into the new. We've done some development prior to this migration, and some tables' structure has been altered from the original (eg. columns were dropped). So currently I've dumped the data from the old database and ...

Pros and cons of building apps with proprietary database systems

I've been interested in 4D SAS' database product for a long time, though have barely touched it in eons. In considering what tools to use for application development, especially one that will require a database component, what should be looked for when considering open-source tools like MySQL and PostgreSQL vs proprietary solutions like...

How to copy from a database to a text file using VBScript?

I have an example in C# code, but it is using streamWriter. It must be involving with FileSystemObject rite. If yes, what are methods should I use? I want to code using VBScript WSH, and my database is MS SQL Server 2005. Any solution, references, or guide are helpful. using (StreamWriter tw = File.AppendText("c:\\INMS.txt")) { us...

What is the purpose of Active Records?

I'm tinkering with CodeIgniter and have come across Active Records for the first time. At first I dismissed it as something for people who don't really know how to write SQL. I realise now that my analysis was flawed and Active Records are pretty prominent, especially in Rails. But what purpose do Active Records hold? Is it to abstra...

Using Rails Migration on different database than standard "production" or "development"

Hi! I have a rails project running that defines the standard production:, :development and :test DB-connections in config/database.yml In addition I have a quiz_development: and quiz_production: definition pointing to a differnet host/db/user/password My goal now is to define a Migration that uses "quiz_#{RAILS_ENV}`" as its database ...

tracking changes made in database structure

Hi all I'm fairly new to MySQL. I need to know how would i be able to track any changes in my database. I need a way to find out exactly what changes I made to the database so I can implement the same changes on another server. For example, if I added a new field in one of the tables, I would like to know what field that was so that I...

How to open a core data database?

Is there any way in which I can view my core data database without having to load it programatically through the code?! ...

Generic Database setup script

We are using SQL and have a script file to generate the Database and tables. I am trying to write a generic script which will execute on all dev/prod machines The file name which i am giving is FILENAME = N'c:\Program Files\Microsoft SQL Server\MSSQL.3\MSSQL\DATA\DBname.mdf' It works on my machine but not on all the dev machine since al...

Why is Select 1 faster than Select count(*)?

In Oracle, when querying for row existence, why is Select 1 fast than Select count(*)? ...

Real Time Analytics Reporting

We are gathering a large amount of custom analytics data. We will be using Hadoop for running batch processes on the analytics. What real time reporting tool/datastore might we consider for storing and generating customized real time web based (as in displayed in a web page not web analytics) reporting. We are considering the rrdtool....

How to generate basic CRUD functionality in python given a database tables...

Hello, I want to develop a desktop application using python with basic crud operation. Is there any library in python that can generate a code for CRUD functionality and user interface given a database table. ...

python database / sql programming - where to start

What is the best way to use an embedded database, say sqlite in Python: Should be small footprint. I'm only needing few thousands records per table. And just a handful of tables per database. If it's one provided by Python default installation, then great. Must be open-source, available on Windows and Linus. Better if SQL is not wri...

Adding relations to an Access Database.

I have an MS Access database with plenty of data. It's used by an application me and my team are developing. However, we've never added any foreign keys to this database because we could control relations from the code itself. Never had any problems with this, probably never will either. However, as development has developed further, I ...

Automating DBCC CHECKDB

I am currently trying to script a job on SQL Server 2005 that will automate the DBCC CHECKDB process. Basically, I am using a cursor to run through and run DBCC CHECKDB on every database on an instance. Sometimes it works, running through every database and logging the errors in a table I have designed for that purpose and sometimes it...

How to create my own recommendation engine?

i am intrested in recommendation engines these days and i wanna improve myself in this area.I am currently reading Programming Collective Intelligence (i think this is the best book about this subject) from OReilly (just started).But i dont have any ideas how to implement engine(what i mean by no idea dont know how to start).Lets say i h...

Database and ERP

I am trying to master a new ERP application. Basically I have good functional knowledge. And I was advised to learn SQL .I do not know where to start. I have two books .Below are the urls which has the TOC of each book. Which book should I read first? The idea is to get a good understanding of the relationship between ERP and database a...

Database Design

I am making a webapp right now and I am trying to get my head around the database design. I have a user model(username (which is primary key), password, email, website) I have a entry model(id, title, content, comments, commentCount) A user can only comment on an entry once. What is the best and most efficient way to go about doing thi...

asp.net mvc model - my own database

The tutorials I have come across usually let you create a dababase from scratch creating a .mdf file or something and so on. However, what if I already have a SQL Server Express set up with the needed database? How do I tell my model to use that database? Right now, all my model contains is basically some classes that execute stored p...