database

MSDataShape on Windows VISTA

I have a connection to an access database that implements MSDataShape that works perfectly on Windows XP, now when i try to run it on Windows Vista it game me an error. The error on vista error: Error # -2147467259 [Microsoft][ODBC Driver Manager] Data source name not found and no default driver specified The same code works perfectl...

How do I grow a database file?

I am trying to grow a database using the following the code below. However I get the following error. How do I check for size (3600MB) and grow it if necessary? USING MyDatabase ALTER DATABASE MyDatabase MODIFY FILE (NAME = MyDatabase_data, SIZE = 3600MB) Error: MODIFY FILE failed. Specified size is less than or equal to current si...

Add new columns in asp .net application

I am facing this question in a new little project: The system to be built will allow user to add new columns to a table in the system, and then the user will be able to maintain the data, I think there is two ways to implement this: 1) create a few tables including "columns" table with "columnName" "columnValue" "datatype" etc to store t...

What is the default Precision and Scale for a Number in Oracle?

When creating a column of type NUMBER in Oracle, you have the option of not specifying a precision or scale. What do these default to if you don't specify them? ...

relational database and net structure

The company Microsoft could be referred as "microsoft", "ms" or "m$" etc. We may say these names are alias to one single identity. If you want to store the "alias" relationship, you might have to do it as the following pairs microsoft ms ms microsoft microsoft m$ m$ microsoft ms m$ m$...

Is NHibernate suitable for an SPC application?

I hear a lot about NHibernate lately (mostly good things) and would like to get to know it. At my company we are planning to create a db based application in C#, and I was wondering if NHibernate was suitable for this project. But as I have no experience with ORM, I can not assess the risks involved. Background: It will be an applicat...

Is there an ANSI SQL alternative to the MYSQL LIMIT keyword?

Is there an ANSI SQL alternative to the MYSQL LIMIT keyword? The LIMIT keyword limits the number of rows returned by a SELECT e.g: SELECT * FROM People WHERE Age > 18 LIMIT 2; returns 2 rows. SELECT * FROM People WHERE Age > 18 LIMIT 10, 2; returns 2 rows after the first 10. ...

Abinitio & Recommended Usage Scenarios for Data Import / Export Processes

I'm curious to find out if anyone has some real world experience using Abinitio for data imports, manipulation, exports and if you highly recommend it. I'm looking to solve a scalability issue with this process and would like some feedback if it solved these problems. I've heard that it's a great tool for doing this. ...

Introduction to SQL triggers?

I am a student, with decent knowledge of SQL, but have had very little to do with triggers in the past. I've looked at a few sites for guidance, but comprehensive explanation on all commonly used statements seems fairly sparse. Is there a 'definitive' site for this kind of thing? Perhaps like a w3chools for advanced SQL? ...

Programmatically extracting relationships between tables in an RDBMS w/out foreign keys?

I'm reverse engineering the relationships between a medium-sized number of tables (50+) in an Oracle database where there are no foreign keys defined between the tables. I can count (somewhat) on being able to match column names across tables. For example, column name "SomeDescriptiveName" is probably the same across the set of tables....

Do 1 to 1 relations on db tables smell?

I have a table that has a bunch of fields. The fields can be broken into logical groups - like a job's project manager info. The groupings themselves aren't really entity candidates as they don't and shouldn't have their own PKs. For now, to group them, the fields have prefixes (PmFirstName for example) but I'm considering breaking the...

Mysql4: SQL for selecting one or zero record

Table layout: CREATE TABLE t_order (id INT, custId INT, order DATE) I'm looking for a SQL command to select a maximum of one row per order (the customer who owns the order is identified by a field named custId). I want to select ONE of the customer's orders (doesn't matter which one, say sorted by id) if there is no order date given...

Which should I use, pear MDB2 or pear DB_DataObject when I use MySQL when I can not use PDO?

Almost all of free web hosting server, you can not use PDO + MySQL. They lack PDO drivers. So I am considering to select pear MDB2, or DB_DataObject. Which do you reccomend to me? Give me your opinions! ...

Oracle DB simple SELECT where column order matters

I am doing a simple SELECT statement in an Oracle DB and need to select the columns in a somewhat-specific order. Example: Table A has 100 attributes, one of which is "chapter" that occurs somewhere in the order of columns in the table. I need to select the data with "chapter" first and the remaining columns after in no particular order...

Backup MySQL users

How do I backup MySQL users and their privileges? Anything like mysqldump? I am looking for something like mysqldump -d -u root -p MyTable > Schema.sql ...

Help required with ancient, unknown storage system.

Morning all, I've gone and told a customer I could migrate some of their old data out of a DOS based system into the new system I've developed for them. However I said that without actually looking at the files that stored the data in the old system - I just figured a quick google would solve all the problem for me... I was wrong! Anyw...

MySQL: Check if the user exists and drop it.

There’s not standard way to check if a MySQL user exists and based on that drop it. Are there any workarounds for this? Edit: I need a straight way to run this without throwing up an error e.g. DROP USER test@localhost; : ...

What is a good MySQL Database Schema tool?

I'm starting a new project soon and I'd like to try to use some better tools this time around. The last project, I wrote all my Database creation SQL by hand for MySQL. I'm hoping there are some good tools out there for creating, maintaining and modifying database schema in MySQL. My budget is out-of-my-own-pocket, so free (as in beer) w...

C# (Visual studio): Correlation between database, dataset, binding source

Hello. I am just learning C# through Visual Studio 2008? I was wondering what exactly is the correlation between dabases, datasets and binding sources? As well, what is the function of the table adapter? ...

"User Preferences" Database Table Design

I'm looking to create a table for user preferences and can't figure the best way to do it. The way that the ASP.NET does it by default seems extremely awkward, and would like to avoid that. Currently, I'm using one row per user, where I have a different column for each user preference (not normalized, I know). So, the other idea that ...