Index: lib/sqlalchemy/schema.py
===================================================================
--- lib/sqlalchemy/schema.py	(revision 778)
+++ lib/sqlalchemy/schema.py	(working copy)
@@ -340,12 +340,27 @@
         # ForeignKey inits its remote column as late as possible, so tables can
         # be defined without dependencies
         if self._column is None:
+            err = ValueError("Invalid foreign key column specification: " + self._colspec)
             if isinstance(self._colspec, str):
-                m = re.match(r"([\w_-]+)(?:\.([\w_-]+))?", self._colspec)
+                m = re.match(r"^([\w_-]+)(?:\.([\w_-]+))?(?:\.([\w_-]+))?$",
+                             self._colspec)
                 if m is None:
-                    raise "Invalid foreign key column specification: " + self._colspec
-                (tname, colname) = m.group(1, 2)
-                table = Table(tname, self.parent.engine, mustexist = True)
+                    raise err
+                groups = tuple(x for x in m.groups() if x is not None)
+                print groups
+                # Default to the containing table's schema.
+                # This assumes that _set_parent() has been called.
+                schema = self.parent.table.schema
+                colname = None
+                if len(groups) == 1:
+                    tname = groups[0]
+                elif len(groups) == 2:
+                    (tname, colname) = groups
+                elif len(groups) == 3:
+                    (schema, tname, colname) = groups
+                else:
+                    raise err
+                table = Table(tname, self.parent.engine, mustexist = True, schema=schema)
                 if colname is None:
                     key = self.parent
                     self._column = table.c[self.parent.key]
@@ -431,6 +446,3 @@
     def visit_sequence(self, sequence):
         """visit a Sequence."""
         pass
-
-            
-            
\ No newline at end of file
