Search Results

Search found 35561 results on 1423 pages for 'value'.

Page 17/1423 | < Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >

  • Video White Paper: Mega-Project Management: Reducing Risk & Complexity across the Value Chain

    - by Melissa Centurio Lopes
    Watch this short video white paper, to learn how Oracle Primavera can help you keep projects on track and protect your investments. You can also download the full white paper “Mega-Project Management: Reducing Risk & Complexity Across the Value Chain” to gain more in depth information about strategies for collaborating and sharing information and data in a systematic way across the value chain. Download the white paper in order to learn how your company can get the expected payoff from your next mega project. Register now to download the full complementary white paper, and discover how to: Improve decision-making and accountability through enterprise-wide visibility, workflows, and collaboration Reduce financial and performance risk

    Read the article

  • Python C API return more than one value / object without building a tuple [migrated]

    - by Grisu
    I got the following problem. I have written a C-Extension to Python(2.7 / 3.2) to interface a self written software library. Unfortunately I need to return two values from the function where the last one is optional. In Python I tried def func(x,y): return x+y, x-y test = func(13,4) but test is a tuple. If I write test1,test2 = func(13,4) I got both values separated. Is there a possibility to return only one value without unpacking the tuple, i.e. the second(,.. third, ..fourth) value gets neglected? And if such a solution existst, how does it look for the C-API? Because return Py_BuildValue("ii",x+y,x-y); results in a tuple as well.

    Read the article

  • SQL SERVER – DELETE, TRUNCATE and RESEED Identity

    - by pinaldave
    Yesterday I had a headache answering questions to one of the DBA on the subject of Reseting Identity Values for All Tables. After talking to the DBA I realized that he has no clue about how the identity column behaves when there is DELETE, TRUNCATE or RESEED Identity is used. Let us run a small T-SQL Script. Create a temp table with Identity column beginning with value 11. The seed value is 11. USE [TempDB] GO -- Create Table CREATE TABLE [dbo].[TestTable]( [ID] [int] IDENTITY(11,1) NOT NULL, [var] [nchar](10) NULL ) ON [PRIMARY] GO -- Build sample data INSERT INTO [TestTable] VALUES ('val') GO When seed value is 11 the next value which is inserted has the identity column value as 11. – Select Data SELECT * FROM [TestTable] GO Effect of DELETE statement -- Delete Data DELETE FROM [TestTable] GO When the DELETE statement is executed without WHERE clause it will delete all the rows. However, when a new record is inserted the identity value is increased from 11 to 12. It does not reset but keep on increasing. -- Build sample data INSERT INTO [TestTable] VALUES ('val') GO -- Select Data SELECT * FROM [TestTable] Effect of TRUNCATE statement -- Truncate table TRUNCATE TABLE [TestTable] GO When the TRUNCATE statement is executed it will remove all the rows. However, when a new record is inserted the identity value is increased from 11 (which is original value). TRUNCATE resets the identity value to the original seed value of the table. -- Build sample data INSERT INTO [TestTable] VALUES ('val') GO -- Select Data SELECT * FROM [TestTable] GO Effect of RESEED statement If you notice I am using the reseed value as 1. The original seed value when I created table is 11. However, I am reseeding it with value 1. -- Reseed DBCC CHECKIDENT ('TestTable', RESEED, 1) GO When we insert the one more value and check the value it will generate the new value as 2. This new value logic is Reseed Value + Interval Value – in this case it will be 1+1 = 2. -- Build sample data INSERT INTO [TestTable] VALUES ('val') GO -- Select Data SELECT * FROM [TestTable] GO Here is the clean up act. -- Clean up DROP TABLE [TestTable] GO Question for you: If I reseed value with some random number followed by the truncate command on the table what will be the seed value of the table. (Example, if original seed value is 11 and I reseed the value to 1. If I follow up with truncate table what will be the seed value now? Here is the complete script together. You can modify it and find the answer to the above question. Please leave a comment with your answer. Reference: Pinal Dave (http://blog.sqlauthority.com) Filed under: PostADay, SQL, SQL Authority, SQL Query, SQL Server, SQL Tips and Tricks, T SQL, Technology

    Read the article

  • Who knows the value of global variables in the qt qtscript script to access the global variable to change the global variable value; [closed]

    - by dawntrees
    Who knows the value of global variables in the qt qtscript script to access the global variable to change the global variable value; forexample int gVar=0; int main(int argc, char *argv[]) { QScriptEngine engine; QScriptValue varValue = m_engine-newVariant(gVar); engine.globalObject().setProperty("gVar", varValue); QScriptValue result = m_engine->evaluate("gVar=100;"); qDebug()<<"gVar================"<<gVar; return 0; } Why gVar = 0 and not equal to 100; how can we make gVar equal to 100(gVar=100) Who can help group I appreciate it, thanks!

    Read the article

  • Architecture: Bringing Value to the Table

    - by Bob Rhubart
    A recent TechTarget article features an interview with Business Architecture expert William Ulrich (Take a business-driven approach to application modernization ). In that article Ulrich offers this advice: "Moving from one technical architecture might be perfectly viable on a project by project basis, but when you're looking at the big picture and you want to really understand how to drive business value so that the business is pushing money into IT instead of IT pulling money back, you have to understand the business architecture. When we do that we're going to really be able to start bringing value to the table." In many respects that big picture view is what software architecture is all about. As an architect, your technical skills must be top-notch. But if you don't apply that technical knowledge within the larger context of moving the business forward, what are you accomplishing? If you're interested in more insight from William Ulrich, you can listen to the ArchBeat Podcast interview he did last year, in which he and co-author Neal McWhorter talked about their book, Business Architecture: The Art and Practice of Business Transformation.

    Read the article

  • jqGrid - dynamically load different drop down values for different rows depending on another column value

    - by Renso
    Goal: As we all know the jqGrid examples in the demo and the Wiki always refer to static values for drop down boxes. This of course is a personal preference but in dynamic design these values should be populated from the database/xml file, etc, ideally JSON formatted. Can you do this in jqGrid, yes, but with some custom coding which we will briefly show below (refer to some of my other blog entries for a more detailed discussion on this topic). What you CANNOT do in jqGrid, referrign here up and to version 3.8.x, is to load different drop down values for different rows in the jqGrid. Well, not without some trickery, which is what this discussion is about. Issue: Of course the issue is that jqGrid has been designed for high performance and thus I have no issue with them loading a  reference to a single drop down values list for every column. This way if you have 500 rows or one, each row only refers to a single list for that particuolar column. Nice! SO how easy would it be to simply traverse the grid once loaded on gridComplete or loadComplete and simply load the select tag's options from scratch, via ajax, from memory variable, hard coded etc? Impossible! Since their is no embedded SELECT tag within each cell containing the drop down values (remeber it only has a reference to that list in memory), all you will see when you inspect the cell prior to clicking on it, or even before and on beforeEditCell, is an empty <TD></TD>. When trying to load that list via a click event on that cell will temporarily load the list but jqGrid's last internal callback event will remove it and replace it with the old one, and you are back to square one. Solution: Yes, after spending a few hours on this found a solution to the problem that does not require any updates to jqGrid source code, thank GOD! Before we get into the coding details, the solution here can of course be customized to suite your specific needs, this one loads the entire drop down list that would be needed across all rows once into global variable. I then parse this object that contains all the properties I need to filter the rows depending on which ones I want the user to see based off of another cell value in that row. This only happens when clicking the cell, so no performance penalty. You may of course to load it via ajax when the user clicks the cell, but I found it more effecient to load the entire list as part of jqGrid's normal editoptions: { multiple: false, value: listingStatus } colModel options which again keeps only a reference to the sinlge list, no duplciation. Lets get into the meat and potatoes of it.         var acctId = $('#Id').val();         var data = $.ajax({ url: $('#ajaxGetAllMaterialsTrackingLookupDataUrl').val(), data: { accountId: acctId }, dataType: 'json', async: false, success: function(data, result) { if (!result) alert('Failure to retrieve the Alert related lookup data.'); } }).responseText;         var lookupData = eval('(' + data + ')');         var listingCategory = lookupData.ListingCategory;         var listingStatus = lookupData.ListingStatus;         var catList = '{';         $(lookupData.ListingCategory).each(function() {             catList += this.Id + ':"' + this.Name + '",';         });         catList += '}';         var lastsel;         var ignoreAlert = true;         $(item)         .jqGrid({             url: listURL,             postData: '',             datatype: "local",             colNames: ['Id', 'Name', 'Commission<br />Rep', 'Business<br />Group', 'Order<br />Date', 'Edit', 'TBD', 'Month', 'Year', 'Week', 'Product', 'Product<br />Type', 'Online/<br />Magazine', 'Materials', 'Special<br />Placement', 'Logo', 'Image', 'Text', 'Contact<br />Info', 'Everthing<br />In', 'Category', 'Status'],             colModel: [                 { name: 'Id', index: 'Id', hidden: true, hidedlg: true },                 { name: 'AccountName', index: 'AccountName', align: "left", resizable: true, search: true, width: 100 },                 { name: 'OnlineName', index: 'OnlineName', align: 'left', sortable: false, width: 80 },                 { name: 'ListingCategoryName', index: 'ListingCategoryName', width: 85, editable: true, hidden: false, edittype: "select", editoptions: { multiple: false, value: eval('(' + catList + ')') }, editrules: { required: false }, formatoptions: { disabled: false} }             ],             jsonReader: {                 root: "List",                 page: "CurrentPage",                 total: "TotalPages",                 records: "TotalRecords",                 userdata: "Errors",                 repeatitems: false,                 id: "0"             },             rowNum: $rows,             rowList: [10, 20, 50, 200, 500, 1000, 2000],             imgpath: jQueryImageRoot,             pager: $(item + 'Pager'),             shrinkToFit: true,             width: 1455,             recordtext: 'Traffic lines',             sortname: 'OrderDate',             viewrecords: true,             sortorder: "asc",             altRows: true,             cellEdit: true,             cellsubmit: "remote",             cellurl: editURL + '?rows=' + $rows + '&page=1',             loadComplete: function() {               },             gridComplete: function() {             },             loadError: function(xhr, st, err) {             },             afterEditCell: function(rowid, cellname, value, iRow, iCol) {                 var select = $(item).find('td.edit-cell select');                 $(item).find('td.edit-cell select option').each(function() {                     var option = $(this);                     var optionId = $(this).val();                     $(lookupData.ListingCategory).each(function() {                         if (this.Id == optionId) {                                                       if (this.OnlineName != $(item).getCell(rowid, 'OnlineName')) {                                 option.remove();                                 return false;                             }                         }                     });                 });             },             search: true,             searchdata: {},             caption: "List of all Traffic lines",             editurl: editURL + '?rows=' + $rows + '&page=1',             hiddengrid: hideGrid   Here is the JSON data returned via the ajax call during the jqGrid function call above (NOTE it must be { async: false}: {"ListingCategory":[{"Id":29,"Name":"Document Imaging & Management","OnlineName":"RF Globalnet"} ,{"Id":1,"Name":"Ancillary Department Hardware","OnlineName":"Healthcare Technology Online"} ,{"Id":2,"Name":"Asset Tracking","OnlineName":"Healthcare Technology Online"} ,{"Id":3,"Name":"Asset Tracking","OnlineName":"Healthcare Technology Online"} ,{"Id":4,"Name":"Asset Tracking","OnlineName":"Healthcare Technology Online"} ,{"Id":5,"Name":"Document Imaging & Management","OnlineName":"Healthcare Technology Online"} ,{"Id":6,"Name":"Document Imaging & Management","OnlineName":"Healthcare Technology Online"} ,{"Id":7,"Name":"EMR/EHR Software","OnlineName":"Healthcare Technology Online"}]} I only need the Id and Name for the drop down list, but the third column in the JSON object is important, it is the only that I match up with the OnlineName in the jqGrid column, and then in the loop during afterEditCell simply remove the ones I don't want the user to see. That's it!

    Read the article

  • Tiled perlin/value noise texture with (2^n)+1 size

    - by tobi
    Actually what I have in mind is value noise I think, but what I am going to ask applies to both of them. It is known that if you want to produce tiled texture by using the perlin/value noise, the size of the texture should be specified as the power of 2 (2^n). Without any modifications to the algorithm when you use the size of (2^n)+1 the texture cannot be tiled anymore, so I am wondering whether it is possible (by modifying the algorithm somehow) to generate such tiling texture with the size of (2^n)+1. The article (from which I have my implementation) is here: http://devmag.org.za/2009/04/25/perlin-noise/ I am aware that I can produce texture with 2^n size and just copy twice the last column/row from the ends to make it (2^n)+1, but I don't want to, because such repetitions are visible too much.

    Read the article

  • Register Today for the Oracle Value Chain Summit 2013

    - by Pam Petropoulos
    Date: February 4 – 6, 2013 Location: Hyatt Regency San Francisco The Oracle Value Chain Summit will bring together users, partners, and luminaries to learn how Oracle is helping companies transform supply chains into value chains to gain competitive edge. This Summit will combine the intimate atmosphere of previous supply chain  events, such as the Oracle PLM and Oracle Maintenance Summits, under one roof and will include almost 200 sessions across all supply chain management solution areas. Oracle’s AutoVue enterprise visualization solutions will be featured as part of the PLM track, where they’ll be showcased within the context of Agile PLM, as well as Oracle’s next generation visualization solutions.   Don’t miss this opportunity to learn more about visualization successes and best practices through sessions featuring customer testimonials, solution demonstrations, and networking activities. Visit the event site for further details and agenda information. An early bird registration fee of $195 is available until December 31, 2012. Click here to register today!

    Read the article

  • Lesetipp: Der TDAzlan Exadata Value Guide

    - by Alliances & Channels Redaktion
    Fast 20 Jahre sind Oracle und TDAzlan schon erfolgreiche Partner. Als VAD unterstützt TDAzlan Oracle Partner bei deren Business, zum Beispiel durch Sales- und Marketing-Support, Webcasts, Zertifizierungstrainings oder Enablement Workshops bis hin zur Spezialisierung. Jetzt wurde der Exadata Value Guide von Azlan für Partner und Kunden aktualisiert auf aktuelle 12c und X4 Technologien. Die Broschüre bündelt Fakten und Tipps rund um die Themen Exadata und Engineered Systems. Sie schlüsselt technische Details zu Oracle Software- und Hardware-Komponenten auf und bietet Verkaufsargumente sowie hilfreiche Erläuterungen zum Salesprozess. Außerdem wird das Oracle Authorized Solution Center (OASC) von TDAzlan in München vorgestellt. Dort haben Partner die Möglichkeit, Oracle Gesamtlösungen zu testen und Ihren Kunden zu präsentieren. Den Exadata Value Guide können sie auch auf der Oracle Informations-Webseite von TDAzlan herunterladen.

    Read the article

  • Lesetipp: Der TDAzlan Exadata Value Guide

    - by Alliances & Channels Redaktion
    Fast 20 Jahre sind Oracle und TDAzlan schon erfolgreiche Partner. Als VAD unterstützt TDAzlan Oracle Partner bei deren Business, zum Beispiel durch Sales- und Marketing-Support, Webcasts, Zertifizierungstrainings oder Enablement Workshops bis hin zur Spezialisierung. Jetzt wurde der Exadata Value Guide von Azlan für Partner und Kunden aktualisiert auf aktuelle 12c und X4 Technologien. Die Broschüre bündelt Fakten und Tipps rund um die Themen Exadata und Engineered Systems. Sie schlüsselt technische Details zu Oracle Software- und Hardware-Komponenten auf und bietet Verkaufsargumente sowie hilfreiche Erläuterungen zum Salesprozess. Außerdem wird das Oracle Authorized Solution Center (OASC) von TDAzlan in München vorgestellt. Dort haben Partner die Möglichkeit, Oracle Gesamtlösungen zu testen und Ihren Kunden zu präsentieren. Den Exadata Value Guide können sie auch auf der Oracle Informations-Webseite von TDAzlan herunterladen.

    Read the article

  • SQL binary value to PHP variable leading zeros

    - by Agony
    Using sql query to pull data from a mssql database results in a value that still has leading zeros. The data in database is stored as binary(13) - so it will pull all 13 digits. However the value is a text, so any leading zeros will generally show up as '?' in a form on the site - and in return will update wrong data to the database later. So what i need is to only select/display the text itself, not all 13 bytes. using: SELECT CONVERT(char,uilock_pw) AS uipwd FROM tbl_UserAccount or SELECT uilock_pw FROM tbl_UserAccount still adds the leading zeros to the char array. Example in database: 0x71776531323300000000000000 Would show up as: qwe123??????? But should be: qwe123 Im not even sure what character those ? represent. Using Echo results in a normal qwe123 - but not in a form.

    Read the article

  • Wireshark TCP Window Size Value

    - by T Vernon
    I am debugging an application with Wireshark and watching the TCP Window Size value shrink on one side of the communication. If the packet's TCP section shows a "Window size value: 1", does that mean the source's window size is 1 or the destination's window size is 1? I know one side is communicating faster than the other can handle, I just want be sure I know which one it is. 1 192.168.0.1 - 192.168.0.100, Modbus/TCP, Length: 66, Window Size Value: 1 2 192.168.0.100 - 192.168.0.1, TCP, Length: 60, Window Size Value: 92 3 192.168.0.100 - 192.168.0.1 TCP, Length: 310, Window Size Value: 92 4 192.168.0.1 - 192.168.0.100 TCP, Length: 54, Window Size Value: 0 So is 192.168.0.1's window size 0 or is it reporting that 192.168.0.100's window is 0? Thanks.

    Read the article

  • Unable to change the value of the variable

    - by Legend
    I'm using a discrete event simulator called ns-2 that was built using Tcl and C++. I was trying to write some code in TCL: set ns [new Simulator] set state 0 $ns at 0.0 "puts \"At 0.0 value of state is: $state\"" $ns at 1.0 "changeVal" $ns at 2.0 "puts \"At 2.0 values of state is: $state\"" proc changeVal {} { global state global ns $ns at-now "set state [expr $state+1]" puts "Changed value of state to $state" } $ns run Here's the output: At 0.0 value of state is: 0 Changed value of state to 0 At 2.0 values of state is: 0 The value of state does not seem to change. I am not sure if I am doing something wrong in using TCL. Anyone has an idea as to what might be going wrong here? EDIT: Thanks for the help. Actually, ns-2 is something over which I do not have much control (unless I recompile the simulator itself). I tried out the suggestions and here's the output: for the code: set ns [new Simulator] set state 0 $ns at 0.0 "puts \"At 0.0 value of state is: $state\"" $ns at 1.0 "changeVal" $ns at 9.0 "puts \"At 2.0 values of state is: $state\"" proc changeVal {} { global ns set ::state [expr {$::state+1}] $ns at-now "puts \"At [$ns now] changed value of state to $::state\"" } $ns run the output is: At 0.0 value of state is: 0 At 1 changed value of state to 1 At 2.0 values of state is: 0 And for the code: set ns [new Simulator] set state 0 $ns at 0.0 "puts \"At 0.0 value of state is: $state\"" $ns at 1.0 "changeVal" $ns at 9.0 "puts \"At 2.0 values of state is: $state\"" proc changeVal {} { global ns set ::state [expr {$::state+1}] $ns at 1.0 {puts "At 1.0 values of state is: $::state"} } $ns run the output is: At 0.0 value of state is: 0 At 1.0 values of state is: 1 At 2.0 values of state is: 0 Doesn't seem to work... Not sure if its a problem with ns2 or my code...

    Read the article

  • WPF ComboBox TemplateBinding to selected value

    - by Greg R
    I'm trying to create an editable textbox via a drop down of selected values. Basically in Red Only mode I want the drop down to be a disabled textbox. It works fine when I do this with SelectedValue but when I need it to display the dropdown text and not the value. This is what I have: <Style x:Key="EditableDropDownValueOnly" TargetType="ComboBox"> <Setter Property="Width" Value="Auto" /> <Setter Property="FontSize" Value="11" /> <Setter Property="HorizontalAlignment" Value="Left" /> <Setter Property="FontFamily" Value="Verdana" /> <Setter Property="MinWidth" Value="25" /> <Style.Triggers> <Trigger Property="IsReadOnly" Value="True"> <Setter Property="Background" Value="#FFFFFF" /> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="ComboBox"> <TextBox Text="{TemplateBinding SelectedItem, Converter={StaticResource StringCaseConverter}}" BorderThickness="0" Background="Transparent" FontSize="{TemplateBinding FontSize}" HorizontalAlignment="{TemplateBinding HorizontalAlignment}" FontFamily="{TemplateBinding FontFamily}" Width="{TemplateBinding Width}" TextWrapping="Wrap"/> </ControlTemplate> </Setter.Value> </Setter> </Trigger> </Style.Triggers> </Style> SelectedItem is a KeyValuePair, since my drop down is bound to a dictionary. I'm trying to display the "Value" element in my template. Is that possible? Thanks a lot!

    Read the article

  • Increment a value from AAA to ZZZ with cyclic rotation

    - by www.openidfrance.frfxkim
    Hi all, I need to code a method that increment a string value from AAA to ZZZ with cyclic rotation (next value after ZZZ is AAA) Here is my code: public static string IncrementValue(string value) { if (string.IsNullOrEmpty(value) || value.Length != 3) { string msg = string.Format("Incorrect value ('{0}' is not between AAA and ZZZ)", value); throw new ApplicationException(msg); } if (value == "ZZZ") { return "AAA"; } char pos1 = value[0]; char pos2 = value[1]; char pos3 = value[2]; bool incrementPos2 = false; bool incrementPos1 = false; if (pos3 == 'Z') { pos3 = 'A'; incrementPos2 = true; } else { pos3++; } if (incrementPos2 && pos2 == 'Z') { pos2 = 'A'; incrementPos1 = true; } else { if (incrementPos2) { if (pos2 == 'Z') { pos2 = 'A'; incrementPos1 = true; } pos2++; } } if (incrementPos1) { pos1++; } return pos1.ToString() + pos2.ToString() + pos3.ToString(); } I know this piece of code is quite dirty and not very efficient but I dont know how to do it properly. How is secured this snippet? (this will only run on windows plaform) How can I optimize-it and make it more readable ? Thanks for your comments

    Read the article

  • how can i change selected value of drop list dynamically

    - by Deepak Gupta
    i want to pick the value from text box and then change the value of dropdown list according to that value <html> <head> <script> function change() { var value = document.getElementById('text').value; document.getElementById("Model").selectedvalue = value } </script> </head> <body> <asp:DropDownList ID="Model" AutoPostBack="false" runat="server" CssClass="styled"> <asp:ListItem Value="None">None</asp:ListItem> <asp:ListItem Value="Enum">Enum</asp:ListItem> <asp:ListItem Value="Sum">Sum</asp:ListItem> <asp:ListItem Value="Multi">Multi</asp:ListItem> <asp:ListItem Value="Xaxis">Xaxis</asp:ListItem> </asp:DropDownList> <input id="text" type="text"/> <input type="button" onclick="change();"/> </body> <html>

    Read the article

  • Getting key/value pairs from plist-style xml using simplexml in php

    - by Anthony
    Here is an example bit from the xml file: <array> <dict> <key>Name</key> <string>Joe Smith</string> <key>Type</key> <string>Profile</string> <key>Role</key> <string>User</string> <key>Some Number</key> <integer>1</integer> <key>Some Boolean</key> <true/> </dict> </array> I have two separate goals. The first is to extract an array from the dictnode that would look like: [Name] => Joe Smith [Type] => Profile [Role] => User [Some Number] => 1 [Some Boolean] => true It's not crucial that the boolean be included, so if that adds too much complexity, I'd rather just know how to deal with the others for now. The second goal is to be able to select the value node (<string>, <integer>,etc) so that I can change the value. I would need to select it based on the text value of the preceding key element. I think the following XPath should work: //key[.=$keyname]/following-sibling[1] But I'm not sure. Basically, this whole system that Apple uses seems logical, but totally contrary to the XML is supposed to work. If I ran the world, the original XML would look more like: <dict type="array"> <value key="Name" type="string">Joe Smith</value> <value key="Type" type="string">Profile</value> <value key="Role type="string">User</value> <value key="Some Number" type="integer">1</value> <value key="Some Boolean" type="boolean">true</value> </dict> But since it is fairly logical, I am wondering if I'm missing some obvious way of handling it.

    Read the article

  • SQL SERVER – Solution of Puzzle – Swap Value of Column Without Case Statement

    - by pinaldave
    Earlier this week I asked a question where I asked how to Swap Values of the column without using CASE Statement. Read here: SQL SERVER – A Puzzle – Swap Value of Column Without Case Statement. I have proposed 3 different solutions in the blog posts itself. I had requested the help of the community to come up with alternate solutions and honestly I am stunned and amazed by the qualified entries. I will be not able to cover every single solution which is posted as a comment, however, I would like to for sure cover few interesting entries. However, I am selecting 5 solutions which are different (not necessary they are most optimal or best – just different and interesting). Just for clarity I am involving the original problem statement here. USE tempdb GO CREATE TABLE SimpleTable (ID INT, Gender VARCHAR(10)) GO INSERT INTO SimpleTable (ID, Gender) SELECT 1, 'female' UNION ALL SELECT 2, 'male' UNION ALL SELECT 3, 'male' GO SELECT * FROM SimpleTable GO -- Insert Your Solutions here -- Swap value of Column Gender SELECT * FROM SimpleTable GO DROP TABLE SimpleTable GO Here are the five most interesting and different solutions I have received. Solution by Roji P Thomas UPDATE S SET S.Gender = D.Gender FROM SimpleTable S INNER JOIN SimpleTable D ON S.Gender != D.Gender I really loved the solutions as it is very simple and drives the point home – elegant and will work pretty much for any values (not necessarily restricted by the option in original question ‘male’ or ‘female’). Solution by Aneel CREATE TABLE #temp(id INT, datacolumn CHAR(4)) INSERT INTO #temp VALUES(1,'gent'),(2,'lady'),(3,'lady') DECLARE @value1 CHAR(4), @value2 CHAR(4) SET @value1 = 'lady' SET @value2 = 'gent' UPDATE #temp SET datacolumn = REPLACE(@value1 + @value2,datacolumn,'') Aneel has very interesting solution where he combined both the values and replace the original value. I personally liked this creativity of the solution. Solution by SIJIN KUMAR V P UPDATE SimpleTable SET Gender = RIGHT(('fe'+Gender), DIFFERENCE((Gender),SOUNDEX(Gender))*2) Sijin has amazed me with Difference and Soundex function. I have never visualized that above two functions can resolve the problem. Hats off to you Sijin. Solution by Nikhildas UPDATE St SET St.Gender = t.Gender FROM SimpleTable St CROSS Apply (SELECT DISTINCT gender FROM SimpleTable WHERE St.Gender != Gender) t I was expecting that someone will come up with this solution where they use CROSS APPLY. This is indeed very neat and for sure interesting exercise. If you do not know how CROSS APPLY works this is the time to learn. Solution by mistermagooo UPDATE SimpleTable SET Gender=X.NewGender FROM (VALUES('male','female'),('female','male')) AS X(OldGender,NewGender) WHERE SimpleTable.Gender=X.OldGender As per author this is a slow solution but I love how syntaxes are placed and used here. I love how he used syntax here. I will say this is the most beautifully written solution (not necessarily it is best). Bonus: Solution by Madhivanan Somehow I was confident Madhi – SQL Server MVP will come up with something which I will be compelled to read. He has written a complete blog post on this subject and I encourage all of you to go ahead and read it. Now personally I wanted to list every single comment here. There are some so good that I am just amazed with the creativity. I will write a part of this blog post in future. However, here is the challenge for you. Challenge: Go over 50+ various solutions listed to the simple problem here. Here are my two asks for you. 1) Pick your best solution and list here in the comment. This exercise will for sure teach us one or two things. 2) Write your own solution which is yet not covered already listed 50 solutions. I am confident that there is no end to creativity. Reference: Pinal Dave (http://blog.SQLAuthority.com) Filed under: PostADay, SQL, SQL Authority, SQL Function, SQL Puzzle, SQL Query, SQL Server, SQL Tips and Tricks, T SQL, Technology

    Read the article

  • Unlock More Value: Oracle Platinum Services at Oracle OpenWorld

    - by Oracle OpenWorld Blog Team
    In a bold move to provide even more value to customers who adopt the extreme performance of Oracle Exalogic Elastic Cloud, Oracle Exadata, and Oracle SPARC SuperCluster, Oracle recently launched a set of enhanced services that help IT managers decrease the cost and complexity of supporting their IT environments: Oracle Platinum Services. Learn more by attending the Oracle Platinum Services: Unlock More Value with Advanced Support session at Oracle OpenWorld. In this session, Oracle shares how to achieve maximum performance and lower total cost of ownership through certified configurations for Oracle engineered systems and Oracle Platinum Services. Hear about the industry-leading Oracle Platinum Services offering and tools already used by Oracle customers, including remote fault monitoring, faster response times and patching services.Vincent Biddlecombe, chief technology officer of Transplace, a third-party logistics provider, is seeing results already. He says “The Platinum Services offering has been a great addition to Oracle Premier Support. This level of support is unique in my experience. We saw results very quickly. Our experience has exceeded my expectations.” The patching services have enabled Transplace to stay up to date on the latest improvements.  According to Biddlecombe, “We've gone from being eight patches behind to completely up to date, and I'm extremely happy.”  Visit us on Monday, October 1 at 12:15 p.m. and become familiar with industry-leading Oracle Platinum Services. For more information on Oracle Customer Support Services sessions and events, go to Oracle Customer Support Services.

    Read the article

  • Value of the HTML5 lang attribute

    - by user359650
    I'm working on a website which will offer localized content following the language+region approach as described on this W3.org page (e.g. fr-CA for Canadian French content, and fr-FR for "French French" content). As we consider content for each language+region to be unique, it is crucial to us that search engines properly identify and serve the content accordingly. By looking up on the Internet (e.g. this question), it appears that most people recommend the use of an ISO639 language code in the HTML lang attribute to describe the content language. Following this recommendation, we would en up using <html lang="fr"> which wouldn't enable the differentiation between the aforementioned language+region combinations. When reviewing the HTML4 specification, it seems that using language+region as a language code would be perfectly OK, as the en-US example is given as one possible value. However I couldn't find any confirmation of this in the HTML5 specification which doesn't seem to provide any example as to the possible allowed values. From there I tried to get a de facto answer by looking at what the web giants are doing. I looked at what Facebook are doing: they offer Candian French and French French versions of their websites with (slightly) different content, whilst the HTML lang value remains the same: fr-CA URL: http://fr-ca.facebook.com HTML lang attribute: <html lang="fr"> translation of the word 'email': courriel fr-FR URL: http://fr-fr.facebook.com/ HTML lang attribute: <html lang="fr"> translation of the word 'email': Adresse électronique Q: What is the recommended/standard way of describing content that was localized using the language+region approach in HTML5 ?

    Read the article

  • Combo/Input LOV displaying non-reference key value

    - by [email protected]
    Its a very common use-case of LOV that we want to diplay a non key value in the LOV but store the key value in the DB. I had to do the same in a sample application I was building. During implementation of this, I realized that there are multiple ways to achieve this.I am going to describe each of these below.Example : Lets take an example of our classic HR schema. I have 2 tables Employee and Department where Dno is the foreign key attribute in Employee that references Department table.I want to create a LOV for Deparment such that the List always displays Dname instead of Dno. However when I update it, it it should update the reference key Dno.To achieve this I had 3 alternative1) Approach 1 :Create a composite VO and add the attributes from Department into Employee using a join.Refer the blog http://andrejusb.blogspot.com/2009/11/defining-lov-on-reference-attribute-in.htmlPositives :1. Easy to implement and use.2. We can use this attribute directly in queries defined on new attribute i.e If i have to display this inside query panel.Negative : We have to create an additional Join on the VO.Ex:SELECT Employees.EMPLOYEE_ID,        Employees.FIRST_NAME,        Employees.LAST_NAME,        Employees.EMAIL,        Employees.PHONE_NUMBER,       Department.Dno,        Department.DnameFROM EMPLOYEES Employees, Department Department WHERE Employees.Dno = Department .Dno2) Approach 2 :

    Read the article

  • Nucleus Research – Research Note: Technology Value Matrix – First Half 2012 Enterprise Applications

    - by LanaProut
    1024x768 Normal 0 false false false EN-US X-NONE X-NONE MicrosoftInternetExplorer4 /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin:0in; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Times New Roman","serif";} The Technology Value Matrix evaluates products that have a global presence and provide core functionality for finance and accounting, human resources, manufacturing, supply chain management, project management, and customer relationship management.  Oracle E-Business Suite and Oracle JD Edwards EnterpriseOne are leaders in the Value Matrix for the first half of 2012.  Click here to view the report.

    Read the article

  • Grouping a comma separated value on common data [closed]

    - by Ankit
    I have a table with col1 id int, col2 as varchar (comma separated values) and column 3 for assigning group to them. Table looks like col1 col2 group .............................. 1 2,3,4 2 5,6 3 1,2,5 4 7,8 5 11,3 6 22,8 This is only the sample of real data, now I have to assign a group no to them in such a way that output looks like col1 col2 group .............................. 1 2,3,4 1 2 5,6 1 3 1,2,5 1 4 7,8 2 5 11,3 1 6 22,8 2 The logic for assigning group no is that every similar comma separated value of string in col2 have to be same group no as every where in col2 where '2' is there it has to be same group no but the complication is that 2,3,4 are together so they all three int value if found in any where in col2 will be assigned same group. The major part is 2,3,4 and 1,2,5 both in col2 have 2 so all int 1,2,3,4,5 have to assign same group no. Tried store procedure with match against on col2 but not getting desired result Most imp (I can't use normalization, because I can't afford to make new table from my original table which have millions of records), even normalization is not helpful in my context. This question is also on stackoverflow with bounty on this link Achieved so far:- I have set the group column auto increment and then wrote this procedure:- BEGIN declare cil1_new,col2_new,group_new int; declare done tinyint default 0; declare group_new varchar(100); declare cur1 cursor for select col1,col2,`group` from company ; DECLARE CONTINUE HANDLER FOR NOT FOUND SET done=1; open cur1; REPEAT fetch cur1 into col1_new,col2_new,group_new; update company set group=group_new where match(col2) against(concat("'",col2_new,"'")); until done end repeat; close cur1; select * from company; END This procedure is working, no syntax mistake but the problem is that I am not achieving the desired result exactly.

    Read the article

< Previous Page | 13 14 15 16 17 18 19 20 21 22 23 24  | Next Page >