On my AIX box, which is using ksh as the default shell, I'd like the prompt to show both the date and time followed by a newline \n, along with the name of the machine, and the working directory.Something like:2014/08/05 10:58:43[username]machinename:/some/path/here $I've tried the following:unset _Y _M _D _h _m _seval $(date +_Y=%Y;_M=%m;_D=%d;_h=%H;_m=%M;_s=%S)((SECONDS=3600*${_h#0}+60*${_m#0}+${_s#0}))typeset -Z2 _h _m _s_tsub=(_m=(SECONDS/60%60)) == (_h=(SECONDS/3600%24)) + (_s=(SECONDS%60))_timehm='${_x[_tsub]}$_h:${_m}'_timehms='${_x[_tsub]}$_h:$_m:${_s}'_timedhms=$_Y'/'$_M'/'$_D '${_x[_tsub]}$_h:$_m:${_s}'PS1=$_timedhms'\n' '[USERNAME]MACHINE:${PWD#$HOME/} $ 'However, there is no newline between the date/time and the rest of the prompt.  It seems now matter what the combination of quotes I try, I cannot get a newline to appear in PS1.Edit: nixed the spaces after SECONDS assignment, and edits need to be 6 characters long, so I'm telling you here. 
How can I get KornShell to display the date and time in the prompt?
ksh;aix;prompt
You can use the literal newline in PS1:PS1=$_timedhms> [USERNAME]MACHINE:${PWD#$HOME/} $ or using $'\n' with ksh93:PS1=$_timedhms$'\n' [USERNAME]MACHINE:${PWD#$HOME/} $ 