Browse Source

Merge remote-tracking branch 'azure/round7-python-update' into round7-python-update

INADA Naoki 12 years ago
parent
commit
d0aa799070
3 changed files with 5 additions and 8 deletions
  1. 3 3
      config/create-postgres.sql
  2. 2 5
      django/hello/world/models.py
  3. BIN
      servicestack/src/.nuget/NuGet.exe

+ 3 - 3
config/create-postgres.sql

@@ -1,15 +1,15 @@
 DROP TABLE IF EXISTS World;
-CREATE TABLE  World (
+CREATE TABLE  "World" (
   id integer NOT NULL,
   randomNumber integer NOT NULL default 0,
   PRIMARY KEY  (id)
 );
 
-INSERT INTO World (id, randomNumber)
+INSERT INTO "World" (id, randomNumber)
 SELECT x.id, random() * 10000 + 1 FROM generate_series(1,10000) as x(id);
 
 DROP TABLE IF EXISTS Fortune;
-CREATE TABLE  Fortune (
+CREATE TABLE  "Fortune" (
   id integer NOT NULL,
   message varchar(2048) NOT NULL,
   PRIMARY KEY  (id)

+ 2 - 5
django/hello/world/models.py

@@ -1,16 +1,13 @@
 from django.db import models
 
-import os
-MYSQL = os.environ['DJANGO_DB'] == 'mysql'
-
 # Create your models here.
 
 class World(models.Model):
   randomnumber = models.IntegerField()
   class Meta:
-    db_table = 'World' if MYSQL else 'world'
+    db_table = 'World'
 
 class Fortune(models.Model):
   message = models.CharField(max_length=65535)
   class Meta:
-    db_table = 'Fortune' if MYSQL else 'fortune'
+    db_table = 'Fortune'

BIN
servicestack/src/.nuget/NuGet.exe