Search Results

Search found 34207 results on 1369 pages for 'query output'.

Page 93/1369 | < Previous Page | 89 90 91 92 93 94 95 96 97 98 99 100  | Next Page >

  • How can I select an audio output device in directshow

    - by Vibhore Tanwer
    I was wondering how I can select the output device for audio in directshow. I am able to get available audio output devices in directshow. But how can I make one of these to be audio output device. Its always going for the default audio device. I want to be able to output audio on my choice of device. I have been struggling through google but couldn't find anything useful. All I could get was this link but it doesn't really solve my problem. Any help will be really helpful for me.

    Read the article

  • mysql query building output taking a long time

    - by user121196
    I have a simple query that does select * from t limit 1; on a remote mysql server. I use squirrel(mysql client) to run it, it shows: Query 1 of 1 elapsed time (seconds) - Total: 22.047, SQL query: 1.047, Building output: 21 why does building output take such a long time? what does this process do? when running from mysql command line, the whole process takes 0.3 secs (also remotely)

    Read the article

  • Why is my PHP string being converted to 1?

    - by animuson
    Ok, so here's the quick rundown. I have a function to generate the page numbers. This: <?php die($ani->e->tmpl->pages("/archive", 1, 15, 1, true)); ?> will output Single Page like expected. But this: <?php $page_numbers = $ani->e->tmpl->pages("/archive", 1, 15, 1, true); ?> <?= $page_numbers ?> will output a simple 1 to the page. Why is it getting converted to a 1? I would expect it to store the 'Single Page' string to the page_numbers variable and then output it (like an echo) exactly the same. EDIT: Running a var_dump($page_numbers) returns int(1)... Here is the entire function in context: <?php // other functions... function show_list() { global $ani; $page_numbers = $ani->e->tmpl->pages("/archive", 1, 15, 1, true); ob_start(); ?> <!-- content:start --> <?php $archive_result = $ani->e->db->build(array("select" => "*", "from" => "animuson_archive", "orderby" => "0-time", "limit" => 15)); while ($archive = $ani->e->db->fetch($archive_result)) { ?> <h2><a href="/archive/article/<?= $archive['aid'] ?>/<?= $archive['title_nice'] ?>"><?= $archive['title'] ?></a></h2> <!-- breaker --> <?php } ?> <?= var_dump($page_numbers) ?> <!-- content:stop --> <?php $ani->e->tmpl->process("box", ob_get_clean()); } // other functions... ?>

    Read the article

  • Error while attempting to output data onto console in xcode

    - by Michael Amici
    I am trying to output general data (source code) from a website, but it just sits there. Can't figure out if its the interface or the code. Would someone double-check for me? #import "Lockerz_RedemptionViewController.h" @implementation Lockerz_RedemptionViewController -(IBAction)start: (id) sender { while (1) { NSMutableData *mydata = [[NSData alloc] initWithContentsOfURL:[NSURL URLWithString:@"http://ptzplace.lockerz.com/"]]; NSString *output = [[NSString alloc] initWithData:mydata encoding:NSASCIIStringEncoding]; NSLog(output); } }

    Read the article

  • Finding Errant Output to System.out in Large Java Program

    - by SvrGuy
    Hi, We have a large java code base [~1 M Lines]. Buried (somewhere) in the code base is some old debug output to System.out that we want to remove (its cluttering things up). The problem is: out code base is so large that we can't easily find where the output is coming from. What we want is a way to see where System.out.println is getting called from (like a stack trace from an exception or some such). Its not suitable to debugging -- the errant output is coming from some errant thread somewhere etc. Any ideas on how to track the source of this errant output down? PS: 99.99% of calls to System.out are legit, and we have thousands of them, so simply searching the code base for System.out calls is not a solution!

    Read the article

  • Flash builder 4 - change output filename using external build-config.xml (not Ant)

    - by Casey
    I'm trying to change the output filename with a config file loaded via the compiler option -load-config. It looks like this in my compiler arguments: -load-config+=build-config.xml. I've tried the following: <flex-config> <o>absolute/path/to/filename</o> </flex-config> and <flex-config> <output>absolute/path/to/filename</output> </flex-config> and <flex-config> <compiler> <o>absolute/path/to/filename</o> </compiler> </flex-config> and <flex-config> <compiler> <output>absolute/path/to/filename</output> </compiler> </flex-config> but none have worked. I'm on a PC using Flash Builder 4. Has anyone else done this? Also, ideally, I want to use a relative path instead of absolute. I can't get this to work either, even if I do so in the "additional compiler arguments" field of the Project configuration. Thanks in advance!

    Read the article

  • My SQL query is only returning I need the parent aswell

    - by sico87
    My sql query is only returning the children of the parent I need it to return the parent as well, public function getNav($cat,$subcat){ //gets all sub categories for a specific category if(!$this->checkValue($cat)) return false; //checks data $query = false; if($cat=='NULL'){ $sql = "SELECT itemID, title, parent, url, description, image FROM p_cat WHERE deleted = 0 AND parent is NULL ORDER BY position;"; $query = $this->db->query($sql) or die($this->db->error); }else{ //die($cat); $sql = "SET @parent = (SELECT c.itemID FROM p_cat c WHERE url = '".$this->sql($cat)."' AND deleted = 0); SELECT c1.itemID, c1.title, c1.parent, c1.url, c1.description, c1.image, (SELECT c2.url FROM p_cat c2 WHERE c2.itemID = c1.parent LIMIT 1) as parentUrl FROM p_cat c1 WHERE c1.deleted = 0 AND c1.parent = @parent ORDER BY c1.position;"; $query = $this->db->multi_query($sql) or die($this->db->error); $this->db->store_result(); $this->db->next_result(); $query = $this->db->store_result(); } return $query; }

    Read the article

  • VS 2008 C++ build output?

    - by STingRaySC
    Why when I watch the build output from a VC++ project in VS do I see: 1Compiling... 1a.cpp 1b.cpp 1c.cpp 1d.cpp 1e.cpp [etc...] 1Generating code... 1x.cpp 1y.cpp [etc...] The output looks as though several compilation units are being handled before any code is generated. Is this really going on? I'm trying to improve build times, and by using pre-compiled headers, I've gotten great speedups for each ".cpp" file, but there is a relatively long pause during the "Generating Code..." message. I do not have "Whole Program Optimization" nor "Link Time Code Generation" turned on. If this is the case, then why? Why doesn't VC++ compile each ".cpp" individually (which would include the code generation phase)? If this isn't just an illusion of the output, is there cross-compilation-unit optimization potentially going on here? There don't appear to be any compiler options to control that behavior (I know about WPO and LTCG, as mentioned above). EDIT: The build log just shows the ".obj" files in the output directory, one per line. There is no indication of "Compiling..." vs. "Generating code..." steps. EDIT: I have confirmed that this behavior has nothing to do with the "maximum number of parallel project builds" setting in Tools - Options - Projects and Solutions - Build and Run. Nor is it related to the MSBuild project build output verbosity setting. Indeed if I cancel the build before the "Generating code..." step, the ".obj" files will not exist for the most recent set of "compiled" files. E.g., if I cancel the build during "c.cpp" above, I will see only "a.obj" and "b.obj".

    Read the article

  • If setUpBeforeClass() fails, test failures are hidden in PHPUnit's JUnit XML output

    - by Adam Monsen
    If setUpBeforeClass() throws an exception, no failures or errors are reported in the PHPUnit's JUnit XML output. Why? Example test class: <?php class Test extends PHPUnit_Framework_TestCase { public static function setUpBeforeClass() { throw new \Exception('masks all failures in xml output'); } public function testFoo() { $this->fail('failing'); } } Command line: phpunit --verbose --log-junit out.xml Test.php Console output: PHPUnit 3.6.10 by Sebastian Bergmann. E Time: 0 seconds, Memory: 3.25Mb There was 1 error: 1) Test Exception: masks all failures in xml output /tmp/pu/Test.php:6 FAILURES! Tests: 0, Assertions: 0, Errors: 1. JUnit XML output: <?xml version="1.0" encoding="UTF-8"?> <testsuites> <testsuite name="Test" file="/tmp/phpunit-broken/Test.php"/> </testsuites> More info: $ php --version PHP 5.3.10-1ubuntu3.1 with Suhosin-Patch (cli) (built: May 4 2012 02:21:57) Copyright (c) 1997-2012 The PHP Group Zend Engine v2.3.0, Copyright (c) 1998-2012 Zend Technologies with Xdebug v2.1.0, Copyright (c) 2002-2010, by Derick Rethans

    Read the article

  • How to check value of stored procedure output parameter

    - by Anna T
    I have a stored procedure that: A. inserts some rows into a "table variable" based on some joins B. selects all values from column x from that table into a string with comma separated values C. selects all from the "table variable" If I execute the procedure like this: EXEC CatalogGetFilmDetails2 2,111111; a table is returned as instructed per step C above. How can I execute it so that also the output parameter value is displayed? (see point B above). I need to check if it's calculated properly. And since the second parameter is of output type, meaning it's calculated inside the procedure, why is it mandatory to specify a value for it when executing the procedure? I normally use a random value for it, it anyway doesn't matter/impact the result. On the other hand if I try to execute it without the output parameter, it returns an error) Thank you very much! This is how the procedure starts: CREATE PROCEDURE CatalogGetFilmDetails2 (@FilmID int, @CommaSepString VARCHAR(50) OUTPUT) AS And this is how @CommaSepString is calculated: SELECT @CommaSepString = STUFF((SELECT ', ' + Categ FROM @Filme1 FOR XML PATH('')), 1,1,'')

    Read the article

  • How to output floating point numbers with a custom output format in C++?

    - by Victor Liu
    The problem is that I want to output Mathematica compatible floating point numbers. The only difference with the standard IOStream or printf output format is that the exponential e is replaced by *^: Standard C/C++ output format: 1.23e-4 Mathematica format: 1.23*^-4 Is there a way to manipulate streams to achieve this effect? My original idea was just to use istringstream and dump it to a string and then replace all the e's. I would also be okay if someone posted code to parse through the bits of the floating point number and output it directly (i.e. a printf("%e") replacement).

    Read the article

  • Embarrassingly parallel workflow creates too many output files

    - by Hooked
    On a Linux cluster I run many (N > 10^6) independent computations. Each computation takes only a few minutes and the output is a handful of lines. When N was small I was able to store each result in a separate file to be parsed later. With large N however, I find that I am wasting storage space (for the file creation) and simple commands like ls require extra care due to internal limits of bash: -bash: /bin/ls: Argument list too long. Each computation is required to run through a qsub scheduling algorithm so I am unable to create a master program which simply aggregates the output data to a single file. The simple solution of appending to a single fails when two programs finish at the same time and interleave their output. I have no admin access to the cluster, so installing a system-wide database is not an option. How can I collate the output data from embarrassingly parallel computation before it gets unmanageable?

    Read the article

  • Searching For A Record After A LINQ query

    - by Justin
    I'm confused to why this is happening. I'm new to LINQ so I'm clearly missing something here, that is probably pretty easy. I've looked up help on the topic, but I don't really know what to ask so I haven't found any answers that really address my question. This doesn't work It throws an EntityCommandExecutionException when the FirstOrDefault method is executed. var query = from band in context.BandsEntitySet where band.ID == 12345 select band; string venueName = "Willis Park"; foreach (var item in query) { var venue = context.VenueEntitySet.FirstOrDefault(r => r.Venue.Equals(venueName)); } This works var query = from band in context.BandsEntitySet where band.ID == 12345 select band; var bandList = query.toList(); string venueName = "Willis Park"; foreach (var item in bandList) { var venue = context.VenueEntitySet.FirstOrDefault(r => r.Venue.Equals(venueName)); } My question is simple: Why is the exception being thrown? And why does creating a list from the query allow me to use the FirstOrDefault method? Exception Message: A first chance exception of type 'System.Data.EntityCommandExecutionException' occurred in System.Data.Entity.dll I guess I am wrong in my assumption that query is a list? Then what is it exactly? I'm confused because this doesn't throw an exception: foreach (var item in query) { var area = item.VenueArea; } I'd appreciate any help on this issue. thanks, Justin

    Read the article

  • How to query the SPView object

    - by Hugo Migneron
    I have a SPView object that contains a lot of SPListItem objects (there are many fields in the view). I am only interested in one of these fields. Let's call it specialField Given that view and specialField, I want to know if a value is contained in specialField. Here is a way of doing what I want to do : String specialField = "Special Field"; String specialValue = "value"; SPList list = SPContext.Current.Site.RootWeb.Lists["My List"]; SPView view = list.Views["My View"]; //This is the view I want to query SPQuery query = new SPQuery(); query.Query = view.Query; SPListItemCollection items = list.GetItems(query); foreach(SPListItem item in items) { var value = item[specialField]; if(value != null) && (value.ToString() == specialValue) { //My value is found. This is what I was looking for. //break out of the loop or return } } //My value is not found. However, iterating through each ListItem hardly seems optimal, especially as there might be hundreds of items. This query will be executed often, so I am looking for an efficient way to do this. EDIT I will not always be working with the same view, so my solution cannot be hardcoded (it has to be generic enough that the list, view and specialField can be changed.

    Read the article

  • Why does R sometimes stop displaying output?

    - by Winston C. Yang
    Sometimes R stops displaying output. I type the number 1, followed by the return key, and nothing appears. This situation occurred after I pressed the "STOP" icon in the window, which is for stopping long calculations. I'm using R 2.11.0 on a Mac. Does pressing "STOP" cause R to stop displaying output? How do I get R to display output again?

    Read the article

  • MySQL: Limit output according to associated ID

    - by Jess
    So here's my situation. I have a books table and authors table. An author can have many books... In my authors page view, the user (logged in) can click an author in a tabled row and be directed to a page displaying the author's books (collected like this URI format: viewauthorbooks.php?author_id=23), very straight forward... However, in my query, I need to display the books for the author only, and not all books stored in the books table (as i currently have!) As I am a complete novice, I used the most simple query of: SELECT * FROM tasks_tb This returns the books for me, but returns every single value (book) in the database, and not ones associated with the selected author. And when I click a different author the same books are displayed for them...I think everyone gets what I'm trying to achieve, I just don't know how to perform the query. I'm guessing that I need to start using more advanced query clauses like INNER JOIN etc. Anyone care to help me out :)

    Read the article

  • problem in reading output of dd command using pipe

    - by Ummar
    I am developing an application, in which I want to redirect the output (progress information) of dd command to my C++ program, but it is not actually getting the output, here is the code FILE * progressInfo = popen("gzip -dc backup/backup.img.gz | pv -ptrbe -i 2 -s 2339876653 | dd of=/dev/sdb","r"); if(!progressInfo) { return -1; } char buf[1024]; while(fgets(buff, sizeof(buff),progressInfo)!=NULL) { std::cout << buff << endl; } but the problem is the progress information is not received in buff, and the output is continuously printed on terminal, and above program halts on while(fgets(buff, sizeof(buff),progressInfo)!=NULL), and as soon as the dd operation is completed, the very next line to loop block is executed. if anyone has any idea why the output is not returned to buff, and its continuously retuned on terminal?

    Read the article

  • Slow T-SQL query, convert to LINQ to Object

    - by yimbot
    I have a T-SQL query which populates a DataSet from an MSSQL database. string qry = "SELECT * FROM EvnLog AS E WHERE TimeDate = (SELECT MAX(TimeDate) From EvnLog WHERE Code = E.Code) AND (Event = 8) AND (TimeDate BETWEEN '" + Start + "' AND '" + Finish + "')" The database is quite large and being the type of nested query it is, the Data Adapter can take a number of minutes to fill the DataSet. I have extended the DataAdapter's timeout value to 480 seconds to combat it, but the client still complains about slow performance and occassional timeouts. To combat this, I was considering executing a simpler query (ie. just taking the date range) and then populating a Generic List which I could then execute a Linq query against. The simple query executes very quickly which is great. However, I cannot seem to build a Linq query which generates the same results as the T-SQL query above. Is this the best solution to this problem? Can anyone provide tips on rewriting the above T-SQL into Linq? I have also considered using a DataView, but cannot seem to get the results from that either.

    Read the article

  • How To perform a SQL Query to DataTable Operation That Can Be Cancelled

    - by David W
    I tried to make the title as specific as possible. Basically what I have running inside a backgroundworker thread now is some code that looks like: SqlConnection conn = new SqlConnection(connstring); SqlCommand cmd = new SqlCommand(query, conn); conn.Open(); SqlDataAdapter sda = new SqlDataAdapter(cmd); sda.Fill(Results); conn.Close(); sda.Dispose(); Where query is a string representing a large, time consuming query, and conn is the connection object. My problem now is I need a stop button. I've come to realize killing the backgroundworker would be worthless because I still want to keep what results are left over after the query is canceled. Plus it wouldn't be able to check the canceled state until after the query. What I've come up with so far: I've been trying to conceptualize how to handle this efficiently without taking too big of a performance hit. My idea was to use a SqlDataReader to read the data from the query piece at a time so that I had a "loop" to check a flag I could set from the GUI via a button. The problem is as far as I know I can't use the Load() method of a datatable and still be able to cancel the sqlcommand. If I'm wrong please let me know because that would make cancelling slightly easier. In light of what I discovered I came to the realization I may only be able to cancel the sqlcommand mid-query if I did something like the below (pseudo-code): while(reader.Read()) { //check flag status //if it is set to 'kill' fire off the kill thread //otherwise populate the datatable with what was read } However, it would seem to me this would be highly ineffective and possibly costly. Is this the only way to kill a sqlcommand in progress that absolutely needs to be in a datatable? Any help would be appreciated!

    Read the article

  • How do I effectively write to 146 output files in C++ using cstdlib library

    - by Elpezmuerto
    I have a very large binary file and I need to create separate files based on the id within the input file. There are 146 output files and I am using cstdlib and fopen and fwrite. FOPEN_MAX is 20, so I can't keep all 146 output files open at the same time. I also want to minimize the number of times I open and close an output file. How can I write to the output files effectively? I also must use the cstdlib library due to legacy code.

    Read the article

  • Run multiple MySQL queries based on a series of ifs

    - by OldWest
    I am just getting started on this complex query I need to write and was hoping for any suggestions or feedback regarding table structure and the actual query itself.. I've already created my tables and populated test data, and now just trying to sort out how and what is possible within MySQL. Here is an outline of the problem: End result: Listing of rates based on specific queried criteria (see below): Age: [ 27 ] Spouse Age: [ 25 ] Num of Children: [ 3 ] Zip Code: [ 97128 ] The problem I am running into is each company that provides rates has a unique way of dealing with the rate. And I am looking for the best approach for multiple queries based on the company (one query with results for each company more or less all combined into one result set). Here are some facts: - Each company deals with zip code ranges which assist in the query result. - Each company has a different method of calculating the rate based on the Applicant, Spouse, Num of Children: Example, a) Company A determines rate by: Applicant + Spouse + Child(ren) = rate (age is pertinent to the applicant within a range). b) Company B determines the rate by total number of applicants like: 1, 2, 3, 4, 5, 6+ = rate (and age is ignored). First off, what would I call this type of query? Multiple nested query? And should I intertwine php within it to determine the If()s ... I apologize if this thread lacks sufficient data, so please tell me anything you would like to see.

    Read the article

  • Stacking standard output of `su`

    - by Kristopher Ives
    I've got some code that I wrote that uses a combination of bash and PHP command line scripting. The script is ran as root and then uses su to become various uses. I start a session like this: $result = `su SomeUser ./dothis.php` Here ./dothis.php is a script that may generate some output being stored in $result, but the problem is that there is usually output that doesn't get caught and makes it hard for me to read my script output. How can I make sure that the output is being captured within this su stacking?

    Read the article

< Previous Page | 89 90 91 92 93 94 95 96 97 98 99 100  | Next Page >