Skip to main content

Posts

You Can Easily Get the Last Inserted/Updated/Deleted Dates as Follows:

CREATE FUNCTIOn fn_TablesLastUpdateDate(@Date NVARCHAR(20)) RETURNS @table TABLE(TableName NVARCHAR(40), LastUpdated Datetime) AS BEGIN IF(@Date='') OR (@Date Is Null) OR (@Date='0') BEGIN INSERT INTO @ table SELECT TOP 100 PERCENT TABLENAME , LASTUPDATED FROM ( SELECT B . NAME AS 'TABLENAME' , MAX ( STATS_DATE ( ID , INDID )) AS LASTUPDATED FROM SYS . SYSINDEXES AS A INNER JOIN SYS . OBJECTS AS B ON A . ID = B . OBJECT_ID WHERE B . TYPE = 'U' AND STATS_DATE ( ID , INDID ) IS NOT NULL GROUP BY B . NAME ) AS A ORDER BY LASTUPDATED DESC END ELSE BEGIN INSERT INTO @ table SELECT TOP 100 PERCENT TABLENAME , LASTUPDATED FROM ( SELECT B . NAME AS 'TABLENAME' , MAX ( STATS_DATE ( ID , INDID )) AS LASTUPDATED , CONVERT ( VARCHAR , MAX ( STATS_DATE ( ID , INDID )), 103 ) as Date ...

11 Simple Concepts to Become a Better Leader

1. Listening Dinleme "When people talk, listen completely. Most people never listen." - Ernest Hemingway "İnsanlar konuşurken, tamamen dinle. Çoğu insan asla dinlemez." - Ernest Hemingway 2. Storytelling "Storytelling is the most powerful way to put ideas into the world today." -Robert McAfee Brown Hikaye Anlatma "Storytelling bugün dünyasına fikirler koymak için en güçlü yoludur." -Robert McAfee Kahverengi 3. Authenticity "I had no idea that being your authentic self could make me as rich as I've become. If I had, I'd have done it a lot earlier." -Oprah Winfrey Otantiklik "Ben senin otantik benliği ben oldum benim kadar zengin ki hiç bir fikrim yoktu. Eğer öyle olsaydı, ben çok daha önce yapardım." -Oprah Winfrey 4. Transparency "As a small businessperson, you have no greater leverage than the truth." -John Whittier Şeffaflık "Küçük bir işadamı olarak, gerçeğin daha büyük bir koz var." -...

Bir yazılımcıda olması gereken 10 özellik

Önümüzdeki 5 yıl içerisinde yazılımcıların ceplerinde bulundurmaları gereken 10 özellik aşağıdaki gibi sıralanmış. Ben de kısaca özetlemek istedim. 1- 3 büyük programlama dilinden birini mutlaka bilmeli. (.NET,Java,PHP) 2- Sevin veya sevmeyin mutlaka Rich Internet Applications (RIA) yapabiliyor olmak şart. Flash,Silverlight,HTML5,AJAX gibi görselliği ön plana çıkartabileceğimiz teknolojileri öğrenmekte fayda var. 3-Web Development :   popüleritesini yitirmeyecek JavaScript, CSS, and HTML gibi diller önemini koruyacak 4-Web Service : REST veya SOAP, JSON veya XML. Artık web servisler developerların sürekli ihtiyaç duydukları teknolojiler. 5-Soft Skills : Müşteriler ve diğer çalışanlar ile iletişimlerini kuvvetlendirmeli ve insanları etkilemeyi öğrenmeli. 6-Ruby, Python, F#,  Groovy gibi fonksiyonel programlama dillerinden bir tanesini öğrenmeli, çünkü bu diller bazı sektörlerde kilit rol oynayabiliyor. 7-Çevik Metodolojiler : Proje yönetim metodolojilerine uzak kalm...

Dynamics AX – Periodic maintenance and performance analysis

1 Periodic clean up - Significance A recent AX_Database analysis showed that the 5 largest tables in the database account for roughly 60% of the database size. The 4 largest tables out of 5 are tables with temporary and/or archival data: Inventory settlements (INVENTSETTLEMENT), database log (SYSDATABASELOG), temporary sales orders data (SALESPARMLINE), temporary master planning data (INVENTSUMLOGTTS). The fifth table is sales lines (SALESLINE). Periodically archiving/purging these tables would significantly reduce database size and will have beneficial effect on system performance . Each individual table and related considerations are discussed below: 1.1   Inventory settlements . The inventory settlements table is used to store information generated during inventory close and adjust periodic job run. This table can be cleaned up/compressed using the Inventory management>Periodic>Clean up>Inventory settlements clean up. Deleting cancelled settlement is a r...

AXAPTA Ana tablo formuna git

Go to the Main Table Form has to be implemented manually. In this recipe, to demonstrate how it works, we will modify the Business relations form in the CRM module to make sure that the Employee filter at the top of the form allows users to use the Go to the Main Table Form feature from the context menu. 1. Open the formform in AOT, and override jumpRef() of the EmployeeFilter control with: "Ana tablo formuna git" butonu otomatik olarak çalışır. Ancak kontrol sadece extended data tipine bağlıysa, çalışmaz. Bu durumda kendi Jumpref methodunuzu yazmanız gerekir. Bu konuda Fatih Demirci 'nin aşağıdaki kodundan faydalandım: public void jumpRef() { EmplTable emplTable; Args args; MenuFunction menuFunction; ; emplTable = EmplTable::find(this.text()); if (!emplTable) { return; } args = new Args(); args.caller(element); args.record(emplTable); menuFunction = new MenuFunction( menuitemdisplaystr(EmplTable), MenuItemType::Display); menuFunction.run(...

Kullanıcı grubu yetkilerini kodla toplu olarak güncelleme

Mesut Boztaş dan bir bilgi tşk. Yetkilendirme malumunuzdur ki AX’ın en hassas kısımlarından biridir. Bir müşterimizde SecurityKey değeri olmadan Canlıya alınan bir form menüdeki ilgili klasörü ve menüyü otomatik olarak tüm kullanıcılara açmıştır. Daha sonra forma SecurityKey değeri verilse bile birkez açılan ana anahtarlar kapanmamaktadır. Eğer çok kullanıcı grubunuz ve etki alanınız varsa bu işlemi telafi etmek uzun sürecek bir işlemdir. Altta belirtiğim job kullanılarak istenilen bir objenin yetki ayarlaması otomatik olarak yapılabilmektedir. İşlem süresi Kullanıcı grubu ve etki alanı sayısına göre değişkenlik gösterebilir.   02 static void changeAccessRights(Args _args) 03 { 04     SecurityKeySet          swSysSecurity; 05     UserGroupList           userGroupList; 06     DomainInfo    ...

Force delete inventtrans

Below is sample job to force delete inventtrans, which will take care of invent on hand update. static void DeleteInventTrans(Args _args) { Dialog dlg = new Dialog("Delete inventtrans ?"); DialogField dlgFld; InventMovement inventMovement; PurchLine purchLine; PurchLineRefRecId recId; ; dlgFld = dlg.addField(typeid(PurchLineRefRecId)); if(dlg.run()) { recId = dlgFld.value(); purchLine = PurchLine::findRecId(recId); if(purchLine) { InventMovement = InventMovement::construct(purchLine); InventUpd_DeleteMovement::newMovement( inventMovement,true).updateNow(); info("done"); } } }