Skip to content

Indentation and code highlighting on multiline, quoted SQL queries #26

@bfavaretto

Description

@bfavaretto

When I create a multiline string with an SQL query, and the string begins with a line break, I lose the code highlighting (apparently, sql-string-double-quoted is not matching).

Also, whenever I add a new line break inside the string, Textmate is increasing the indentation level. So , when I try to write something like this:

$qry = "
    SELECT col
    FROM tbl
    WHERE othercol = :val
";

I end up with this:

$qry = "
    SELECT col 
        FROM tbl 
            WHERE othercol = :val
"; 

I posted a question on Stack Overflow about this, here is the link for reference: http://stackoverflow.com/questions/12452333/textmate-php-bundle-adds-extra-indentation-on-multiline-strings-how-to-avoid-it

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions