Sabtu, 10 Agustus 2013

PHP Indonesia - Facebook: gan mau naya nihh ane mau bikin report pertahun ...

PHP Indonesia - Facebook
PHP Indonesia is a community for everyone that loves PHP. Our focus is in the PHP world but our topics encompass the entire LAMP stack. Topics include PHP coding, to memcached handling, db optimizations, server stack, web server tuning, code deploying, hosting options and much much more. Youtube Channel : http://www.youtube.com/user/OurPHPIndonesia Twitter : @php_indonesia NOTE: Rules for Wall posting: https://www.facebook.com/groups/35688476100/doc/10151597056316101/ Daftar Keanggotaan : http://www.facebook.com/groups/35688476100/doc/10150671770741101/ 
gan mau naya nihh ane mau bikin report pertahun ...
Aug 10th 2013, 15:57, by Muhammad Suwanda

Muhammad Suwanda 3:57pm Aug 10
gan mau naya nihh

ane mau bikin report pertahun dan perbulan
data pkl

nah ane bingun pass mau nampilin reportnya
misalkan ane mau nyari tahun 2012
nahh yang 2012 doank kan yang tampil
itu ane pake pencarian
kan di data pkl itu ada
tgl masuk dan tanggal keluar nya
klou ane cari tgl masuk nya 2012
itu bisa nahh
ane bingung pass nyari 2012
tapi dia tuh masuk nya bulan desember 2011
keluar nya january 2012
kan itu ane pencarian nya hanya dari tanggal masuk
nah gimna caranya pass nyari 2012 dari tanggal keluar dan tanggal masuk nya ??

Gunawan Mujur Wibisono 4:03pm Aug 10
share dahulu strucktur tablenya plus jgn lupa.. tidak termasuk data

Muhammad Suwanda 4:07pm Aug 10
nihh gan strucur nya

Gunawan Mujur Wibisono 4:08pm Aug 10
ubah yg pake tgl jadi format date.. jgn pake char

Yoga Hanggara 4:09pm Aug 10
SQL query-nya kurang lebih: SELECT .... FROM ... WHERE YEAR(siswa_tgl_masuk) = 2012 OR YEAR(siswa_tgl_selesai) = 2012

Kalau bisa tipe datanya Date, jangan varchar

Bertho Joris 4:10pm Aug 10
wah...TS brutal..:D tanggal dipakein char...^_^

Muhammad Suwanda 4:11pm Aug 10
mas Gunawan Mujur Wibisono ::
udahh ane ganti barusan
terus gimna lagi gann ,., heheh
Yoga Hanggara :: ane coabiin
Bertho Joris :: maklum gan ane newbie

Gunawan Mujur Wibisono 4:12pm Aug 10
SELECT .... FROM ... WHERE YEAR(siswa_tgl_masuk) like '2012%'

Gunawan Mujur Wibisono 4:12pm Aug 10
sesuaikan dgn kebutuhan.. tgl pake char biar greget

Muhammad Suwanda 4:12pm Aug 10
wokeh gan ane coba ,.,.,

Yaddi Surahman 4:14pm Aug 10
1st rule, use appropriate data type for your fields/columns. for instance, datatype for siswa_tgl_masuk and siswa_tgl_keluar should be in date or datetime or timestamp

Gunawan Mujur Wibisono 4:15pm Aug 10
2nd use easy name for field
3rd put status .. when you want to del.. just change status to 0 not delete query

Yaddi Surahman 4:17pm Aug 10
agreed with gunawan, never ever use delete command to keep data in history

Gunawan Mujur Wibisono 4:17pm Aug 10
4rd pick the right filed to index

Yaddi Surahman 4:19pm Aug 10
5th make sure you have enough stock of cigars and coffee aside your laptop :D hehehe

Muhammad Suwanda 4:20pm Aug 10
thank fery much for matery
and I very agree for 5th hehehe :)

You are receiving this email because you subscribed to this feed at blogtrottr.com.

If you no longer wish to receive these emails, you can unsubscribe from this feed, or manage all your subscriptions

Tidak ada komentar:

Posting Komentar