I have a job with around 100K records to process.
There are many print statements which get executed for each record. Does these print statements have any impact on performance?
For that matter, does number of lines or comments have any impact on performance? I want to save even a single ms if I can.
...
I am trying to debug a strange problem with Windows XP (SP3) Adobe AIR performance. Our app syncs data from a remote server to a local SQLite database, and on certain machines, this process takes 15 minutes or more. It should take, at most, a few minutes. We've done enough investigating to come to the conclusion that is definitely re...
I have function which I am using in one of the SQL Job (see function below). I am trying to created a persisted column on this function based on existing column on the same table.
It is giving me following error.
Computed column 'FormattedSSN' in
table 'SomeTable' cannot be persisted
because the column is
non-deterministic.
...
Hi,
I am trying to optimize a class that serializes objects in binary format and writes them in a file. I am currently using a FileStream (in sync mode because of the size of my objects) and a BinaryWriter. Here's what my class looks like:
public class MyClass
{
private readonly BinaryWriter m_binaryWriter;
private readonly S...
I have one job with around 100K records to process. This job truncates the destination tables, and then insert all the records "one at a time", not a batch insert, in these tables.
I need to know how indexes will take affect as these records are inserted? Whether cost of creating index during the job will be more than benefit from using...
var property = obj.GetType().GetProperty(blockName);
if (property == null)
{
var method = obj.GetType().GetMethod(blockName);
if (method == null)
return "[" + blockName + "]";
else
return method.Invoke(obj, null).ToString();
}
el...
I noticed if I print out a long string(char*) using cout it seems to print 1 character at a time to the screen in Windows 7, Vista, and Linux(using putty) using Visual C++ 2008 on Windows and G++ on Linux. Printf is so much faster I actually switched from cout to printf for most printing in a project of mine. This is confusing me because...
Hello,
I do some operation on "big" file (around 4Mb)
I do this :
1. Get all files from a directory and place them in an IList MyInfoClass has properties : name, extension, fullPath, creationDate, contentPart
2. I do a Linq query to get only some extension type.
3. I loop on the Linq query result and for each, I open the file, do some ...
inline void add(const DataStruct& rhs) {
using namespace boost::assign;
vec.reserve(vec.size() + 3);
vec += rhs.a, rhs.b, rhs.c;
}
The above function was executed for about 17000 times and it performed (as far as I can see. There was some transformation involved) about 2 magnitudes worse with the call to vector::reserve.
I ...
Below is example of text:
String id = "A:abc,X:def,F:xyz,A:jkl";
Below is regex:
Pattern p = Pattern.compile("(.*,)?[AC]:[^:]+$");
if(p.matcher(id).matches()) {
System.out.println("Hello world!")
}
When executed above code should print Hello world!.
Does this regex can be modified to gain more performance?
...
What all IIS features in regards to maintain application/optimization should an .NET (ASP.NET) architect or team lead should be aware of?
LIST of features
HTTP Compression. This option significantly improves bandwidth utilization and application performs much faster.
Load Balancing (chris-lively)
Sessions (chris-lively) Different opti...
I use Python 2.5.4. My computer: CPU AMD Phenom X3 720BE, Mainboard 780G, 4GB RAM, Windows 7 32 bit.
I use Python threading but can not make every python.exe process consume 100% CPU. Why are they using only about 33-34% on average?.
I wish to direct all available computer resources toward these large calculations so as to complete t...
My problem in short:
I need a functionality to have optional columns in a linq to sql definition. So that linq to sql normally ignores this column within selects and updates etc.
But if a select contains a value for this column it should use this value.
Long version:
The Scenario
I've the following tables:
If Field.FieldViews.Coun...
I'm creating an app that will have a fair amount of users. Everytime someone views a page or performs an activity I will be writing to a log. While I'm concerned about the performance of that in itself, my bigger concern is that I'm actually wanting to store that history in-session within the ASP.NET MVC application so that when they l...
I have a Perl script that runs via a system() command from C. On a specific site (SunOS 5.10), when that script is run, it nearly always takes 6 seconds or more. On other sites, it runs pretty much instantly (0.1s). If I run the script manually, i.e. not from the C code, it also runs instantly. I eventually tracked the slowness down (by...
Currently I'm running these two queries:
SELECT COUNT(*) FROM `mytable`
SELECT * FROM `mytable` WHERE `id`=123
I'm wondering what format will be the most efficient. Does the order the queries are executed make a difference? Is there a single query that will do what I want?
...
Hi, as a fact of performance which one is better? Is there a difference between the actual 3 three versions of sql-server (2000 / 2005 / 2008)?
...
I've got a situation where I need to resize a large number of images. These images are stored as .jpg files on the file system currently, but I expect to just have byte[] in memory later on in the project. The source image size is variable, but the output should be 3 different predetermined sizes. Aspect ratios should be preserved, paddi...
I am experiencing very odd performance on DB2 version 9.1 when running the query below:
select a.CYCL_NUM
, a.AC_NUM
, a.AUTHS_DTE
, a.PL_ID
, a.APRVD_RSPN_CDE
, a.AUTHS_AMT
, a.AUTHS_STS_CDE
, a.TRAN_CTGR_CDE
, a.MRCHN_CTGR_CDE
, d.out_pu_au_amt
from nwhd12.chldr_auths a, nwhd12.w_chldr_ac d
where cycl_num = 200911
...
I've implemented an HttpModule that intercepts the Response stream of every request and runs a half dozen to a dozen Regex.Replace()s on each text/html-typed response. I'm concerned about how much of a performance hit I'm incurring here. What's a good way to find out? I want to compare speed with and without this HttpModule running.
...