jika ingin melakukan update field di table dengan mengunakan proses looping di storeprocedure adalah sebagai berikut untuk contoh:
kasus nya adalah apabila saya ingin mengupdate 1 filed kolom mothername di table customer dengan server DBO1 dan diupdate dengan menggunakan data pada server DBO2.
ALTER proc [dbo].[sproc_RDO_migrate_TCustomer_update]
as
begin
declare @unitholder varchar(30)
declare @mycursor CURSOR
set @mycursor=CURSOR FAST_FORWARD
FOR
select unitholderidno from [DBO1].DBO.TCustomer where InvestorType='I'
OPEN @mycursor
FETCH NEXT FROM @mycursor
INTO @unitholder
WHILE @@FETCH_STATUS = 0
BEGIN
update [DBO1].DBO.TCustomer set
MothersName=(select Mothername from [DBO2].[SIAR2004].dbo.tcustomer where InvestorType='I' AND UnitHolderIDNo=@unitholder)
WHERE UnitHolderIDNo =@unitholder
FETCH NEXT FROM @mycursor
INTO @unitholder
END
CLOSE @mycursor
DEALLOCATE @mycursor
end
Selasa, 03 Juni 2014
Selasa, 07 Januari 2014
Solution Problem "Could not find any resources appropriate for the specified culture or the neutral culture. Make sure "AjaxControlToolkit.Properties.Resources.NET4.resources" was correctly embedded or linked into assembly "AjaxControlToolkit" at compile time, or that all the satellite assemblies required are loadable and fully signed."
Could not find any resources appropriate for the specified culture or the neutral culture. Make sure "AjaxControlToolkit.Properties.Resources.NET4.resources" was correctly embedded or linked into assembly "AjaxControlToolkit" at compile time, or that all the satellite assemblies required are loadable and fully signed.
if we have error message this in asp.net when we make new .aspx we must add this below:
<asp:ScriptManager ID="ScriptManager1" runat="server" />
or
<asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server" />
example file default.aspx
<%@ Page Title="" Language="C#" MasterPageFile="~/cr.Master" AutoEventWireup="true"
CodeFile="AllPengeluaran.aspx.cs" MaintainScrollPositionOnPostback="true" Inherits="Pengeluaran_ALL_AllPengeluaran" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="CntnPlaceBreadcrumb" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="CntnPlaceMain" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server" />
<asp:Panel ID="pnlPengeluaranAll" runat="server">
<fieldset>
<table>
<tr>
<td>
TANGGAL TRANSAKSI
</td>
<td>
:
</td>
<td>
<asp:TextBox ID="txtInputTanggall" runat="server" border-color="darkgreen"></asp:TextBox>
</td>
<td>
<asp:ImageButton ID="ImageButton1" runat="server" ImageUrl="~/images/calendar.gif" />
</td>
<td>
<asp:CalendarExtender ID="cldpilihtanggalAll" Enabled="true" Animated="true" runat="server"
TargetControlID="txtInputTanggall" PopupButtonID="ImageButton1">
</asp:CalendarExtender>
</td>
</tr>
</table>
</fieldset>
</asp:Panel>
</asp:Content>
if we have error message this in asp.net when we make new .aspx we must add this below:
<asp:ScriptManager ID="ScriptManager1" runat="server" />
or
<asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server" />
example file default.aspx
<%@ Page Title="" Language="C#" MasterPageFile="~/cr.Master" AutoEventWireup="true"
CodeFile="AllPengeluaran.aspx.cs" MaintainScrollPositionOnPostback="true" Inherits="Pengeluaran_ALL_AllPengeluaran" %>
<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="CntnPlaceBreadcrumb" runat="server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="CntnPlaceMain" runat="server">
<asp:ScriptManager ID="ScriptManager1" runat="server" />
<asp:Panel ID="pnlPengeluaranAll" runat="server">
<fieldset>
<table>
<tr>
<td>
TANGGAL TRANSAKSI
</td>
<td>
:
</td>
<td>
<asp:TextBox ID="txtInputTanggall" runat="server" border-color="darkgreen"></asp:TextBox>
</td>
<td>
<asp:ImageButton ID="ImageButton1" runat="server" ImageUrl="~/images/calendar.gif" />
</td>
<td>
<asp:CalendarExtender ID="cldpilihtanggalAll" Enabled="true" Animated="true" runat="server"
TargetControlID="txtInputTanggall" PopupButtonID="ImageButton1">
</asp:CalendarExtender>
</td>
</tr>
</table>
</fieldset>
</asp:Panel>
</asp:Content>
Langganan:
Postingan (Atom)