Spyrax Posted May 2, 2020 Share Posted May 2, 2020 (edited) السلامم عليكم .. يـ شباب , وشالحل؟ يقولي فالدي بق dbPoll failed; no suck column: pName الكود: dbExec( HS, ' CREATE TABLE IF NOT EXISTS `HandlingS` ( pName,Han,Chan ) ' ) addEvent( 'SendH', true ) addEventHandler( 'SendH', root, function(Han,Chan) local name = getPlayerName(source) local check = dbQuery( HS, ' SELECT * FROM `HandlingS` WHERE pName = ? ', name ) local result = dbPoll( check, -1 ) if ( type ( result ) == 'table' and #result == 0 ) then dbExec( HS,' INSERT INTO `HandlingS` VALUES(?,?,?) ', pName, Han, Chan ) outputChatBox( '* #FFFF00VIP System : #FFFFFF تمم الإرسال بنجاح ، الرجاء الإنتظار !', source, 0, 0, 0, true ) refresh() end end ) Edited May 2, 2020 by CLoz Link to comment
Spyrax Posted May 2, 2020 Author Share Posted May 2, 2020 (edited) 18 minutes ago, Abdul KariM said: جرب احذف القاعدة dbExec( HS, ' DROP TABLE `HandlingS` ' ) كذا ؟ , يوم سويت كذا راحت القاعدهه , وش اسوي بعدها؟ Edited May 2, 2020 by CLoz Link to comment
Spyrax Posted May 2, 2020 Author Share Posted May 2, 2020 (edited) 43 minutes ago, Abdul KariM said: جرب احذف القاعدة تمام , حذفتها وضفت قاعده جديدة وزبطت لكن وش المشكلة هنا يجبلي فالقريد ليست الرو الثاني والثالث لكن رو حق إسم اللاعب م يجيبه ! الكود: -- Server function refresh() setTimer( function( ) local check = dbQuery( XD, ' SELECT * FROM `Hss` ' ) local results = dbPoll( check, -1 ) if ( type ( results ) == 'table' and #results == 0 or not results ) then triggerClientEvent( root, 'rList', root ) return end triggerClientEvent( root, 'rTable', root, results ) end, 500, 1 ) end addEvent( 'refresh', true ) addEventHandler( 'refresh', root, refresh ) addEvent( 'SendH', true ) addEventHandler( 'SendH', root, function(Han,Chan) name = getPlayerName(source) local check = dbQuery( XD, ' SELECT * FROM `Hss` WHERE Han = ? AND Chan = ? ',Han , Chan ) local result = dbPoll( check, -1 ) if ( type ( result ) == 'table' and #result == 0 ) then dbExec( XD,' INSERT INTO `Hss` VALUES(?,?,?) ',name, Han, Chan ) outputChatBox( '* #FFFF00VIP System : #FFFFFF تمم الإرسال بنجاح ، الرجاء الإنتظار !', source, 0, 0, 0, true ) refresh() end end ) -- Client: addEvent( 'rTable', true ) addEventHandler( 'rTable', root, function( table ) guiGridListClear(GridList_) for f,_ in ipairs( table ) do local row2 = guiGridListAddRow( GridList_ ) local playerN = guiGridListSetItemText( GridList_, row2, 1,table[f].name, false, false ) local playerA = guiGridListSetItemText( GridList_, row2, 2,table[f].Han, false, false ) local playerC = guiGridListSetItemText( GridList_, row2, 3,table[f].Chan, false, false ) guiGridListSetItemColor(GridList_, row2, 1, 0, 255, 0) guiGridListSetItemColor(GridList_, row2, 2, 255, 255, 0) guiGridListSetItemColor(GridList_, row2, 3, 0, 0, 255) end end ) Edited May 2, 2020 by CLoz Link to comment
Spyrax Posted May 3, 2020 Author Share Posted May 3, 2020 1 hour ago, Abdul KariM said: pName حط name في الكلينت بدل الله يسعدك , مشكور @!#NssoR_) - يُغلق . Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now