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

Add Oracle-Store implementation. #178

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

Conversation

DerHulk
Copy link

@DerHulk DerHulk commented Jan 8, 2020

Dear Mr Craver, i have implemented a datastore to Oracle-DB. I hope this will help other develpers in future if the need oracle support. Maybe you are interested to include it to your great Exceptional lib. What i don't know is if the oracle licence for the oracle client (Nuget Oracle.ManagedDataAccess.Core) is a problem for the licence of your project.

@DerHulk
Copy link
Author

DerHulk commented Feb 1, 2020

Is something wrong with my pullrequest?

@NickCraver
Copy link
Owner

@DerHulk Hey there - I just unfortunately haven't had time to sync with Marc on this to investigate some issues. The major issue I see is the way Oracle handles types and since it has no native GUID, we have to convert it. Unfortunately, these type handlers are global in Dapper. This means the library would be changing (and potentially breaking) all other GUID behavior in an application - that's a pretty nasty side-effect and I think we have to find a way to remedy that issue before it's viable to do in a library. This would need changes in Dapper (which we're planning v3 on as time allows) and is likely something that's a dependency here before moving forward.

That issue being what it is, the PR itself is great - adding tests and formats and...just very well done! I'm going to sync with @mgravell this week on ideas.

@DerHulk
Copy link
Author

DerHulk commented Feb 2, 2020

Ok thanks for response, i was't sure that i have missing something. I have seen the problem with the guid-mapping (first i thought i could solve it with the TypeHandler but this was not 100% successfull) but i normally use ef as orm so for me it was not a problem. Hope you find a good solution.

@kilroyFR
Copy link

kilroyFR commented Apr 27, 2020

There is other way to fool dapper without changing GUID handler is using a private property (supported by Dapper).

public Guid Foo {get;set;}

public string FooString {
get { return Foo.ToString("N"); }
set { Foo = new Guid(value); }
}
And in your query, alias the column as FooString.

@NickCraver NickCraver changed the base branch from master to main June 20, 2020 13:51
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.

3 participants