Click here to Skip to main content
15,844,364 members
Home / Discussions / Database
   

Database

 
AnswerRe: sql query Pin
leoinfo7-Jul-08 4:43
leoinfo7-Jul-08 4:43 
QuestionCreate a table with columns' name as primary columns data Pin
prithaa7-Jul-08 2:57
prithaa7-Jul-08 2:57 
AnswerRe: Create a table with columns' name as primary columns data Pin
ChandraRam7-Jul-08 3:14
ChandraRam7-Jul-08 3:14 
GeneralRe: Create a table with columns' name as primary columns data Pin
prithaa7-Jul-08 4:01
prithaa7-Jul-08 4:01 
GeneralRe: Create a table with columns' name as primary columns data Pin
ChandraRam7-Jul-08 4:04
ChandraRam7-Jul-08 4:04 
AnswerRe: Create a table with columns' name as primary columns data Pin
leoinfo7-Jul-08 9:14
leoinfo7-Jul-08 9:14 
GeneralRe: Create a table with columns' name as primary columns data Pin
prithaa8-Jul-08 22:02
prithaa8-Jul-08 22:02 
AnswerRe: Create a table with columns' name as primary columns data [modified] Pin
leoinfo9-Jul-08 4:06
leoinfo9-Jul-08 4:06 
<br />
You have there a #s table defined like:
CREATE TABLE #s (TimePeriod <big>INT</big>, Qty <big>INT</big>, ProdID <big>INT</big>);

Then you have some dummy data inserts like
INSERT INTO #s ( TimePeriod,  Qty, ProdID ) 
       SELECT      20080705,  138,      1  ;

or (if you understand better this syntax)
INSERT INTO #s ( TimePeriod,  Qty, ProdID ) 
       VALUES  (   20080705,  138,      1 );

You can change TimePeriod field type to DATETIME or whatever suits your needs better.

Let me know if you have any difficulties understanding the code.

modified on Wednesday, July 9, 2008 10:56 AM

QuestionHow to simplify the query Pin
BalasubramanianK7-Jul-08 2:01
BalasubramanianK7-Jul-08 2:01 
AnswerRe: How to simplify the query Pin
ChandraRam7-Jul-08 4:09
ChandraRam7-Jul-08 4:09 
Questionhow to write "connection string" in namespace or webconfig file ? Pin
sacr837-Jul-08 1:29
sacr837-Jul-08 1:29 
AnswerCross post Pin
dan!sh 7-Jul-08 1:37
professional dan!sh 7-Jul-08 1:37 
Questiondifference between sql server 2000 and 2005, Pin
Shaik Haneef7-Jul-08 1:06
Shaik Haneef7-Jul-08 1:06 
Questionhow to find string match in any updated columns in a trigger Pin
P. S. Pundeer6-Jul-08 20:18
P. S. Pundeer6-Jul-08 20:18 
AnswerRe: how to find string match in any updated columns in a trigger Pin
Giorgi Dalakishvili6-Jul-08 23:00
mentorGiorgi Dalakishvili6-Jul-08 23:00 
QuestionOptimizing query [modified] Pin
Puneri6-Jul-08 3:43
Puneri6-Jul-08 3:43 
QuestionRe: Optimizing query Pin
Puneri6-Jul-08 4:34
Puneri6-Jul-08 4:34 
AnswerRe: Optimizing query Pin
Kjetil Svendsen6-Jul-08 22:34
Kjetil Svendsen6-Jul-08 22:34 
Questionscript Pin
rezarafiee6-Jul-08 3:15
rezarafiee6-Jul-08 3:15 
AnswerRe: script Pin
Saksida Bojan6-Jul-08 4:26
Saksida Bojan6-Jul-08 4:26 
AnswerRe: script Pin
Pete O'Hanlon6-Jul-08 10:14
subeditorPete O'Hanlon6-Jul-08 10:14 
QuestionEmail Alert after Insert on table Pin
obarahmeh5-Jul-08 22:42
obarahmeh5-Jul-08 22:42 
AnswerRe: Email Alert after Insert on table Pin
N a v a n e e t h6-Jul-08 5:15
N a v a n e e t h6-Jul-08 5:15 
GeneralRe: Email Alert after Insert on table Pin
obarahmeh7-Jul-08 0:52
obarahmeh7-Jul-08 0:52 
GeneralRe: Email Alert after Insert on table Pin
N a v a n e e t h7-Jul-08 1:38
N a v a n e e t h7-Jul-08 1:38 

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.