Fork me on GitHub
Subscribe 2

Ticket #365 (fixed enhancement)

Add tables related queries to database layer

  • Created: 2011-03-20 12:14:07
  • Reported by: Reines
  • Assigned to: Franz
  • Milestone: 2.0-alpha1
  • Component: database
  • Priority: normal

The database layer currently supported most "normal" query types, but has no support for modifying table structure.

We should add queries/methods for:

  • create table

  • drop table

  • rename table

  • table exists

  • add field

  • field exists

  • alter field

  • drop field

  • add index

  • index exists

  • drop index

  • table info


Reines 2011-03-24 09:51:28

  • Owner set to Reines.

Reines 2011-03-27 17:18:39

  • Description changed. (Diff)

I've added support for CreateTable and DropTable.

Reines 2011-03-27 18:39:14

Added RenameTable support.

Reines 2011-04-06 16:13:39

  • Owner Reines removed.

Franz 2011-09-14 16:19:28

  • Owner set to Franz.

Franz 2011-10-19 15:03:00

  • Description changed. (Diff)

Franz 2011-10-25 23:58:12

  • Description changed. (Diff)

A query type for fetching table information (stuff like all columns, indices etc.) is also nice to have.

Franz 2011-10-26 22:25:27

  • Description changed. (Diff)

"table exists" and "index exists" are both done.

Franz 2011-10-26 22:31:28

  • Description changed. (Diff)

So are "drop field" and "drop index".

Franz 2011-10-26 22:45:15

Commit 48f96b5 to database master

Implement fieldExists for PostgreSQL and SQLite. And some minor fixes.
Related to #365.

Franz 2011-10-26 22:47:10

  • Description changed. (Diff)

So is "field exists".

Franz 2011-10-26 23:00:23

Commit f1944c8 to database master

Implement addIndex for PostgreSQL.
Related to #365.

Franz 2011-10-26 23:00:51

  • Description changed. (Diff)

And "add index" is implemented.

Franz 2011-10-27 13:04:53

  • Description changed. (Diff)

"Add field" is supported by all layers.

Franz 2011-10-27 13:38:43

  • Description changed. (Diff)

And so is "alter field". Not necessary (and thus empty) for SQLite.

Franz 2011-10-31 14:31:33

Commit 56582c2 to database master

SQLite does not use the standard syntax for adding an index.
Related to #365.

Franz 2011-10-31 14:47:02

Commit 7e66272 to database master

Fix dropField for SQLite.
Related to #365.

Franz 2011-10-31 15:44:11

Commit 06d88c2 to database master

Implement tableInfo for all three database engines.
Related to #365.

Franz 2011-10-31 15:46:12

  • Description changed. (Diff)
  • Status changed from open to fixed.

And, with "table info" implemented, this is finally done!

Well, I'm sure there are still loads of bugs to catch, but we're getting there.

Next up are the unit tests which will help finding those pesky little bugs.