Crystal Reports 2008 - Formula for Date String

Posted on 2012-09-14
Last Modified: 2012-09-14
Hi and thanks

I have this formula:
Left({TEMP_PWC_Sales_Report_SP_MAIN.mtransferdate}, CStr({TEMP_PWC_Sales_Report_SP_MAIN.mtransferdate}, " ") -1)

I get error:
A number, currency amount, date, time, or date-time is required here

what I am trying to do:
|01/01/2012 12:01:01| = |01/01/2012|

Question by:Amour22015
    LVL 83

    Expert Comment

    I am not sure if you can use Split method in CR but give it a try

    Split(varname, " ")(0)
    LVL 12

    Accepted Solution

    There is a built-in date function for this.

    LVL 100

    Expert Comment

    You can use the Split function but it is

    Split({YourFieldName}," ")[1]


    Author Closing Comment

    Just what I am looking for, Thanks

    Write Comment

    Please enter a first name

    Please enter a last name

    We will never share this with anyone.

    Featured Post

    Why You Should Analyze Threat Actor TTPs

    After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

    INTRODUCTION: While tying your database objects into builds and your enterprise source control system takes a third-party product (like Visual Studio Database Edition or Red-Gate's SQL Source Control), you can achieve some protection using a sing…
    There have always been a lot of questions related to when Crystal Reports evaluates report components (such as formulas, summaries, cross-tabs, charts, to name a few examples). Crystal Reports uses a two-pass reporting process to provide greater …
    Internet Business Fax to Email Made Easy - With eFax Corporate (, you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…
    Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

    794 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    17 Experts available now in Live!

    Get 1:1 Help Now