Click here to Skip to main content
15,172,078 members
Home / Discussions / Database
   

Database

 
AnswerRe: SQL Query with a Loop Pin
Bobby Underwood6-Jan-20 6:11
MemberBobby Underwood6-Jan-20 6:11 
AnswerRe: SQL Query with a Loop Pin
#realJSOP6-Jan-20 6:16
mva#realJSOP6-Jan-20 6:16 
GeneralRe: SQL Query with a Loop Pin
Bobby Underwood6-Jan-20 6:22
MemberBobby Underwood6-Jan-20 6:22 
AnswerRe: SQL Query with a Loop Pin
Jörgen Andersson7-Jan-20 6:52
professionalJörgen Andersson7-Jan-20 6:52 
Questionincorrect syntax near begin expecting external for Alter Procedure Pin
simpledeveloper27-Dec-19 10:23
Membersimpledeveloper27-Dec-19 10:23 
AnswerRe: incorrect syntax near begin expecting external for Alter Procedure Pin
Jörgen Andersson28-Dec-19 0:14
professionalJörgen Andersson28-Dec-19 0:14 
QuestionAdding multiple columns with condition Pin
simpledeveloper26-Dec-19 15:58
Membersimpledeveloper26-Dec-19 15:58 
AnswerRe: Adding multiple columns with condition Pin
Mycroft Holmes26-Dec-19 20:58
professionalMycroft Holmes26-Dec-19 20:58 
Are you asking how to add a specific column only if a condition exists? That is not possible.

You could change the structure to use an Attribute table

Cases
CaseID - PK
DocketNumber
Date
Locations (should this be an attribute as many are implied)

Attributes
AttrID
CaseID
Key - eg InterpreterNeeded
Value - Y (I would use a string type for the value field)

Then you can select from Cases and inner join the Attributes needed for a particular query.
Never underestimate the power of human stupidity -
RAH
I'm old. I know stuff - JSOP

AnswerRe: Adding multiple columns with condition Pin
Jörgen Andersson27-Dec-19 4:40
professionalJörgen Andersson27-Dec-19 4:40 
GeneralRe: Adding multiple columns with condition Pin
simpledeveloper27-Dec-19 6:29
Membersimpledeveloper27-Dec-19 6:29 
GeneralRe: Adding multiple columns with condition Pin
Jörgen Andersson27-Dec-19 6:32
professionalJörgen Andersson27-Dec-19 6:32 
GeneralRe: Adding multiple columns with condition Pin
simpledeveloper27-Dec-19 9:44
Membersimpledeveloper27-Dec-19 9:44 
QuestionCrystal Report to SQL server 2012 database Pin
Member 1447460719-Dec-19 11:39
MemberMember 1447460719-Dec-19 11:39 
QuestionBackup rows tables of SQL Server database by SMO base on colums's value Pin
Member 1417466417-Dec-19 15:39
MemberMember 1417466417-Dec-19 15:39 
AnswerRe: Backup rows tables of SQL Server database by SMO base on colums's value Pin
Richard Deeming18-Dec-19 0:47
mveRichard Deeming18-Dec-19 0:47 
GeneralRe: Backup rows tables of SQL Server database by SMO base on colums's value Pin
Member 1417466418-Dec-19 0:57
MemberMember 1417466418-Dec-19 0:57 
AnswerRe: Backup rows tables of SQL Server database by SMO base on colums's value Pin
David Mujica18-Dec-19 6:58
MemberDavid Mujica18-Dec-19 6:58 
GeneralRe: Backup rows tables of SQL Server database by SMO base on colums's value Pin
Member 1417466418-Dec-19 15:35
MemberMember 1417466418-Dec-19 15:35 
GeneralRe: Backup rows tables of SQL Server database by SMO base on colums's value Pin
David Mujica19-Dec-19 10:37
MemberDavid Mujica19-Dec-19 10:37 
GeneralCode converter Pin
David Mujica19-Dec-19 10:47
MemberDavid Mujica19-Dec-19 10:47 
GeneralRe: Code converter Pin
Member 1417466419-Dec-19 17:01
MemberMember 1417466419-Dec-19 17:01 
AnswerRe: Backup rows tables of SQL Server database by SMO base on colums's value Pin
Member 1417466430-Jan-20 23:40
MemberMember 1417466430-Jan-20 23:40 
Questionms sql server error 18456 on sa login Pin
pwojtysiak17-Dec-19 1:24
Memberpwojtysiak17-Dec-19 1:24 
AnswerRe: ms sql server error 18456 on sa login Pin
Richard Deeming17-Dec-19 2:33
mveRichard Deeming17-Dec-19 2:33 
QuestionSQL Server Management Studio VS SQL Server in Visual Studio 2019 Pin
Ebrahimaw21-Nov-19 20:33
MemberEbrahimaw21-Nov-19 20:33 

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.