- sudo apt install mesa-utils in Linux
- sudo apt-get install freeglut3-dev build-essential libx11-dev libxmu-dev libxi-dev libgl1-mesa-glx libglu1-mesa libglu1-mesa-dev libglfw3-dev libgles2-mesa-dev
- update SDK in Delphi, ==> tools - Options - Enviroment Option - SDK Manager
- Finish
Senin, 11 Desember 2017
Delphi 10.2 Tokyo - crossvcl - error cannot find -IGL
Sabtu, 28 Oktober 2017
Replace CR & LF with spaces - Oracle SQL
select replace(replace(alamat_pemilik,chr(10),''),chr(13),' ') alamat from dual
Rabu, 18 Oktober 2017
Jumat, 06 Mei 2016
TOAD ORA-01031: insufficient privileges when connecting to Oracle 12c
An issue faced is that when we try to connect from TOAD (version: 11.6 ) to a newly upgraded Oracle database 12c we faced the error:
ORA-01031: insufficient privileges
The reason we are facing this problem, is the newly security implementation by Oracle in 12c for the system privilege SELECT ANY DICTIONARY. They have stripped this system privilege from accessing the following tables:USER$, ENC$,DEFAULT_PWD$, LINK$, USER_HISTORY$, CDB_LOCAL_ADMINAUTH$, XS$VERIFIERS
The current TOAD version checks the old (SELECT ANY DICTIONARY) which already has this table SYS.USER$ part of its permissionwhen it can’t access this table, it throws the error message: ORA-01031
The reason in 12c they stripped those tables from “SELECT ANY DICTIONARY” is to protect the passwords in case this privilege is granted to non-DBA account , so the hashed passwords are not exposed (ONLY SYS account can query those tables).
So, to let the current version of TOAD works for 12c execute the following sql query:
SQL> grant select on sys.user$ to database_account;
Hope This Helps
Senin, 29 Februari 2016
Shortcuts Keyboard Sublime 3
Shortcuts Keyboard Sublime 3
Basic
F11 | Full Screen |
shift + F11 | Distraction Free Mode |
ctrl + shift + p | Command Palette |
ctrl + ` | Show Console |
ctrl + k + b | Show/Hide Sidebar |
ctrl + / | Comment |
ctrl + shift + / | Block Comment |
ctrl + k + u | Uppercase |
ctrl + k + l | Lowercase |
Selections
ctrl + d | Select Word |
ctrl + d | Use multiple times to select next instance of the selected word |
ctrl + click | Create multiple cursors for multi-editing |
ctrl + shift + space | Expand selection to scope. Repeating keeps expanding. |
ctrl + shift + m | Expand to brackets |
ctrl + shift + j | Expand to indentation |
Go To
ctrl + p | Open file based on name |
ctrl + g | Go to line number |
ctrl + r | Go to symbol |
ctrl + p THEN @ | Open file based on name and search for symbol |
ctrl + m | Go to matching bracket |
Lines
ctrl + l | Select line |
ctrl + shift + k | Delete line |
ctrl + ] | Indent |
ctrl + [ | Unindent |
ctrl + enter | Insert line after |
ctrl + shift + enter | Insert line before |
ctrl + shift + ↑ | Swap line up |
ctrl + shift + ↓ | Swap line down |
ctrl + shift + d | Duplicate line |
ctrl + j | Join Line |
Code Folding
ctrl + shift + [ | Fold |
ctrl + shift + ] | Unfold |
ctrl + k + j | Unfold All |
Search / Find / Replace
ctrl + f | Find |
F3 | Find next |
shift + F3 | Find previous |
ctrl + shift + f | Search all files in a folder |
ctrl + h | Replace |
ctrl + f THEN alt + | Find a certain term then select them all for multi-editing |
Tabs and Window Panes
ctrl + shift + n | New Window |
ctrl + n | New Tab |
alt + | Select a Tab (ie alt + 3) |
ctrl + w | Close Tab |
ctrl + shift + # | Move tab to a Pane (ie ctrl + shift + 2) |
ctrl + # | Focus on a Pane (ie ctrl + 2) |
alt + | One Column |
alt + | Two Columns |
alt + | Three Columns |
alt + | Four Columns |
alt + | Two Rows |
alt + | Three Rows |
alt + | Two x Two Grid |
Bookmarks
ctrl + F2 | Create Bookmark |
F2 | Next Bookmark |
shift + | Previous Bookmark |
ctrl + shift + F2 | Clear Bookmarks |
Senin, 30 November 2015
Drop Box Dinamis
...
type
TString = class(TObject)
private
fStr: String;
public
constructor Create(const AStr: String) ;
property Str: String read FStr write FStr;
...
constructor TString.Create(const AStr: String);
begin
inherited Create;
FStr := AStr;
end;
Proses ke combobox nya :
-------------------------------
cbDealer.Properties.Items.Clear;
with DM.Q do
begin
Close;
SQL.Text := 'select KD_DEALER,NAMA_DEALER from t_faktur'+
' where DATE_FORMAT(tgl_faktur, ''%Y%m%d'') between :tgl and :tgl2 group by KD_DEALER order by KD_DEALER';
Params[0].AsString := FormatDateTime('yyyymmdd',dt.Date);
Params[1].AsString := FormatDateTime('yyyymmdd',dt2.Date);
Open;
if DM.Q.RecordCount > 0 then
begin
while not eof do
begin
cbDealer.Properties.Items.AddObject(Fields[1].AsString,TString.Create(Fields[0].AsString));
Next;
end;
end
else
begin
cbDealer.Properties.Items.AddObject('SEMUA DEALER',TString.Create('ALL'));
end;
end;
cbDealer.Text := '';
.......
Penggunaan pada saat combobox di pilih adalah sebagai berikut:
params() := TString(cbDealer.Properties.Items.Objects[cbDealer.ItemIndex]).Str;
type
TString = class(TObject)
private
fStr: String;
public
constructor Create(const AStr: String) ;
property Str: String read FStr write FStr;
...
constructor TString.Create(const AStr: String);
begin
inherited Create;
FStr := AStr;
end;
Proses ke combobox nya :
-------------------------------
cbDealer.Properties.Items.Clear;
with DM.Q do
begin
Close;
SQL.Text := 'select KD_DEALER,NAMA_DEALER from t_faktur'+
' where DATE_FORMAT(tgl_faktur, ''%Y%m%d'') between :tgl and :tgl2 group by KD_DEALER order by KD_DEALER';
Params[0].AsString := FormatDateTime('yyyymmdd',dt.Date);
Params[1].AsString := FormatDateTime('yyyymmdd',dt2.Date);
Open;
if DM.Q.RecordCount > 0 then
begin
while not eof do
begin
cbDealer.Properties.Items.AddObject(Fields[1].AsString,TString.Create(Fields[0].AsString));
Next;
end;
end
else
begin
cbDealer.Properties.Items.AddObject('SEMUA DEALER',TString.Create('ALL'));
end;
end;
cbDealer.Text := '';
.......
Penggunaan pada saat combobox di pilih adalah sebagai berikut:
params() := TString(cbDealer.Properties.Items.Objects[cbDealer.ItemIndex]).Str;
Minggu, 10 Mei 2015
Oracle error 28001 - the password has expired
1. connect to database using sys users.
where d.username = upper('&&username')
and u.user# = d.user_id;
2. Sql > select * from dba_profiles; --> result PASSWORD_LIFE_TIME PASSWORD 180
3. Sql> ALTER PROFILE DEFAULT LIMIT PASSWORD_LIFE_TIME UNLIMITED;
4. Sql > select * from dba_profiles;
5. SQL> select 'alter user "'||d.username||'" identified by values '''||u.password||''';' c
from dba_users d, sys.user$ uwhere d.username = upper('&&username')
and u.user# = d.user_id;
&&username = ganti dengan user nama user yg mau diaktifkan;
hasil querynya dipakai untuk proses update usernya: misalkan
SQL> alter user "SCOTT" identified by values 'F894844C34402B67';
terakhir cek query ini:
sql> select username,account_status from dba_users;
Langganan:
Postingan (Atom)
