|
|
منتدى أكواد ومواضيع الـ SQL Server يتعامل برنامج جريت بلينز مع أقوى قواعد البيانات وهي SQL_Server سنناقش في هذا المنتدى المواضيع التي تتعلق بخادم قواعد البيانات من مشاكل وحلول وأكواد تضفي طابع الإحترافي لمطوري جريت بلينز |
| أدوات الموضوع | انواع عرض الموضوع |
16-Jul-2013, 12:49 AM | #1 | ||
عضو نشيط
| سكربت لأغلاق المستخدمين تلقائي انا كنت بدور في النت علي سكربت لاغلاق idle user فوجدت الأتي : ------------------------------------------------------------------------------------------------------- كود PHP: بس المشكلة ان في هدا السكربت معمول كل 12 ساعة بس انا بدي اعدله للكل نصف ساعة بس مش عارف ايش اسوي ارجو ممكن لدية المعرفه انه يدلني ----------------------------------------------------------------------------------------------- السكربت الثاني منقول ذي ما هو بس انا مش فاهم اي شيء منه اجو ان احد يشرحوا. -------------------------------------------------------------------------------------- . SQL Server offers a great way of tracking idle times from a process perspective. This is very cool, because most of the time we want to know that there is absolutely nothing running on the user's session before we decide to take some action -- most of the time remotely. The following script displays the time (in seconds) the last batch was executed for a particular Dynamics GP user. It looks at the DEX_SESSION table and cross-reference it with the SPIDs retrieved via the undocumented SQL Server system stored procedure sp_who2. UserActivity.sql -- Create by Mariano Gomez, MVP -- This script conferes no rights and has no warranties express or implied كود PHP: The script can be automated to track idleness information periodically and obtain detailed reports of system usage among GP users -- a sort of process activity. I use it a lot to plan server expansions activities and monitoring for my clients in conjunction with other important metrics. I hope you find this script useful in your daily administrative activities. [Edit] One thing I truly like about blogging is that there is no short of solutions to a problem. My friend Robert Cavill, Systems Analyst in Western Australia offers his own version of determining Dynamics GP users' activity (or lack thereof). Robert adds "I have to point out to you that sometimes I have noticed that on my system the DEX_SESSION table infrequently will not have a row present in it for an active user". His comment is well on as the above script will exclude such users. Why and how a logged on user does not register a session in the DEX_SESSION table is something that's up for research, but the bottom line is it happens, especially on Citrix and Terminal Server environments. Take a look at Robert's elegant script: كود PHP: ولا تنسو ان في تصويت من ميكرسوفت للطرح اغلاق البرنامج كل فتر تلاقي للمستخدمين http://www.microsoft.com/Businesssol...ic.greatplains آخر تعديل بواسطة Monzer Osama ، 16-Jul-2009 الساعة 09:51 AM. | ||
16-Jul-2013, 12:03 PM | #2 | ||
عضو نشيط
| انا حليت المشكلة في السكربت الاول وعرفت ان اعدله لكل نصف ساعة الحل كما يلي كود PHP: اربط السكربت بوقت محدد يعني كل خمسه دقائق اشتغل | ||
17-Jul-2013, 09:01 PM | #3 | |
مدير عام منتديات جريت بلينز العربية | اقتباس:
استخدام الـ Jobs من داخل SQL Server يسهل عليك هذه العملية بحيث يقوم بتشغيل سكريبت معين أن تحده بتشغيله كل يوم عند الساعة الفلانية أو كل ساعة أو كل خمس دقائق ... الخ __________________ Monzer Osama Saudia Arabia - Jeddah 00966501826235 Microsoft Certified Business Management Solutions Professional Microsoft Certified Trainer | |
يتصفح الموضوع حالياً : 1 (0 عضو و 1 ضيف) | |
أدوات الموضوع | |
انواع عرض الموضوع | |
|
|
المواضيع المتشابهه | ||||
الموضوع | كاتب الموضوع | المنتدى | مشاركات | آخر مشاركة |
سكربت لعمل تقرير خاص ب Analytical Accounting | Maged Salah | منتدى أكواد ومواضيع الـ SQL Server | 5 | 20-Feb-2017 05:00 PM |
مشكلة في اصدار رقم Po بشكل تلقائي | wabbas77 | مناقشة المشاكل والأخطاء في برنامج جريت بلينز | 5 | 01-Sep-2012 11:45 PM |
تطبيق Policy على المستخدمين | moneimmae_2004 | منتدى جريت بلينز العام | 10 | 27-Feb-2012 02:39 PM |
تطبيق الصلاحيات على المستخدمين | moneimmae_2004 | منتدى جريت بلينز العام | 9 | 17-Dec-2011 10:59 PM |
اري د سكربت | marysamuel | منتدى أكواد ومواضيع الـ SQL Server | 7 | 12-Aug-2011 01:55 PM |