docker container ls -q --format '{{.Names}},{{.CreatedAt}}' --filter status=running
docker container ls --filter status=running --format='{{json .}}' | jq -cr '.Names + " " + .CreatedAt'
ROWS=$(docker container ls --filter status=running --format='{{json .}}' | jq -cr '.Names + ", " + .CreatedAt' )
IFS=\n;echo $ROWS |while read L ;do D=$(echo "$L" | awk '{print $2}') ;N=$(echo $L|awk '{print $1}'); DU=$(date -d "$D" +'%s') ; echo $N$DU;done
String[] x = new String[] { "a", "b", "c" };
String[] y = new String[] { "a", "b" };
List<String> x1 = Arrays.asList(x);
List<String> y1 = Arrays.asList(y);
x1.containsAll(y1);
import java.sql.PreparedStatement
String sql = "INSERT INTO survey (register) VALUES(?)";
PreparedStatement preparedStatement = conn.prepareStatement(sql);
preparedStatement.setInt(1, 12);
preparedStatement.setString(2, "test");
preparedStatement.executeUpdate();
resultSet.next()
- инересная особенность постгреса resultSet.first();
final int cnt = resultSet.getInt(1);
System.out.println("cnt: " + cnt);
java.text.SimpleDateFormat
https://docs.oracle.com/javase/8/docs/api/java/tex...
методы
parse
иformat