[sqlalchemy] Join Table Alliases

2016-05-21 Thread John Omernik
In a dialect I am trying to write for Apache Drill, I when a join comes through (with no visit_join function) however it's being created (excuse my "newness") it lands in Apache Drill like this SELECT field1 AS field1, COUNT(*) AS cnt FROM table JOIN (SELECT field1 AS __field1 FROM table GROUP BY

Re: [sqlalchemy] Re: Is there a good doc page/tutorial for writing a dialect?

2016-05-20 Thread John Omernik
gt; > > On Thursday, May 19, 2016 at 2:20:57 PM UTC-7, John Omernik wrote: >> >> I am trying to write a new dialect, and while many things are fairly >> obvious, many are also not. It would be helpful to point to some docs on >> how the dialect writing works, what even

Re: [sqlalchemy] Dialect not replacing ? with parameter

2016-05-20 Thread John Omernik
So maybe I want "with_labels" but I am not sure how to set that in the visit_join... or am I looking in the wrong place? On Fri, May 20, 2016 at 7:53 AM, John Omernik wrote: > Awesome, I am making some progress, I realized that the visit_join I had > was specific to Micros

Re: [sqlalchemy] Dialect not replacing ? with parameter

2016-05-20 Thread John Omernik
bvious to me, but I don't want hard code anon_1 in a dialect... Thanks for your help thus far in pointing me in the right direction. John On Thu, May 19, 2016 at 7:50 PM, John Omernik wrote: > Hey Mike, thanks for the reply. I feel really bad in that I am struggling > o

Re: [sqlalchemy] Dialect not replacing ? with parameter

2016-05-19 Thread John Omernik
that lines up with the ? > is part of the "parameters" sequence. The specification for this is at > https://www.python.org/dev/peps/pep-0249/#id15 which also links out to > paramstyle. > > > > On 05/19/2016 05:27 PM, John Omernik wrote: > >> I am writing my

Re: [sqlalchemy] Is there a good doc page/tutorial for writing a dialect?

2016-05-19 Thread John Omernik
st way to really get into the methods and things is to look > at the existing dialects and see what they are doing.we don't have > extensive documentation on each area to be dealt with from a developer > standpoint. > > On 05/19/2016 05:20 PM, John Omernik wrote: > >&

[sqlalchemy] Dialect not replacing ? with parameter

2016-05-19 Thread John Omernik
I am writing my own dialect, and for some reason, when my application sets a limit via parameter, the query submitted to the back end just has ? in it. Is this an issue with the dialect, the pyodbc (doubt it's that), or the ODBC driver itself? Thanks, John -- You received this message beca

[sqlalchemy] Is there a good doc page/tutorial for writing a dialect?

2016-05-19 Thread John Omernik
I am trying to write a new dialect, and while many things are fairly obvious, many are also not. It would be helpful to point to some docs on how the dialect writing works, what events/methods we can overwrite and what it can help us do. Thanks! John -- You received this message because yo