Hi, I want to convert this checked in sql report into renew sql report. How i can convert this report. guide me. SELECT b.title, b.author, i.itemcallnumber, i.barcode, c.returndate FROM (SELECT iss.returndate, iss.itemnumber FROM issues iss, (SELECT @StartDate:=<<Between (yyyy-mm-dd)|date>>,@EndDate:=<<and (yyyy-mm-dd)|date>>) AS var WHERE date(iss.returndate) BETWEEN @StartDate AND @EndDate UNION ALL SELECT oi.returndate, oi.itemnumber FROM old_issues oi WHERE date(oi.returndate) BETWEEN @StartDate AND @EndDate) AS c LEFT JOIN items i USING (itemnumber) LEFT JOIN biblio b USING (biblionumber) WHERE i.homebranch=<<Item belongs TO|branches>> -- *Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad.
Hello Arshad, The renew information is in the same tables issues/old_issues, there are lastreneweddate and renewals. Note that asking the question only once is enough :) Regards, Jonathan On Mon, 23 Apr 2018 at 10:47 Arshad Iqbal <arshadsanwal@gmail.com> wrote:
Hi, I want to convert this checked in sql report into renew sql report. How i can convert this report. guide me.
SELECT b.title, b.author, i.itemcallnumber, i.barcode, c.returndate FROM (SELECT iss.returndate, iss.itemnumber FROM issues iss, (SELECT @StartDate:=<<Between (yyyy-mm-dd)|date>>,@EndDate:=<<and (yyyy-mm-dd)|date>>) AS var WHERE date(iss.returndate) BETWEEN @StartDate AND @EndDate UNION ALL SELECT oi.returndate, oi.itemnumber FROM old_issues oi WHERE date(oi.returndate) BETWEEN @StartDate AND @EndDate) AS c LEFT JOIN items i USING (itemnumber) LEFT JOIN biblio b USING (biblionumber) WHERE i.homebranch=<<Item belongs TO|branches>>
--
*Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad. _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
I have added reneweddate and renwal as well in sql report but working not good On Mon, Apr 23, 2018 at 7:38 PM, Jonathan Druart < jonathan.druart@bugs.koha-community.org> wrote:
Hello Arshad,
The renew information is in the same tables issues/old_issues, there are lastreneweddate and renewals.
Note that asking the question only once is enough :)
Regards, Jonathan
On Mon, 23 Apr 2018 at 10:47 Arshad Iqbal <arshadsanwal@gmail.com> wrote:
Hi, I want to convert this checked in sql report into renew sql report. How i can convert this report. guide me.
SELECT b.title, b.author, i.itemcallnumber, i.barcode, c.returndate FROM (SELECT iss.returndate, iss.itemnumber FROM issues iss, (SELECT @StartDate:=<<Between (yyyy-mm-dd)|date>>,@EndDate:=<<and (yyyy-mm-dd)|date>>) AS var WHERE date(iss.returndate) BETWEEN @StartDate AND @EndDate UNION ALL SELECT oi.returndate, oi.itemnumber FROM old_issues oi WHERE date(oi.returndate) BETWEEN @StartDate AND @EndDate) AS c LEFT JOIN items i USING (itemnumber) LEFT JOIN biblio b USING (biblionumber) WHERE i.homebranch=<<Item belongs TO|branches>>
--
*Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad. _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
-- *Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad. Phone number:051-90851371 Cell no.+923444900809
How look like the new version of the query? On Mon, 23 Apr 2018 at 12:02 Arshad Iqbal <arshadsanwal@gmail.com> wrote:
I have added reneweddate and renwal as well in sql report but working not good On Mon, Apr 23, 2018 at 7:38 PM, Jonathan Druart < jonathan.druart@bugs.koha-community.org> wrote:
Hello Arshad,
The renew information is in the same tables issues/old_issues, there are lastreneweddate and renewals.
Note that asking the question only once is enough :)
Regards, Jonathan
On Mon, 23 Apr 2018 at 10:47 Arshad Iqbal <arshadsanwal@gmail.com> wrote:
Hi, I want to convert this checked in sql report into renew sql report. How i can convert this report. guide me.
SELECT b.title, b.author, i.itemcallnumber, i.barcode, c.returndate FROM (SELECT iss.returndate, iss.itemnumber FROM issues iss, (SELECT @StartDate:=<<Between (yyyy-mm-dd)|date>>,@EndDate:=<<and (yyyy-mm-dd)|date>>) AS var WHERE date(iss.returndate) BETWEEN @StartDate AND @EndDate UNION ALL SELECT oi.returndate, oi.itemnumber FROM old_issues oi WHERE date(oi.returndate) BETWEEN @StartDate AND @EndDate) AS c LEFT JOIN items i USING (itemnumber) LEFT JOIN biblio b USING (biblionumber) WHERE i.homebranch=<<Item belongs TO|branches>>
--
*Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad. _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
--
*Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad. Phone number:051-90851371 Cell no.+923444900809 <+92%20344%204900809>
SELECT b.title, b.author, i.itemcallnumber, i.barcode, c.renewaldate FROM (SELECT iss.renewaldate, iss.itemnumber FROM issues iss, (SELECT @StartDate:=<<Between (yyyy-mm-dd)|date>>,@EndDate:=<<and (yyyy-mm-dd)|date>>) AS var WHERE date(iss.returndate) BETWEEN @StartDate AND @EndDate UNION ALL SELECT oi.renewaldate, oi.itemnumber FROM old_issues oi WHERE date(oi.renewaldate) BETWEEN @StartDate AND @EndDate) AS c LEFT JOIN items i USING (itemnumber) LEFT JOIN biblio b USING (biblionumber) WHERE i.homebranch=<<Item belongs TO|branches>> On Mon, Apr 23, 2018 at 8:12 PM, Jonathan Druart < jonathan.druart@bugs.koha-community.org> wrote:
How look like the new version of the query?
On Mon, 23 Apr 2018 at 12:02 Arshad Iqbal <arshadsanwal@gmail.com> wrote:
I have added reneweddate and renwal as well in sql report but working not good On Mon, Apr 23, 2018 at 7:38 PM, Jonathan Druart < jonathan.druart@bugs.koha-community.org> wrote:
Hello Arshad,
The renew information is in the same tables issues/old_issues, there are lastreneweddate and renewals.
Note that asking the question only once is enough :)
Regards, Jonathan
On Mon, 23 Apr 2018 at 10:47 Arshad Iqbal <arshadsanwal@gmail.com> wrote:
Hi, I want to convert this checked in sql report into renew sql report. How i can convert this report. guide me.
SELECT b.title, b.author, i.itemcallnumber, i.barcode, c.returndate FROM (SELECT iss.returndate, iss.itemnumber FROM issues iss, (SELECT @StartDate:=<<Between (yyyy-mm-dd)|date>>,@EndDate:=<<and (yyyy-mm-dd)|date>>) AS var WHERE date(iss.returndate) BETWEEN @StartDate AND @EndDate UNION ALL SELECT oi.returndate, oi.itemnumber FROM old_issues oi WHERE date(oi.returndate) BETWEEN @StartDate AND @EndDate) AS c LEFT JOIN items i USING (itemnumber) LEFT JOIN biblio b USING (biblionumber) WHERE i.homebranch=<<Item belongs TO|branches>>
--
*Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad. _______________________________________________ Koha mailing list http://koha-community.org Koha@lists.katipo.co.nz https://lists.katipo.co.nz/mailman/listinfo/koha
--
*Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad. Phone number:051-90851371 Cell no.+923444900809 <+92%20344%204900809>
-- *Muhammad Arshad Iqbal* Assistant Librarian at Publishing and Student Affairs Directorate, National University of Science and Technology (NUST) Islamabad. Phone number:051-90851371 Cell no.+923444900809
participants (2)
-
Arshad Iqbal -
Jonathan Druart