By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,323 Members | 1,216 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,323 IT Pros & Developers. It's quick & easy.

subquery not allowed here

P: n/a
Oracle 9.
Trying to put a constraint. The date_time field in table Visit should
be >= than date_admitted field in table Admission.

CREATE TABLE Visit (
adid INT REFERENCES myAdmission(adid),
date_time DATE CONSTRAINT date_time_limits
CHECK (date_time >= ALL
(SELECT date_admitted
FROM Admission, Visit
WHERE Admission.adid = Visit.adid)),
);

I get subquery not allowed here. I don't have much experience, but as
far as i can tell from my book this should work. But then again I just
learned that oracle does not allow ASSERTION which is taught in this
book; so is this the same problem? If yes could someone tell me how to
get around this please.
Jul 19 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.