Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed bug in FixStringValue() in JetDbCommand.cs where exception with desc: "String not recognized as a valid DateTime" would be thrown if p.Value.ToString() was empty. Also upgraded nHibernate to v3.1.0.4000 #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Geddon
Copy link

@Geddon Geddon commented May 25, 2012

private void FixStringValue(IDataParameter p)
{
if (!_convertedDateParameters.Contains(p))
return;

  -->      if (!string.IsNullOrEmpty((p.Value ?? String.Empty).ToString()))
        {
            //Someimes two pass conversion makes a parameter value
            //of type DateTime to be of String Dbtype
            DateTime date = DateTime.Parse(p.Value.ToString());
            p.Value = GetNormalizedDateValue(date);
        }
    }

@tgmayfield
Copy link

James's git repository here is just a copy of NHContrib. NHibernate.JetDriver isn't getting any support from core devs, so there's been a few independent efforts to get it up to date. My own is at https://github.com/tgmayfield/nhibernate.jetdriver and has your fix above as well as others, thought it's set up for NH 3.2. You can do as you wish, but I know of a couple other people that have gone through the same level of effort, and I'm all about not wasting another person's time on it. :)

I've volunteered to become the new maintainer for NHibernate.JetDriver on the dev list, but it seems like nobody can really decide what to do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants