Viewing 15 posts - 2,911 through 2,925 (of 6,036 total)
Then what makes you think 108 is appropriate style for the format used in your file?
_____________
Code for TallyGenerator
August 14, 2008 at 4:54 am
No it should be CONVERT(datetime, HC_IH_TD_ACTUAL_TIME_TO, 108)
Always read manuals before using tools.
In this case it's BOL ("help" for SQL Server)
_____________
Code for TallyGenerator
August 14, 2008 at 4:45 am
Then you need first EXPLICITLY convert to to datetime acording to the format used in the file.
Apparently you convert FROM datetime indtead of converting TO datetime.
_____________
Code for TallyGenerator
August 14, 2008 at 4:07 am
What are the datatypes of the columns used in the query?
_____________
Code for TallyGenerator
August 14, 2008 at 4:00 am
Don't use CAST for varchar-datetime conversions.
Always use CONVERT with style specified.
_____________
Code for TallyGenerator
August 14, 2008 at 3:48 am
Though delimiter "," does its job in most cases it still can fail if someone will try to pass something like this:
Monitor 17","TCO'03" compliant.
For bullet proof solution you need to...
_____________
Code for TallyGenerator
August 12, 2008 at 8:07 pm
It's not about an offense.
I have not noticed one.
It's about your reasons.
Index gives you desired result using single page reading.
It's theoretically minimal possible amount of reading. Because SQL Server reads...
_____________
Code for TallyGenerator
August 11, 2008 at 6:00 am
Join the table to itself on
T1.Descr = T2.Descr AND T1.value = T2.value-1
_____________
Code for TallyGenerator
August 11, 2008 at 5:40 am
Did you ever use an index in your life?
For example, an index on a book?
How many pages you need to read to find what is the MIN and MAX keywords...
_____________
Code for TallyGenerator
August 11, 2008 at 5:22 am
How many rows, on you opinion, server needs to read to find MAX or MIN value from an index?
_____________
Code for TallyGenerator
August 11, 2008 at 5:13 am
Why?
_____________
Code for TallyGenerator
August 11, 2008 at 4:42 am
You wanna say it did not work?
_____________
Code for TallyGenerator
August 11, 2008 at 4:26 am
If application fails because of special characters in logins then it's programmers who wrote it must be found and eliminated, not the characters.
Those failures mean that application is not protected...
_____________
Code for TallyGenerator
August 10, 2008 at 3:32 pm
You may use derived tables:
SELECT Three, Three+3 AS Six
FROM (
SELECT 1+2 as Three
) DT
_____________
Code for TallyGenerator
August 8, 2008 at 4:44 am
Simple index on DOC_RECEIVED_DATE would allow you to get result from that query in no time.
_____________
Code for TallyGenerator
August 8, 2008 at 3:17 am
Viewing 15 posts - 2,911 through 2,925 (of 6,036 total)