Click here to Skip to main content
16,006,013 members
Home / Discussions / Database
   

Database

 
GeneralRe: Connecting to remote SQL Express Pin
Joe Smith IX28-Jan-07 22:28
Joe Smith IX28-Jan-07 22:28 
GeneralRe: Connecting to remote SQL Express Pin
Joe Smith IX1-Feb-07 5:51
Joe Smith IX1-Feb-07 5:51 
AnswerRe: Connecting to remote SQL Express Pin
S Douglas28-Jan-07 20:32
professionalS Douglas28-Jan-07 20:32 
AnswerRe: Connecting to remote SQL Express Pin
steve_rm29-Jan-07 4:03
steve_rm29-Jan-07 4:03 
GeneralRe: Connecting to remote SQL Express Pin
S Douglas29-Jan-07 4:26
professionalS Douglas29-Jan-07 4:26 
AnswerRe: Connecting to remote SQL Express Pin
steve_rm29-Jan-07 6:05
steve_rm29-Jan-07 6:05 
QuestionHow do I change the date format? Pin
davidstern10028-Jan-07 5:01
davidstern10028-Jan-07 5:01 
AnswerRe: How do I change the date format? Pin
Colin Angus Mackay28-Jan-07 5:37
Colin Angus Mackay28-Jan-07 5:37 
davidstern100 wrote:
In C#, the date in DateTime uses slashes ("/").


It depends on your locale. A DateTime does not store dates with slashes. That is only how they are rendered in your locale.

davidstern100 wrote:
How do I change the format in order to save dates (like DateTime.Now) in my sql database?


Dates are stored as SMALLDATETIME or DATETIME types, not in any specific format with dashes, slashes or whatever. It is the responsibility of the presentation layer to render the dates in a human readable form.

If you are attempting to inject a date into a SQL statement in order to make up something like this:
INSERT MyTable(SomeDate) VALUES ('2006-01-28')
then I suggest you don't. Use Parameterised queries instead.

If you tell us exactly why (in other words, to what higher purpose) you want to convert dates in this way we may be able to suggest a better solution.


QuestionHow do i compare Datetime Pin
www.Developerof.NET28-Jan-07 0:33
www.Developerof.NET28-Jan-07 0:33 
AnswerRe: How do i compare Datetime Pin
Bassam Saoud28-Jan-07 2:04
Bassam Saoud28-Jan-07 2:04 
GeneralRe: How do i compare Datetime Pin
www.Developerof.NET28-Jan-07 6:56
www.Developerof.NET28-Jan-07 6:56 
QuestionConnectivity issue - SQLServer not listening on port 1433/ms-sql-s Pin
viji]27-Jan-07 22:23
viji]27-Jan-07 22:23 
Questioncannot connect to server Pin
rp_suman27-Jan-07 20:51
rp_suman27-Jan-07 20:51 
AnswerRe: cannot connect to server [modified] Pin
Aaron VanWieren28-Jan-07 9:23
Aaron VanWieren28-Jan-07 9:23 
GeneralRe: cannot connect to server Pin
rp_suman2-Feb-07 4:16
rp_suman2-Feb-07 4:16 
QuestionCrystal Report vb.net 2005 !!! Pin
kindman_nb27-Jan-07 19:08
kindman_nb27-Jan-07 19:08 
AnswerRe: Crystal Report vb.net 2005 !!! Pin
Bassam Saoud27-Jan-07 21:59
Bassam Saoud27-Jan-07 21:59 
GeneralRe: Crystal Report vb.net 2005 !!! Pin
kindman_nb27-Jan-07 22:05
kindman_nb27-Jan-07 22:05 
GeneralRe: Crystal Report vb.net 2005 !!! Pin
kindman_nb28-Jan-07 5:10
kindman_nb28-Jan-07 5:10 
GeneralRe: Crystal Report vb.net 2005 !!! Pin
Bassam Saoud28-Jan-07 7:40
Bassam Saoud28-Jan-07 7:40 
GeneralRe: Crystal Report vb.net 2005 !!! Pin
kindman_nb28-Jan-07 22:06
kindman_nb28-Jan-07 22:06 
GeneralRe: Crystal Report vb.net 2005 !!! Pin
kindman_nb29-Jan-07 3:08
kindman_nb29-Jan-07 3:08 
AnswerRe: Crystal Report vb.net 2005 !!! Pin
Jati Indrayanto31-Jan-07 15:20
Jati Indrayanto31-Jan-07 15:20 
Questionadvanced subquery Pin
Bit_flipper27-Jan-07 8:42
Bit_flipper27-Jan-07 8:42 
AnswerRe: advanced subquery Pin
Colin Angus Mackay27-Jan-07 10:21
Colin Angus Mackay27-Jan-07 10:21 

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.