Hello :) I have a class : cls_Communication_base which has a private variable Private p_Descr as String = nothing and a public property public Overrides property [Descr]() as String get return me.p_Descr end get set (ByVal value As String) me.p_Descr = value end set end property I have some load method, which loads data from a data table and assigns the value from the datarow to the property row is a datarow from a datatable with 47000 Records public overrides sub fillDataRow(byval row as system.data.datarow,byval bolBuffer as boolean) ... If (Not row.isNull(5)) Then ' this line is too slow, really!!!!!!!!!! me.Descr = row(5).tostring() End If .... end sub Like said. Everything is ok in terms of speed. Only the line assigning the row value to the string property is really slow. OK. I am skipping a lot of lines here to make the example easy. But, Without this line assigning the value to the property (but creating 47000 instances of my class and doing everything like querying the database takes Zero Seconds). Just including this one line and the whole thing needs 72 seconds So, I guess there is something wrong in my way assigning strings to a property Is there a better way assigning values to a string property? Many thanks for helping :)
dl4gbe
Posts
-
string assignment in vb.net (It's too slow -
Right Outer Joins and performanceHello, Many thanks for the replies. The problem is. This query does not work at all. The query returns with an error telling me that there is no temporary system tablespace which can handle this query (pagesize). Without the order by clause the query is working. Strange enough, no error number is returned, only the description (in german) An object (rentobj) are assigned 12 categories like manufactor , type of object (truck,van,bus) etc. The category descriptions are stored in an own table. There can be only one category assigned to one object (1:1) But one object can have up to 12 categories, this is why there are 12 categories numbered from 1 til 12. Basically there are 12 joins on the same table category using 12 different fields in rentobj. This joins are used to retrieve the description of each category of the object. I am not the DBA of this database so I can't change system tables space settings. And the design is done by somebody else. The base table rentobj has more than hundred thousend records. I can't look at the execution plan. The query tool we are using does not allow that. Many thanks again
modified on Wednesday, December 10, 2008 11:09 PM
-
Right Outer Joins and performanceHallo, I am working in an company which is using extensivly right outer joins. I argue that outer joins are bad for performance, and we have a lot of performance problems. We are using db2 from IBM. To show you an example (a query which returns page size error in system temporary tablespace) But nobody seems to care. My colleges add more and more right outer joins to querries. Here is the example: Please give me some feetback if this is an ordinary query (my colleges say a database must be able to handle this) or if I am right. I think this query is overkill. SELECT RentObj.Classific1 AS Classific1, RentObj.Classific2 AS Classific2, RentObj.Classific3 AS Classific3, RentObj.Classific4 AS Classific4, RentObj.Classific5 AS Classific5, RentObj.Classific6 AS Classific6, RentObj.Classific7 AS Classific7, RentObj.Classific8 AS Classific8, RentObj.Classific9 AS Classific9, RentObj.Classific10 AS Classific10, RentObj.RentObjId AS RentObjId, Car.RegistrationNumber AS RegistrationNumber, RentObj.Number AS Number, Classification_1.Code AS CCode_1, Classification_2.Code AS CCode_2, Classification_3.Code AS CCode_3, Classification_4.Code AS CCode_4, Classification_5.Code AS CCode_5, Classification_6.Code AS CCode_6, Classification_7.Code AS CCode_7, Classification_8.Code AS CCode_8, Classification_9.Code AS CCode_9, Classification_10.Code AS CCode_10, Car.RentObjId AS Car_RentObjId, Car.FirstLicense AS FirstLicense, Car.ChassisNo AS ChassisNo, Car.CarDocumentNo AS CarDocumentNo, Car.CarKeyNo AS CarKeyNo, Car.CubicCapacity AS CubicCapacity, Car.Kilowatt AS Kilowatt, Car.PayLoad AS PayLoad, Car.RadioCode AS RadioCode, Car.MayorRevison AS MayorRevison, Car.TankContent AS TankContent, Car.Consumption AS Consumption, Car.Kilometer AS Kilometer, Car.UnitNumber AS UnitNumber, Car.KilometerMax AS KilometerMax, Car.KMHigCos AS KMHigCos, Car.KMCI AS KMCI, Car.FuelType AS FuelType, Car.PS AS PS, Car.BrakeSpecInvest AS BrakeSpecInvest, Car.Totalweight AS Totalweight, Car.Unloadedweight AS Unloadedweight, Car.MatchRegNumber AS MatchRegNumber, Car.ConsumptionCityIn AS ConsumptionCityIn, Car.ConsumptionCityOut AS ConsumptionCityOut, Car.CO2Emission AS CO2Emission, RentObj.CompanyId AS CompanyId, RentObj.RentObjTypeId AS RentObjTypeId, RentObj.LicenceeId AS LicenceeId, RentObj.ObjEvent AS ObjEvent, RentObj.StationCIId AS StationCIId, RentObj.ObjPositionCIId AS ObjPositionCIId, RentObj.CostCarrierId AS CostCarrierId, RentObj.CheckInStatPlanId AS CheckInStatPlanId, R
-
Topped 1TB!Hallo 1 TB Normally that's one Thai Baht TB means Thai Baht and thats about 2 Cent Euro :( My wife is doing 120 TB a day... that's a fact of the underdeveloped world... :( What is she doing... She works at Tesco... :^) Chris -- modified at 13:15 Sunday 15th July, 2007
-
Developer's Age !Hallo, I think coding is the most stupid thing you could do in your live. As sooner you quit, as better it is Unfortunatelly I am still in coding but I am trying to avoid coding as much as I can. By the way I am much more than 35 years old.... Being a soldier is the much better choice... long time ago....:( chris
-
What are you doing? [modified]Nice answers: You should use an emulater for development and the PDAs for testing I use special hardware so often emulator is not usable. I have to communicate with a radio transceiver. Nobody is making you use .NET. I have to. It's not my decission what to use. It's the project managers choice. Here programming jobs are quite hard to find. I live in one of the 10 poorest countries in the world. Only 30 % have electricity, for example. :( We only have view computers. I would program the whole thing in eVC, but like said my boss things .Net is cool. I doubt that I do not understand the class system of .Net. I do understand them. But still I consider them as not good designed. I need fast development and not exceptions. And in my opinion .Net is not good for fast development. Unfortunatelly I program on small devices. I do not have tons of choices. :( Now I have to continue to program my medic appointments application. I have to go to a demo tomorrow. :( Chris P.S: I did not ask a programming question. I just got angry because of an unnecessary exception. And I ask how other react in such situations. But it seems that other people have tons of time to deal with all this unexpected things.
-
What are you doing? [modified]Hello What are you doing in case an unexpected exception hits you? I mean Visual Studio does not react for view seconds. The Pocket PC is acting strangely. And than it comes on the screen of the PC: An unexpected exception! An ugly screen pops up claiming that you can't set a selectedindex of a combobo to 0 in case the combobox has no items, for example. Stop debugging, fix the error. Start debugging again. Wait for ages until all the files are copied to the device again. I would like to know how you feel in this crazy moments? To be honest, I get mad. Last year I through 3 Pocket PC's out of the window because of this cracy exceptions. I hate this situations. I hate .Net because of all this useless exceptions it throughs. Why can't this Microsoft classes are not be more forgiving. Why can't I set a selctedindex property to 0 in a combobox in case the combobox got no items. Why can't this classes handle null,nothing as empty string, e.t.c. I think Microsoft did a very lousy job, designing their classes. They should be much more forgiving. It's useless time wasting to protect all the classes from illegal values passed to them. One of the reason I prefer C programming. Instead of crashing the program,the api give back a status if a function worked or not. The program does not crash in most cases. All the additional QA effort is a big waste of time in .Net. And exceptions are in my opinion just a big waste of time and nerves anyway. But there are people who a crazy enough and create their own exceptions in code instead of handling them. :doh: Redmond should be bombed not Beirut. :( Chris :) P.S: My latest crazy piece of code to avoid an error. #if COMPACT_FRAMEWORK = false then dim i as integer #end if Just to avoid an error: unused variable -- modified at 3:54 Tuesday 8th August, 2006
-
VS 2003 XML validation How to switch off?Hallo, Using Visual Studio 2003 I have a big problem editing a XML file with about 25000 lines. As soon as I copy paste something into the xml file validation starts which needs on my computer up to a minute. I do not need validation at all. I need fast editing capibilities. How can I switch this slow crap function off? :doh: Sincerely Chris :)
-
If Only...Be happy in case you got a job. :)
-
I want to buy an ambulanceHallo, An Helicopter would be nice, sure :) But... It is difficult to get an permission for a helicopter flight here. We have helicopters but you have to arrange 3 days in advance. :mad: You can't hire an helicopter just .... :mad: And don't forget it is very expensive.:doh: I worked on helicopters for a long time and on ambulances. I was a military paramedic ;) for 15 years before I started programming... :)
-
Firefox MithsWhy are you so agressiv? I did not attack you personally. So you should not attack me. OK!!!!! Chris :) Personally I prefer Internet Explorer , but I am not agressive! -- modified at 13:19 Friday 21st April, 2006
-
Firefox MithsJust now I am running Internet Explorer, OK! But that is quit of stupid on this page: Legal Notice - Reproduction of this page in whole or in part is strictly forbidden. This guide and ALL versions thereof are protected by copyright under the Digital Millennium Copyright Act (DMCA). Feel free to link to this Guide. That is this: confuse non native english speakers? Chris :) Vietiane Lao (PDR)
-
I want to buy an ambulanceHallo Why not. I got paid for my job... (From a US company) I would like to do something good... buying an ambulance... In the village of my wife we do not have such thing. We do not have an ambulance in the district!!!!! Chris Lao (PDR)
-
I want to buy an ambulanceNice Nish I am a little bit drunk now... But it does not matter My Idea is to buy an ambulance :) Chris :)
-
I want to buy an ambulanceWe do not have any emergency services here. But... I would like to have same emergency services here... An Ambulance... With red, blue lights on the top like police , rescue people:) An ambulance Cool Idea:) Chris :)
-
Interestingไทยลาวดีมาก Just a test. :) No, it does not work for me. :(( -- modified at 3:26 Wednesday 19th April, 2006
-
small database neededThank you for the replies. I will check out everything you sugjest. Many thanks again. Greetings from Bangkok Chris :)
-
small database neededHallo, I need a small sql database. The database should be able to handle inner joins and return something like a recordset or an array of values. It is not necessary for the database to support things like group by, count, max, min and other more complicated sql select statements. The database has to support unicode string types. No other types are required. Yes, a method to add a new record should be avaiable. No need for updating a record. I could create create a new record and delete the old one instead. It's not necessary that this has to be done with SQL. Any kind of method can do. Oh, yes it should support "delete from table where ..." Sequences, stored procedures are not required. Support for Indexes should be avaiable. Some functions to create a table or index is required. Not necessary to be SQL. A drop table function is also required. Basically I need a database which has the functionality of microsoft adoce and cedb (Ce object store). I need to replace adoce and cedb and the Odyssey Software wrapper. no support for sync is required. No support for .net,ado.net or cdb is required either. It's fine if I can use it with C++ (embedded Visual C) The database should be written in C++ or C and should compile with evc 3 or 4. Primarilly it must work with strongarm processors. The database must be small in size and memory consumption. It must run on a machine which has just a view megabyte of RAM avaiable. The database will be used to collect medical records of hilltribe people in remote areas of Laos, Burma, Thailand and Vietnam. It's for a NGO, so it should not cost any serious money and should be open source, so I can remove not required functionality. Unicode support is a must. The database will be only used on the device. No RAD or sync. technology is required. Primarily we use HP Pocket PC hardware. Support for PC is not required. It must have a much smaller footprint than sql server ce has. Anybody a sugjestion. Thanks a lot. Chris :) Vietiane Lao (PDR) Bangkok, Thailand
-
VS makes me crazySituation: Visual Basic project. Open solution. Write some code. Debug Start. Find some bug, or just something I did not program jet. Stop debugging. Change some code. Suddendly some errors appear in the task list: FinishLoadedControlsEventHandler is not defined and other errors. I have no clue what FinishLoadedControlsEventHandler is. I can't find a function like this in my project. The others errors are also just plain wrong. For example the Interop.ADODB depedency is not found, Ok I close the solution. Open the solution again. The errors are gone. So I am closing the solution every view minutes just to continue working. Any Ideas what is wrong with VS on my machine? Thanks Chris :) Windows XP Professional. VS Version 7.1.3088 Framwork 1.1.4322 SP 1 The Solution is a windows.forms application -- modified at 6:05 Tuesday 14th March, 2006
-
My postBut it wasn't stricktly a programming question. I could not find another forum where I could put it. It was a general question about Visual Studio. It wasn' related to any code. Chris :)