Skip to content

Select statement inspection and postresql #19

@GoogleCodeExporter

Description

@GoogleCodeExporter
Steps:
1. Creqte project with ibatis facet
2. Create datasource for postgresql DB
3. Write sql mapping for class with floow select

    <select id="selectAddressByID" parameterClass="long"
resultMap="AddressResult">
        select
            "AddressId",
            "AddressCountry",
        from "Address"
        where "AddressId" = #id#;
    </select>

Result: i see suggestion: 
ADDRESSID in result map ......
ADDRESSCOUNTRY in result map ......

If i rewrite statement as: 
    <select id="selectAddressByID" parameterClass="long"
resultMap="AddressResult">
        select
            AddressId,
            AddressCountry,
        from Address
        where AddressId = #id#;
    </select>

Then all rigth.

It seems to we need to chage ResultMapInSelectInspection.java for to be
able use sql syntax with quoted names

Original issue reported on code.google.com by achmedzh...@gmail.com on 22 Feb 2009 at 9:40

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions