Search Results

Search found 37 results on 2 pages for 'amo'.

Page 2/2 | < Previous Page | 1 2 

  • How to select the first element of a set with JSTL?

    - by Sergio del Amo
    I managed to do it with the next code but there must be an easier way. <%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> <%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions" %> <c:if test="${fn:length(attachments) > 0}"> <c:forEach var="attachment" items="${attachments}" varStatus="loopCount"> <c:if test="${loopCount.count eq 1}"> attachment.id </c:if> </c:forEach> </c:if>

    Read the article

  • Scale an image which is stored as a byte[] in Java

    - by Sergio del Amo
    I upload a file with a struts form. I have the image as a byte[] and I would like to scale it. FormFile file = (FormFile) dynaform.get("file"); byte[] fileData = file.getFileData(); fileData = scale(fileData,200,200); public byte[] scale(byte[] fileData, int width, int height) { // TODO } Anyone knows an easy function to do this? public byte[] scale(byte[] fileData, int width, int height) { ByteArrayInputStream in = new ByteArrayInputStream(fileData); try { BufferedImage img = ImageIO.read(in); if(height == 0) { height = (width * img.getHeight())/ img.getWidth(); } if(width == 0) { width = (height * img.getWidth())/ img.getHeight(); } Image scaledImage = img.getScaledInstance(width, height, Image.SCALE_SMOOTH); BufferedImage imageBuff = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB); imageBuff.getGraphics().drawImage(scaledImage, 0, 0, new Color(0,0,0), null); ByteArrayOutputStream buffer = new ByteArrayOutputStream(); ImageIO.write(imageBuff, "jpg", buffer); return buffer.toByteArray(); } catch (IOException e) { throw new ApplicationException("IOException in scale"); } } If you run out of Java Heap Space in tomcat as I did, increase the heap space which is used by tomcat. In case you use the tomcat plugin for Eclipse, next should apply: In Eclipse, choose Window Preferences Tomcat JVM Settings Add the following to the JVM Parameters section -Xms256m -Xmx512m

    Read the article

  • Is it possible to use wildcards within J2EE - fitlers?

    - by Sergio del Amo
    I would like to apply a filter to severl url endings. The next configuraiton seems to work. <filter> <filter-name>LanguageFilter</filter-name> <filter-class>filters.LanguageFilter</filter-class> </filter> <filter-mapping> <filter-name>LanguageFilter</filter-name> <url-pattern>*.do</url-pattern> </filter-mapping> <filter-mapping> <filter-name>LanguageFilter</filter-name> <url-pattern>*.xml</url-pattern> </filter-mapping> Originally I asked if it was possible to use wildcards such as: <url-pattern>*.do|*.xml</url-pattern> But it does not seem to be possible.

    Read the article

  • How to replace plain URLs with links?

    - by Sergio del Amo
    I am using the function below to match URLs inside a given text and replace them for HTML links. The regular expression is working great, but currently I am only replacing the first match. How I can replace all the URL? I guess I should be using the exec command, but I did not really figure how to do it. function replaceURLWithHTMLLinks(text) { var exp = /(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/i; return text.replace(exp,"<a href='$1'>$1</a>"); }

    Read the article

  • SQL SERVER – List of All the Samples Database Available to Download for FREE

    - by Pinal Dave
    It is pretty much very common to have a sample database for any database product. Different companies keep on improving their product and keep on coming up with innovation in their product. To demonstrate the capability of their new enhancements they need the sample database. Microsoft have various sample database available for free download for their SQL Server Product. I have collected them here in a single blog post. Download an AdventureWorks Database The AdventureWorks OLTP database supports standard online transaction processing scenarios for a fictitious bicycle manufacturer (Adventure Works Cycles). Scenarios include Manufacturing, Sales, Purchasing, Product Management, Contact Management, and Human Resources. Coconut Dal Coconut Dal is a lightweight data access layer, for use in projects where the Entity Framework cannot be used or Microsoft’s Enterprise Library Data Block is unsuitable. Anyone who is handwriting ADO.NET should use a library instead and Coconut Dal might be the answer.  DataBooster – Extension to ADO.NET Data Provider The dbParallel DataBooster library is a high-performance extension to ADO.NET Data Provider, includes two aspects: 1) A slimmed down API encapsulation which simplified the most common data access operations (DbConnection -> DbCommand -> DbParameter -> DbDataReader) into a single class DbAccess, to help application with a clean DAL, avoid over-packing and redundant-copy of data transfer. 2) A booster for writing mass data onto database. Base on a rational utilization of database concurrency and a effective utilization of network bandwidth. Tabular AMO 2012 The sample is made of two project parts. The first part is a library of functions to manage tabular models -AMO2Tabular V2-. The second part is a sample to build a tabular model -AdventureWorks Tabular AMO 2012- using the AMO2Tabular library; the created model is similar to the ‘AdventureWorks Tabular Model 2012. SQL Server Analysis Services Product Samples SQL Server Analysis Services provides, a unified and integrated view of all your business data as the foundation for all of your traditional reporting, online analytical processing (OLAP) analysis, Key Performance Indicator (KPI) scorecards, and data mining. Analysis Services Samples for SQL Server 2008 R2 This release is dedicated to the samples that ship for Microsoft SQL Server 2008R2. For many of these samples you will also need to download the AdventureWorks family of databases. SQL Server Reporting Services Product Samples This project contains Reporting Services samples released with Microsoft SQL Server product. These samples are in the following five categories: Application Samples, Extension Samples, Model Samples, Report Samples, and Script Samples. If you are interested in contributing Reporting Services samples, please let us know by posting in the developers’ forum. Reporting Services Samples for SQL Server 2008 R2 This release is dedicated to the samples that ship for Microsoft SQL Server 2008 R2 PCU1. For many of these samples you will also need to download the AdventureWorks family of databases. SQL Server Integration Services Product Samples This project contains Integration Services samples released with Microsoft SQL Server product. These samples are in the following two categories: Package Samples and Programming Samples. If you are interested in contributing Integration Services samples, please let us know by posting in the developers’ forum. Integration Services Samples for SQL Server 2008 R2 This release is dedicated to the samples that ship for Microsoft SQL Server 2008R2. For many of these samples you will also need to download the AdventureWorks family of databases. Windows Azure SQL Reporting Admin Sample The SQLReportingAdmin sample for Windows Azure SQL Reporting demonstrates the usage of SQL Reporting APIs, and manages (add/update/delete) permissions of SQL Reporting users. Windows Azure SQL Reporting ReportViewer-SOAP API usage sample These sample projects demonstrate how to embed a Microsoft ReportViewer control that points to reports hosted on SQL Reporting report servers and how to use SQL Reporting SOAP APIs in your Windows Azure Web application. Enterprise Library 5.0 – Integration Pack for Windows Azure This NuGet package contains a zip file with the source code for the Enterprise Library Integration Pack for Windows Azure.  Reference: Pinal Dave (http://blog.sqlauthority.com) Filed under: PostADay, SQL, SQL Authority, SQL Download, SQL Query, SQL Server, SQL Tips and Tricks, T SQL, Technology Tagged: SQL Sample Database

    Read the article

  • Comment procédez vous pour maintenir votre mapping Objet / Relationnel pendant la vie de vos applica

    Bonjour, Il existe 2 approches majeures dans le mapping Objet Relationnel :partir de la base de données et générer ses objets mappés avec les outils complémentaires au framework utilisé mettre en place son modèle objet et s'appuyer sur configuration (annotations / xml) du mapping pour créer / mettre à jour sa base de données Et il y a bien entendu un monde entre les deux, comprenant une approche moins outillée, et également une approche moins méthodique (combinaison des 2 approches par mises à jour dans un sens ou dans l'autre selon la nature de la mise à jour). L'objet de ce sondage est de voir quelle est la pratique la plus répandue hors initialisation (pour ceux qui démarrent avec un modèle objet / relationnel concu en amo...

    Read the article

  • How do I fix the error: CS1548: Cryptographic failure while signing assembly ?

    - by Paula DiTallo
    The full error in Microsoft Visual Studio on a compile looks like this: error CS1548: Cryptographic failure while signing assembly 'C:\Program Files\Microsoft SQL Server\100\Samples\Analysis Services\Programmability\AMO\AMOAdventureWorks\CS\StoredProcedures\obj\Debug\StoredProcedures.dll' This is likely due to a missing strong key pair value file. The easiest way to solve this problem is to create a new one. Navigate to:  Microsoft Visual Studio 2010>Visual Studio Tools>Visual Studio x64 Win64 Command Prompt (2010)  [if you aren't on an x64 box, pick another command prompt option that fits] Once the MS-Dos window displays, type in this statement: sn -k c:\SampleKey.snk Then copy the output *.snk file to project directory, or the *referenced directory. Remove the old reference to the *.snk file from the project. Add the paired key back to the project as an existing item. When you add back the *.snk file to the project, you will see that the *.snk file is no longer missing.   Our work is done!   *referenced directory: Pay attention to the original error message on compile. The *.snk file that is referenced may be in a directory path you aren't expecting--so you will still get the error unless you change the directory path or write the file to the directory the program is expecting to find the *.snk file.

    Read the article

  • Jornada de conocimiento CX. Una experiencia sin precedentes.

    - by Noelia Gomez
    v\:* {behavior:url(#default#VML);} o\:* {behavior:url(#default#VML);} w\:* {behavior:url(#default#VML);} .shape {behavior:url(#default#VML);} Más de 40 profesionales de Contact Centers de las empresas más notorias del país, se reunieron ayer en un entorno privilegiado como es la majestuosa Casa de Velázquez de Madrid. La jornada comenzó con la bienvenida de Fernando Rumbero, Director de Generación de Negocio de Aplicaciones en Oracle, que nos planteó la situación del mercado y nos puso en perspectiva de la visión del cliente. Después Ana del Amo , Gema Sebastian, ambas especialistas en soluciones CRM,y Albert Valls, especialista en aplicaciones en la nube, nos hablaron de los retos a los que se enfrentan los departamento de atención al cliente, nos dieron las claves de cómo abordarlos y aterrizaron los conceptos con casos reales. La nota de positivismo nos la dio la ponencia de Silvia García, Directora del Instituto de la Felicidad de Coca-Cola, hablándonos de la importancia de la felicidad y cómo llevarla a nuestro trabajo y transmitirla al cliente. La jornada finalizó con una mesa redonda donde todos los asistentes compartieron sus experiencias, inquietudes y necesidades para lograr el lazo perfecto en la relación con el cliente. El broche final fue marcado por la comida con el networking como telón de fondo y amenizado por un concierto de piano en directo. Esperando que lo hayan disfrutado, queríamos agradecer a los asistentes su participación y disposición, que fueron la clave para lograr un ambiente excepcional. Normal 0 21 false false false ES 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:0cm 5.4pt 0cm 5.4pt; mso-para-margin:0cm; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:"Times New Roman"; mso-fareast-theme-font:minor-fareast; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin; mso-bidi-font-family:"Times New Roman"; mso-bidi-theme-font:minor-bidi;}

    Read the article

  • Updates about Multidimensional vs Tabular #ssas #msbi

    - by Marco Russo (SQLBI)
    I recently read the blog post from James Serra Tabular model: Not ready for prime time? (read also the comments because there are discussions about a few points raised by James) and the following post from Christian Wade Multidimensional or Tabular. In the last 2 years I worked with many companies adopting Tabular in different scenarios and I agree with some of the points expressed by James in his post (especially about missing features in Tabular if compared to Multidimensional), but I strongly disagree in others. In general, Tabular is a good choice for a new project when: the development team does not have a good knowledge of Multidimensional and MDX (DAX is faster to learn, not so easy as it is sold by MS, but definitely easier than MDX) you don’t need calculations based on hierarchies (common in certain financial applications, but not so common as it could seem) there are important calculations based on distinct count measures there are complex calculations based on many-to-many relationships Until now, I never suggested to migrate an existing Multidimensional model to a Tabular one. There should be very important reasons for that, such as performance issues in distinct count and many-to-many relationships that cannot be easily solved by optimizing the Multidimensional model, but I still never encountered this scenario. I would say that in 80% of the new projects, you might use either Multidimensional or Tabular and the real difference is the time-to-market depending on the skills of the development team. So it’s not strange that who is used to Multidimensional is not moving to Tabular, not getting a particular benefit from the new model unless specific requirements exist. The recent DAXMD feature that allows using SharePoint Power View on Multidimensional is a really important one, even if I’d like having also Excel Power View enabled for this scenario (this should be just a question of time). Another scenario in which I’m seeing a growing adoption of Tabular is in companies that creates models for their product/service and do that by using XMLA or Tabular AMO 2012. I am used to call them ISVs, even if those providing services cannot be really defined in this way. These companies are facing the multitenancy challenge with Tabular and even if this is a niche market, I see some potential here, because adopting Tabular seems a much more natural choice than Multidimensional in those scenario where an analytical engine has to be embedded to deliver one of the features of a larger product/service delivered to customers. I’d like to see other feedbacks in the comments: tell your story of choosing between Tabular and Multidimensional in a BI project you started with SQL Server 2012, thanks!

    Read the article

  • Trying to style the first tbody different than others without introducing another class.

    - by mwiik
    I have a table with multiple tbody's, each of which has a classed row, and I want it so that the classed row in the first tbody has style differences, but am unable to get tbody:first-child to work in any browser. Perhaps I am missing something, or maybe there is a workaround. Ideally, I would like to provide the programmers with a single tbody section they can use as a template, but will otherwise have to add a class to the first tbody, making for an extra test in the programming. The html is straightforward: <tbody class="subGroup"> <tr class="subGroupHeader"> <th colspan="8">All Grades: Special Education</th> <td class="grid" colspan="2"><!-- contains AMO line --></td> <td><!-- right 100 --></td> </tr> <tr>...</tr> <!-- several more rows of data --> </tbody> There are several tbody's per table. I want to style the th and td's within tr.subGroupHeader in the very first tbody differently than the rest. Just to illustrate, I want to add a border-top to the tr.subGroupHeader cells. The tr.subGroupHeader will be styled with a border-top, such as: table.databargraph.continued tr.subGroupHeader th, table.databargraph.continued tr.subGroupHeader td { border-top: 6px solid red; } For the first tbody, I am trying: table.databargraph.continued tbody:first-child tr.subGroupHeader th { border-top: 6px solid blue ; } However, this doesn't seem to work in any browser (I've tested in Safari, Opera, Firefox, and PrinceXML, all on my Mac) Curiously, the usually excellent Xyle Scope tool indicates that the blue border should be taking precedence, though it obviously is not. See the screenshot at http://s3.amazonaws.com/ember/kUD8DHrz06xowTBK3qpB2biPJrLWTZCP_o.png This screenshot shows (top left) the American Indian th is selected, and (bottom right), shows (via black instead of gray text for the css declaration), that, indeed, the blue border should be given precedence. Yet the border is red. I may be missing something fundamental, like pseudo-classes not working for tbodys at all... This really only needs to work in PrinceXML, and maybe Safari so I can see what I'm doing with webkit-based css tools. Note I did try a selector like tr.subGroupHeader:first-child, but such tr's apparently consider the tbody the parent (as I would suspect), thus made every border blue. Thanks...

    Read the article

< Previous Page | 1 2