alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

jforum example source code file (postgresql_rc4_to_rc5.sql)

This example jforum source code file (postgresql_rc4_to_rc5.sql) is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Java - jforum tags/keywords

alter, column, create, default, drop, integer, integer, not, not, null, null, table, table, varchar

The jforum postgresql_rc4_to_rc5.sql source code

CREATE TABLE jforum_posts_text (
	post_id INTEGER NOT NULL,
	post_text TEXT,
	post_subject VARCHAR(100) DEFAULT NULL,
	PRIMARY KEY ( post_id )
);

INSERT INTO jforum_posts_text ( post_id, post_text, post_subject ) SELECT post_id, post_text, post_subject FROM jforum_posts;

ALTER TABLE jforum_posts DROP COLUMN post_subject;
ALTER TABLE jforum_posts DROP COLUMN post_text;

CREATE TABLE jforum_privmsgs_text (
	privmsgs_id INTEGER NOT NULL,
	privmsgs_text TEXT
);
CREATE INDEX idx_pm_text_id ON jforum_privmsgs_text (privmsgs_id);

INSERT INTO jforum_privmsgs_text ( privmsgs_id, privmsgs_text ) SELECT privmsgs_id, privmsgs_text FROM jforum_privmsgs;

ALTER TABLE jforum_privmsgs DROP COLUMN privmsgs_text;

DROP TABLE jforum_resutls;
CREATE TABLE jforum_vote_results (
  vote_id INTEGER NOT NULL DEFAULT 0,
  vote_option_id INTEGER NOT NULL DEFAULT 0,
  vote_option_text VARCHAR(255) NOT NULL DEFAULT '',
  vote_result INTEGER NOT NULL DEFAULT 0
);

Other jforum examples (source code examples)

Here is a short list of links related to this jforum postgresql_rc4_to_rc5.sql source code file:

... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2024 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.