עבור לתוכן
View in the app

A better way to browse. Learn more.

HWzone

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

בעיה במחיקת משתמש ממסד הנתונים

Featured Replies

פורסם

יש לי בעיה במחיקת משתמש ממסד הנתונים למרות שהמשתמש קיים במסד

איך פותרים את הבעיה ?

הקוד של הקובץ :


<%
if session("iao")="no" then
response.redirect("admin.html")
end if
%>
<HTML>
<HEAD>
<TITLE>מחיקת משתמש</TITLE>
</HEAD>
<BODY>
<%
'======= שליפת נתוני המשתמש מהטופס =======

username = Request.Form("username")

'======= חיבור למסד הנתונים ופתיחתו =======

Set con = Server.CreateObject("ADODB.connection")
con.Open("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=" & Server.MapPath("db/members.mdb"))

'=========== בדיקה האם כבר קיימת רשומת משמתמש בטבלה ==========
sqlSelectCmd = "SELECT * FROM users WHERE username='" & username & "'"
Set rec = con.Execute(sqlSelectCmd)

If (rec.EOF = True) Then
'======= החזרת תשובה ללקוח שפעולת המחיקה לא בוצעה כי לא קיים משתמש כזה =======
Response.Write("<html><body dir='rtl'><h1><center>המשתמש לא קיים במסד !</center></h1></body></html>")
Else
'======= בניית הפקודה למחיקת רשומת המשתמש מהטבלה =======
sqlDeleteCmd = "DELETE FROM users WHERE username='" & username & "'"

'======= מחיקת רשומת המשתמש מהטבלה =======
con.Execute(sqlDeleteCmd)

'======= החזרת תשובה ללקוח שפעולת המחיקה בוצעה בהצלחה =======
Response.Write("<html><body dir='rtl'><h1><center>נתוני המשתמש נמחקו בהצלחה!</center></h1></body></html>")
End If

'======= סגירת מסד הנתונים =======
rec.Close()
con.Close()
%>
</BODY>
</HTML>

השגיאה היא :


Microsoft JET Database Engine (0x80004005)
‏‏מחיקה מהטבלאות שצויינו לא הצליחה.
/mySite/delete.asp, line 33

ארכיון

דיון זה הועבר לארכיון ולא ניתן להוסיף בו תגובות חדשות.

דיונים חדשים

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.