hi

trying to build a new app on top of our accounting software.  building
with turbogears 1.1.

managed to connect to database properly.

this is my model (narrowed down to minimum columns just to see if
works)

class ZoomFncItem(Entity):
    using_options(tablename='dbo.FNCITEMS')
    trans = Field(Integer,colname='FNCTRANS',primary_key=True)
    udate = Field(Integer,colname='UDATE')

I try:

ZoomFncItem.query.all()

and get ugly error message:

ProgrammingError: (ProgrammingError) ('42S02', "[42S02] [Microsoft]
[ODBC SQL Ser
ver Driver][SQL Server]Invalid object name 'dbo.FNCITEMS'. (208)
(SQLExecDirectW
)") u'SELECT [dbo.FNCITEMS].[FNCTRANS] AS [dbo.FNCITEMS_FNCTRANS],
[dbo.FNCITEMS
].[UDATE] AS [dbo.FNCITEMS_UDATE] \nFROM [dbo.FNCITEMS] ORDER BY
[dbo.FNCITEMS].
[FNCTRANS]' []

I try the query directly to the database and get a similar error.

I try editing the query and if there is no period('.' sign) after the
AS, it works.. is there a way to make sqlalchemy ask for the columns
like
select [dbo.FNCITEMS].[FNCTRANS] AS FNCITEMS_FNCTRANS (i.e without the
period) ?

i do not control the database and i have no way to change the table
names..


thanks in advance

Rotem Tamir

-- 
You received this message because you are subscribed to the Google Groups 
"SQLElixir" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sqlelixir?hl=en.

Reply via email to