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

how to return multiple select in one function #4381

Open
nuo-o opened this issue Jul 4, 2022 · 0 comments
Open

how to return multiple select in one function #4381

nuo-o opened this issue Jul 4, 2022 · 0 comments

Comments

@nuo-o
Copy link

nuo-o commented Jul 4, 2022

我想实现类似于 https://blog.csdn.net/chp891202/article/details/85012940 这样的实现。
nebula 版本 2.6.1。
我的mapper.xml 里写法如下,但返回结果只有最后一条query的结果。依照mysql的实现方法,是需要指定一个allowMultiQueries的参数,请问nebula实现是需要指定什么参数吗?

<resultMap id="personOuterInvest" type="Children"/> <resultMap id="outerInvest" type="Children"/> <resultMap id="have" type="Children"/> <select id="getBasicGraphItemsAll" resultSets="have,personOuterInvest,outerInvest"> go from #{id} overhave` yield

id($$) as entid,
true as hasChildren,
$$.company.entname as name,
"2" as parameter,
"" as ratio,
;

    go from #{id} over person_outer_invest yield
    <trim suffixOverrides=",">
        properties(edge).entid as entid,
        true as hasChildren,
        properties(edge).entname as name,
        "2" as parameter,
        properties(edge).fundedratio as ratio,
    </trim>;

    go from #{id} over outer_invest yield
    <trim suffixOverrides=",">
        id($$) as entid,
        true as hasChildren,
        $$.company.entname as name,
        "2" as parameter,
        properties(edge).fundedratio as ratio,
    </trim>;


</select>`
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

No branches or pull requests

1 participant