Click here to Skip to main content
15,920,383 members
Home / Discussions / Database
   

Database

 
AnswerRe: Regarding stored procedure parameters Pin
kubben29-Jun-07 2:01
kubben29-Jun-07 2:01 
NewsNAKRA FINAL Pin
NAKRAINC29-Jun-07 1:45
NAKRAINC29-Jun-07 1:45 
Questionhow to enter date Pin
ArchaBhandare29-Jun-07 0:37
ArchaBhandare29-Jun-07 0:37 
QuestionDate time storing null values Pin
Rajiya28-Jun-07 23:11
Rajiya28-Jun-07 23:11 
AnswerRe: Date time storing null values Pin
aamironline29-Jun-07 1:50
aamironline29-Jun-07 1:50 
GeneralRe: Date time storing null values Pin
Rajiya29-Jun-07 1:59
Rajiya29-Jun-07 1:59 
GeneralRe: Date time storing null values Pin
kguinn3-Jul-07 8:06
kguinn3-Jul-07 8:06 
QuestionDateTime value problem Pin
phantanagu28-Jun-07 22:50
phantanagu28-Jun-07 22:50 
AnswerRe: DateTime value problem Pin
kubben29-Jun-07 1:57
kubben29-Jun-07 1:57 
Questioni Problem in Installing SQL7 localy Pin
Vimalsoft(Pty) Ltd28-Jun-07 22:18
professionalVimalsoft(Pty) Ltd28-Jun-07 22:18 
AnswerRe: i Problem in Installing SQL7 localy Pin
Dave Kreskowiak29-Jun-07 7:56
mveDave Kreskowiak29-Jun-07 7:56 
AnswerRe: i Problem in Installing SQL7 localy Pin
Mike Dimmick29-Jun-07 14:43
Mike Dimmick29-Jun-07 14:43 
Questionspace in-between search parameters Pin
acodman28-Jun-07 22:18
acodman28-Jun-07 22:18 
AnswerRe: space in-between search parameters Pin
Sgg24529-Jun-07 0:36
Sgg24529-Jun-07 0:36 
AnswerRe: space in-between search parameters Pin
Sgg24529-Jun-07 0:39
Sgg24529-Jun-07 0:39 
NewsNAKRA Pin
NAKRAINC28-Jun-07 22:10
NAKRAINC28-Jun-07 22:10 
GeneralRe: NAKRA Pin
Pete O'Hanlon28-Jun-07 22:20
mvePete O'Hanlon28-Jun-07 22:20 
GeneralRe: NAKRA Pin
kubben29-Jun-07 1:53
kubben29-Jun-07 1:53 
NewsNAKRA Pin
NAKRAINC28-Jun-07 22:09
NAKRAINC28-Jun-07 22:09 
NewsNAKRA Pin
NAKRAINC28-Jun-07 22:08
NAKRAINC28-Jun-07 22:08 
AS:2
QNO : 1
SELECT MEMBER_NAME
FROM MEMBER
WHERE ACC_OPEN_DATE>'31-DEC-2005' AND ACC_OPEN_DATE <'1-JAN-2007';

OR

SELECT MEMBER_NAME
FROM MEMBER
WHERE ACC_OPEN_DATE BETWEEN '31-DEC-2005' AND '1-JAN-2007';

QNO : 2
SELECT BOOK_NAME,AUTHOR
FROM BOOK
WHERE AUTHOR='LONI' AND COST>600;

QNO : 3
SELECT LIB_ISSUE_ID,BOOK_NO,MEMBER_ID,ISSUE_DATE,RETURN_DATE
FROM ISSUE
WHERE COMMENTS='PENDING';


QNO : 4
UPDATE ISSUE SET RETURN_DATE='31-DEC-06'
WHERE RETURN_DATE=NULL AND (LIB_ISSUE_ID!=7005 OR LIB_ISSUE_ID!=7006);

QNO : 5
SELECT LIB_ISSUE_ID,BOOK_NO,MEMBER_ID,ISSUE_DATE,RETURN_DATE
FROM ISSUE
WHERE (SYSDATE-ISSUE_DATE)>30 AND (ISSUE_DATE-RETURN_DATE)>30;

OR

SELECT LIB_ISSUE_ID,BOOK_NO,MEMBER_ID,ISSUE_DATE,RETURN_DATE
FROM ISSUE
WHERE ((SYSDATE-ISSUE_DATE)>30 AND RETURN_DATE=NULL) OR (ISSUE_DATE-RETURN_DATE)>30;

