[ 
https://issues.apache.org/jira/browse/OPTIQ-316?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14048009#comment-14048009
 ] 

Julian Hyde commented on OPTIQ-316:
-----------------------------------

We need to design the syntax bearing in mind that 95% of the code will be SQL 
and results. Comments and control structures are rarer, so can be less natural. 
SQL code should not require any special escaping.

TCL or similar could work, provided it has an unobtrusive syntax for multi-line 
strings. E.g.

{code:java}
sql [
  select *
  from emps
]
expect [
EMPNO | NAME
===== | ====
   10 | Fred
   20 | Bill
]
if false [
sql [
select unimplememented_feature(1) from dept
]
output [
don't know yet
]
]
{code}

> SqlRun: Match output regardless of order if ORDER BY not present
> ----------------------------------------------------------------
>
>                 Key: OPTIQ-316
>                 URL: https://issues.apache.org/jira/browse/OPTIQ-316
>             Project: optiq
>          Issue Type: Bug
>            Reporter: Julian Hyde
>            Assignee: Julian Hyde
>
> If ORDER BY is not present, a compliant implementation may return rows in any 
> order. SqlRun should detect this, output the rows in the original order, not 
> the actual order.
> This feature makes it much easier to handle unsorted data. The previous 
> workaround, adding an ORDER BY clause, may trigger a different execution path 
> and mask bugs. And it was common to forget an ORDER BY and have to go back to 
> add the ORDER BY and correct the data some weeks later.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to