[orm-devel] Non-alphanumeric column identifyers

Diedrich Vorberg diedrich at tux4web.de
Sun Mar 28 05:33:22 CEST 2004


Hello everybody!

I've made changes to orm to allow the following to work:

  class email:
    columns = {'Subject': text(columnName='"Subject"'),
               'MessageID': text(columnName='"Message-ID"') }

as you see the MessageID attribute is mapped to a column whoes name is
enclosed in "" in SQL. The " will be stripped of the identifyer in
dbclass.py. (In MySQL you have to use ` instead of ", both
possibilities are handled correctly).

As a sidenote I'd like to welcome Charles Brandt on the list, who
brought this up. Iresent his mail and my response to orm-users.

Regards
Diedrich

-- 
Diedrich Vorberg <diedrich at tux4web.de>      .---.   /             \
http://tux4web.de Tel: 02302 425269        /     \ ((__-^^-,-^^-__))
                                           \.O-O./  `-_---' `---_-'
"Unix is simple, but it takes a genius     /`\_/`\   `--|o` 'o|--'
to understand the simplicity."            //  _  \\     \  `  /
                      - Dennis Ritchie   | \     )|_     ): :(
                                        /`\_`>  <_/ \    :o_o:
     Associate Member of the FSF #1245  \__/'---'\__/     "-"



More information about the orm-devel mailing list