Posts

Showing posts from September, 2015

c# - Microsoft word document to OLE field -

Image
I am trying to upload the docx document to access the database. OleDbConnection conn = null; OleDbDataReader Reader = Faucet; Try {Conn = new OleDbConnection ("Provider = Microsoft.ACE.OLEDB.12.0;" + "Data Source =" + "" @: "C: \ Audios \ Auditor_Artificci 20077.ACADB"); Conn.Open (); Olebey Commands CMD = New Oleadby Commands (); Cmd.CommandText = "Questions (Category, Question, Answer, Correct Answer, Comment, Reference, Question No, Change, Issue) Prices (@ P2, @ P3, @ P4, @ P5, @ P6, @ P7, P in P8, @ P9, @ P10) "; Byte [] file = file. Read AllBytes (@ "C: \ AudSystem \ rez.docx"); Cmd.Parameters.AddWithValue ("@ P2", 2); Cmd.Parameters.AddWithValue ("@ P3", file); Cmd.Parameters.AddWithValue ("@ P4", file); Cmd.Parameters.AddWithValue ("@ P5", "AD"); Cmd.Parameters.AddWithValue ("@ P6", "FH"); Cmd.Parameters.AddWithValue ("@ p7", "z

php - Wrap array around SimpleXML object -

I get XML results from a web service, which I read as simple XML elements. Now there is a situation that results can vary depending on the configuration given by the web service. The issue is: I want to wrap an array around ordinary XML objects in "position 2", so I do not later "simplify XXXXXXconfig inside the array" and "Surfag" while processing the data. Configure the form as "the difference between the object. I have been looking for a while for a while and thinking, but by now I could not find anything. Situation 1: Many simple xx elements are returned within an array ["myConfig"] = & gt; Array (2) {[0] = & gt; Object (simple assemment) # 41 (5) {["id"] = & gt; String (1) "1" ["type"] = & gt; String (1) "4" ["Comment"] = & gt; String (2) "Fobor" ["name"] = & gt; String (1) "Exam" ["attribute"] = & gt; String (5

reporting services - Need To Calculate Percentage Difference In ssrs with multiple row and column Grouping -

I have a line and column grouping. I need the difference and percentage difference of each month as shown below. <: Example: march diff 2013 2014 Hyderabad 12 15 15-12 = 3 I want more than this result, I need percentage difference ---- (this year - last year) / last year I usually try to handle it in SQL and dumb report. In your case, I look at the result like this: City month month month year Dravid year's feed --------- ---- --- --- ---------------------- Hyderabad 3 March 2013 2013 12 Hyderabad 3 March 2014 2014 15 Hyderabad 3 March 99 99 Diff 3 Hyderabad 3 March 99 99% Diff 0.25 Your Row group will be the city. Your column group 1 group / sorting will be on the monthly integer, and the month displays the string. Your column group will group / sort 2 years / fid integer, and the eardid string will display. If you provide your SQL, then I can help the result look like this. If you insist on computing on this report and you have a city, date and val

uislider - In a MATLAB GUI, how does one implement a continuously varying slider from a GUIDE created .m file? -

I am trying to create a GUI with a plot and a slider. The slider should be described as continuously and output. I have a problem with this explanation that the uicontrol object is programmatically created, on the contrary, I want to know that in the last three instances, to complete the same thing done according to the program What can be added to a GUI file that is created. The code is down, and I have marked the (wrong) code that is provided by some of the above examples. Thanks a lot for any help! This slider function sets P1_slider_Callback (hObject, eventdata, handle) (handle, dragon, 'string', num2str (get (hObject, 'value'), 3)) PlottheData_Callback ( HOBject, EventData, Handle)% "PlotHeadata" is a button that creates the data slider based on the value of P1_slider%, and I think that here "p1_slider_CreateFcn" (hObject, eventdata, handle) needs to be assembled (HOBJECT, 'BackgroundRoller'), (0, 'Default UITTACKBACK MANDROLLE

jQuery Dialog Chrome issue -

I am using a jQuery dialog box. I'm facing a problem in Chrome browser $ ("# dialog"). App ('& lt; p class = "elms"> This step 1 & # 39; & # 39;); I have written the JS code in I where I am adding new material to the dialog box that was opened. But I have an AJAX request after the ADX statement. jQuery.ajax ({type: "post", datatype: "Jason", .... What is this on Chrome that the dialog The box does not say "this step 1 message." But it only displays the end result by jquery.ajax. "This is step 1 message" in the Firefox browser. After this the result has been returned with the jquery.ajax call. How do I fix this problem? Remember .dialog (); $ ("# dialog"). Attachments ('& lt; p class = "elm" & Gt; this step 1 & lt; / p & gt; '); $ ("# dialog"). Dialog (); If it does not work for you, Try: $ ("# dialog"). E

How to run SQL(MYSQL) stored procedure in JAVA jdbc? -

I am a MySQL user and I am using the following statement in the MySQL workspace: (Based on these statements) / P> SET group_concat_max_len = 4294967295; SELECT GROUP_CONCAT ('SELECT', QUOTE (COLUMN_NAME), 'FROM (choose * from table_name * s3_01 =', coloumn1, '' 'abc', 'WHERE', REPLACE (COLUMN_NAME, '`', '` `') Not Faucet, 'Hosting COUNT (*)' SEPARATOR Union All ') Information from INTO @sql_SCAMA Columns where TabCHAMA = Database () and Tableinda = 'Table_Name'; Prepare SSML with SSMT; EXTUTE STMT; DEALLOCATE STMT; Although it works in my workspace, I do not know how it works in Java. For example, I created the following code: string sql1 = "SET group_concat_max_len = 4294967295;"; String sql2 = "SELECT GROUP_CONCAT ('SELECT', QUOTE (COLUMN_NAME), 'FROM (select * from PTC_weight) where S3_01 =', column 1, '' ABC '', 'WHERE', repeat (COLUMN_NA

c# - Polling the right way? -

I'm software / hardware engineer with some experience in C and embedded technologies, and currently I'm doing something in C # (.NET) I'm busy writing apps which are using hardware for data acquisition. Now the following, burning for me, question: For example: I have a machine in which there is one end to find the last place of a pivot. Now I am using the USB Data Acquisition module to read data. Currently I am using a thread to read port-states continuously. There is no interruption on this device. My question: Is this the right way? Should I Use Timers, Threads or Tasks? I know that there is something in the poll that most of you "hate", but any suggestions are welcome! IMO It depends very heavily on your exact environment, but before that: in most cases you have threads Should not be used Low voting interval: Timer and voting in tick . Work Medium: Waiting for Tasks and Tasks Delay (delay) High: Using tasks and threads. Sleep (delay)

javascript - Testing selector presence in Jasmine -

Do anyone know how I can test it in Jasmine? function gameWon) {$ ('#final_message_cpu'). Html ('you von !!!') $ ('. Computer_selection'). CSS ('display', 'block'); Deleting $ ('# Show_after_starting'). $ ('# Hide_after_starting') CSS ('display', 'inline') $ ('# hide_after_starting'). Click (function () {location.reload ();}}} What is the only way I can test to see if $ ('# show_after_starting') is deleted has given? Yes: expected ($ ('# show_after_starting') Length). TBE (0);

sql - Speed up very slow query -

I am trying to delete the old records from the old SQLite3 database to 30,000 old records. I'm using this question to remove: remove items from items ITEMS_ID IN (SELECT ITEMS_ID) with objects where the last time is not like '2014%' And do not like '2013%' and finally '2012%' and ITEMS_ID! = 1 and ITEMS_ID! = 4); The problem is that I have seen that this query is very slow or better, it is so slow that it takes ages and I have to stop it because it seems stuck. I think the problem is that IN () within SELECT statement is being repeated for each row repeated < P> How can I fix this query? Before heavy deletion, make sure there are no triggers behind the curtains, which are < Code> delete statement can be quite slow. I do not think it is possible to temporarily disable triggers in SQLite because it is in other DBMSs. Therefore, you have to do this: Delete Trigger Script Drop Dump Triggers Run Delete Question Rebuild the t

javascript - Laravel PHP Jquery - TextBox updating Label -

मेरे पास यह टेक्स्टबॉक्स है {{form :: text ('horasT', $ HorasT, array ('class' = & gt; 'इनपुट-ब्लॉक-स्तरीय', 'प्लेसहोल्डर' = & gt; '0.00'))}} मैं एक लेबल को अपडेट करना चाहता हूं जब टेक्स्ट बॉक्स वैल्यू परिवर्तन। यह लेबल है: & lt; लेबल आईडी = "उप-कुल" नाम = "उप-कुल" & gt; 0 & lt; / label & gt; मेरी जेक्जरी यह है: jQuery ('# horasT')। पर ('इनपुट', फ़ंक्शन () {var valT = $ (' #horasT ')। Val (); $ (' # subTotal ')। Value = valT;}); यह काम करने के लिए प्रतीत नहीं होता है और मैंने अब तक कई चीजों की कोशिश की है। लेकिन मेरे लिए यह काम करना चाहिए ... क्या लगता है समस्या? लेबल केवल 0 में बैठता है कोई भी बात नहीं है जो टेक्स्ट बॉक्स में है इवेंट है और लेबल में पाठ नहीं है संभावित अन्य ईवेंट को ट्रिगर करने के लिए: "इनपुट परिवर्तन कीप कीप कट पेस्ट माउसउप फोकस ब्लर" & lt; script src =" https : //ajax.googleapis.com/ajax/lib

php - how could we find the page URLs which is not linked to any menu in drupal 6? -

How can we find page URLs that are not associated with any menu item or are stand-alone pages in Drupal 6? The suggestion of any question is also correct ... Something like this: Select 'menu_links' from the select * menu, where select 'menu_links', select menu_name = 'navigation' link_path)

Converting wgs84 POINT into Coordinate LON, LAT -

मेरे पास wgs84 बिंदु की यह परिभाषा है: enforce_geotype_coordinate_wgs ((ज्यामितीय टाइप (coordinate_wgs84) = 'POINT' :: पाठ) enforce_dims_coordinate_wgs84 (st_ndims (coordinate_wgs84) = 3) enforce_srid_coordinate_wgs84 (srid (coordinate_wgs84) = (-1)) " ऐसा लगता है: " 0101000000315601E572722F40842D615AA089444 " / P> मुझे पोस्टजीआईएस के कार्य को नहीं पता है जो इस बिंदु को जीडी (अक्षांश, रेखांश) [जीपीएस] समन्वय में बदल देता है। क्या आप मेरी मदद कर सकते हैं। धन्यवाद सरल उपयोग: ST_X ("coordinate_wgs84") एक्स के रूप में, ST_Y ("coordinate_wgs84") वाई के रूप में।

jquery - The right way to include page specific Javascript in Rails -

I want to include it, for example: jQuery. Ready (function ($) {$ ('# my-modal'). Modal (option)}); In my case in a specific place in a Rail App file / model / mymodal.html. Called ARB. There and only there. I do not understand that if I put it in the property then why not do it with all the pages, thanks so much! These are some useful moves # 1 file js Remove // require_tree. application.js at your.js for code-per compound add code on Config / application.rb >: config.assets.precompile + =% w (your.js) # 2 inserted non-layout in specific file (not recommended) mymodal.html. ARB Put your JS script with javascript tag on # 3 .. this .. Change your code to layout / yourlayout.html. Enter in ARB and use if ..and .. argument example: & if; Current_page? (Yourspecific_path)%> & Lt; Script language = "text / javascript" & gt; Your javascript is here .. & lt; / Script & gt; & Lt;% en

python multiprocessing with map_sync - catching problems -

I am trying to use a multiprocessing package in Python. I have a code that is designed to generate output based on the collection processes that have many processors ... years = [2013] days = [1,2,3,4,5,6,7,8,9, 10] months = [8] hours = [0, 6, 12, 18] ens = [1, 2, 3, 4] nuns = Lane (days) * lane (hours) hours = hours * lane (days) year = days * days (days) * lane (hours) month = months * lane (days) * lane (hours) temporarily = [days] D: temp.append ([d] * lane (hour)) = [x in the sublist for x in the sublist for hours] hour = hour * lane (d N) nens = ens * len (day) In this example I have 260 times that are near different processors. t1 = c [:]. Map_sync (doCoolStuff, year, month, day, hour, nanus, [option] * lane (day)) There are times when there is a missing / incomplete data When this happens, then kills all the processes on other nodes. Is there any way to catch these examples? I'm not sure / works here except for try. Thanks I can think of two options

python - create heatmap2d from txt file -

Image
I have set 2D data (30a) as a set txt file. XY 2.50 135.89 2.50 140.92 2.50 157.53 2.50 114.61 2.50 119.53 2.50 154.14 2.50 136.48 2.51 176.85 2.51 147.19 2.51 115.59 2.51 144.57 2.51 148.34 2.51 136.73 2.51 118.89 2.51 145.73 2.51 131.43 2.51 118.17 2.51 149.68 2.51 132.33 < / Code> I plotted with Gnuplot as a scatter plot but I would like to represent a heatmap as a 2D or density distribution. I saw examples in MatPlotLib or R and they have already started with random data to generate all the images. I tried those codes and got an error like this hist, edges = histogad ([x, y], cans, range, honorary, weight) Attribute: Error: The compartment's dimensions should be equal to the dimensions of the sample x. Script ending Is there any way to open the TSTT file and plot this data in gnuplot, the matplob my scatter plot looks like this I want to show this image Map of contour map or density with color code bar My X-X 2.5- At a distance of 3.5 and at the dist

Magento - Which "Shopping Basket Price Rules" have been applied to the cart? -

I would like to exclude a list of "shopping basket price rules" that have been applied in the current basket. I can not find the code for this! Can you help I can take out the name of the discount voucher in this way: Gungo echo :: MillModel ('Sales / Rules') - & gt; Load ($ -> this (& quot; getQuote () -> getCouponCode (), 'code') -> GetRuleId ()) - & amp; Gt; getName (); But I have been stuck on any of the automatic discounted basketball discounts. I do not know how to see them. I mage :: getSingleton ('checkout / Session ') - Try getVote () -> GetTotals () , but Magento should run out of memory because I only get a white screen. < / P> copy $ $ $ $ $ this- & gt; render total ($ total ['discount']); This row can be displayed in either self , Or its data may be removed.

javascript - Dropdown to modify textbox value with knockout -

निम्न HTML / जावास्क्रिप्ट एक ड्रॉपडाउन मेनू बनाने का मेरा प्रयास पाठ बॉक्सेज़ में दो मानों को संशोधित करता है। & lt; प्रकार चुनें = "दिनांक" डेटा-बाइंड = "विकल्प: डेटारंग, विकल्प टेक्स्ट: 'श्रेणीनाम', विकल्पपरिवर्तन: 'चुनें'" & gt; & LT; gt चयन और; & Lt; br & gt; & Lt; इनपुट प्रकार = "तिथि" डेटा-बाइंड = "मान: श्रेणी स्टार्टवैल, वैल्यूअपडेट: 'बाद में डाउन'" / & gt; & Lt; br / & gt; & Lt; इनपुट प्रकार = "तिथि" डेटा-बाइंड = "मान: श्रेणीःस्टॉपवाल, वैल्यूअपडेट: 'बाद में डाउन'" / & gt; & Lt; स्क्रिप्ट प्रकार = "टेक्स्ट / जावास्क्रिप्ट" & gt; Var रेंजवैल्यू = फ़ंक्शन (नाम, स्टार्टवैल, स्टॉपवैल) {this.rangeName = name; This.rangeStartVal = startVal; This.rangeStopVal = stopVal; वापसी }; Var viewModel = {dateranges: ko.observableArray ([नया रेंजवैल्यू ("आज", "2014-04-28", "2014-04-28"), नया रेंजवाले (&

Complete overwrite of current version of android app with update -

I'm just thinking that this is a way to set up via the manifest or elsewhere when users update your app Does it completely overwrite the current version on the device? I know that when the user updates, data etc. from the old version is updated. I'm looking to set it up like this that every time the user updates the app from the Play Store So if anyone has any idea or how to do it, then how will I hear or hear them. Gary Google Play manages the version number from your manifest. So the update for your app will be completed when your version number changes. If you want to blow up your data after the update, then I recommend that you keep the version number as part of your saved data. Then, when it is updated, it can see that the version number is different and the data needs to be reset.

view all customizations in MS Dynamic CRM 2011 -

We had optimized a solution for our dynamic CRM 2011, but that person has left the project Know what adaptations were done and were published when I went to the "Customize Systems" section, it shows all the components, I should know what customization has been done and it has been published. New to me, so please Please be gentle: 0) Thank you! I'm afraid that it would be really complicated but since CRM 2011, the available metadata changes message Try to -

SQL Query to get results that match between three tables, or a single result for no match -

Is there a way where the clause is to check that there are zero matches between the tables for the first table, And displays a line or results? I am trying to get results which looks like this: + ---------- + --- ----- - + ----------- + ---------- + ------------- + | Results | + ---------- + ---------- + ----------- + ---------- + ---- --------- + | Date | Qatar ID | By date To date | Campaign ID. | 3/1/2014 | 1 | 2/24/2014 | 3/2/2014 | 1 | | 3/1/2014 | 2 | (NULL) | (NULL) | (NULL) | + ---------- + ---------- + ----------- + ---------- + ---- --------- + Combining tables that look like this: + ---------- + ---- --- + ------- + ---- + ---- + ----------- + ----------- + - - ------- + | Table 1 | | Table 2. | Table 3. + ---------- + ------- + + ------- + ---- + + ---- + ---------- - + ----------- + ---------- + | Date | Qatar | | Qatar | SP | SP By date To date | Campaign | | | ID | | ID | ID | | ID | | | ID | + ---------- + ------- + + ------- + ---- + + ---- + ---------- - +

android - adding a project from GitHub -

I am trying to add this project to my project. I tried to add it to my workspace as a lib project, but eclipse did not allow me to add a folder to my workspace. You need to know, that with the Gradle build tool Android How to make application For some essential requirements such as Apache Ent and Gradle here is a good tutorial - Before importing the library If you complete an example using Gradeley, you will surely know how to do it.

sql - Is it semantically correct to use a foreign key to indicate a range? -

I am trying to create a SQL table to represent a series of codes used by a third-party API I am So far, I have the following applause: create table api code (id it is not tap identity (1, 1) primary key, respccode code char (1) tap, respansubcod char (1) No NULL, ResponseSubSubCode char (1) NULL, MinorCodeRangeId Intel Zero References ApiMinorCodeRange, Description nvarchar (500)) Make Table ApiMinorCodeRange (id it not zero identity (1, 1) primary key, four from MainCode (4) No, Thermincorecode (4 ) No Taps) Table APIIM code (code four (4) tap primary key, detail Encryption (500)) Create The problem is, FromMinorCode and Thermyncore code can reference code that does not exist . For example: A category can indicate "5000 - 5ZZZ", but entries can only enter "code 5000 - 500A" in minor code new codes are added every few months Therefore, the ApiMinorCodeRange table requires reference to the full range defined in the specs. I was planning to create

c# - Highlight all words containing a letter in a richtextbox -

How do I highlight all the words in a letter in a rich text box? If I want to expose the words that contain the letters "a", such as a hat or candle word, both words are highlighted, I am using C # on Winform. Private Zero Button 208_Click (Object Sender, EventArgs E) {HighlightFrage (Rich Textbox 1, "A", Color. Yellow); } It exposes all the words with a word "a", but I'm not sure how to highlight the length of the spaces. Thank you. You can use the method to find incidents of sub-location. Then, use the property to change the colors back to Highlight colors for each event. int len ​​= richTextBox.TextLength; Int index = 0; String textconfind = "A"; // This will highlight the text you are viewing (index & lt; len) {richTextBox.Find (textToFind, index, len, RichTextBoxFinds.None); RichTextBox.SelectionBackColor = Color.Yellow; Index = rich textbox. Lesson Index (texttofind, index) + textaophind Langeline; } If you want

java - SPARQL query against Portuguese dbpedia endpoint for dcterms:subject returns no results -

मैंने उस क्वेरी का परीक्षण किया: SELECT? Comment WHERE {& lt; http: // pt.dbpedia.org/resource/Portugal> Dcterms: topic? Comment} पर और मुझे सही परिणाम मिलता है: http://pt.dbpedia.org/resource/Categoria:Portugal लेकिन मैं जेना का उपयोग कर रहा हूं और जब मैं जेना के साथ ऐसा प्रश्न करने की कोशिश करता हूं तो मुझे कोई परिणाम नहीं मिलता। यही तरीका है कि मैं जेना के साथ क्वेरी कर रहा हूं: निजी स्ट्रिंग पाने का विवरण (स्ट्रिंग uri) {RDFNode नोड; स्ट्रिंग टिप्पणी = ""; अंतिम स्ट्रिंग QUERY = "PREFIX rdf: & lt; http: //www.w3.org/1999/02/22-rdf-syntax-ns#> \ n" + "PREFIX dcterms: & lt; http: // purl Org / dc / terms / subject & gt; \ n "+" चुनें? टिप्पणी कहाँ {"+" & lt; " + यूरी + "& gt; dcterms: subject? टिप्पणी।" + "}"; अंतिम स्ट्रिंग ENDPOINT = "http://pt.dbpedia.org/sparql"; अंतिम परिणामसेट आरएस = क्वेरीएक्ज़ेक्यूशनफैरेंटीसीपीआरसीएल सेवा (एंडपोइन, QUERY) .execSelec

Grails' Config.groovy in plugins and dependent apps -

I will use a Grails plugin and the plugin which am I building several Grails apps. I want to define some properties and give them default in the plugin, but let the app optionally override your values ​​(optional). This question is surrounded by mechanical details in how to wire both the plugin and the child app. Say I want to define the following properties for the following plugin ( grails-myplugin ) of its Config.groovy : myplugin {fizz {whistles = true // default = 3 / this plugin} for all child apps using this plugin buzz}} grails.plugins.anotherPlugin.widget = 'auto' grails.plugins.anotherPlugin .foo = '$ {myplugin.fizz.buzz} -40' // So, by default, '3-40' is Now, I want a baby Grails app, say , To override myapp.war (which uses grails-myplugin ) 2 FASA properties: // myapp's Config.groovy: myplugin {fizz {// whistles property is not defined here, so uses this app // Override the plugin's default "true" // 3 plugin

ios - Roximity iBeacon gives error "ERROR: Failed to begin ranging beacons" -

We purchased some iBeacon devices from Roximity and write them a sample app now to set up and receive notifications sent to it. Are trying. We used to also use sample applications on Github for testing. When we run the app, we can all see the following log messages and nothing else. 2014-04-28 08: 49: 15.817 Roximity MyAEP [5172: 60b] Roximity SDK Version: 1.1.51 2014-04-28 08: 49: 16.726 AroximityMap App [5172: 60b] Error: Failed to initialize beacon 2014-04-28 08:49: 16.814 RoximityMaypace [5172: 60B] Error: Beacon failed to initialize 2014-04-28 08:49 49: 16.827 RoximityMyApp [5172: 60b] Error: Failed to start with beacon 2014-04-28 08: 49: 16.830 Reximitimap app [5172: 60B] Error: Beacon failed to start with Let me answer your question I'm going to give it a bit, so it seems that there is an issue to use in the device. Before I was using the iPhone 4 but with it being supported on the iPhone 4S and above versions. Also, there was a problem in my Bluetooth antenna, w

android - how to add several images in a listview after getting their names from the sqlite database -

I have an Android application that uses esclaims and after receiving the data, it should appear in a list view . My question is how to display images? Can anyone help me ??? This is my code // But here is this hall listing to display the same image to display each image in its true place? For (int i = 0; i <49; i ++) {ImageView imagenow = (ImageView) Convertview. FindViewById (R.id.imageView1); // flag1 int imageid = context.getResources (). GetIdentifier ("Brazil_flag", "Drawable", context.getPackageName ()); Imagenow.setImageResource (imageid); Will help to think in terms of MVC < Li> Create a layout with the list that contains images in each element Create an adapter to read images from the database In the activity, use the adapter to fill the images in the list. For

java - Adding A An ArrayList, that is stored in a SQL database, to a table in jForm -

My problem is currently that I am unable to get my room list for my hotel management GUI, my jTable. My current code for this is: Roommaker: Public AERLIT < Cell & gt; GetRooms (Connection Con) {ArrayList & lt; Cell & gt; Room = new ArrayList (); String sqlString1 = "select from room" + "order by room_ID"; String sqlString2 = "SELECT TABLE_NAME" from USER_TABLES; Statement made statement; Try {statement = con.prepareStatement (sqlString1); Results reset rs = statement.executeQuery (); Int i = 0; While (rsnext ()) {i ++; Println (rs.getString (1)); System.out.println ("Just Add Room NB" + i); Rooms.add (new room (rs.getInt (1), rs.getInt (2), 0, "string string"); } Statement.close (); } Hold (exception e) {System.out.println ("Access failed - RoomRooms"); Println (e.getMessage ()); } System.out.println ("Room Surfing Size:" + rooms.size ()); Return room; } cell class: public class room

date parameter similar to access in SQL Server -

I am working on a query that we are expanding into MS Access with another simple query. REQUIREMENTS_DATE & lt; Now () - ([M: 56 T: 57 W: 58 Th: 59 F: 60]) Where I have the REQUIREMENTS_DATE & lt; Gateet (60) access query below allows the person to enter the report to enter the number of days given on that day of the week, but as of now, let me manually The code has to be changed which is not a big deal for me, but I can export a user like Excel and execute a user with some SQL knowledge. Is there something in SQL Server that is in the function used in access, so that my user can enter the value and has been reported for that date: SELECT P.PLANT_CODE, P.STOCK_CATEGORY, P.MATERIAL, P.DISTRIBUTION_VERSION_CODE, P.PERIOD_CODE, p. REQUIREMENTS_DATE, p. PPLANNED_QTY AS 'REM Plan QT', p. VERSION_IND_FLAG, P.S.I.S..S..S.JLLLL, p. Withdrawal_Centity, P.technical_index, pplnadit + p. Withdrawal_quentity AS 'Original FCST Volume' in PW ('6040', '60

mysql - SQL statement in php will not insert onto database -

Image
I have this SQL statement that I am trying to save the new students on the students' desk, although this only However, I do not receive an error message when I do not have an error reporting and I ran the query in sqlbuddy with values ​​and it worked fine Post prices come from the form that is directed to this page I only worked on the issue which was me and I am sorry that it was a stupid, I was not updating my counter, so every time I tried to add a new student, he The same student will try with ID, and thus fail, a simple fix

MongoDB: connecting with ASP.NET MVC application -

I have created an asp.net mvc5 application, and I'm hosting it on IIS 7. Now I would like to start using this MongoDB database with this application. I have been able to run a Mongodabi Windows service, but now what I am doing in the next step. Like: i) How do I specify in my ASP? Net MVC application that is the name of the database, and where is that directory stored? ii) How do I create this database in mangodibi? My web In the configured file, I have the following lines: & lt; Connection best & gt; & Lt; Add name = "Mongo" connection String = "mongodb: // localhost" /> & Lt; / ConnectionStrings & gt; and: & Lt; Add Key = "MONGOHQ_URL" value = "mongodb: // localhost" /> & Lt; / AppSettings & gt; How do I go about creating a database called mydb , as if it is running in the Mongo DB Windows Service? i) How do I specify in my ASP.NET MVC application, the name of the databas

sql server 2008 - Interesting SQL query issue -

I have such a table (yes the structure is useless, can not change it): ID | Line | Position | Timestamp | Association 1 | A. Close 10:30 am F2da3 2 | A. AK | 10:15 am | F2da3 3 | A. Open | At 10:00 am F2D3 4 | A. Close At 9:10 | J7S9D5 | A. AK | 08:45 p.m. | J7S9D6 | A. Open | At 08:00 am I need a SQL query which will give me the time (in minutes) between 'open' and 'time off' I copy per association. Then the output table will look like this: association | OpenTalkLos time F2D3 | 30J7S9D | 70 Looks like SQL queries? I am far away from my element and appreciate any help! Is it looking for you? This work will provide association, the situation is unique. (Select from * from table * where position = 'Open') A AOCASEAD ======================= < Select a AOCISSIDIDID, DATEDIFF (MIN, A. Timestamp, B. Timestamp) from BASSACIDID

ios - EAAccessoryDidConnectNotification not firing until Bluetooth Accessory Picker completion block is called -

itemprop = "text"> I recently started using EAAccessoryManager showBluetoothAccessoryPickerWithNameFilter method in order Giving us access to our MFI Bluetooth Accessories (if it is not already connected) When our app launches I am running in the following scenario: The episode is off User launches app Accessory picker is displayed User on an assistant Powers (which have already been made, and thusly reconnect) The secondary picker continues to display, and the application does not receive a EAAccessoryDidConnectNotification The user dismisses the helper picker by pressing "Cancel". In this situation I have explained above, even if we have our NSPredicate hanging around the picker and we have not received any information that till the helper The block that is connected is called the secondary. User is locked in captivity. We are running iOS 7.1.1 and have tested against 7.1 and 7.0. Any help would be appreciated. I'm looking at

How to convert a CIDR prefix to a dotted-quad netmask in Python? -

How can I convert a CIDR prefix into a dotted-quad netmask into a dragon? For example, if the prefix 12 needs me to return 255.240.0.0 . You can do it like this: def cidr (Prefix): Return socket.inet_ntoa (struct.pack ("& gt; I", (0xffffffff & lt; (32 - prefix)) & amp; 0xffffffff)

javascript - How best should I keep track of a timer between page requests? -

I am writing a web app in PHP that takes fake exams to users (multiple choice questions). Examinations take place from time to time, for example, for 30 minutes, I am not sure how long the user has left to complete his exam, what is the best way to keep track of it? Each question is drawn from a MySQL database and the user is served as a new page. Should I start a timer on the first page with javascript (like setInterval) and whenever any question has been submitted before retrieving the next page? Is there any more elegant or efficient way to do this? Create a table that stores the user in the examination Association and when the test is no longer valid there At one time it will be allowed to inquire and find out what the time is left to the students, as well as people will not be allowed to lock in the examination if this is not allowed.

How to split 16-bit unsigned integer into array of bytes in python? -

I need to divide a 16-bit signed integer into an array of bytes (i.e. array.array ('B') ) in Python For example: & gt; & Gt; & Gt; Reg_val = 0xABCD [Insert Python Magic]> gt; & Gt; & Gt; Print ("0x% X"% myarray [0]) 0xCD & gt; & Gt; & Gt; Print ("0x% X"% myarray [1]) 0xAB The way I am currently doing it is very easy, so some are very easy: & gt; & Gt; & Gt; Import structure & gt; & Gt; & Gt; Import array & gt; & Gt; & Gt; Reg_val = 0xABCD> & Gt; & Gt; Reg_val_msb, reg_val_lsb = struct.unpack ("& lt; BB", struct.pack ("& lt; H", (0xFFFF and reg_val))) & Gt; & Gt; Myarray = array.array ('B')> gt; & Gt; & Gt; Myarray.append (reg_val_msb) & gt; & Gt; & Gt; Myarray.append (reg_val_lsb) Is there a better / more efficient / more python way to accomplish the same thing? (using Python 3 here, ther

php - header() download corrupted file -

Why this code does not work, the URL is a sound file: header ( "Location: http://biencaleta.com/musica/Billboard-70s/Grupos/Billboard%201970.ca/Simon Y Garfunkel - Bridge Over Troubled. MSA"); Browser (Chrome) Play it instead of downloading it, but this http://23.250.9.10/~caletaco/Alkilados-mona Lisa. Works with MSA I also tried with it: $ file = 'http: //biencaleta.com/musica/Billboard-70s/Grupos/Billboard%201970 .ca / Simon Y Garfunkel - Bridge at Trubled.msa '; $ Basename = basename ($ file); Header ('content-description: file transfer'); Header ('content-type: application / octet-stream'); Header ('content-dispute: attachment; filename =' '.basename.' '' '); Header ('content-transfer-encoding: binary'); Set_time_limit (0); Readfile ($ file); But it downloads a corrupted file. Thank you You are requesting an invalid URL, leaving the free space in place. Your browser takes care of it for you

javascript - Iframe Passing variables and capture then in landing page -

I am using an iframe to pass some variables (A and B) and capture them on the landing page the wanted. Page-1 & lt; Iframe id = "trackFrame" width = "600" height = "500" src = "map Html? A = 1 & amp; B = 2" frameborder = "0" scrolling = "no" margin-height = "0" marginwidth = " 0 "& gt; & Lt; / Iframe & gt; In the landing page Landing Page Please help me I'm new to presentation development. Try looking at this post here: Previously passed to you The parameters will be required to get an array, which can be done by: var newArray = window.location. Search.substr (1) .split ('& amp;') Try calling a blank function on page log, which then reads it. The array is then created by reading the absolute string window.location.search.substr (1) and then it is separated into one array & amp; Farm. So if you have mysite.com/page.html?a=3&

python - NameError: name 'result' is not defined -

I have written a very simple program in Python for the category I (1 , 1000): if (i% 3 == 0) and (i% 5 == 0): result + = i other: print ('sum is {}'. Format (result)) When I try to compile the problem, I get an error. Name error: Name 'Result' is not defined This statement: is the result of + i = : result = result + I But, for the first time this statement has reached your loop, variable result is not defined, so the right hand of that assignment statement is evaluated Does not happen.

c# - Table valued parameters - time out -

I have applied table honorable parameters that are populated by the C # program and finally stored procedure for storing in tables Uses. I found that if I send 75 records at a time, then it takes time or I do not. How can I include more records at one time? - Select the top 75 master reassures where .... Recs many details in each master recs - The list of collections has been made and with these 75 rec, their extensive recieved and inserted copper has been added. Private static zero empty copper (List & lt; MasterTbl & gt; New MinuteBlock, List & Lt; ExpansionTebby & gt; New DredTubluble) {Init 32 Rows Affected = 0; Try {DataSet ds = new DataSet (); Datatale dtMasterVerified = Create DataTable (); Datatable dtMasterVerified1 = dtMasterVerified.Clone (); Datatyll dtDetail = CreateDatatableDetail (); Datatelle dtDetail1 = dtDetail.Clone (); Leading (AdverbitterTMM TMP in New Mintib) {Datarave Domaster = DTMasterVirified 1.NewRow (); Daumaster ["id"] =

java - Changing the colors on a image -

I am trying to create a program that allows me to change the colors of an image, an interface through color, then decided in the interface, you choose the color, by clicking on the image problem that: once the Parekspoint method to change me again image fill pixels Requires the same as the selected pixel on which the pixel was clicked and The reference is the pixel, but click points in tramsform image 2, and color is the color color. The transport point method should be portrayed if the reference is similar to the color of the pixel and afterwards send their paint points to the North, South, Est and West, then it (if any) calls itself through a recursive method. is. Because each method call stack requires this method of changing the image, it is not possible for areas with pixels where you need more than the current stack. public void Tronsformment was 2 (Click Point Point, Color color) {// Dispresrs O Canal Alpha (Tronspriansia) in Tuds course Int paint as the use of Rngor

java - PageSize of PDF always the same between landscape and portrait with itextpdf -

I have a PDFReader that includes some pages and other images in landscape mode. I need it to treat them differently ... However, if I call GetOrientation or GetPageSize, the value is always the same (595 for paging and 0 for orientation) . A page in the scenario? I have tried to find other ways to get page width / orientation but nothing has worked. Here is my code: for (int i = 0; i & lt; pdfreader.getNumberOfPages (); i ++) {document = PdfStamper.getOverContent (I) .getPdfDocument (); Document.getPageSize () getWidth // it will always be the same) Thanks! getPageSize () and getPageSizeWithRotation () There are two feature methods named. Let's take a look at an example: PDF Reader Reader = New PDF Reader ("src / main / resources / pages.pdf"); Show (reader.getPageSize (1)); Show (reader.getPageSize (3)); Show (reader.getPageSizeWithRotation (3)); Show (reader.getPageSize (4)); Show (reader.getPageSizeWithRotation (4)); In this example

php - JSON Return List from Array -

I am trying to create a list of names with the checkbox using AJAX. Unfortunately, using the code given below, I get only one name instead of the four in my database. The code I am using here sits in a separate php file called by AJAX: $ query = "SELECT id, first_name, last_name, From e-mail users where location_id = '{$ location_id}' "; $ Result = mysqli_query ($ connection, $ query); If (! $ Result) {dead ("database queries failed:". Mysqli_error ($ connection)); } While ($ line = mysqli_fetch_array ($ result)) {$ name = $ row ['first_name'] "" $ line ['last_name']; $ Attendees = '& lt; Label & gt; & Lt; Input type = "checkbox" name = "emp_name []" id = "emp_name []" value = "'. $ Name.' & Gt; '$ name' & lt; / labels & gt; & lt; span style = "Padding-right: 20px;" & gt; & lt; / span & gt; ';} echo json_encode (arra

actionscript 3 - as3 check for 2 objects with same property in array -

I have an array, call it _persons I am making this object popular with value objects, this object Calling PersonVO Everyone has the name and score properties of VO. What am I trying to do, array & amp; // PSEUDO code 1 Find any VO with same name (should only be maximum 2) Compare properties compared to 2 digits 3 Keep VO with only the highest score And delete the _persons array from the other I'm having trouble with code implementation, any AS3 wizard capable of helping you? You better dictionary for this task, because you have to query A specific unique asset is a dictionary approach is viable, in case you have only one major property in name , and you should have only one object at any time in this property. An example: High Highscore: Dictionary; // Load it anyway addHighscore function (name: string, score: number): Boolean {// returns if the score is bigger than stored, aka private best prev prev :core = highscores [name] ; If (INNAN (ProstScore) ||

c - Semicolon - How is messing with this exercise -

I know that I should not have a semicolon after the loop. But I am learning and by mistake I have put one. And I wanted to know what was happening with my error, so the next time something like that happens, I know the source of the mistake. In the code below, in this part of the code: "triangular number = 0; / Pre> I accidentally inserted a semi colon " for (n = 1; n & lt; = number; ++ n)" loop when I execute the entire code This indicates the user to insert a number to calculate the triangle number, but the result with a semicolon is false. For example, when I insert 10, then the answer must be 55 Which semicolon error leads me to 56. I want to understand why 56. The complete code is below: < Pre> #include & lt; stdio.h> int main (zero) {int n, number, triangular number, counter (for counter = 1; counter & lt; = 5; counter ++) {Printf ("What triangle number do you want?"); Scanf ("% i", and number); fo

Parsing JSON in Ruby (like XPATH) -

I have a JSON document for a Google Book API with a query, such as: parsed = json.parse (my_uri_response) ). In this loop, I have a next if k ['type'] = "other" which sets "type" to "other". How do I remove only one ISBN number from my JSON example? Not all of them, just one Some XPath will be useful as a search. How about: perced ['items'] . Map {| Book | Book ['volume_info'] ['industrial identifiers']. Find {| Sahara | ['ISBN_10', 'ISBN_13']? If you get the undefined method for [zero]: NilClass means that there is an element inside you ['type']} ['type']} ['identifier']} item array, which has no volume_info key, or you have a industry identifier without an iPhone Quantity with the set should cover all those cases in the code below (+ when you have volumeInfo without industry_in recognizers : < Code> Has been parsed ['items']. {| Book

ruby on rails - Use \ instead of + or << to concatenate those strings -

I'm using RookOp to clean my dirty code ... A There were errors: use instead of + or Why is that so? I can not find it. + or & lt; Why would I use the \ instead of = "post-text" itemprop = "text"> ruby In, virtual wires are allocated as objects in memory, when they come in front. If you add two string literals, like str = "foo" + "bar" you will actually assign three strings Objects: "foo" , "bar" and combination result (which is then referred to by str ) It is as if you do: "foo" & lt; & Lt; "Bar" In many cases, this is only a light inability that you should not worry too much. However, keep in mind that if you do this, a loop, and if the total string gets bigger, then you should use an ever greater string < / Code> will assign objects (even if you call it string parts as aaa , and then call ; foo foo \ in' you can not

javascript - Referencing Anchors from multiple ckeditors -

हम एक वेब पेज पर एक से अधिक ckeditors प्रदर्शित करते हैं। उपयोगकर्ता सभी ckeditors में एंकर बनाता है । वर्तमान में टूलबार में लिंक आइकन उपयोगकर्ता को उस सीकेडीटर के भीतर एंकर को संदर्भित करने की क्षमता देता है। उपयोगकर्ता अन्य कोकडीटर में बनाए गए एंकर को भी देखना चाहता है और उन एंकरों के संदर्भ में, जब एक वेब लिंक को क्लिक किया गया है किसी भी युक्तियों / समाधानों को कैसे लागू किया जा सकता है कि कैसे अन्य एक्टर्स से कई एन्कर्स दिखाए जा रहे हैं? धन्यवाद / एमके एल्गोरिथम बदलने के लिए जो एन्कर्स को ढूंढता है आपको इस विधि को ओवरराइड करना है:। यहां इसका स्रोत है: आप इसे किसी भी समय कर सकते हैं - यह तरीका गतिशील रूप से कहा जाता है जब लिंक डायलॉग खोला जाता है। PS यह सीकेएडीटर 4.3.3 के बाद से काम करेगा। पिछले संस्करणों के लिए कोई आसान समाधान नहीं है।

I got blank page in openshift -

यूआरएल: तैनात युद्ध फाइल को खोलें 1) Src / pom.xml फ़ाइल को हटा दिया गया 2) वेबएप्स डायर के लिए युद्ध जोड़ा गया 3) जीआईटी ऐड / कमिट / पुश लेकिन मुझे खाली पृष्ठ मिल रहा है। यदि आप चाहते हैं कि आपका आवेदन मूल संदर्भ में तैनात किया गया है, तो आपको इसे "ROOT.war" नाम की आवश्यकता है, अन्यथा यह < / P>

dart - How to see all packages of given author on http://pub.dartlang.org? -

How to see all the packages from a given author For example, if I want to See all the packages of Solan I can click on the author link and go to the author page. As far as I know, there are also own writers on their package. For some reason I could not find any way to get the overall picture about the packages relative to my authors. Is this possible? If it is not possible then why? PS I am amazed at the complete lack of services provided to me. / P> It is a belief that no one does this because they do not care about it. Perhaps there is an argument in favor of this fact that I am wrong? I do not think there is a huge investment in this. Pub site is not such a feature for now. However sources are available. You can help improve the service by submitting a pull-request. You can optionally use JSX output and you can get whatever you want. I made it and you can see a raw result. The assembled json datas are available. (Source :)

concurrency - How to spawn concurrent computation in Haskell? -

If I get a function that calculates four very long and returns a list with the result of four calculations, but Where each calculation is not dependent on another, how do you "parallel" in Haskell? To better explain my question, here is a close example of my thoughts: (defan some-function [arg1 arg2] [c1 C2 (c1 c3 c4]] [c1 c2 c3 c4]) cgi (future (very long-calculated ARGU1)) C3 (future (very-long-calculation logic 2)) 3 (Future (very long-computed hypothesis)) C4 (long-term calculations) Beggary]]; There is no need to wrap the C4 in the future [@ C1 @ C2 @ C3C4]) What will happen in Haskell as follows? someFunction :: (a -> A -> A -> a) - & gt; (A) C1 and Lt; - Rapper (very long computed computation) C2 and Lt; - Rapper (very long-calculated logic 2) C3 and LT; - Rapper (very long-calculated computation) C4 and LT; - (very-long-calculated arg4) rseq c1 rseq c2 rseq c3 returns (c1, c2, c3, c4) Do I need rpar / rseq c4? What is the rpar / Rs

node.js - response.writeHead not sending post data -

मेरे पास निम्न कोड है console.log (typeof (postData)); console.log (typeof (querystring.parse (POSTDATA))); console.log (typeof (querystring.parse (POSTDATA) .text)); console.log (querystring.parse (POSTDATA) .text); Var सामान = querystring.parse (postData) .text; console.log (सामान); Stuff = "आपने पाठ भेजा है:" + सामान; console.log (सामान); Console.log ("अनुरोध हैंडलर 'अपलोड' बुलाया गया था।"); Response.writeHead (200, {"सामग्री प्रकार": "पाठ / सादे"}); console.log (response.write (सामान)); response.end (); Console.log ("अधिक पाठ"); console.log (सामान); कंसोल में मुझे मिलता है स्ट्रिंग ऑब्जेक्ट स्ट्रिंग fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff आप पाठ भेजा है: ffffffffffffffffffffffffffffffffffffff अनुरोध हैंडलर 'अपलोड' कहा जाता था। झूठा अधिक पाठ आपने पाठ भेजा है: ffffffffffffffffffffffffffffffffffffff लेकिन वेबपेज पर मुझे आपने पाठ