Search Results

Search found 11238 results on 450 pages for 'miserable variable'.

Page 44/450 | < Previous Page | 40 41 42 43 44 45 46 47 48 49 50 51  | Next Page >

  • What is the '@(' doing in this Perl code?

    - by Anthony Veckey
    In this code snippet: use strict; use warnings; use Data::Dumper; my $r = [qw(testing this thing)]; print Dumper($r); foreach my $row (@({$r}) { print "$row\n"; $row .= 'mod'; } print Dumper($r); print Dumper(@({$r}); I figured out that the '(' after the '@' in the foreach is causing this not to loop correctly. I have no idea why this code even works as there is no ending parenthesis. What is this doing? It looks to be creating a new variable on the fly, but shouldn't 'use strict' have fired or something? Please help explain what that '@(' is doing and why it still runs without an ending parenthesis.

    Read the article

  • Counting variables per observation per month in Sas.

    - by John
    Hey guys, a quick question, I have data of the following sort: Ticker _ Date _ Fem Analyst (dummy 1 if true) AA _ 04/2001 _ 1 AA _ 04/2001 _ 1 AA _ 04/2001 _ 1 AA _ 05/2002 _ 1 AA _ 05/2002 _ 1 AA _ 07/2002 _ 0 AA _ 04/2003 _ 1 and so on.. What I want to receive is the following: Ticker _ Date _ Number of fem analyst AA _ 04/2001 _ 3 AA _ 05/2002 _ 2 AA _ 07/2002 _ 0 AA _ 04/2003 _ 1 So an easy counting algorithm that allows me to count for the number of analysts per company per month (the date is in 01/04/2002 format but I also have a month count variable which can be used too) Any ideas?

    Read the article

  • vim variable declaration

    - by dorelal
    I added following line of code in .vimrc let g:jslint_status = 'enabled' if exists("jslint_status") echo jstlint_status else echo 'not found' endif Error message E121: Undefined variable: jstlint_status E15: Invalid expression: jstlint_status What am I doing wrong?

    Read the article

  • Using static variable in android

    - by michael
    Hi, In android, is it recommend to use static variable? E.g, implement a Singleton pattern in Java, I usually do: private static A the_instance; public static A getInstance() { if (the_instance == null) { the_instance = new A(); } return the_instance; } My question is when do that get free by android JVM? Thank you.

    Read the article

  • PHP while(variable=mysql_fetch_assoc) - explanation

    - by Petr
    Hi, I have been working with C# so this is quite strange for me: while($variable=mysql_fetch_assoc) I have not been able to look up in PHP manual how it works. I guess that in each loop it advances to next element of assoc.array. But what is this generally called in PHP? I am just not used to see '=' in loop condition.

    Read the article

  • file content into unix variable with newlines

    - by Hugo
    I have a text file test.txt with the following content: text1 text2 And I want to assign the content of the file to a UNIX variable but when I do this: testvar=$(cat test.txt) echo $testvar the reult is: text1 text2 instead of text1 text2 Can someone suggest me a solution for this?

    Read the article

  • Require_once to variable

    - by swamprunner7
    I want to call require_once("test.php") but not display result and save it into variable like this: //pseudocode $test = require_once('test.php'); //some operations like $test = preg_replace(…); echo $test; Is it possible?

    Read the article

  • how can put a javascript variable in img tag

    - by ajithperuva
    I need to put a javascript variable as image source.That is my image tag should be in this format here i am adding my script document.getElementById("pricefilter").innerHTML ='' here variablename carries my image path.How can i put this in double quates.Please help to solve this

    Read the article

  • how to declare variable in POSTGRE

    - by user307880
    I try to declare a variable in a code like this, but it's doesn't work. Can you tell me what's the problem? ERROR: syntax error at or near "VARCHAR" LINE 2: p_country VARCHAR; DECLARE p_country VARCHAR; p_country : = ''; SELECT p_country;

    Read the article

  • how to get an xml in a variable

    - by sam
    I have a stored procedure that will return xml. I have delared a variable of type xml and trying to execute the following code declare @v xml set @v = execute get_xml @id, 33 whereas id is returned by another query. now it keeps compalinng about the following error Incorrect syntax near the keyword 'execute'.

    Read the article

  • find the total values get in a variable in php

    - by Hmwd
    hi, i am doing a shopping cart.i had a variable $total.when i add 1st product of price 200 i get $total=200 , when i add 2nd product of price 100 i get $total=200100 when i add 3rd product of price 400 i get $total=200100400 . i want to get $total=700. how to fix this problem? please help me........ thanks, Hmwd

    Read the article

  • jquery pass dynamic variable name

    - by Alessandro
    hi function liveUpdate(fld,value,id) { $.ajax({ type: 'POST', url: 'myurl.html', data: { fld:value, 'id': id }, success: function(data){//console.log(data); } }); } i want fld to be posted as fld's value not the variable name fld? i've tried to wrap around with eval but no luck any ideas? thanks

    Read the article

  • Missing $ on loop variable

    - by k0re
    Hi, 1 #!/usr/bin/perl 2 use strict; 3 use warnings; 4 5 my @array = qw[a b c]; 6 foreach my($a,$b,$c) (@array) { 7 print "$a , $b , $c\n"; 8 } I receive following error: Missing $ on loop variable What is wrong? I am using: perl v5.10.1 (*) built for x86_64-linux-thread-multi

    Read the article

  • Variable table or column names.

    - by Frank Computer
    INFORMIX-SQL or any other SQL-based DB: Suppose I have an app where depending on the value of some columns, example: company.code char(3) {abc} company.brach char(2) {01} Can I construct table name "abc01" for inclusion in SELECT * FROM abc01; ? In other words, a variable table name.. same question applies for column names.

    Read the article

  • i can't get variable in function.

    - by kaym
    i can't read the variable in the function, i want to use it outside the function, here is my code. var contentLoader:URLLoader = new URLLoader(); contentLoader.load(new URLRequest("http://localhost/data.php")); function onComplete(event:Event):void { var txtu:String = event.target.data; } contentLoader.addEventListener(Event.COMPLETE, onComplete); trace(txtu); thanks.

    Read the article

  • Linking a Text Box to a variable?

    - by cam
    I would like to have direct access to the text inside a textbox on another form, so I added a public variable _txt to a form and added an event like so: private void richTextBox1_TextChanged(object sender, EventArgs e) { _txt = richTextBox1.Text; } But the form is loaded like this: public FrmTextChild(string text) { InitializeComponent(); _txt = text; richTextBox1.Text = _txt; Text = "Untitled.txt"; } Is there a better way to directly link the two?

    Read the article

  • java app behind proxy to use http_proxy variable in linux

    - by rbbeltran
    hello java guys, im thinking of a simple java app (command line) that connects to the internet to download xml file, the problem is that my ubuntu is using a proxy to connect to internet with username and password (tru http_proxy ="http://:@:" ). So My question is, could it be possible to write a java app to use http_proxy variable? instead of programmatically setting http proxy and host in every app i will write.

    Read the article

  • Variable number of arguments in VB

    - by Kratz
    How to create a function with variable number of arguments in visual basic? ex. x = Sum(1,2,3) y = Sum(1,2) Function Sum('how to declare argument here') 'Is there any special argument manipulation inside function before it is usable? End Function

    Read the article

< Previous Page | 40 41 42 43 44 45 46 47 48 49 50 51  | Next Page >