Tampilkan postingan dengan label Oracle. Tampilkan semua postingan
Tampilkan postingan dengan label Oracle. Tampilkan semua postingan

Kamis, 03 Februari 2011

About oracle 11g password is case sensistive

When i get email from multi data. another friend. Tell about oracle 11g password was case sensitive. The project is database 10g, and client 11g. that not worry about it. Because 10g not case sensitive.

Senin, 14 Juni 2010

How to export and import oracle on CMD

How to export and import oracle

go to cmd
type
C:\>exp >> for export
and please type username example :
haikal@ORCL
*****
enter
export file is > yourname.dmp
so your exp will on C:\>
enter all
until user to be exported > type your username
done


type imp >> for import
and please type username example :
haikal@ORCL
*****
enter until
choose destination test.dmp(where your export dmp)
and type username for your dmp/dump
enter and finally done

Connection, command insert update delete .NET

Example Code ASP.NET

Imports System.Data.OleDb
Public Class Class1
Public Shared con As New OleDbConnection(ConfigurationSettings.AppSettings("CONN2"))
Public Shared com As New OleDbCommand
Public Shared newval, tgToSQL As String
Public Shared appStrConn, appUserName, appPassword As String
Public Shared dbConnection As OleDbConnection
Public Shared dbCommand As OleDbCommand
Public Shared dr As OleDbDataReader
Public Shared status As Integer
Public Shared temp As String
Public Shared strConn As String
Public Shared pnlDefaultMenu As Panel
Public Shared bbndata As String

Public Shared Sub cekKoneksi()
If con.State = Data.ConnectionState.Open Then
con.Close()
End If
End Sub
End Class


Imports System.Data.OleDB
Imports Class1

Sub tampilgridview1()
Dim tabel As New DataTable
com.CommandText = "SELECT nofaktur, nama, alamat, kddealer, namadealer FROM lookup_register WHERE (tgregbpkb IS NULL) ORDER BY nofaktur"
cekKoneksi2()
con.Open()
com.Connection = con
dr = com.ExecuteReader
If dr.HasRows = True Then
tabel.Load(dr)
GridView1.DataSource = tabel
GridView1.DataBind()
End If
con.Close()
End Sub

Protected Sub GridView1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles GridView1.SelectedIndexChanged
displaydata()

End Sub

Protected Sub GridView2_PageIndexChanging(ByVal sender As Object, ByVal e As System.Web.UI.WebControls.GridViewPageEventArgs) Handles GridView2.PageIndexChanging
Response.Write("
NewpageIndex: " & e.NewPageIndex)
GridView2.PageIndex = e.NewPageIndex
tampilgridview2()

End Sub

Public Sub ClearTextBox(ByVal root As Control)
For Each ctrl As Control In root.Controls
ClearTextBox(ctrl)
If TypeOf ctrl Is TextBox Then
CType(ctrl, TextBox).Text = String.Empty
End If
Next ctrl
End Sub

Protected Sub Button9_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button9.Click
ClearTextBox(Me)
End Sub

Protected Sub Button11_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Button11.Click
Dim tabel As New DataTable
Dim tes As String
tes = "SELECT .. WHERE " & DropDownList2.SelectedItem.Value & " LIKE '%" & txtcaridatabpkb.Text & "%'"
com.CommandText = tes
cekKoneksi2()
con.Open()
com.Connection = con
dr = com.ExecuteReader
If dr.HasRows = True Then
tabel.Load(dr)
GridView2.DataSource = tabel
GridView2.DataBind()
End If
con.Close()
End Sub

---------------------
Dim tes As String
cekKoneksi2()
con.Open()
tes = "INSERT INTO BPKB_MASTER(NOREG_A,NOREG_B,NOREG_C," & _
"NOREG_D,NM_DITLANTAS,TGREGISTER,NOBPKBA,NOBPKB,NOBPKBC," & _
VALUES ('" & edRegA.Text & "','" & edRegB.Text & "'" & _
",'" & edRegC.Text & "','" & edRegD.Text &
com.CommandText = tes
com.Connection = con
com.ExecuteNonQuery()
con.Close()

-------
If Trim(TextBox2.Text) = "" Or Trim(ComboBox1.SelectedValue) = "" Then
MsgBox("Inputan tidak boleh kosong")
Else
cekKoneksi()
con.Open()
com.CommandText = "update Kamar set ID_Paket_Kelas = '" & ComboBox1.SelectedValue & "', Lokasi = '" & TextBox2.Text & "', Status = '" & ComboBox2.SelectedValue & "' where No_Kamar = '" & TextBox1.Text & "'"
com.Connection = con
com.ExecuteNonQuery()
con.Close()
hapus()
MsgBox("Data telah diubah")
--------

Connection Oracle to ASP.NET

under

type this :




so that username for login to dynamic code:
code.vb

strConn = ConfigurationManager.AppSettings("strConn").ToString()
Session("dbConn") = dbconn
Session("userName") = userName
Session("passWord") = passWord

that will add to session every page