Date format dd-MMM-yyyy works only sometimes

  • After setting up a date format in SSRS of dd-MMM-yyyy report has many rows correct but not all. I've checked and don't see why this would happen. Any ideas of what could be wrong? I've attached an image with sample data. Just in case here it is in text:

    01-Jan-2008 customer1 product1

    15-Jan-2008 customer1 product2

    01-eb-2008 customer2 product1

    22-eb-2008 customer2 product3

    16-Apr-2008 customer1 product1

    As you can see "Feb" lost the "F" and moved the data over by 1 space. I am testing this with data from Jan, Feb, Mar, and Apr. The report renders the first and last month correctly but not the two between.

    Thanks for any comments!

  • How and where are you formatting the date?

  • could you show us you SQL ?

    ----------------------------------------------
    Try to learn something about everything and everything about something. - Thomas Henry Huxley

    :w00t:
    Posting Best Practices[/url]
    Numbers / Tally Tables[/url]

    SQL-4-Life
  • Long story short, we found several options and finally one of them worked as expected. I'll delete the post a bit later. Thanks for trying to help.

  • Since you posted it here why don't you tell us what the problem was and how you fixed it... it might be of serious help to someone else 🙂

  • Fair enough. Sorry but I'm sure you'll understand how we work in haste at times. Okay so here' is what happened and I'll try to answer the questions I generated.

    The sql simply return a date value from from a table column with the data type datetime.

    Our first edit was in the SSRS columns properties for format with the format string set to dd-MMM-yyyy. As you saw this only worked on some rows for some reason.

    After attempting a number of changes we dropped the SSRS property setting (no formatting) and changed the SQL.

    The SQL now returns the formatted string directly to SSRS (this is text in the SSRS data, not a SP call).

    The SQL now reads:

    select ....,convert(varchar,datein,106) as dateout,....

    Hope that helps others!

    And again sorry to be in such a rush.

    P

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply