#6148: Add generic support for database schemas
---------------------------------------------------+------------------------
          Reporter:  ikelly                        |         Owner:             
                    
            Status:  new                           |     Milestone:             
                    
         Component:  Database layer (models, ORM)  |       Version:  SVN        
                    
        Resolution:                                |      Keywords:  oracle 
postgresql mysql schemas
             Stage:  Accepted                      |     Has_patch:  1          
                    
        Needs_docs:  0                             |   Needs_tests:  0          
                    
Needs_better_patch:  1                             |  
---------------------------------------------------+------------------------
Changes (by oldium):

 * cc: oldium (added)

Comment:

 Replying to [comment:16 anonymous]:
 > So, are MySQL databases really equivalents of schemas? If databases are
 like schemas, it would need to patch model's db_schemas to
 {{{test_schemaname}}} while testing. I don't like the idea of
 monkeypatching names for tests, as custom SQL will fail with different
 "schema" (not really) names. Isn't cleaner to fallback to less features
 for MySQL (as we do for SQLite)?

 Just few notes from a random reader:

  1. I had a look at MySQL manual and the {{{CREATE SCHEMA}}} command is
 synonym to {{{CREATE DATABASE}}} (see
 [http://dev.mysql.com/doc/refman/5.0/en/create-database.html 12.1.6.
 CREATE DATABASE Syntax]). The database name is rather flexible and can
 contain any character except {{{NUL}}} ({{{\0}}}) - the name is coded in a
 special way for the file system (see
 [http://dev.mysql.com/doc/refman/5.4/en/identifier-mapping.html 8.2.3.
 Mapping of Identifiers to File Names]).

  2. The patch contains {{{DROP SCHEMA}}} ''{{{IF EXISTS}}}'' extension for
 PostgreSQL as well, but it has been supported since the
 [http://www.postgresql.org/docs/8.2/static/release-8-2.html 8.2 version].
 Maybe it could be noted somewhere.

-- 
Ticket URL: <http://code.djangoproject.com/ticket/6148#comment:17>
Django <http://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django updates" 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/django-updates?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to