on 10-27-2009 5:47 AM
Hi,
I use a table view to display the results of a SQL query. The format displayed after executing the query in SQL editor is 2009-10-27 00:00:00.0 but the date displayed in the table view is 1933-03-31
I have tried formatting date using different Date Formats but the output does not seem to change.
How can i fix this
Thanks in advance.
Hello
Change date from in SQL server or Use date conversion function Date(Year, Month, Date)
for eg Date (1st four digits, 6th & 7th digit, Last two digits)
Dstr(Date(leftt("2009-03-29",4), Mid("2009-03-29",5,2),right("2009-03-29",2) ,"DD-MM-YYYY")
Regards
Pramod Patil
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the response
I tried using the Date function in the formula as below.
1)Dstr(Date(left("2009-03-29",4), Mid("2009-03-29",5,2),right("2009-03-29",2) ,"DD-MM-YYYY") and I could see the results.
But when I use the date field from the table as in the formula below
1)Dstr(Date(left("YYYY-MM-DD",4), Mid("YYYY-MM-DD",5,2),right("YYYY-MM-DD",2)) ,"YYYY-MM-DD")
2)Dstr(Date(left("@CREATEDON",4), Mid("@CREATEDON",5,2),right("@CREATEDON",2)) ,"YYYY-MM-DD")
where CREATEDON is the column name in my table,I do not see the correct output.
Thanks in advance.
Vidya
Hi
Have you tried with DSTR( ) Function?
Regards
Sandeep
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
On which SP and Version you are working ?
it may Bug with your SP.
Regards,
Govindu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
23 | |
11 | |
9 | |
8 | |
5 | |
5 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.