database

What is the easiest way to simulate a database table with an index in a key value store?

What is the easiest way to simulate a database table with an index in a key value store? The key value store has NO ranged queries and NO ordered keys. The things I want to simulate (in order of priority): Create tables Add columns Create indexes Query based on primary key Query based on arbitrary columns ...

Local Data Cache Sync Framework table loses ability to use Default values

Hi, I have a clinet sdf file (sql compact) that is created by the LocalDataCache.sync in Visual Studio 2008. The server is SQL Server 2008. On the server if I do the following: CREATE TABLE test ( [firstfield] float NOT NULL DEFAULT 1, [secondfield] float NOT NULL DEFAULT 2) GO INSER...

Why is my index not used for this SELECT DISTINCT query on a text column?

I expected either index to be used for my SELECT DISTINCT query below: CREATE TABLE test( value TEXT ); INSERT INTO test (value) VALUES ('a'); INSERT INTO test (value) VALUES ('b'); INSERT INTO test (value) VALUES ('c'); CREATE INDEX value_i ON test(value(32)); CREATE FULLTEXT INDEX value_i_ft ON test(value); SELECT DISTINCT value ...

Complex SQL query for ShoppingCart

I've been trying to figure out how to query a shopping cart database to find all Orders that contain tangible items (items can be downloadable, therefore, not shipped) that have not been assigned a UPS tracking label. I haven't been able to do it. The involved tables are as follows: // dbo.Inventory - details about the individual produ...

Entity framework Querying

Hello Everyone, I am trying to figure out how to query my entities based on the following situation. I have two tables, LKCATEGORY AND LKSUBCATEGORY as you can imagine this two tables are related to each other. However when i come to a page that needs to display only active categories and subcategories how do i do this and pull back a ...

Recommended SQL database for commerical product

We have a commercial off the shelf product which used a Access Database. Due to the limitations and corruptions involved in multi user environments we decided to move to SQL Express. However now asit turns our,deployment of SQL Express 2005/2008 is a nightmare. The list of dependencies these depend on just keeps growing. Can anyone recom...

Custom Database integration with MOSS 2007

Hopefully someone has been down this road before and can offer some sound advice as far as which direction I should take. I am currently involved in a project in which we will be utilizing a custom database to store data extracted from excel files based on pre-established templates (to maintain consistency). We currently have a process (...

storing and retrieving colors with database, C# windows forms application

I'm making a windows application with C#. I'm using the color dialog box for the user to select a color. I'd like to store that color in a database, and be able to retrieve it later on, and be able to use that color in the user interface. What approach would you suggest to me? ...

How do I store a persistent array of objects on the iphone?

I need to store an array of user created objects (a user enters data for several properties and then commits it), and I need it to be available in a database or something similar so that I can call it up and display the data when the user calls for it even after the user quits the program(the persistent part). Other considerations are ...

Data Access Application Framework for .NET + SQL Server?

We are looking to create an in-house Project Dashboard application. Project Managers will use this to create and update projects, submit project status, enter project metrics, etc. A separate reporting piece would read the data entered by the tool and bubble up reporting data. If this were 1990 and the app was to run in DOS I would ch...

What does a database log keep track of?

Hey, I'm quite new to SQL Server and was wondering what the difference between the SQL Server log is and a custom log (in my case, using log4net)? I guess there's more choice on what to log using log4net, but what things are automatically logged by the database? For example, if a user signs up to my site, would I have to manually log t...

Read/Write xBASE (DBASE 3-5 /DBF) files

Is there any good library for reading / writing DBF files in java or any other language ? ...

In-Database Memoization - a good idea? Any experiences?

Hi All, I have an idea I have yet to implement, because I have some fear I may be barking up the wrong tree... mainly because Googling on the topic returns so few results. Basically I have some SQL queries that are slow, in large part because they have subqueries that are time-consuming. For example, they might do things like "give me...

Porting Oracle Procedure to PostgreSQL

I am porting an Oracle function into Postgres PGPLSQL.. I have been using this guide: http://www.postgresql.org/docs/8.1/static/plpgsql.html CREATE OR REPLACE PROCEDURE DATA_UPDATE (mission NUMBER, task NUMBER) AS BEGIN IF mission IS NOT NULL THEN UPDATE MISSION_OBJECTIVE MO SET (MO.MO_TKR_TOTAL_OFF_SCHEDULED, ...

What is the best database for a C# Desktop App? (NO NETWORKING)

What should I use? I need to store data, and it only needs to be on the local machine. I will be storing all string variables, and in many columns. What is the best? Would it even be a database? ...

Help me differentiate between a truly distributed setup and a merely redundant system

i understand that a master/slave setup is redundant, in that data is mirrored to all slaves from a central master. how does this vary from a distributed architecture? ...

Porting Oracle Procedure (With Specific Function Calls) To Postgres PL/PGSQL

(This is similar to a question I asked earlier: http://stackoverflow.com/questions/2277731/porting-oracle-procedure-to-postgresql) I need to port: /* || The following private procedure will execute a dynamic pl/sql || statement passed to it. */ CREATE OR REPLACE FUNCTION DB_SHELL_UTIL_PKG.EXECUTE_STMT (stmt VARCHAR) IS v_num_...

User permission table structure

Hi, I have a PHP script with many restricted areas. In each of these areas I have a function that checks if the user have access to the current area by checking the "usergroup" table. That problem is I have over 100 columns now so I'm not sure if that's a correct database design. Please advise. Thanks. ...

Database design issue:

Hey guys, I'm building a Volunteer Management System and I'm having some DB design issues: To explain the process: Volunteers can sign up for accounts. Volunteers report their hours to a project (each volunteer can have multiple projects). Volunteer supervisors are notified when a volunteers number of hours are close to some specified ...

Create a table in the sharepoint database using C#

How to create A new table in the sharepoint database from c# using the sharepoint libraries. ...