• Post Reply Bookmark Topic Watch Topic
  • New Topic

library task given a book per student

 
sarathd kumar
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi...

i am working on library project we already set each student only take 2 books after he take a book it it show you are reaching your limit kindly return your book

so that i using this query but i can't get it

EX: when i issue a book it save on issue table like this so that i am using this kind of logic,

insert into issues(mid,isbn,bname,subject,bdate,rdate,status,bid )
values('1','100','java','java','2014-08-14','2014-08-14','s','0') where
SELECT * FROM issues GROUP BY mid HAVING ( COUNT(mid) <= '2' )

Please Help me....
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What is this INSERT supposed to do, and what is the connection between it and the requirement not to lend more than 2 books per person?
 
sarathd kumar
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
 
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!