Click here to Skip to main content
15,917,702 members
Home / Discussions / Database
   

Database

 
GeneralRe: Sum of all rows Pin
Wendelius22-Mar-11 2:12
mentorWendelius22-Mar-11 2:12 
GeneralRe: Sum of all rows Pin
CodingLover22-Mar-11 18:27
CodingLover22-Mar-11 18:27 
QuestionSelecting one record from one table and multiple from second table Pin
Dominick Marciano21-Mar-11 13:54
professionalDominick Marciano21-Mar-11 13:54 
AnswerRe: Selecting one record from one table and multiple from second table Pin
RyanEK21-Mar-11 14:44
RyanEK21-Mar-11 14:44 
GeneralRe: Selecting one record from one table and multiple from second table Pin
Dominick Marciano21-Mar-11 15:21
professionalDominick Marciano21-Mar-11 15:21 
GeneralRe: Selecting one record from one table and multiple from second table Pin
Dominick Marciano21-Mar-11 15:35
professionalDominick Marciano21-Mar-11 15:35 
QuestionPlease Interview Me Pin
Nagy Vilmos21-Mar-11 10:55
professionalNagy Vilmos21-Mar-11 10:55 
AnswerRe: Please Interview Me Pin
Simon_Whale21-Mar-11 23:12
Simon_Whale21-Mar-11 23:12 
SQL Server Question (taken from sql server central question of the day!)

SQL
CREATE TABLE #Money
(ID INT IDENTITY(1,1) PRIMARY KEY CLUSTERED,
 Date DATETIME,
 Amount INT,)

SET IDENTITY_INSERT #Money ON
INSERT INTO #Money(ID,Date,Amount)
SELECT '1', ' 2/10/2010 ','12' UNION ALL
SELECT '2', ' 2/11/2010 ','13' UNION ALL
SELECT '3', ' 2/12/2010 ','14' UNION ALL
SELECT '4', ' 2/13/2010 ','15' UNION ALL

SELECT SUM(AMOUNT) FROM #Money


Will the create statement fail?
will the insert statement fail?
will the select sum(amount) from #money fail?

Possible answers

1. The CREATE TABLE statement will fail, and hence so will all the following sql statements.
2. The INSERT INTO statements will fail and hence so will all the following sql statements
3. The SELECT SUM(Amount) will return a value of 54
4. The SELECT SUM(Amount) .. statement will fail
As barmey as a sack of badgers

Dude, if I knew what I was doing in life, I'd be rich, retired, dating a supermodel and laughing at the rest of you from the sidelines.

GeneralRe: Please Interview Me Pin
Nagy Vilmos21-Mar-11 23:37
professionalNagy Vilmos21-Mar-11 23:37 
GeneralRe: Please Interview Me Pin
Simon_Whale21-Mar-11 23:43
Simon_Whale21-Mar-11 23:43 
AnswerRe: Please Interview Me Pin
Johan Hakkesteegt21-Mar-11 23:37
Johan Hakkesteegt21-Mar-11 23:37 
AnswerRe: Please Interview Me Pin
Corporal Agarn22-Mar-11 1:32
professionalCorporal Agarn22-Mar-11 1:32 
AnswerRe: Please Interview Me Pin
Wendelius22-Mar-11 2:28
mentorWendelius22-Mar-11 2:28 
AnswerRe: Please Interview Me Pin
Prasanta_Prince15-Apr-11 0:56
Prasanta_Prince15-Apr-11 0:56 
QuestionSQLServer 2008 Express to Standard Upgrade Pin
Tim Carmichael21-Mar-11 8:27
Tim Carmichael21-Mar-11 8:27 
AnswerRe: SQLServer 2008 Express to Standard Upgrade Pin
Wendelius21-Mar-11 9:41
mentorWendelius21-Mar-11 9:41 
AnswerRe: SQLServer 2008 Express to Standard Upgrade Pin
PIEBALDconsult21-Mar-11 18:48
mvePIEBALDconsult21-Mar-11 18:48 
AnswerRe: SQLServer 2008 Express to Standard Upgrade Pin
Roger Wright21-Mar-11 19:42
professionalRoger Wright21-Mar-11 19:42 
QuestionConnect Dababase from Windows7 to windows 2008 Pin
buffering8321-Mar-11 4:59
buffering8321-Mar-11 4:59 
AnswerRe: Connect Dababase from Windows7 to windows 2008 Pin
Simon_Whale21-Mar-11 5:23
Simon_Whale21-Mar-11 5:23 
AnswerRe: Connect Dababase from Windows7 to windows 2008 Pin
Wendelius21-Mar-11 6:17
mentorWendelius21-Mar-11 6:17 
QuestionConnect Dababase from Windows7 to windows 2008. Pin
buffering8320-Mar-11 19:59
buffering8320-Mar-11 19:59 
AnswerRe: Connect Dababase from Windows7 to windows 2008. Pin
Wendelius20-Mar-11 20:29
mentorWendelius20-Mar-11 20:29 
GeneralRe: Connect Dababase from Windows7 to windows 2008. Pin
buffering8320-Mar-11 21:30
buffering8320-Mar-11 21:30 
GeneralRe: Connect Dababase from Windows7 to windows 2008. Pin
Wendelius20-Mar-11 21:41
mentorWendelius20-Mar-11 21:41 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.