Permalink
Browse files

Improving ORM (missing commit)

  • Loading branch information...
1 parent 8eaf4bc commit ff6a4cde8b6853d346aa2a4744108ca9dc0e83c0 @alsonkemp committed Jun 9, 2009
Showing with 8 additions and 3 deletions.
  1. +8 −3 Config/Database.hs
View
@@ -1,18 +1,23 @@
module Config.Database (
databaseConnection,
+ ormAdapter
) where
import System.Log.Logger
+import Database.HDBC
-- Your favorite HDBC driver
-import Database.HDBC.PostgreSQL
+import Database.HDBC.ODBC
+import qualified Turbinado.Database.ORM.Adapters.MySQL as M
import Turbinado.Environment.Types
----------------------------------------------------------------
-- Database connection
----------------------------------------------------------------
--- databaseConnection :: Maybe (IO Connection)
+--databaseConnection :: Maybe (IO c)
-- databaseConnection = Nothing
-databaseConnection = Just $ connectPostgreSQL "host=localhost dbname=turbinado user=turbinado password=turbinado"
+--databaseConnection = Just $ connectPostgreSQL "host=localhost dbname=turbinado user=turbinado password=turbinado"
+databaseConnection = Just $ connectODBC "DSN=turbinado;USER=user;password=password"
+ormAdapter = M.ormAdapter

0 comments on commit ff6a4cd

Please sign in to comment.