//
archives

IT-Center

This category contains 99 posts

Memulai Android Development – 1

Langkah pertama memulai development Android : Persiapkan Tools Mencoba sample aplikasi Share aplikasi lewat google playstore Kita mula dari Persiapan Tools Install a. Download Android Studio di https://developer.android.com/studio/index.html b. Download Java SDK 1.8 http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html c. Install Java SDK 1.8 dan Android Studio d. Setup JAVA_HOME di MyCompure > Klik Kanan Properties > Advance System Settings > Environment … Continue reading

SSH Using PHP

Install SSH2 PHP in Centos 6.5 Before we start, please ensure that you have the EPEL repo installed. If you don’t, goto http://fedoraproject.org/wiki/About_EPEL to get instructions. Firstly, we’re going to install the dependencies: yum install gcc php-devel php-pear libssh2 libssh2-devel These will allow us to build the SSH2 extension using pecl. pecl install -f ssh2 After running … Continue reading

SQL Server Last ID Identity

Assuming a simple table: CREATE TABLE dbo.foo(ID INT IDENTITY(1,1), name SYSNAME); We can capture IDENTITY values in a table variable for further consumption. DECLARE @IDs TABLE(ID INT); — minor change to INSERT statement; add an OUTPUT clause: INSERT dbo.foo(name) OUTPUT inserted.ID INTO @IDs(ID) SELECT N’Fred’ UNION ALL SELECT N’Bob’; SELECT ID FROM @IDs; The nice … Continue reading

Javascript Google Maps V3, multiple Marker with color dan label

1. get API key from google.com All Maps API applications* should load the Maps API using an API key. Using an API key enables you to monitor your application’s Maps API usage, and ensures that Google can contact you about your application if necessary. If your application’s Maps API usage exceeds the Usage Limits, you must … Continue reading

Installing Apache and PHP5 at CentOS Linux

CentOS comes with Apache v.2.2.3 and PHP v.5.1.6 and they are easily installed via the default CentOS Package Manager ‘yum’. The advantage of using yum (as opposed to installing via source code) is that you will get any security updates (if and when distributed) and dependencies are automatically taken care of. Apache Install A basic … Continue reading

Pattemplate for PHP, call template in different page

Can I re-use templates in different pages? Of course you can. Let’s say you’v got a footer and a header, which should be the same in all of your pages, so you have to change it only once and it will be updated in all pages. To accomplish this, at first create the two files, … Continue reading

Postgres Database

Backup SQL Format using PgAdmin: 1. Right click in database 2. Set Format to “Plain” Restore SQL Format (Plain) in Windows 1. cmd 2. type : psql -h host -U user -p port dbname < file (User use U capslock) example : C:\Program Files\PostgreSQL\9.3\bin>psql -h localhost -U postgres -p 5443 fantasi < c:/fantasy_server.backup Restore SQL Format … Continue reading

Find Slow/Worst Query in Database

1. SQL Server Sql Server haven’t monitoring GUI for finding worst query may be need optimized, but can use this sql script SELECT TOP 10 SUBSTRING(qt.TEXT, (qs.statement_start_offset/2)+1, ((CASE qs.statement_end_offset WHEN -1 THEN DATALENGTH(qt.TEXT) ELSE qs.statement_end_offset END – qs.statement_start_offset)/2)+1), qs.execution_count, qs.total_logical_reads, qs.last_logical_reads, qs.total_logical_writes, qs.last_logical_writes, qs.total_worker_time, qs.last_worker_time, qs.total_elapsed_time/1000000 total_elapsed_time_in_S, qs.last_elapsed_time/1000000 last_elapsed_time_in_S, qs.last_execution_time, qp.query_plan FROM sys.dm_exec_query_stats qs CROSS … Continue reading

Get All Table,Field and properties in SQL Server

1. Getting All Table in database : USE your_database SELECT name FROM sys.tables 2. Getting All Field in database, if you want getting all field with description can use this : SELECT u.name + ‘.’ + t.name AS [table], td.value AS [table_desc], c.name AS [column], cd.value AS [column_desc] FROM sysobjects t INNER JOIN sysusers u … Continue reading

Simple Encrypt/Decrypt String, ASP.NET/VB

This sample class for Encrypt/Descrypt string : Imports System.IO Imports System.Security.Cryptography Imports System.Text Public Class globalSecurity Protected key As String = “&/?@*>:>” Public Sub New() ‘constructor End Sub Public Function encryptString(ByVal strtext As String) As String Return Encrypt(strtext, key) End Function Public Function decryptString(ByVal strtext As String) As String Return Decrypt(strtext, key) End Function ‘The … Continue reading

Enter your email address to follow this blog and receive notifications of new posts by email.

Join 10 other subscribers
May 2024
M T W T F S S
 12345
6789101112
13141516171819
20212223242526
2728293031  

Archives

Web Statistic

Blog Stats

  • 187,137 hits