oceanicwang / dapper-dot-net

Automatically exported from code.google.com/p/dapper-dot-net
Other
0 stars 0 forks source link

Can the current limit of 4 joins in a Multi Map Query be increased? #49

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Not a bug, just a feature request.

It looks like there is currently a limit of about 4 joins in a Multi Map query, 
which most of the time is fine, but occasionally we need to join on more tables 
than this.

Can this limit be increased to permit up to about 10 joins please?

Original issue reported on code.google.com by marcus.s...@gmail.com on 19 Jul 2011 at 12:18

GoogleCodeExporter commented 8 years ago
sure ... but someone is going to have to submit a patch

Original comment by sam.saff...@gmail.com on 20 Jul 2011 at 12:42

GoogleCodeExporter commented 8 years ago
I've been through the file this morning and updated it to accommodate the extra 
joins, so at least I can take advantage of that in my current projects.

Unfortunately I don't know about GitHub / submitting patches etc, so will just 
attach the version I made the changes to earlier, in case it's of any use.

Original comment by marcus.s...@gmail.com on 20 Jul 2011 at 1:05

GoogleCodeExporter commented 8 years ago
...with attachment!

Original comment by marcus.s...@gmail.com on 20 Jul 2011 at 1:06

Attachments:

GoogleCodeExporter commented 8 years ago
Dude, see issue 50 and vote it :)

Original comment by sdsilve...@gmail.com on 2 Dec 2011 at 12:05

GoogleCodeExporter commented 8 years ago
@Marcus I am using your edited SqlMapper, thanks :)

However you should update line 1559 with:
var identity = this.identity.ForGrid(typeof(TReturn), new Type[] { 
                    typeof(TFirst), 
                    typeof(TSecond),
                    typeof(TThird),
                    typeof(TFourth),
                    typeof(TFifth),
                    typeof(TSixth),
                    typeof(TSeventh),
                    typeof(TEighth),
                    typeof(TNinth),
                    typeof(TTenth)
                }, gridIndex);

You didn't cater for all the new generic params there :)

Attached is my version supporting 10 multi-mappings as at Dapper release 
16-Nov-11.

Original comment by grahamon...@gmail.com on 5 Dec 2011 at 2:50

Attachments:

GoogleCodeExporter commented 8 years ago
@graham: Thanks a lot for highlighting this, it must have slipped through the 
net.

Original comment by marcus.s...@gmail.com on 12 Dec 2011 at 9:35

GoogleCodeExporter commented 8 years ago
Issue 73 has been merged into this issue.

Original comment by sam.saff...@gmail.com on 19 Dec 2011 at 12:51