transform

flattening XML to load via SSIS package

扶醉桌前 提交于 2019-12-11 04:39:26
问题 I have an XML output from Lotus Notes DB. Following is the XML structure: <Exec> <project id='C000253' type='Approved' > <DaysInOnHold>39</DaysInOnHold> <DaysInCompleted>0</DaysInCompleted> <ProjectComplexity type='1280'>Complex</ProjectComplexity> <ChangeRequest> <OnGoingAmt type='768'>-112</OnGoingAmt> <EAmt type='768'>123</EAmt> </ChangeRequest> <ChangeRequest> <ItemNbr type='768'>2</ItemNbr> <EAmt type='768'>321</EAmt> </ChangeRequest> <IncidentalItem> <ACost type='768'>0</ACost>

Creating an ETL system (Data import and transformation)

北慕城南 提交于 2019-12-11 04:24:39
问题 I have been tasked to write a module for importing data into a client's system. I thought to break the process into 4 parts: 1. Connect to the data source (SQL, Excel, Access, CSV, ActiveDirectory, Sharepoint and Oracle) - DONE 2. Get the available tables/data groups from the source - DONE i. Get the available fields form the selected table/data group - DONE ii. Get all data from the selected fields - DONE 3. Transform data to the user's requirements 4. Write the transformed data the the

Css transition animation not working with .appendChild

徘徊边缘 提交于 2019-12-11 03:14:25
问题 I'm making a game with javascript and css and so on. Animation of character is slow in some mobile browsers. Now it is working with a callback. User request tile, server looks if tile is free, server send packet to move avatar. so user is going to walk to that tile, server sends tile where to go . var movecallback = avatars.moved(id); movelayer('ava_'+id, ava_x, ava_y, 25, 20, 1, movecallback); before something was done with movecallback function but I remove that and make use CSS3 transform

transform-origin doesnt apply in safari

陌路散爱 提交于 2019-12-11 02:44:56
问题 Why doesn't transform-origin doesn't work in Safari? Here, how it should look (Chrome): http://i.imgur.com/f3zBu8e.png Here, how it looks in Safari: http://i.imgur.com/0XrPYXs.png I already tried some stuff with percents but it my content divs are having different sizes, so it looks awkward. Here's the JSFiddle. http://jsfiddle.net/2f4pferq/ text-align: right; -ms-transform: rotate(-90deg); -ms-transform-origin: right top; -webkit-transform: rotate(-90deg); -webkit-transform-origin: right top

Make a SVG transform matrix rotate around its center

匆匆过客 提交于 2019-12-11 02:41:20
问题 HTML <rect id="red" style="fill: red;" height="100" width="20"></rect> JS var layer = { sizeReal : { "width": 20, "height": 100 } , sizeScaled : { "width": 10, "height": 50 } , position : { "x": 200, "y": 200 } , scale : 0.5 , rotation : 0 , matrix : [ 1, 0, 0, 1, 0, 0 ] }; // Not sure if its the cleanest way but it works it rotates itself arounds its center. // $("#red")[0].setAttribute( 'transform', 'translate(' + layer.position.x + ',' + layer.position.y +') rotate(' + layer.rotation +','

convert List[Tuple2[A,B]] to Tuple2[Seq[A],Seq[B]]

时光总嘲笑我的痴心妄想 提交于 2019-12-11 01:40:59
问题 Stuck here, trying to convert a List of case class tuples to a tuple of sequences and multi-assign the result. val items = repo.foo.list // gives me a List[(A,B)] I can pull off multi-assignment like so: val(a,b) = (items.map(_._1).toSeq, items.map(_._2).toSeq) but it would be nicer to do in 1 step, along the lines of: val(a,b) = repo.foo.list.map{case(a,b) => (a,b)} 回答1: I am not sure if I understood the question correctly. Maybe unzip works for what you want? Here is a link with some

LINQ: how to transform list by performing calculations on every element

孤街浪徒 提交于 2019-12-11 01:19:27
问题 I have a class Class MyObject { decimal v1; decimal dv1; decimal v2; decimal dv2; } and a List<MyObject> ... I need to process every element of the list by adding dv1 to v1 and dv2 to v2 Something like (pseudo-syntax): myList.Transform(o=>o.v1+=o.dv1, o.v2+=o.dv2) How can I do this (obvious my pseudo-syntax doesn't works)? Thank you 回答1: You can use the List's ForEach method: List<MyObject> objects = new List<MyObject>(); // Populate list. objects.ForEach(obj => { obj.v1 += obj.dv1; obj.v2 +=

make visual clone of displayObject that's nested within other displayObjects, and add the clone to the stage layer in the same location, rotation, etc

生来就可爱ヽ(ⅴ<●) 提交于 2019-12-10 23:57:57
问题 I want to be able to grab a copy of a DisplayObject that is nested within other transformed DisplayObjects (rotated, scaled, stretched objects), and be able to stamp it back into the same visual location, but on the stage layer. Essentially, being able to make a clone of a nested DisplayObject, but be able to add the clone to the stage layer, yet have it perfectly align (visually) with the original (same position, scale, rotation) I have been working with something along the lines of: // draw

Device orientation sensor to CSS transform

折月煮酒 提交于 2019-12-10 22:41:45
问题 I've created the following widget (see demo here) to mimic the sensors tab on the chrome developer tab: My code listens to the orientation event of the device and tries to convert the values to fit the css transform scale, like so: let phone = document.querySelector(".phone"); window.addEventListener('deviceorientation', (event) => { phone.style.transform = "rotateY(" + ( event.alpha) + "deg) " + "rotateX(" + (90 - event.beta) + "deg) " + "rotateZ(" + (event.gamma ) + "deg)"; }) However, if I

std::transform for a vector of vectors

半城伤御伤魂 提交于 2019-12-10 20:55:13
问题 I have numerical data in a vector< vector < double> > and need to add scalar values to them as follows: vector <vector<double> > data ( M, vector<double>(N) ); vector <double>scalars(N); data[0][0] += scalars[0]; data[0][1] += scalars[1]; ... data[0][N-1] += scalars[N-1]; data[1][0] += scalars[0]; data[1][1] += scalars[1]; ... data[1][N-1] += scalars[N-1]; ... data[M-1][N-1] += scalars[N-1]; Of course this is possible with two for loops. I was wondering if it can be done as simply with