Ruang penulis
SEBUAH JURNAL TENTANG TEKNOLOGI

Belajar hal baru.
Tulis. Bagikan.

Ruang untuk merangkai pengetahuan, satu baris kode setiap hari.
Temukan tutorial, ide, dan catatan dari perjalanan belajar.

1914 catatan & terus bertumbuh
PILIHAN EDITOR
Java

Memahami Java Stream: olah koleksi dengan lebih ringkas

Pelajari alur filter, map, dan collect untuk mengolah data Java dengan kode yang mudah dibaca.

D Tim Diary Coding · 1 menit baca
UNTUK RASA INGIN TAHUMU

Catatan terbaru.

CORE API / CATATAN</>
Core API27 Mar 2007

How do I add leading zeros to a number?

This example shows you how to use the String.format() method to add zero padding to a number. If you just want to print out the result you can use System.out.format(). This method is available since Java 1.5, so If you use a previous version you can use the NumberFormat class, see: How do I format […]

Wayan · 1 menit baca
JDBC / CATATAN</>
JDBC23 Mar 2007

How do I create a batch update in JDBC?

A batch statement can be used to execute multiple update commands as single unit in a database manipulation. This statement in the database is not executed one by one but as a single execution instead. In some cases, using a batch update can be more efficient than to execute the commands separately. In this example, […]

Wayan · 2 menit baca
APPLET / CATATAN</>
Applet22 Mar 2007

How do I read an applet parameters?

package org.kodejava.applet; import java.applet.Applet; import java.awt.Color; import java.awt.Graphics; public class AppletParameterExample extends Applet { private String name = ""; public void init() { // Here we read a parameter named name from the applet tag definition // in our html file. name = getParameter("name"); } public void paint(Graphics g) { g.setColor(Color.BLUE); g.drawString("Hello " + name […]

Wayan · 1 menit baca
CORE API / CATATAN</>
Core API19 Mar 2007

How do I convert string date to long value?

package org.kodejava.util; import java.text.DateFormat; import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Date; public class StringDateToLong { public static void main(String[] args) { // Here we have a string date, and we want to covert it to long value String today = "25/09/2021"; // Create a SimpleDateFormat which will be used to convert the string to // a […]

Wayan · 1 menit baca
JDBC / CATATAN</>
JDBC19 Mar 2007

How do I create a scrollable result sets?

Since JDBC 2.0 (JDK 1.2), a scrollable ResultSet was introduced to the java.sql API family. Using this ResultSet enables us to navigate the result set in forward or backward way. To enable the scrollable ResultSet, we need to create a statement object by defining the ResultSet type (ResultSet.TYPE_SCROLL_SENSITIVE, ResultSet.TYPE_SCROLL_INSENSITIVE). If you define the ResultSet type […]

Wayan · 2 menit baca
JDBC / CATATAN</>
JDBC15 Mar 2007

How do I move to absolute or relative row?

In this example we are showing you how to use result set absolute() and relative() method to jump from one result set row to the other. When you pass a positive number as the parameter, you’ll move from the first record to the last. But if you pass a negative number as parameter, you’ll move […]

Wayan · 2 menit baca

Pengetahuan tumbuh ketika dibagikan.

Simpan rasa ingin tahu. Selalu ada hal baru untuk dipelajari.

Jelajahi catatan ↗
Putu Adi Guna Permana
TENTANG PENULIS

Dr (C). Ir. Putu Adi Guna Permana, S.Kom., M.Kom., IPM., ASEAN Eng.

Penulis dan pendiri Diary Coding — berbagi catatan, tutorial, dan pengalaman seputar pemrograman untuk siapa pun yang ingin terus belajar.