QNO : 6
SELECT BOOK_NAME
FROM BOOK
WHERE (COST BETWEEN 500 AND 750) AND CATEGORY='DATABASE';

QNO : 7
SELECT BOOK_NAME
FROM BOOK
WHERE CATEGORY IN('SCIENCE','DATABASE','FICTION','MANAGEMENT');

QNO : 8
SELECT MEMBER_ID,MEMBER_NAME,PENALTY_AMOUNT
FROM MEMBER
ORDER BY PENALTY_AMOUNT DESC;

OR

SELECT MEMBER_ID,MEMBER_NAME,PENALTY_AMOUNT
FROM MEMBER
ORDER BY 3 DESC;

QNO : 9
SELECT BOOK_NAME,COST
FROM BOOK
ORDER BY BOOK_NAME,COST DESC;

OR

SELECT BOOK_NAME,COST
FROM BOOK
ORDER BY 1,2 DESC;

QN0 : 10
SELECT BOOK_NAME
FROM BOOK
WHERE BOOK_NAME LIKE '%SQL%';

QNO : 11
SELECT MEMBER_NAME
FROM MEMBER
WHERE MEMBER_NAME LIKE ('G%I%' ||'R%I%');

QNO : 12
SELECT INITCAP(BOOK_NAME),UPPER(AUTHOR)
FROM BOOK
ORDER BY 1 DESC;

QNO : 13
SELECT BOOK_NO, CONCAT('IS WRRITTEN ', 'BY') " ---------------- ", AUTHOR AS NAME
FROM BOOK;

OR

SELECT CONCAT( BOOK_NO,' IS WRITTEN BY') "BOOKNO ------------------",AUTHOR AS NAME
FROM BOOK;

QNO : 14
SELECT LIB_ISSUE_ID,BOOK_NO,TO_CHAR(TO_DATE(ISSUE_DATE,'DD-MM-YY'),'Day,Month,DD,YYYY') ,
TO_CHAR(TO_DATE(RETURN_DATE,'DD-MM-YY'),'Day,Month,DD,YYYY')
FROM ISSUE
WHERE MEMBER_ID=101;

QNO : 15 & 16
SELECT CATEGORY,
DECODE(CATEGORY,'DATABASE','D','SCIENCE','S','RDBMS','R','OTHERS','O')
FROM BOOK;

QNO : 17
SELECT CONCAT( RPAD(BOOK_NAME,20,'*'),LPAD(AUTHOR,20,'*') )
FROM BOOK;

QNO : 18
SELECT LIB_ISSUE_ID,ISSUE_DATE,RETURN_DATE,COUNT(ISSUE_DATE-RETURN_DATE) "NO OF DAYS"
FROM ISSUE;

QNO : 19
SELECT MEMBER_ID,MEMBER_NAME,ACC_OPEN_DATE,MAX_BOOKS_ALLOWED,PENALTY_AMOUNT
FROM MEMBER
ORDER BY 3 DESC;

QNO : 20
SELECT COUNT(BOOK_NO)
FROM ISSUE
WHERE MEMBER_ID=101;

QNO : 21
SELECT SUM(PENALTY_AMOUNT)
FROM MEMBER;

QNO : 22
SELECT SUM(COST)
FROM BOOK
WHERE CATEGORY='DATABASE';

QNO : 23
SELECT BOOK_NAME,COST
FROM BOOK ;

QNO : 24
SELECT BOOK_NO,MIN(ISSUE_DATE)
FROM ISSUE;

QNO : 25
SELECT BOOK_NO,MAX(ISSUE_DATE)
FROM ISSUE;

QNO : 26
SELECT AVG(COST)
FROM BOOK
WHERE CATEGORY='DATABASE';

*****************************************************************************
NewsNAKRA Pin
NAKRAINC28-Jun-07 22:06
NAKRAINC28-Jun-07 22:06 
Questionhow to encrypt whole Database ? Pin
hdv21228-Jun-07 21:51
hdv21228-Jun-07 21:51 
AnswerRe: how to encrypt whole Database ? Pin
originSH29-Jun-07 0:06
originSH29-Jun-07 0:06 
QuestionMerge Replication rights Pin
Sgg24528-Jun-07 20:15
Sgg24528-Jun-07 20:15 
QuestionCritical probs to display records..., Pin
Member 387988128-Jun-07 18:02
Member 387988128-Jun-07 18:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.