-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

OK. I hoped, there is a possibility to use ManyToManyField. Well, the
Model-way is already implemented but i would like to use
ManyToManyField. Anyway, it works.

joshuajonah wrote:
| You need to define your many-to-many table in the model, and then use
| the "db_column" option to name the fields in that table.
|
| http://www.djangoproject.com/documentation/models/custom_columns/
|
| On Jun 24, 1:43 pm, Stephan Jäkel <[EMAIL PROTECTED]> wrote:
| hi,
|
| joshuajonah wrote:
|
| | You should use the 'db_table' option for any given model. This will
| | allow you to use a specific table name and it also works on many-to-
| | many relational tables if you define them specifically in your
| | models.py.
|
| yes, db_table helps do define the many-to-many table. but i also need to
| define the field-names in the many-to-many table, because they dont
| match the names generated by the many-to-many related manager (and i
| cant rename them).
|
| |
| | You can get the info on them (scattered everywhere) in this doc:
| |http://www.djangoproject.com/documentation/model-api/
| |
| | Does that help?
|
| a bit, but thanks anyway :-)
|
| |
| | On Jun 24, 12:41 pm, Stephan Jäkel <[EMAIL PROTECTED]> wrote:
| | Hi list,
| |
| | i'm currently implementing django as management interface for an
| | existing project. until now, nearly everything worked as expected,
| | but i've got a problem.
| |
| | is there a way to override the join_table, source_col_name and
| | target_col_name in many-to-many relations. as i read django's source i
| | think these properties define the names used in the database.
| | and i cant change the database schema without getting many problems.
| |
| | is there another way to solve this problem excluding the possibility to
| | create a database view to map the tablename and columns?
| |
| | best regards,
|
| 
- --
Stephan Jäkel

e-Mail  : [EMAIL PROTECTED]
Website : http://rdev.info
Mobile  : +49 163 458 9 173

What do you mean that could take down the whole network?
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIYT+y4B/i3Mb6qe4RAgjqAJ93PoRas8LKnG5Fyg1TD0/BhVaLTACfSSi/
q6awo8ahMK2xNU/2Ig5jf6Q=
=mjII
-----END PGP SIGNATURE-----

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to