summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEvgeny Fadeev <evgeny.fadeev@gmail.com>2012-05-01 14:26:38 -0300
committerEvgeny Fadeev <evgeny.fadeev@gmail.com>2012-05-01 14:26:38 -0300
commitdcc992c34db1d22bb03296d2b61782ed5f85f0f2 (patch)
tree176c680ce05419e6351b16599512aa79183d8eb5
parentfe8c65bfcf6c55e4037ce125f244fdb11c0fb01e (diff)
downloadaskbot-dcc992c34db1d22bb03296d2b61782ed5f85f0f2.tar.gz
askbot-dcc992c34db1d22bb03296d2b61782ed5f85f0f2.tar.bz2
askbot-dcc992c34db1d22bb03296d2b61782ed5f85f0f2.zip
deleted an unused file
-rw-r--r--askbot/migrations/0088_install__post_view__for__development.py2
-rw-r--r--askbot/models/post_view.sql255
2 files changed, 2 insertions, 255 deletions
diff --git a/askbot/migrations/0088_install__post_view__for__development.py b/askbot/migrations/0088_install__post_view__for__development.py
index e948299a..f8de0c50 100644
--- a/askbot/migrations/0088_install__post_view__for__development.py
+++ b/askbot/migrations/0088_install__post_view__for__development.py
@@ -8,6 +8,8 @@ import askbot
class Migration(SchemaMigration):
+ """This migration was for development only and now it
+ is effectively a no-op"""
def forwards(self, orm):
# create_post_view_sql = open(
diff --git a/askbot/models/post_view.sql b/askbot/models/post_view.sql
deleted file mode 100644
index c55b4027..00000000
--- a/askbot/models/post_view.sql
+++ /dev/null
@@ -1,255 +0,0 @@
-/*
-
-SQL for creating a database VIEW for the unmanaged `Post` model
-
-Tested with: SQLite3
-
-Important: String literals should be wrapped in single quotes (http://www.sqlite.org/lang_keywords.html)
-
-*/
-
--- DROP VIEW IF EXISTS askbot_post;
-
-CREATE VIEW askbot_post AS
-
-/*
-
-Answers
-
-*/
-
-SELECT
- answer.id + 1000000 AS id, -- fake unique ID - has to stay consistent with Post.parent_id for answer comments (defined below) !
-
- /* Some required pseudo-fields */
- 'answer' AS post_type,
-
- NULL AS parent_id,
- joined_question.thread_id AS thread_id,
-
- answer.id AS self_answer_id,
- NULL AS self_question_id,
- NULL AS self_comment_id,
-
- /* Shared fields from content.Content */
- answer.author_id,
- answer.added_at,
-
- answer.deleted,
- answer.deleted_at,
- answer.deleted_by_id,
-
- answer.wiki,
- answer.wikified_at,
-
- answer.locked,
- answer.locked_by_id,
- answer.locked_at,
-
- answer.score,
- answer.vote_up_count,
- answer.vote_down_count,
-
- answer.comment_count,
- answer.offensive_flag_count,
-
- answer.last_edited_at,
- answer.last_edited_by_id,
-
- answer.html,
- answer.text,
-
- answer.summary,
-
- answer.is_anonymous
-
-FROM answer
-
-INNER JOIN question as joined_question
-ON joined_question.id=answer.question_id
-
-UNION
-
-/*
-
-Questions
-
-*/
-
-SELECT
- question.id AS id, -- fake unique ID - has to stay consistent with Post.parent_id for question comments (defined below) !
-
- /* Some required pseudo-fields */
- 'question' AS post_type,
-
- NULL AS parent_id,
- question.thread_id,
-
- NULL AS self_answer_id,
- question.id AS self_question_id,
- NULL AS self_comment_id,
-
- /* Shared fields from content.Content */
- question.author_id,
- question.added_at,
-
- question.deleted,
- question.deleted_at,
- question.deleted_by_id,
-
- question.wiki,
- question.wikified_at,
-
- question.locked,
- question.locked_by_id,
- question.locked_at,
-
- question.score,
- question.vote_up_count,
- question.vote_down_count,
-
- question.comment_count,
- question.offensive_flag_count,
-
- question.last_edited_at,
- question.last_edited_by_id,
-
- question.html,
- question.text,
-
- question.summary,
-
- question.is_anonymous
-
-FROM question
-
-
-UNION
-
-/*
-
-Comments to Questions
-
-*/
-
-
-SELECT
- comment.id + 2000000 AS id, -- fake unique ID
-
- /* Some required pseudo-fields */
- 'comment' AS post_type,
-
- joined_question.id AS parent_id, -- has to stay consistent with Post.is for joined_questions !!
- joined_question.thread_id AS thread_id,
-
- NULL AS self_answer_id,
- NULL AS self_question_id,
- comment.id AS self_comment_id,
-
- /* Shared fields from content.Content */
- comment.user_id AS author_id,
- comment.added_at,
-
- 0 AS deleted,
- NULL AS deleted_at,
- NULL AS deleted_by_id,
-
- 0 AS wiki,
- NULL AS wikified_at,
-
- 0 AS locked,
- NULL AS locked_by_id,
- NULL AS locked_at,
-
- comment.score,
- comment.score AS vote_up_count,
- 0 AS vote_down_count,
-
- 0 AS comment_count,
- comment.offensive_flag_count,
-
- NULL AS last_edited_at,
- NULL AS last_edited_by_id,
-
- comment.html,
- comment.comment AS text,
-
- '' AS summary,
-
- 0 AS is_anonymous
-
-FROM comment
-
-INNER JOIN django_content_type AS ct
-ON ct.id=comment.content_type_id AND ct.app_label='askbot' AND ct.model='question'
-
-INNER JOIN question AS joined_question
-ON joined_question.id=comment.object_id
-
-
-UNION
-
-/*
-
-Comments to Answers
-
-*/
-
-
-SELECT
- comment.id + 2000000 AS id, -- fake unique ID
-
- /* Some required pseudo-fields */
- 'comment' AS post_type,
-
- joined_answer.id + 1000000 AS parent_id, -- has to stay consistent with Post.is for joined_questions !!
- joined_question.thread_id AS thread_id,
-
- NULL AS self_answer_id,
- NULL AS self_question_id,
- comment.id AS self_comment_id,
-
- /* Shared fields from content.Content */
- comment.user_id AS author_id,
- comment.added_at,
-
- 0 AS deleted,
- NULL AS deleted_at,
- NULL AS deleted_by_id,
-
- 0 AS wiki,
- NULL AS wikified_at,
-
- 0 AS locked,
- NULL AS locked_by_id,
- NULL AS locked_at,
-
- comment.score,
- comment.score AS vote_up_count,
- 0 AS vote_down_count,
-
- 0 AS comment_count,
- comment.offensive_flag_count,
-
- NULL AS last_edited_at,
- NULL AS last_edited_by_id,
-
- comment.html,
- comment.comment AS text,
-
- '' AS summary,
-
- 0 AS is_anonymous
-
-FROM comment
-
-INNER JOIN django_content_type AS ct
-ON ct.id=comment.content_type_id AND ct.app_label='askbot' AND ct.model='answer'
-
-INNER JOIN answer AS joined_answer
-ON joined_answer.id=comment.object_id
-
-INNER JOIN question AS joined_question
-ON joined_question.id=joined_answer.question_id
-
-; -- End of SQL statement