Search Results

Search found 262 results on 11 pages for 'harry pham'.

Page 8/11 | < Previous Page | 4 5 6 7 8 9 10 11  | Next Page >

  • bash: How to evaluate PS1, PS2, ...?

    - by Harry
    Is there any way to 'evaluate' PS1, PS2, etc from within a bash script? Although, I can use alternate means to get all elements of my current PS1, I would really like to be able to reuse its definition instead of using these alternate means. For example, ===================================== PS1 element --> Alternate means ===================================== \u --> $USER \h --> $HOSTNAME \w --> $PWD ... ===================================== I could very well use the 'alternate means' column in my script, but I don't want to. In my PS1, I, for example, use bold blue color via terminal escape sequences which I'd like to be able to simply reuse by evaluating PS1.

    Read the article

  • How to change password hashing algorithm when using spring security?

    - by harry
    I'm working on a legacy Spring MVC based web Application which is using a - by current standards - inappropriate hashing algorithm. Now I want to gradually migrate all hashes to bcrypt. My high level strategy is: New hashes are generated with bcrypt by default When a user successfully logs in and has still a legacy hash, the app replaces the old hash with a new bcrypt hash. What is the most idiomatic way of implementing this strategy with Spring Security? Should I use a custom Filter or my on AccessDecisionManager or …?

    Read the article

  • SQL Database dilemma : Optimize for Querying or Writing?

    - by Harry
    I'm working on a personal project (Search engine) and have a bit of a dilemma. At the moment it is optimized for writing data to the search index and significantly slow for search queries. The DTA (Database Engine Tuning Adviser) recommends adding a couple of Indexed views inorder to speed up search queries. But this is to the detriment of writing new data to the DB. It seems I can't have one without the other! This is obviously not a new problem. What is a good strategy for this issue?

    Read the article

  • Externally disabling signals for a Linux program.

    - by Harry
    Hello, On Linux, is it possible to somehow disable signaling for programs externally... that is, without modifying their source code? Context: I'm calling a C (and also a Java) program from within a bash script on Linux. I don't want any interruptions for my bash script, and for the other programs that the script launches (as foreground processes). While I can use a... trap '' INT ... in my bash script to disable the Ctrl C signal, this works only when the program control happens to be in the bash code. That is, if I press Ctrl C while the C program is running, the C program gets interrupted and it exits! This C program is doing some critical operation because of which I don't want it be interrupted. I don't have access to the source code of this C program, so signal handling inside the C program is out of question. #!/bin/bash trap 'echo You pressed Ctrl C' INT # A C program to emulate a real-world, long-running program, # which I don't want to be interrupted, and for which I # don't have the source code! # # File: y.c # To build: gcc -o y y.c # # #include <stdio.h> # int main(int argc, char *argv[]) { # printf("Performing a critical operation...\n"); # for(;;); // Do nothing forever. # printf("Performing a critical operation... done.\n"); # } ./y Regards, /HS

    Read the article

  • Django Custom Admin

    - by Harry
    Hello there Currently I have an app with a save method in its models.py . So I would like to change this so the models does not do the save() method, but rather have a separate view that will do this in die admin site. Can you please direct me in the correct direction? Thank you

    Read the article

  • Resize an 8bpp bitmap in GDI+

    - by harry
    I've just noticed that GDI+ doesn't like the Graphics.FromImage() method to be called with an image that is 1bpp, 4bpp, or 8bpp. Is there any way of resizing an 8bpp image without changing from 8bpp to 24bpp, resizing, and then changing it back to 8bpp?

    Read the article

  • Can't update rows in my database using Entity Framework...?

    - by Dissonant
    Okay, this is really weird. I made a simple database with a single table, Customer, which has a single column, Name. From the database I auto-generated an ADO.NET Entity Data Model, and I'm trying to add a new Customer to it like so: using System; using System.Collections.Generic; using System.Linq; using System.Text; namespace Test { class Program { static void Main() { Database1Entities db = new Database1Entities(); Customer c = new Customer(); c.Name = "Harry"; db.AddToCustomer(c); db.SaveChanges(); } } } But it doesn't persist Customer "Harry" to the database! I've been scratching my head for a while now wondering why such a simple operation doesn't work. What on earth could be the problem!?

    Read the article

  • Django modelform ForeignKey List

    - by Harry
    How do you get each item in the ForeignKey field in a list, for example: class Delegate(models.Model): excursion = models.ForeignKey(Excursion, limit_choices_to = {'is_activity': False}, related_name='excursion', null=True, blank=True) Template: {% for object in formset.excursion_set.all %} {{ object.lable }} etc {% endfor %} My reason is that I don't want the options to display as a dropdown, but in a custom way that I will style etc.

    Read the article

  • Saving data that is in a table efficiently and also is easy to retrieve and echo back out

    - by Harry
    Information I currently have a table which image is below, Problem I have made this table using ul & li Here is the code http://jsfiddle.net/8j2qe/1/ Question What would be the best way of storing the data in the image and easily displaying it? Keeping in mind that each column can only have 1 entry. Thank you! And any questions will be answered ASAP! EDIT Sorry, I dont think I was clear enough in my initial question. What I am asking is, what is the best way to store and then display this type of data. I want to DISPLAY data from my database to show like it would in the image. Should I have a column in my database for each column on the table, then say either A,B,C or D depending on what column it is in but then how would I display it using PHP in my code provided? Im struggling to find a good way of explaining this, I am sorry.

    Read the article

  • How to allow utf-8 charset in preg_match ???

    - by Shri.harry
    Hello everone, I am using preg_match() function only to allow specific charachters to accept. It is allowing all alphabates and numbers but along with that i also want to allow utf-8 characters such as "ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖ" so how can i allow this charachters from preg_match() function.Plase suggest me. Thanks in advance. Regards Shri

    Read the article

  • using windows service can we copy files from one computer to another computer C#.net ?

    - by Harry
    I have one service that will create a text file to local machine and then need to copy the same file to another server . I am using " File.Copy(SourceFilePath, TargetFilePath, true);" and getting an exception at the target file path "access denied. I am able to copy the files manually to that location ( TargetFilePath) . any idea , what is going wrong ?? I don't have any network drive mapping with this target location. Thanks in Advance

    Read the article

  • Google Maps panTo AND setCenter

    - by Harry
    The default panTo only pans to the edge of the screen. I like setCenter but would like to pan to that point. Any ideas welcome map.setCenter(mymarker.getPoint()); GEvent.trigger(mymarker,"click"); //open the info window

    Read the article

  • INSERT INTO othertbl SELECT * tbl

    - by Harry
    Current situation: INSERT INTO othertbl SELECT * FROM tbl WHERE id = '1' So i want to copy a record from tbl to othertbl. Both tables have an autoincremented unique index. Now the new record should have a new index, rather then the value of the index of the originating record else copying results in a index not unique error. A solution would be to not use the * but since these tables have quite some columns i really think it's getting ugly. So,.. is there a better way to copy a record which results in a new record in othertbl which has a new autoincremented index without having to write out all columns in the query and using a NULL value for the index. -hope it makes sense....-

    Read the article

  • Inserting "£" in a string to a text file

    - by Harry
    iPhone Application writes data to a text file, saves it on the Documnets folder. Great that works If I place "£" in the string, or use [currencyStyle stringFromNumber] the text file will not be created. The "£" and the [currencyStyle stringFromNumber] works if the information is printed to a "New View" page on the simulator, pound and all Can someone please explain what's happening?

    Read the article

  • How to get the content of two xml tags even when they have another xml tags inside them (PHP-XML)

    - by Harry
    In simple terms, let's suppose you have the following xml structure: <TEXT>Well, I need some help as you <CUSTOMTAG>can</CUSTOMTAG> see.</TEXT> When extracting the text of this node in PHP with strip_tags(), I am not getting the content of tags. First step: What I want to do, is to extract and thus have the following string: "Well, I need some help as you can see." Second step: I would also like to convert the <CUSTOMTAG> and </CUSTOMTAG> to something else, like <e> and </e> for example, and finally have the following string: "Well, I need some help as you <e>can</e> see." I would appreciate only tested and working code. Thanks in advance! Kind Regards

    Read the article

  • My Interview With DevExpress Regarding Silicon Valley Code Camp

    Last week, while at Microsofts TechEd 2010, Mehul Harry, Technical Evangalist for Developer Express, interviewed me about our upcoming Silicon Valley Code Camp (of which Dev Express is a platinum... This site is a resource for asp.net web programming. It has examples by Peter Kellner of techniques for high performance programming...Did you know that DotNetSlackers also publishes .net articles written by top known .net Authors? We already have over 80 articles in several categories including Silverlight. Take a look: here.

    Read the article

  • Visual Studio 2010: Pro Power Tools

    - by Enrique Lima
    There is a set of Pro Power Tools released yesterday for Visual Studio 2010.  Check them out here. Brian Harry did a feature summary description on his blog.  Check it out here: http://blogs.msdn.com/b/bharry/archive/2010/06/07/announcing-the-first-visual-studio-pro-power-tools.aspx

    Read the article

  • New Book: "Systems Performance: Enterprise and the Cloud"

    - by uwes
    Brendan Gregg, former Solaris kernel engineer at Sun published his new book "Systems Performance: Enterprise and the Cloud" in October. The book is a modern, very comprehensive guide to general system performance principles and practices, as well as a highly detailed reference for specific UNIX and Linux observability tools used to examine and diagnose operating system behaviour. Read a more detailed abstract and review on Harry J Foxwell's Blog entry "Brendan Gregg's "Systems Performance: Enterprise and the Cloud"

    Read the article

  • Java remove HTML from String without regular expressions

    - by behrk2
    Hello, I am trying to remove all HTML elements from a String. Unfortunately, I cannot use regular expressions because I am developing on the Blackberry platform and regular expressions are not yet supported. Is there any other way that I can remove HTML from a string? I read somewhere that you can use a DOM Parser, but I couldn't find much on it. Text with HTML: <![CDATA[As a massive asteroid hurtles toward Earth, NASA head honcho Dan Truman (<a href="http://www.netflix.com/RoleDisplay/Billy_Bob_Thornton/20000303">Billy Bob Thornton</a>) hatches a plan to split the deadly rock in two before it annihilates the entire planet, calling on Harry Stamper (<a href="http://www.netflix.com/RoleDisplay/Bruce_Willis/99786">Bruce Willis</a>) -- the world's finest oil driller -- to head up the mission. With time rapidly running out, Stamper assembles a crack team and blasts off into space to attempt the treacherous task. <a href="http://www.netflix.com/RoleDisplay/Ben_Affleck/20000016">Ben Affleck</a> and <a href="http://www.netflix.com/RoleDisplay/Liv_Tyler/162745">Liv Tyler</a> co-star.]]> Text without HTML: As a massive asteroid hurtles toward Earth, NASA head honcho Dan Truman (Billy Bob Thornton) hatches a plan to split the deadly rock in two before it annihilates the entire planet, calling on Harry Stamper (Bruce Willis) -- the world's finest oil driller -- to head up the mission. With time rapidly running out, Stamper assembles a crack team and blasts off into space to attempt the treacherous task.Ben Affleck and Liv Tyler co-star. Thanks!

    Read the article

  • Linq-to-SQL: How to shape the data with group by?

    - by Cheeso
    I have an example database, it contains tables for Movies, People and Credits. The Movie table contains a Title and an Id. The People table contains a Name and an Id. The Credits table relates Movies to the People that worked on those Movies, in a particular role. The table looks like this: CREATE TABLE [dbo].[Credits] ( [Id] [int] IDENTITY (1, 1) NOT NULL PRIMARY KEY, [PersonId] [int] NOT NULL FOREIGN KEY REFERENCES People(Id), [MovieId] [int] NOT NULL FOREIGN KEY REFERENCES Movies(Id), [Role] [char] (1) NULL In this simple example, the [Role] column is a single character, by my convention either 'A' to indicate the person was an actor on that particular movie, or 'D' for director. I'd like to perform a query on a particular person that returns the person's name, plus a list of all the movies the person has worked on, and the roles in those movies. If I were to serialize it to json, it might look like this: { "name" : "Clint Eastwood", "movies" : [ { "title": "Unforgiven", "roles": ["actor", "director"] }, { "title": "Sands of Iwo Jima", "roles": ["director"] }, { "title": "Dirty Harry", "roles": ["actor"] }, ... ] } How can I write a LINQ-to-SQL query that shapes the output like that? I'm having trouble doing it efficiently. if I use this query: int personId = 10007; var persons = from p in db.People where p.Id == personId select new { name = p.Name, movies = (from m in db.Movies join c in db.Credits on m.Id equals c.MovieId where (c.PersonId == personId) select new { title = m.Title, role = (c.Role=="D"?"director":"actor") }) }; I get something like this: { "name" : "Clint Eastwood", "movies" : [ { "title": "Unforgiven", "role": "actor" }, { "title": "Unforgiven", "role": "director" }, { "title": "Sands of Iwo Jima", "role": "director" }, { "title": "Dirty Harry", "role": "actor" }, ... ] } ...but as you can see there's a duplicate of each movie for which Eastwood played multiple roles. How can I shape the output the way I want?

    Read the article

  • merging javascript arrays for json

    - by Nat
    I serially collect information from forms into arrays like so: list = {"name" : "John", "email" : "[email protected]", "country" : "Canada", "color" : "blue"}; identifier = "first_round"; list = {"name" : "Harry", "email" : "[email protected]", "country" : "Germany"}; identifier = "second_round"; I want to combine them into something (I may have braces where I need brackets) like: list_all = { "first_round" : {"name" : "John", "email" : "[email protected]", "country" : "Canada", "color" : "blue"} , "second_round" : {"name" : "Harry", "email" : "[email protected]", "country" : "Germany"} }; so I can access them like: alert(list_all.first_round.name) -> John (Note: the name-values ("name", "email", "color") in the two list-arrays are not quite the same, the number of items in each list-array is limited but not known in advance; I need to serially add only one array to the previous structure each round and there may be any number of rounds, i.e. "third-round" : {...}, "fourth-round" : {...} and so on.) Ultimately, I'd like it to be well-parsed for JSON. I use the jquery library, if that helps.

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11  | Next Page >