database

Testing a (big) collection retrieved from a db

I'm currently doing integration testing on a database and I have the following sql statement: var date = DateTime.Parse("01-01-2010 20:30:00"); var result = datacontext.Repository<IObject>().Where(r => r.DateTime > date).First(); Assert.IsFalse(result.Finished); I need to test if the results retrieved from the statement, where the giv...

SQL Server 2005 Copy Database Wizard keeps failing

Hi, I am just trying to copy a database from one server to another one... on the same domain. I use the Copy DB Wizard and set up everything correctly but it keeps failing. Is something wrong with the Wizard or just me missing something? ...

Querying Last Entries group by DeviceId

I have the database table logs as the following: I would like to extract the last entry of device, pollDate, status. For eg. deviceId, pollDate, status 1, 2010-95-06 10:53:28, 1 3, 2010-95-06 10:26:28, 1 I tried to run the following query but the distinct only selects the f...

Create a trigger in sql server 2008

Hi, I am trying to create a trigger for a cinema database. I need it to update once a rating is added for a movie showing the text "rating added". The table name is movie_ratings the primary key is = movie_rating I am not really sure how to do it, I have looked online but still are not too sure. I was wondering if anyone could help. ...

How do you fetch the complete contents of a core data entity and display the results in a uitableview?

I want to get and display the complete contents of one of my entities in a UITableView. How would i go about this im fairlt new to xcode. Once i have the data in the UITable how would i go about sorting the data? ...

Another rookie question; How to implement Count() here?

I have this query: SELECT mt.*, fordon.*, boende.*, elektronik.*, business.*, hem_inredning.*, hobby.* FROM classified mt LEFT JOIN fordon ON fordon.classified_id = mt.classified_id LEFT JOIN boende ON boende.classified_id = mt.classified_id LEFT JOIN elektronik ON elektronik.classified_id = mt.classified_id LEFT JOIN business ON bu...

I need to convert my Mysql database to SQL Server 2005 database

I need to convert my Mysql database to SQL Server 2005 database, Is there any tools available for this conversion. ...

How to change date formate in mysql stored procedure insert statemant "22-12-2010" to "2010-12-22"

I send the registration date parameter to mysql database like "22-12-2010". But my sql date date type is in another formate how can i change the date formate like "2010-12-22" also i have to insert this into table. Give code in c#,asp.net code behind either sql query statement! Cheerss!!!!! **Thanks A.Ayy...

Using SQL Server for web applications

As far as I understand, due to license reqirements all web applications, which use MS SQL Server, use SQL Server Express (free) or SQL Server web edition (processor license). Is it so? What are other specific features of SQL Server usage for web app? ...

Is there a structured source of Holland Code (RIASEC) data available?

I'm trying to put together some career-related resources and I need access to the Holland Codes/RIASEC that classifies interests and skills to occupations. I can find many sites that already do this, but I can't find raw data in a structured format. Is anyone aware of a source for this. It can be commercial with licensing fees, though...

Optional one-to-one mapping in Hibernate

How do I create an optional one-to-one mapping in the hibernate hbm file? For example, suppose that I have a User and a last_visited_page table. The user may or may not have a last_visited page. Here is my current one-to-one mapping in the hbm file: User Class: <one-to-one name="lastVisitedPage" class="LastVisitedPage" cascade="save-up...

TinyText VS LongText !!

Maybe this is a very stupid question but... Why should I use tinytext and not longtext ? In tinytext I can save only 255 chars. ...

Getting weird issue with TO_NUMBER function in Oracle

I have been getting an intermittent issue when executing to_number function in the where clause on a varchar2 column if number of records exceed a certain number n. I used n as there is no exact number of records on which it happens. On one DB it happens after n was 1 million on another when it was 0.1. million. E.g. I have a table with...

Database Schema Validation - deployable/compilable

Looking for a tool that will allow building database schema validation that can be compiled into a standalong tool or as a module to be used in another application. The scenario is - a client/server application that is sold to customers, and maintained through service releases. The service releases include database scripts to updated t...

How do you delete rows from UITableView?

This has been bugging me for hours now and i have not been able to figure it out. I am importing data into a tableview using core data and NSMutableArray. As shown below. CORE DATA ARRAY NSMutableArray *mutableFetchResults = [CoreDataHelper getObjectsFromContext:@"Spot" :@"Name" :YES :managedObjectContext]; self.entityArray = mutable...

Javascript Object Database

Hi, is there any javascript object database?? Something like http://www.db4o.com/ but for javascript? thanks ...

how to create setup of database

how to create setup of database. I have windows application in c#.net i am able to create setup of my application in vs2008 but i want to create my MySql database server setup for multiple clients of my application. Please help me... ...

How to tell the database type checking the file

My friend have a system to manage customers. The program per si is terrible, and my friend lost contact with the developers. The case is, now my friend lost the access to program (something that the developers say "locked to machine" so when moved to another pc, he lost the access to program and data. I get mission of to try to recover...

Closing database when using a wrapper in iPhone SDK

Hey guys I am using http://th30z.netsons.org/2008/11/objective-c-sqlite-wrapper/ wrapper for my iPhone Application. How do I close my database when applicationWillTerminate with the help of this wrapper? Thanks in advance. ...

sharepoint custom aspx page with database connection

hi there i have created a custom aspx page whithin my sharepoint site with a sql server connection to a database on that server to select data when i view the page it works but when another user tries to view it it gives the following error : Server Error in '/' Application. Login failed for user 'GRINCOR\GuguK'. Description: An ...