Daily Archives

Articles indexed Tuesday April 20 2010

Page 9/121 | < Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >

  • multiple VM vs multiple named instance

    - by thushya
    Hi , I am looking for some comparison or data for sql 2008 deployment , what are the advantages and disadvantages installing multiple VM vs multiple named instance ? How can i save license cost using VMs vs physical server for sql 2008 ? is there a way to find out what is maximum number of connections to database at any time or in the past - need to calculate needed CAL license ? Thanks.

    Read the article

  • So you're a new sysadmin...

    - by 80bower
    I've recently taken over management of a Windows 2003 Small Business server and network for a small, less than ten person company. I have some (antiquated) sysadmin experience, but I've little experience with Exchange. The documentation of the existing infrastructure leaves much to be desired, and I was wondering if there's any sort of "So you've just become sysadmin" guides that anyone could recommend.

    Read the article

  • Converting Inkscape layers directly to a slideshow presentation?

    - by darenw
    I'm creating a slideshow in Inkscape. There's one or more layer per slide, plus several background layers, and some special layers to be used on several slides in a row, etc. In the past, I'd create each slide as a .png image by turning on appropriate layers and exporting an image. This is tedious and easy to make mistakes. Is it possible to automate this? To enable the right layers and save all slides directly to a file format suitable for presenatations, such as .ppt, which I can give to anyone for display? The solution will have to work on Linux.

    Read the article

  • Identifying which value of a multi-row inserts fails foreign key constraint

    - by Jonathan
    I have a multi-row insert that looks something like: insert into table VALUES (1, 2, 3), (4, 5, 6), (7, 8, 9); Assume the first attribute (1, 4, 7) is a foreign key to another table and assume that this referenced table does not have the value '4'. A MySQLExeption is thrown with error code 1452. EXCEPTION: Cannot add or update a child row: a foreign key constraint fails (dbName/tableName, CONSTRAINT id FOREIGN KEY (customer_id) REFERENCES referencedTable (customer_id)) Is there a way to identify which value caused the error? I would love to give my user an error message that said something like: Error: '4' does not exist in the referenced table. I am using the .NET mysql connector to execute the insert. Thanks- Jonathan

    Read the article

  • Dump characters (glyphs) from TrueType font (TTF) into bitmaps

    - by jpatokal
    I have a custom TrueType font (TTF) that consists of a bunch of icons, which I'd like to render as individual bitmaps (GIF, PNG, whatever) for use on the Web. You'd think this is a simple task, but apparently not? There is a huge slew of TTF-related software here: http://cg.scs.carleton.ca/~luc/ttsoftware.html But it's all varying levels of "not quite what I want", broken links and/or hard to impossible to compile on a modern Ubuntu box -- eg. dumpglyphs (C++) and ttfgif (C) both fail to compile due to obscure missing dependencies. Any ideas?

    Read the article

  • Splitting a test to a set of smaller tests

    - by mkorpela
    I want to be able to split a big test to smaller tests so that when the smaller tests pass they imply that the big test would also pass (so there is no reason to run the original big test). I want to do this because smaller tests usually take less time, less effort and are less fragile. I would like to know if there are test design patterns or verification tools that can help me to achieve this test splitting in a robust way. I fear that the connection between the smaller tests and the original test is lost when someone changes something in the set of smaller tests. Another fear is that the set of smaller tests doesn't really cover the big test. An example of what I am aiming at: //Class under test class A { public void setB(B b){ this.b = b; } public Output process(Input i){ return b.process(doMyProcessing(i)); } private InputFromA doMyProcessing(Input i){ .. } .. } //Another class under test class B { public Output process(InputFromA i){ .. } .. } //The Big Test @Test public void theBigTest(){ A systemUnderTest = createSystemUnderTest(); // <-- expect that this is expensive Input i = createInput(); Output o = systemUnderTest.process(i); // <-- .. or expect that this is expensive assertEquals(o, expectedOutput()); } //The splitted tests @PartlyDefines("theBigTest") // <-- so something like this should come from the tool.. @Test public void smallerTest1(){ // this method is a bit too long but its just an example.. Input i = createInput(); InputFromA x = expectedInputFromA(); // this should be the same in both tests and it should be ensured somehow Output expected = expectedOutput(); // this should be the same in both tests and it should be ensured somehow B b = mock(B.class); when(b.process(x)).thenReturn(expected); A classUnderTest = createInstanceOfClassA(); classUnderTest.setB(b); Output o = classUnderTest.process(i); assertEquals(o, expected); verify(b).process(x); verifyNoMoreInteractions(b); } @PartlyDefines("theBigTest") // <-- so something like this should come from the tool.. @Test public void smallerTest2(){ InputFromA x = expectedInputFromA(); // this should be the same in both tests and it should be ensured somehow Output expected = expectedOutput(); // this should be the same in both tests and it should be ensured somehow B classUnderTest = createInstanceOfClassB(); Output o = classUnderTest.process(x); assertEquals(o, expected); }

    Read the article

  • safely encode and pass a string from a html link to PHP program

    - by bert
    What series of steps would be reqired to safely encode and pass a string from a html href using javascript to construct the link to a php program. in javascript set up URL // encodes a URI component. path = "mypgm.php?from=" + encodeURIComponent(myvar) ; in php: // get passed variables $myvar = isset($_GET['myvar']) ? ($_GET['myvar']) : ''; // decode - (make the string readable) $myvar = (rawurldecode($myvar)); // converts characters to HTML entities (reduce risk of attack) $myvar = htmlentities($myvar); // maybe custom sanitize program as well? // see [http://stackoverflow.com/questions/2668854/php-sanitizing-strings-to-make-them-url-and-filename-safe][1] $myvar = sanitize($myvar);

    Read the article

  • How does the Garbage Collector decide when to kill objects held by WeakReferences?

    - by Kennet Belenky
    I have an object, which I believe is held only by a WeakReference. I've traced its reference holders using SOS and SOSEX, and both confirm that this is the case (I'm not an SOS expert, so I could be wrong on this point). The standard explanation of WeakReferences is that the GC ignores them when doing its sweeps. Nonetheless, my object survives an invocation to GC.Collect(GC.MaxGeneration, GCCollectionMode.Forced). Is it possible for an object that is only referenced with a WeakReference to survive that collection? Is there an even more thorough collection that I can force? Or, should I re-visit my belief that the only references to the object are weak?

    Read the article

  • ActiveRecord + CodeIgniter - Return single value from query, not in array form.

    - by txmail
    Say you construct an activerecord query that will always just return a single value, how do you just address that single value instead of getting an array in return? For instance I am using an ActiveRecord query to return the SUM of a single column, it will only return this one single SUM, instead of having to parse the array is there a way to assign the value as a function return equal to that value instead of getting an array?

    Read the article

  • I need someone to explain this ASP function to me

    - by Ronnie Chester Lynwood
    Hello! I've got an ASP document that 5 years old. Actually I'm working with PHP but I must use ASP for a Windows Application. So I need someone to explain this function to me. //DNS SETTINGS ARE INCLUDED ALREADY. function Check_Is_Web_Locked() dim cmdDB , Ret OpenDatabase Set cmdDB = Server.CreateObject("ADODB.Command") With cmdDB .ActiveConnection = DBCon .CommandText = "TICT_CHECK_WEB_STATUS" .CommandType = adCmdStoredProc .Parameters.Append .CreateParameter("RETURN_VALUE", adInteger, adParamReturnValue, 0) .Execute,,adExecuteNoRecords Ret = Trim(.Parameters("RETURN_VALUE")) End With Set cmdDB = Nothing CloseDatabase Check_Is_Web_Locked = Ret end function What does this function do? Is "TICT_CHECK_WEB_STATUS" a StoredProcedure? If it's what are the coulumns that function looking for?

    Read the article

  • How do I monitor trap alerts in Perl?

    - by AzharMG
    What is the simplest code in perl to monitor trap from any devices such as UPS, Rectifier, AirCond etc. In example we want to monitor temperature, server room humidity, aircond level etc. Each devices such as UPS, there are SNMP card inside and then we put out trap server IP address. Currently I am using snmptt open software application.

    Read the article

  • Single Form with Multiple Dynamic Buttons

    - by John Reilly
    I've spent hours/days trying to figure this out and now I'm completely perplexed so I thought I'd give stackoverflow a try. I'm (a newb) working in Java/JSP using Eclipse hosting on Google App Engine trying to develop an app for a volunteer organization I'm a member of. Rather than embarrass myself by showing my current code I'd love just a nudge in the right direction. I have a form (which doubles as a report basically) showing "people" grouped under the "task" they are currently working on. I would like to select multiple people from multiple tasks and reassign them to another task e.g. Bill and Jane are Gardening, Jeff is Painting. I want to select Jane and Jeff (all people have an associated checkbox in the form) and re-assign them to Sweeping (which is a task on the form but has no people assigned to it yet). Ideally, the re-assignment to Sweeping would be via a Sweeping button (each task would have a dynamically-created task button) that would pass the "Sweeping" value to a servlet along with an array or list of people whose checkbox has been checked. The servlet would handle the request (creating an Assignment "object/entity" with timeStamp, personId, taskId) and then re-direct back to the form/report which would then repaint with the current tasks/people generated from the Assignments class in the datastore. All the tasks are user-defined and retrieved from the database when building the form. Ditto the people. I've been trying to keep the jsp for presentation and the servlets for the processing but I'm no purist and would just like to get unstuck. Many thanks in advance for your assistance.

    Read the article

  • using eval in server side code on asp.net page

    - by Sumit Sharma
    <asp:Repeater ID="rptrParent" runat="server"> <ItemTemplate> <li> <a href="<% =ResolveUrl("~/cPanel/UserView.aspx?User=")%><%# Eval("StudentUserName") %>"> <span> <% ProfileCommon pc = new ProfileCommon(); pc.GetProfile(Eval("StudentUserName").ToString()); Response.Write(pc.FirstName + "" + pc.LastName); %> <%# Eval("StudentUserName") %> </span> </a> </li> </ItemTemplate> The following error Databinding methods such as Eval(), XPath(), and Bind() can only be used in the context of a databound control. is coming in this part <% ProfileCommon pc = new ProfileCommon(); pc.GetProfile(Eval("StudentUserName").ToString()); Response.Write(pc.FirstName + "" + pc.LastName); %>

    Read the article

  • A file was added to git on commit n. How do I add it instead to commit n-m?

    - by carleeto
    I have a branch. Half way through I noticed git was not tracking a file that it should have been and so I added it as part of a commit and continued with my work. Now, I'm doing a git bisect and all commits before the file was added do not build. So I'm thinking, I need to split the commit that added the file into two parts: the file add and the rest of the commit. I then need to re-order the commits so that the file add commit will be at the beginning of my branch. Is this the correct solution or is there a better way of doing it?

    Read the article

  • Silverlight WCF serialization [DataContract(IsReference=true)] problem

    - by Ciaran
    Hi, I'm have a Silverlight 3 UI that access WCF services which in turn access respositories that use NHibernate. To overcome some NHibernate lazy loading issues with WCF I'm using my own DataContract surrogate as described here: http://timvasil.com/blog14/post/2008/02/WCF-serialization-with-NHibernate.aspx. In here I'm setting preserveObjectReferences = true My model contains cycles (i.e. Customer with Collection). When I retrieve an object from my service it works fine, however when I try and send that same object back to the wcf service I get the error: System.ServiceModel.CommunicationException was unhandled by user code Message=There was an error while trying to serialize parameter http://tempuri.org/:searchCriteria. The InnerException message was 'Object graph ...' contains cycles and cannot be serialized if references are not tracked. Consider using the DataContractAttribute with the IsReference property set to true.' So cyclical references are now a problem in Silverlight, so I try change my DataContract to be [DataContract(IsReference=true)] but now when I try to retrieve an object from my service I get the following exception: System.ServiceModel.CommunicationException was unhandled by user code Message=The remote server returned an error: NotFound. It shouldn't be this hard to do something so trivial...

    Read the article

  • Suppress "No Source Available" pane in 2010

    - by Jason
    Arg! I have a custom "harness" executable running my class library project. Every time I step into the harness's code, I get that "No Source Available" pane popping up. As I know there is no source available, and that this is completely expected, I don't want this very intrusive and useless pane popping up every time. How can I suppress it completely? I can make it smaller at least by making that window part of another smaller pane-set, such as with the watches/locals. It remembers its location from run to run, but its still useless. There might be a more general answer to this question - how can I suppress any particular pane/window from showing at all? I have a VSX package, originally built for VS 2008 (and must keep that compatibility) but I just don't know what command to run to do it. (I had the package commissioned, so I have the source, but not the know-how. This seems like a one/two liner). Thanks!

    Read the article

  • Install grub on 2nd hard drive

    - by jldupont
    I have 2 HDs in my machine: Drive 1 with grub and my Windows XP OS Drive 2 with only Ubuntu 9.04 I would like to be able to boot directly from drive 2. I am missing grub on drive 2... how do I add it? EDIT: I ended up reinstalling the whole OS.

    Read the article

  • Website Marketing - Essential Skills For Driving Search Engine Traffic (SEO)

    When the internet was populated by only a few thousand websites, it was easy to have a presence on the internet, and there was not much need for a search engine. Things have changed in the last few decades, and with more than 162 million websites currently populating the internet you need to be aware of a few search engine optimization (SEO) basics. These skills will help you make smart choices as you build, edit, and market your website.

    Read the article

  • Database - Designing an "Events" Table

    - by Alix Axel
    After reading the tips from this great Nettuts+ article I've come up with a table schema that would separate highly volatile data from other tables subjected to heavy reads and at the same time lower the number of tables needed in the whole database schema, however I'm not sure if this is a good idea since it doesn't follow the rules of normalization and I would like to hear your advice, here is the general idea: I've four types of users modeled in a Class Table Inheritance structure, in the main "user" table I store data common to all the users (id, username, password, several flags, ...) along with some TIMESTAMP fields (date_created, date_updated, date_activated, date_lastLogin, ...). To quote the tip #16 from the Nettuts+ article mentioned above: Example 2: You have a “last_login” field in your table. It updates every time a user logs in to the website. But every update on a table causes the query cache for that table to be flushed. You can put that field into another table to keep updates to your users table to a minimum. Now it gets even trickier, I need to keep track of some user statistics like how many unique times a user profile was seen how many unique times a ad from a specific type of user was clicked how many unique times a post from a specific type of user was seen and so on... In my fully normalized database this adds up to about 8 to 10 additional tables, it's not a lot but I would like to keep things simple if I could, so I've come up with the following "events" table: |------|----------------|----------------|--------------|-----------| | ID | TABLE | EVENT | DATE | IP | |------|----------------|----------------|--------------|-----------| | 1 | user | login | 201004190030 | 127.0.0.1 | |------|----------------|----------------|--------------|-----------| | 1 | user | login | 201004190230 | 127.0.0.1 | |------|----------------|----------------|--------------|-----------| | 2 | user | created | 201004190031 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 2 | user | activated | 201004190234 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 2 | user | approved | 201004190930 | 217.0.0.1 | |------|----------------|----------------|--------------|-----------| | 2 | user | login | 201004191200 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 15 | user_ads | created | 201004191230 | 127.0.0.1 | |------|----------------|----------------|--------------|-----------| | 15 | user_ads | impressed | 201004191231 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 15 | user_ads | clicked | 201004191231 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 15 | user_ads | clicked | 201004191231 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 15 | user_ads | clicked | 201004191231 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 15 | user_ads | clicked | 201004191231 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 15 | user_ads | clicked | 201004191231 | 127.0.0.2 | |------|----------------|----------------|--------------|-----------| | 2 | user | blocked | 201004200319 | 217.0.0.1 | |------|----------------|----------------|--------------|-----------| | 2 | user | deleted | 201004200320 | 217.0.0.1 | |------|----------------|----------------|--------------|-----------| Basically the ID refers to the primary key (id) field in the TABLE table, I believe the rest should be pretty straightforward. One thing that I've come to like in this design is that I can keep track of all the user logins instead of just the last one, and thus generate some interesting metrics with that data. Due to the nature of the events table I also thought of making some optimizations, such as: #9: Since there is only a finite number of tables and a finite (and predetermined) number of events, the TABLE and EVENTS columns could be setup as ENUMs instead of VARCHARs to save some space. #14: Store IPs as UNSIGNED INT with INET_ATON() instead of VARCHARs. Store DATEs as TIMESTAMPs instead of DATETIMEs. Use the ARCHIVE (or the CSV?) engine instead of InnoDB / MyISAM. Overall, each event would only consume 14 bytes which is okay for my traffic I guess. Pros: Ability to store more detailed data (such as logins). No need to design (and code for) almost a dozen additional tables (dates and statistics). Reduces a few columns per table and keeps volatile data separated. Cons: Non-relational (still not as bad as EAV): SELECT * FROM events WHERE id = 2 AND table = 'user' ORDER BY date DESC(); 6 bytes overhead per event (ID, TABLE and EVENT). I'm more inclined to go with this approach since the pros seem to far outweigh the cons, but I'm still a little bit reluctant.. Am I missing something? What are your thoughts on this? Thanks!

    Read the article

< Previous Page | 5 6 7 8 9 10 11 12 13 14 15 16  | Next Page >