We Are Currently Unable To Serve Your Request
Posted May 16th, 2009 by Andrew PopoffSV Blog does not answer about a week. It is permissible for a single developer, but very strange for a stable company.
Tags: SV blog | No Comments »
Clarion Developer Blog
The future depends on us. It is up to us to the future of Clarion.
Will this programming language to live long and happy life or dies in oblivion depends on us. If you have to say, do it here in this blog. Welcome!
Read More
SV Blog does not answer about a week. It is permissible for a single developer, but very strange for a stable company.
Tags: SV blog | No Comments »
Arcadia, Inc. is one of the leading Russian offshore software development companies, providing services to international clientele. Arcadia’s software development team is located in St. Petersburg, Russia.
Here you can see the Results of 2008 Year.
Tags: Arcadia | No Comments »
You can find my article Locating Records In Hand Coded List Boxes at Clarion Magazine.
Tags: Clarion Magazine | No Comments »
We use one table to create a tree normally. This table should contain at least two columns. One column is the identifier of the record. The second column is the identifier of the parent record.
Example:
Office
Lawyer department
Bob
John
Tech department
Dave
Michael
ID ParentID Desc
1 0 Office
2 1 Lawyer department
3 2 Bob
4 2 John
5 1 Tech department
6 5 Dave
7 5 Michael
If we want to climb up or down the tree, then typically we use a recursion. This works but not effective. This method becomes slow when the table becomes large.
To speed up the movement, you can add an additional field that will contain the path to the first parent. This is a string field. The format you can define yourself.
Example:
ID ParentID Path Desc 1 0 .1. Office 2 1 .1.2. Lawyer department 3 2 .1.2.3. Bob 4 2 .1.2.4. John 5 1 .1.5. Tech department 6 5 .1.5.6. Dave 7 5 .1.5.7. Michael
“Path”-field helps to easily and quickly identify all the children of the selected record. You should have the index for this field of course. You can create triggers that will automatically build the “Path”-field.
But it turned out that the definition of the parent of choosed record is too slow. So I found another way. The method is that you must add additional table, which contains all the parents’ IDs to the upper level for each record.
I have read about this method about two years ago and used it on a large SQL-tables.
Table Additional Table
ID ParentID Desc ID ParentID
1 0 Office 1 0
2 1 Lawyer department 2 1
3 2 Bob 2 0
4 2 John 3 2
5 1 Tech department 3 1
6 5 Dave 3 0
7 5 Michael 4 2
4 1
4 0
5 1
5 0
6 5
6 1
6 0
7 5
7 1
7 0
You can move up and down on the table more quickly. This method is suitable for tps-tables and for SQL. You must create an indexes of course. For SQL you can create triggers that will fill in the additional table. The additional table may also contain additional fields, for example, the “Level”-field.
Tags: trees | No Comments »
You can create a text file containing a one letter.
That means that the size of this file is 1 byte.
You can see the properties of this file in Explorer.
There are two properties:
- “Size” which displays the 1 byte
- “Size on disk” which displays the cluster size (for example 4096 bytes).
Tags: cluster size | No Comments »
Today we celebrate Victory Day. This is a special day for all people. Everyone in our country remembers that day, despite the fact that it has been for many years ago.
Tags: Victory Day | No Comments »
To transfer data, I made a backup of the database and just restored it to the new server. The speed of execution of queries has become much lower than on the old server.
I decided that it was necessary to rebuild all indexes in the database. You can do this using Management Studio. In this case, you will need to do this operation for each table. I have about 400 tables in the database. Therefore, it takes a long time.
I wrote a small script that performs these operations. I have updated statistics and clean the cache plans for queries at the end.
USE database_name DECLARE @TableName varchar(255) DECLARE @SqlQ char(260) DECLARE TableCursor CURSOR FOR SELECT table_name FROM information_schema.tables WHERE table_type = 'base table' OPEN TableCursor FETCH NEXT FROM TableCursor INTO @TableName WHILE @@FETCH_STATUS = 0 BEGIN SET @SqlQ = 'ALTER INDEX ALL ON ' + @TableName + ' REBUILD WITH (FILLFACTOR = 90, SORT_IN_TEMPDB = ON,STATISTICS_NORECOMPUTE = ON);' EXEC (@SqlQ) SET @SqlQ = 'ALTER INDEX ALL ON ' + @TableName + ' REORGANIZE' EXEC (@SqlQ) FETCH NEXT FROM TableCursor INTO @TableName END CLOSE TableCursor DEALLOCATE TableCursor go exec sp_msforeachtable 'update statistics ?' go dbcc freeproccache go
Tags: MS SQL Server | No Comments »
I work for a large trading company. The company has about 10 shops selling home appliances in the city of Khabarovsk and two stores in other cities. The company has a division to develop software for their corporate needs. There are 5 programmers. I am engaged in the development and support programs for trade and services.
A week ago we got a new server. Now we transfer the program to a new MS SQL Server 2008. Previously, we have worked with MS SQL Server 2000. At first glance, the new server is running twice as fast:) But I think that there is still a lot of work.
Tags: work | No Comments »
Today I started work on a template for the menu. I usually make it quickly. But now I have decided that I will spend considerable time for writing a template. I think that I will slightly rewrite the template for the context menu and the toolbar, so that all these templates were able to work together.
In product xXPFrame I redraws the standard menu. In CFC-menu I decided that I will build menu again. This means that you have to create all the menus again. And I understand that this is a bad thing. Therefore, I decided to start work on the template with the possibility of implementing the import of existing menus.
The template contains only one button, which allows you to import an existing menu to the template. I am importing the structure of the menu, the names of items and icons. I do not know the way to import actions that are performed by pressing the menu item.
Tags: CFC Library, template | No Comments »
You can download the MS SQL Field Box source here.
You must also install the CFC Library 2.5 and register the templates that are included in the library (cfc_templates.tpl, DEBUG.TPL, dp_class.tpl).
I think that the class for working with ADO is that it’s worth a look.
Tags: CFC Library, Clarion 7, MS SQL Field Box | 1 Comment »
I have added two classes. One for incremental search and one for system global hotkeys. The documentations is still missing.
I have a plans to develop a template for menu. And after that I will write documentation for the product.
Tags: CFC Library | No Comments »
I’ve uploaded the MS SQL Field Box 2.0.
It is a small tool which allow you view MS SQL Server database structure and paste table or field names in your favorite editor with mouse left double click or keyboard hotkeys.
I wrote this program using the Clarion 7, CFC Library, ADO and hand-coding.
ps
I will upload the source code of the utility soon.
Tags: MS SQL Field Box | No Comments »
Today I finished work on “MS SQL Field Box“. I need only add the “About” or a little documentation. Of course I used the CFC Library. I have added to the library class to work with global hot keys. So I need to do build the library version 2.5. I think that I will do it tomorrow.
Resize the window was a big problem for me. I used “Anchor”-strategy in recent times. But this strategy is wrong, in the absence of restrictions on the minimum size of the window. I had to make a change in the size of the window manually. I think that I will write a class to change the size of the windows controls in the future. It is an old problem and it requires a solution.
I have an idea to find the overlapping controls and hide them, when I struggled with resizing. I have not used it now.
To determine the overlap of two rectangular areas, you can use the WinAPI functions.
There are two functions: CreateRectRgn and RectInRegion. The first function creates a region with a given size. The second function determines the location of the rectangle in the region. I checked it works:)
Tags: CFC Library, Clarion 7, MS SQL Field Box | No Comments »
Today I continued working on the “MS SQL Field Box”. Yesterday, I was not able to compile the application with a dictionary. Today, I exported it in txa-format. And I made a new application using txa-file. Compilation worked successfully!
I have not encountered major problems today. Some things annoy. Sometimes Clarion crashed. But today I feel better and faster then yesterday.
“MS SQL Field Box” uses ADO. I am using hand-coding inside the app. It is a small class to work with ADO. I will publish the code of the product when I finish.
Tags: Clarion 7, MS SQL Field Box | No Comments »
People are different. Programs are different.
If you hate the CapsLock key like I do, you have come to the right place. This site is the home to CapsLockBeGone, the blessed little utility that will rid you of your CapsLock key forever.
Tags: ihatethecapslockkey.com | No Comments »