ignite-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Vladimir Ozerov (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (IGNITE-3716) ODBC: Implement escape sequence parsing.
Date Mon, 22 Aug 2016 09:55:20 GMT

     [ https://issues.apache.org/jira/browse/IGNITE-3716?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Vladimir Ozerov updated IGNITE-3716:
------------------------------------
    Description: 
ODBC standard defines a set of special escape sequences [1] which help to create SQL requests
in database-independent format. We need to implement special processor which will accept ODBC
string and return parsed SQL query string.

Possible simple stack-based approach:
1) When escape start is found, put it's start position into stack. 
2) If there are no other escapes between start and end - evaluate expression.
3) Finally, replace escape sequence in original string and adjust positions up the stack accordingly.

This way after N replaces we will have fully-escape string.

[1] https://msdn.microsoft.com/en-us/library/ms711838(v=vs.85).aspx

  was:
ODBC standard defines a set of special escape sequences [1] which help to create SQL requests
in database-independent format. We need to implement special processor which will accept ODBC
string and return parsed SQL query string.

Possible simple stack-based approach:
1) When escape start is found, put it's start position into stack. 
2) If there are no other escapes between start and end - evaluate expression.
3) Finally, replace escape sequence in original string and adjust positions up the stack accordingly.

This way after N replaces we will have fully-escape string.


> ODBC: Implement escape sequence parsing.
> ----------------------------------------
>
>                 Key: IGNITE-3716
>                 URL: https://issues.apache.org/jira/browse/IGNITE-3716
>             Project: Ignite
>          Issue Type: Task
>          Components: odbc
>    Affects Versions: 1.7
>            Reporter: Vladimir Ozerov
>            Assignee: Andrew Mashenkov
>            Priority: Critical
>             Fix For: 1.8
>
>
> ODBC standard defines a set of special escape sequences [1] which help to create SQL
requests in database-independent format. We need to implement special processor which will
accept ODBC string and return parsed SQL query string.
> Possible simple stack-based approach:
> 1) When escape start is found, put it's start position into stack. 
> 2) If there are no other escapes between start and end - evaluate expression.
> 3) Finally, replace escape sequence in original string and adjust positions up the stack
accordingly.
> This way after N replaces we will have fully-escape string.
> [1] https://msdn.microsoft.com/en-us/library/ms711838(v=vs.85).aspx



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message